tebarDocs
GuideDevelopersAPI ReferenceChangelog

Connect links

Let clients connect their own social accounts to one of your profiles, without a Tebar account.

A connect link is a one-time link to a Tebar page where your client logs in to a platform (Instagram, Threads, TikTok, and others) and grants access. The account goes into the profile you chose, then the client is sent back to your app. The client needs no Tebar account and never sees your dashboard.

1. Allow your app's domain

Clients can only be sent back to domains you have registered. Register them once, in the dashboard (Integrations → Redirect domains) or through the API:

curl -X POST https://api.tebar.app/v1/connect/redirect-origins \
  -H "Authorization: Bearer tb_live_xxx" -H "Content-Type: application/json" \
  -d '{ "origin": "https://app.example.com" }'

Also set the name shown on the connect page ("Connect your account to …") under Integrations → Display name, or with PATCH /v1/connect/settings { "brand_name": "Your Agency" }.

curl -X POST https://api.tebar.app/v1/profiles/client-42/connect-links \
  -H "Authorization: Bearer tb_live_xxx" -H "Content-Type: application/json" \
  -d '{ "redirect_url": "https://app.example.com/tebar/done", "state": "session-abc123" }'
{
  "url": "https://publish.tebar.app/connect/s/1z35fNMp…",
  "profile_id": "9d09…",
  "expires_at": "2026-10-20T12:30:00.000Z"
}
  • {id} in the path can be the profile ID or its external_id.
  • state (optional) comes back as is, handy to match the client in your system.
  • platforms (optional), for example ["instagram", "tiktok"], limits which platform buttons show.
  • A link is valid for 30 minutes and can only be used once. Create a new link every time a client wants to connect an account.

In the dashboard, links can be created from Connect account → Is the account signed in on another phone or computer?, or from the ⋯ menu on a profile → Create a connect link. Without redirect_url, the client ends on Tebar's own finish page ("Account connected"), so no redirect domain needs registering.

Treat the link like a key

Anyone who opens the link can connect their account to that profile. Only send it to clients who are logged in to your app, and never put it on a public page.

3. Receive the client back

When done, the client is sent to redirect_url with extra query parameters:

https://app.example.com/tebar/done?status=connected&profile_id=…&account_ids=…&state=session-abc123

If it failed or was canceled:

https://app.example.com/tebar/done?status=error&error=access_denied&state=session-abc123
errorMeaning
access_deniedThe client canceled on the platform's permission page
permission_missingThe client did not tick every permission needed
account_in_other_profileThe account is already connected in another of your profiles
plan_account_limitYour plan's account limit is full
expiredThe link expired before the client finished

A failed link can be tried again until it expires.

Always check again through the API

The query in the URL can be changed by anyone holding it. Make sure the account is really connected with GET /v1/accounts and the Tebar-Profile header, or with the account.connected webhook.

Facebook

A Facebook login can grant access to several Pages at once. The client then chooses which Pages to connect on the same Tebar page, and every chosen Page goes into that profile.

The connect page is shown in English or Indonesian following the client's browser language.

On this page