Create authentication token for Target profile API via API | Community
Skip to main content
October 27, 2025
Solved

Create authentication token for Target profile API via API

  • October 27, 2025
  • 1 reply
  • 382 views

Hello!

I need help with creation of an authentication token for Target profile update API.
What I did so far:

  1. I've created a project in the dev console and connected Target
  2. I ran a test via https://ims-na1.adobelogin.com/ims/token and created a Bearer token successfully.
  3. But when I now try to use that token with the Target Bulk Profile Update API I get the message "Authentication failed, make sure a valid token is provided" (using http://clientcode.tt.omtrdc.net/m2/CLIENTCODE/v2/profile/batchUpdate with the correct client code of course).

What am I doing wrong? Did I forget a step? When I generate a token in Target settings, everything works perfectly, but the setup is not ideal because this token is only valid for 90 days.

Thank you!
Jan

Best answer by Gokul_Agiwal

Hi @gokul_agiwal,

the endpoint https://mc.adobe.io/{tenant}/target/properties is working well – that is the reason why I'm thinking now, that the authentication endpoint is faulty.

When I try

curl -X POST \ "https://mc.adobe.io/{tenant}/target/authentication/token?authorizationScope=profile_api" \ -H "Authorization: Bearer <token>" \ -H "x-api-key: <API Key>" \ -H "Content-Type: application/json" \

 I get

{ "httpStatus": 500, "requestId": "DBvekhBEvGa3LvEgpSXPZHUwjbFEXc1g", "requestTime": "2025-11-05T11:31:20.017954133Z", "errors": [{ "errorCode": "INTERNAL_SERVER_ERROR.Service", "message": "Internal Server Error", "meta": {} }] }

Same result with GET method. I tested it with postman and my Mac terminal.
I think I need to contact customer care to get this issue resolved.

Thank you guys for your help!


Hi @janp42  Thank you for your response ! 

Yes please raise this with customer care and see what they say. Once you have the outcome please let us know so that we'll get benefit.

Thanks

1 reply

October 28, 2025

Hi Jan,

 

I ran into the exact same issue today - after 4 hours of debugging, it turns out that the documentation isn’t under the “Target APIs” section like you’d expect. Here is the Adobe documentation page with more info.

How Do I Use Profile API Settings to Enable or Disable Batch Updates? | Adobe Target

 

TLDR: The Target Profile API uses a separate authentication token.
You’ll need to retrieve it by going to Target > Administration > Implementation. Scroll down to Profile API - toggle on to "Require Authentication" > Generate and copy Authentication Token. Note: it expires after 90 days.

 

Cheers,

Amy

 

JanP42Author
October 28, 2025

Hey Amy,

thank you. Good to hear that I'm not the only one with that problem.

I am familiar with the documentation – I spent a lot of time there 😅
The page you linked says: "You can also generate a profile authentication token via API. For more information, see “Profiles” in the Adobe Target Admin and Profile API guide."

When I follow the link, I end up in the Adobe Target Admin API documentation. The section "Authentication > Create authorization token" describes the API endpoint for generating a token for the Profiles API ("Retrieve an existing authorization token to use for mbox trace or profile API access.").

First I checked with List properties endpoint -> Everything is fine! Afterwards I tried the Create authorization token endpoint (https://mc.adobe.io/{tenant}/target/properties?authorizationScope=profile_api, with correct tenant), but that ends in 500 Internal Server Error.

😥

Gokul_Agiwal
Community Advisor
Community Advisor
October 31, 2025

Hi @janp42  

Adding my thoughts here - as you already went through documentation. 

 

I hope the URL follow the correct pattern and there is no syntactical error, 

https://mc.adobe.io/{tenant}/target/properties?authorizationScope=profile_api 

{tenant}  need to be replaced by actual name and also you're sending the correct authentication header info. 

 

Quick question - did you try this request in Postman or using Curl command? If no then give a try which shows you the detail feedback in response which tell you what's wrong. 

curl -X GET \ 'https://mc.adobe.io/{tenant}/target/properties?authorizationScope=profile_api' \ -H 'Authorization: Bearer <Access_Token>' \ -H 'x-api-key: <Your_API_Key>' \ -H 'Content-Type: application/json'

Check the response for 500 error... 

let us know how it goes, feel free to post further info. 

 

Thanks