Create a client company

Create a client company attached to your reseller account

Recent Requests
Log in to see full request history
TimeStatusUser Agent
Retrieving recent requests…
LoadingLoading…

Example payload

name, trial_end and company_setting.license_category are required. trial_end is a Unix timestamp in seconds: the company starts a Leexi trial until that date, or is created with an ended trial when the date is in the past.

{
    "name": "New Client",
    "reseller_external_id": "CLIENT-9",
    "trial_end": 1767222000,
    "company_setting": { "license_category": "business" },
    "setting": { "locale": "fr-FR", "time_zone": "Europe/Paris" },
    "admin": { "name": "Jane Doe", "email": "[email protected]" }
}

The company is created under your reseller account with its settings and the license you choose among free, starter, ai_meeting and business: an unknown or missing license answers 422, and so does an unknown subscription_interval, subscription_currency, setting.locale or setting.time_zone.

First admin

admin is optional. When you send it, the same call creates a team named Default and the admin in it, as super admin with the license of the company, and sends them the welcome email to set their password ("send_welcome_email": false skips it). The admin is checked before anything is created, so a refused admin leaves no company behind:

  • a missing admin.name or admin.email answers 400,
  • an invalid or undeliverable email answers 400,
  • an email already used by a Leexi user answers 409. A duplicate reseller_external_id answers 409 too: only the message tells them apart.

The response returns the company only: read the admin with the client users endpoint, GET .../companies/{company_uuid}/users.

Without admin, the company has no team yet: create one with the client teams endpoints before adding users.

📘

Requires the write_clients permission scope on the API key of a reseller account.

❗️

reseller_external_id must be unique among your client companies: a duplicate answers 409.

Body Params
admin
object

First user of the client company, created in the same call as its super admin in a team named Default, with the license of the company. Nothing is created when the admin is refused. The response returns the company only: read the admin with the client users endpoint. An email already used answers 409, like a duplicate reseller_external_id: only the message tells them apart.

company_setting
object
required
string

Industry of the client company.

string
required

Name of the client company. Must not contain # or _.

string

Your own reference for this client company. Must be unique among your client companies.

setting
object
string

Billing currency, for example eur. Locked while a Stripe subscription is active.

string
enum

Billing interval, month or year.

Allowed:
integer
required

End of the Leexi trial as a Unix timestamp (seconds). Required. A date in the past creates the company with an ended trial.

Responses

401

401

402

402

429

429

Language
Credentials
Header
LoadingLoading…
Response
Click Try It! to start a request and see the response here! Or choose an example:
application/json