Skip to content

Authentication

The API uses OAuth 2.0 client credentials. Exchange your application’s credentials for a token, then send it on each request.

Terminal window
curl -u "$CLIENT_ID:$CLIENT_SECRET" \
-d grant_type=client_credentials \
-d "scope=screens:read campaigns:read campaigns:write" \
https://partner-api.smartcast.media/oauth/token
Terminal window
curl -H "Authorization: Bearer $TOKEN" https://partner-api.smartcast.media/v1/screens

Tokens last 30 minutes. Cache one and fetch a new one shortly before expires_in runs out, or when you get a 401.

Scope Allows
screens:read Screens and availability
creatives:read Reading creatives
creatives:write Uploading creatives
campaigns:read Reading campaigns, pricing plans
campaigns:write Creating, editing, submitting, cancelling
stats:read Stats and reports
Environment Base URL
Live https://partner-api.smartcast.media
Sandbox https://partner-api-sandbox.smartcast.media

Credentials are separate per environment. A sandbox token is refused in live, and the reverse.

Call the API only from your server, never from a browser or mobile app. An application can have two active secrets at once, so you can rotate without downtime.