Skip to main content
POST
Set plans for 1 to 500 users
List active human members, change a plan, and set the extra usage budget beyond the included allowance. Amounts are US dollars. The calls use the workspace API key’s BILLING_API scope. Writes run as the key’s service account owner. This API does not invite or deactivate members. Use the User Management API for that.

Base URL

Dedicated deploymentsReplace api.langdock.com with <your-deployment-url>/api/public in all requests.

Prerequisites

  • API key with the BILLING_API scope
  • The key owner is a service account that has not been deleted and has an active Admin membership
  • USER_MANAGEMENT_API on the same key when you need email, name, or an email filter

Change plans in bulk

POST /users/plan/bulk sets one plan for 1 to 500 member ids.
Repeated ids count once. If any id is not an active human member of the workspace, the call returns 400 with those ids in details.userIds and changes nothing. Members already on the plan are listed in alreadyOnPlanUserIds and stay unchanged. Usage requests follow the same rules as a single plan change: power_user closes linked pending requests, and standard closes none.
Langdock intentionally blocks browser-origin requests to protect your API key and ensure your applications remain secure. For more information, please see our guide on API Key Best Practices.

Authorizations

Authorization
string
header
required

API key as Bearer token. Format "Bearer YOUR_API_KEY"

Body

application/json
userIds
string<uuid>[]
required
Required array length: 1 - 500 elements
plan
enum<string>
required
Available options:
standard,
power_user

Response

Successful response.

plan
enum<string>
required
Available options:
standard,
power_user
updatedUserIds
string<uuid>[]
required
alreadyOnPlanUserIds
string<uuid>[]
required