code tao
code tao

Reputation: 9

About Amazon Advertising Api

I applied for the use of the Amazon advertising API, but when I created a security profile in the console, I could use the advertising API of the North American station but not the European station. Do I need to resubmit the application form? url returns an unknown scope

Upvotes: 0

Views: 1363

Answers (1)

Alex
Alex

Reputation: 1198

You should use Amazon-Advertising-API-Scope header value which is tied to the EU seller or vendor account.

  1. Use profile endpoint and fetch all profiles which are tied to your current token.
curl --location --request GET 'https://advertising-api.amazon.com/v2/profiles' \
--header 'Amazon-Advertising-API-ClientId: amzn1.application-oa2-client.xxxxxxxxxxxxxxxxxxxxxxxxxxx' \
--header 'Content-Type: application/json' \
--header 'Authorization: Bearer Atza|xxxxxxxxx'

Response:

 {
        "profileId": 390000000000000000,
        "countryCode": "US",
        "currencyCode": "USD",
        "dailyBudget": 0.0,
        "timezone": "America/Los_Angeles",
        "accountInfo": {
            "marketplaceStringId": "AXXXXXXXXXXX",
            "id": "BXXXXXXXXXXXX",
            "type": "seller"
        }
    },

You can see NA(North America) profiles(marketplaces) using this request above. In order to retrieve the EU or FE region profiles(marketplaces), Change the API endpoint.

EU = https://advertising-api-eu.amazon.com/v2/profiles
FE = https://advertising-api-fe.amazon.com/v2/profiles
  1. Use profileId property in Amazon-Advertising-API-Scope header(This header is required. see documentation) for all API requests.

Upvotes: 2

Related Questions