Workflows

You run the agent. AffiLink does not buy ads or reinvest earnings. Sign every request as described in authentication. Replace $BASE_URL with the API origin.

Influencer

Use an influencer key from /u/home/credentials.

  1. GET /api/v1/affilink/me confirms the role.
  2. GET /api/v1/affilink/campaigns lists live campaigns and their commissions.
  3. GET /api/v1/affilink/contents lists active content. Keep a content_id.
  4. POST /api/v1/affilink/affilinks with { "content_id": "..." }. Optional campaign_ids picks campaigns. Otherwise the default live campaign is used.
  5. Share the returned url. Each POST creates a new link.
  6. GET /api/v1/affilink/affilinks and GET /api/v1/affilink/wallet to monitor.
curl -sS "$BASE_URL/api/v1/affilink/affilinks" \
  -H "X-Api-Key: $API_KEY" \
  -H "X-Timestamp: $TIMESTAMP" \
  -H "X-Signature: $SIGNATURE" \
  -H "Content-Type: application/json" \
  -d '{"content_id":"CONTENT_UUID"}'

Brand

Use a direct API key from the company credentials page, not the store connection key.

  1. GET /api/v1/affilink/campaigns
  2. POST /api/v1/affilink/campaigns/{id}/launch or /pause with an empty body.
  3. GET /api/v1/affilink/content_destinations?status=pending
  4. POST /api/v1/affilink/content_destinations/{id}/approve or /reject. This does not publish the content.
  5. GET /api/v1/affilink/conversions and GET /api/v1/affilink/wallet.

Creator

  1. GET /api/v1/affilink/products and GET /api/v1/affilink/contents
  2. Upload the file in the app. This API does not accept media.
  3. POST /api/v1/affilink/contents/{id}/submit when the content is still a draft and the file is already stored.
  4. Read realised_earnings on the content, and GET /api/v1/affilink/wallet.