Client workspaces API

White-label resellers manage client (child) workspaces under their own brand. This API creates them, sets their plan and billing mode, runs trials, and manages membership. Gated on clients.access — the capability designed for this, which an OAuth connector can hold (unlike the admin caps). Available on white-label plans; creating a client needs a user-scoped token (a bearer key or an OAuth connection, not an anonymous one).

List & create

GET  /api/v1/rest/clients
POST /api/v1/rest/clients
{
  "name": "Northwind Auto",
  "billing_mode": "reseller"   // "reseller" (draws your pool) | "self" (client billed directly)
}

You're added as the new workspace's owner automatically, so you can immediately switch into it (pass its id as the workspace argument on any tool) and create agents, trigger crawls, etc.

Get & update

GET   /api/v1/rest/clients/:orgId
PATCH /api/v1/rest/clients/:orgId
{
  "name": "Northwind Auto Group",
  "client_status": "live"      // onboarding | live | paused (a lifecycle label; does not gate activity)
}

Billing, plan & trials

POST   /api/v1/rest/clients/:orgId/billing-mode   { "billing_mode": "self" }
POST   /api/v1/rest/clients/:orgId/plan           { "plan": "growth" }   // tier override, no charge
POST   /api/v1/rest/clients/:orgId/trial          { "minutes": 100, "ends_at": "2026-08-15" }
DELETE /api/v1/rest/clients/:orgId/trial          // end the trial

planis a no-charge tier override (grants the plan's free integrations); starting a trial seeds the client's balance (1 minute = 1 credit) and charges nobody. Real Stripe-billed plan changes stay in the dashboard.

Suspend, detach, membership

POST   /api/v1/rest/clients/:orgId/suspend        { "suspended": true, "reason": "..." }
POST   /api/v1/rest/clients/:orgId/detach         // client becomes standalone; data preserved
GET    /api/v1/rest/clients/:orgId/members
POST   /api/v1/rest/clients/:orgId/members        { "email": "ops@northwind.example" }  // returns an accept URL
DELETE /api/v1/rest/clients/:orgId/members/:memberId
DELETE /api/v1/rest/clients/:orgId/invitations/:inviteId

Use membersto invite yourself (or a teammate) into a pre-existing client you can't otherwise reach. Every operation here is also an MCP tool (create_client, set_client_plan, invite_client_member, …) — see MCP. Full schemas are in the OpenAPI reference.