Skip to main content

Connect a Pinterest ad account

You connect each Pinterest ad account once. Pinterest asks you to approve Upload-Post's access to your ads, and from then on every Pinterest Ads call can use it.

This connection is separate from the Pinterest account you publish with. It asks only for the ads permissions (ads:read, ads:write, billing:read, biz_access:read, biz_access:write, catalogs:read, user_accounts:read, pins:read, boards:read). Your publishing connection, its permissions and its token are not changed, and you do not need to reconnect it.

  • Authentication: API key, Authorization: Apikey your-api-key-here
  • Base URL: https://api.upload-post.com/api/uploadposts/ads/pinterest
POST /api/uploadposts/ads/pinterest/connect
NameTypeRequiredDescription
profile_usernameStringNoLink the ad account to this profile when it connects.
redirect_urlStringNoWhere the Upload-Post dashboard sends the user back after connecting (http/https). It gets grant_id, ad_accounts_count and, when the only ad account was connected right away, ad_account_id. Parameters of yours with those names are replaced.
curl -X POST https://api.upload-post.com/api/uploadposts/ads/pinterest/connect \
-H 'Authorization: Apikey your-api-key-here' \
-H 'Content-Type: application/json' \
-d '{"profile_username": "my-profile", "redirect_url": "https://example.com/ads/done"}'
{
"success": true,
"authorize_url": "https://www.pinterest.com/oauth/?client_id=...&scope=ads:read,ads:write,...&state=pinads....",
"scopes": ["ads:read", "ads:write", "billing:read", "biz_access:read", "biz_access:write", "catalogs:read", "user_accounts:read", "pins:read", "boards:read"],
"expires_in": 3600
}

Open authorize_url in a browser within the hour. Sign in with the Pinterest account that has access to the ad account and approve. Pinterest then sends the browser to the Upload-Post dashboard, which finishes the connection.

  • If the authorization reaches one ad account, it is connected right away.
  • If it reaches several (your own and the ones shared with you through Business Access), pick the one to connect. With redirect_url, the user comes back to your site: read grant_id from the URL and connect the account you want by API.

2. List the connected accounts​

GET /api/uploadposts/ads/pinterest/accounts

Reads Upload-Post only (no Pinterest call). No token is ever returned.

{
"success": true,
"count": 1,
"accounts": [
{
"ad_account_id": "549755885175",
"name": "Acme Ads",
"currency": "EUR",
"country": "ES",
"owner_username": "acme",
"permissions": ["OWNER"],
"default": true,
"reauth_required": false,
"profiles": ["my-profile"],
"scopes": ["ads:read", "ads:write", "billing:read", "..."],
"connected_at": "2026-12-02T10:00:00+00:00"
}
]
}

reauth_required: true means Pinterest no longer accepts the authorization (for example, it was not used for about two months, or access was removed in Pinterest): connect it again.

GET /api/uploadposts/ads/pinterest/account returns the live details of the account in use (one Pinterest call).

Connect another account of the same authorization​

GET  /api/uploadposts/ads/pinterest/grants/{grant_id}/ad-accounts
POST /api/uploadposts/ads/pinterest/accounts

The first call lists every ad account the authorization reaches, with connected. The second connects one:

NameTypeRequiredDescription
grant_idStringYesFrom the connection's return.
ad_account_idStringYesOne of the listed accounts.
profile_usernameStringNoLink it to this profile.
defaultBooleanNoMake it the default account.
curl -X POST https://api.upload-post.com/api/uploadposts/ads/pinterest/accounts \
-H 'Authorization: Apikey your-api-key-here' \
-H 'Content-Type: application/json' \
-d '{"grant_id": "g_9xK2mQ4pT7vR", "ad_account_id": "549755885175", "profile_username": "client-a"}'

Disconnect​

DELETE /api/uploadposts/ads/pinterest/accounts/{ad_account_id}

Removes the ad account from Upload-Post and unlinks it from every profile. With ?profile_username= only that profile is unlinked. Campaigns keep running in Pinterest: pause them first if you want them to stop. Your Pinterest publishing connection is not affected.