PDP API authentication
To access the Price Discovery and Provisioning (PDP) API, you must have the following:
The API credentials provided by your Account Manager.
An API token, generated and placed in the header of your request.
You can create and revoke API tokens using the interactive UI experience available through the OpenTTD Access Management app.
TIP: To change the lifetime of a token or otherwise update it, you need to revoke it, generate a new token, and then replace the tokens in your integration.
Create an API token
You can create tokens with a lifetime range of one week to one year using the OpenTTD access management app.
To generate an API token, complete the following steps:
- Log in with your The Trade Desk account credentials.
- Navigate directly to the OpenTTD Access Management app.
- Click Generate Token / Key. The Generate API Token dialog appears.
- Enter a descriptive name for your token. For example, include the tool name for which it will be used or any other details that will help you distinguish between multiple tokens later.
- In the Application field, select PDP / OpenPath API.
- Select the token lifetime based on your key rotation strategy and integration needs.
- Click Save. A confirmation message appears with an API token.
- Copy the displayed API token, save it to your secrets management system for future reference, and then close the message.
- Include the token as the
TTD-Authvalue in the headers of all API calls that use tokens, for instance, as shown in the following example.
Content-Type: application/json
TTD-Auth: IBqLpJBhK/UnugaMLo56tUittjoBsjG1KCZ0FxxkIoY=
IMPORTANT: Save your API token in your secrets management system, you cannot retrieve or regenerate the same token. If you lose it, you must create a new token.
To change the lifetime of a token or otherwise update it, you need to revoke it, generate a new token, and then replace the tokens in your integration. For details, see Platform authentication.
For details on using your API token, see Making GraphQL API calls.
Check your API token information
To check the creation and expiration dates or the names of your generated API tokens, complete the following steps:
- Log in with your The Trade Desk account credentials.
- Navigate directly to the OpenTTD Access Management app.
TIP: To update a token, you need to revoke it, generate a new token, and then replace the tokens in your integration.
Revoke an API token
If your API token has been compromised, is no longer needed, or needs to be replaced with a new token with a longer or shorter lifetime, you can revoke the token at any time.
To revoke a API token, complete the following steps:
- Log in with your The Trade Desk account credentials.
- Navigate directly to the OpenTTD Access Management app.
- Find the row with the name of the token you want to revoke, then in the Actions column on the far right, click Revoke. A confirmation message appears.
- Verify that you've selected the correct token and click Continue.
- Update the integration where the token was used as needed (for example, by generating a new token and replacing the old one in the integration).
FAQs
The following is the most commonly asked question about generating tokens.
When generating an API token, what do I do if the Application option I need to select is unavailable?
Contact your Technical Account Manager for assistance.