API Reference Card
All examples use three environment variables:
TIKTOK_ACCESS_TOKEN, TIKTOK_ADVERTISER_ID, and MAVERA_API_KEY. TikTok tokens are long-lived but can be revoked. Store them in your secrets manager.Prerequisites
1
TikTok for Business account
Register at TikTok for Business. Create or link an ad account with active campaigns.
2
Marketing API access
Apply for API access at TikTok Marketing API. Obtain your App ID, Secret, and complete the OAuth flow.
3
Mavera API key
Get your key from Mavera dashboard.
4
Environment variables
export TIKTOK_ACCESS_TOKEN="...", export TIKTOK_ADVERTISER_ID="...", and export MAVERA_API_KEY="mvra_live_xxxxx"Jobs
Rate Limits & Production Notes
Checklist: Store tokens in env vars or secrets manager. TikTok tokens are long-lived but verify with
GET /oauth2/token_info/. Handle pagination via page and page_size params. Monitor X-TT-RateLimit-Remaining headers. Compress video before Mavera upload. Cache TikTok data for daily analysis runs. Monitor Mavera credits at Dashboard.