Operator API: add partners from your system
Create partners from your own website when they buy, without entering the panel.
With the API you can add partners from your web: one call to POST /api/v1/partner/resellers with their name, email, and tier. It only works if your account is Unlimited, just like on the screen.
You use the same master key as for creating customer accounts: the one from Developers in your operator panel, which is the same one you see here. There's no separate operator key; what tells one thing from the other is the endpoint.
In the response we send you back the partner's id, their signup link, and whether the email went through. From there the signup goes as if you'd created it from the panel: the partner enters their link, fills in what's missing, and connects their domain.
There's no endpoint to list or check partners: you look at that in your panel, in Partners. And on this screen you see how many calls were made with your keys and which ones failed.
What you can do
- Create a partner from your web when they buy, with their tier: Starter, Growth, or Unlimited.
- Get back in the response their signup link, to take them there from your own page.
- Know whether the signup email went through.
- See in the panel the activity of your keys and the latest failures.
What you do with each key
| For what | With what |
|---|---|
| Add a partner | POST /api/v1/partner/resellers with your master key. Only with an Unlimited account. |
| Create and manage customer accounts | The endpoints at /api/v1/partner/accounts, with the same master key. See the operator API. |
| The contacts, conversations, catalog, and appointments of an account | That account's API, with its own key. The owner of that account creates it. |
Add a partner
curl -X POST https://platform.chatlevel.ai/api/v1/partner/resellers \
-H "X-ACCESS-TOKEN: tu_master_key" \
-H "Content-Type: application/json" \
-d '{
"name": "Agencia Norte",
"contactEmail": "hola@agencianorte.com",
"type": "NORMAL"
}'
# type: STARTER (Starter), NORMAL (Growth) o WHITELABEL (Unlimited)
# → { "status": 201, "id": "…", "paymentUrl": "…", "emailSent": true }An example
Sell partners from your landing
- Someone wants to resell your platform and leaves their details on your web.
- Your server calls POST /partner/resellers with their name, email, and the tier they bought.
- They get the email with their signup link, and your web also takes them there with the link from the response.
- From that link they finish the signup, set up their DNS, and register their domain.
- When it's verified, they get their access and log in through their own address, with their brand.
Recommendations
- Start with GET /partner/me to confirm the key is right and which account it belongs to.
- Call from your server, never from the browser: the master key gets into all your accounts.
- After creating it, also send them the DNS record in writing yourself: that's where everyone gets stuck.
Watch out for this
- Only an Unlimited account can create partners through the API. With Starter or Growth it responds 403, just like the screen won't let you.
- This screen is seen by the panel owner and anyone on your team who has the Developers section. Everyone else doesn't see it in the menu and can't enter by typing the address, because with these keys you get into all your accounts.
- If your operator account is suspended or cancelled, it won't let you create partners either.
- An email that's already from another partner can't be used: the call fails and nothing gets created.
- There's a cap on signups in a row: 10 per hour and 40 per day with the same key from the same address. Past that it responds 429 and tells you when to try again.
- There's no endpoint to list or check partners: only to add them.
- With this same key you create accounts and partners, and both things cost money. If it leaks, delete it in your panel and make a new one.
