Langdock User Management API
The User Management API from Langdock — 2 operation(s) for user management.
The User Management API from Langdock — 2 operation(s) for user management.
Every API here is available over the APIs.io API and to AI agents over MCP.
One button, every client — Claude, Cursor, VS Code and the rest.
https://apis.io/mcp
find_apisBrowse and filter every API in the catalog.get_api_artifactsOne API's artifacts, grouped by type.get_openapiThe primary OpenAPI for this API.find_similar_apisAPIs that look like this one.apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.resolveTurn a domain, URL or GitHub org into the provider it belongs to.find_cohortsEvery scored population of providers in the catalog.curl "https://apis.io/api/v1/apis/langdock:langdock-user-management-api"
curl "https://apis.io/api/v1/apis?limit=25"
Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.
Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.
A second provider on the same verified email joins the account you already have.
openapi: 3.2.0
info:
title: Langdock User Management API
version: 3.0.0
servers:
- url: https://api.langdock.com
description: Production
security:
- bearerAuth: []
tags:
- name: User Management
paths:
/user-management/v1/invite:
post:
tags:
- User Management
summary: Invite users to workspace
description: 'Sends workspace invitations to one or more users by email. Each user can optionally
be assigned a specific role. If no role is specified, the default role `member` is used.
Users who are already members of the workspace are silently skipped. Users with pending
join requests are automatically approved. Invalid email addresses are reported in the
response but do not cause the entire request to fail.
An invitation email is sent to each successfully invited user. If the workspace does not
have SAML enabled, the email includes a magic link for passwordless sign-in. If SAML and
Allow External Authentication are enabled, users outside the workspace''s verified domains
receive a magic link. SAML remains enforced for users from verified domains.'
parameters: []
requestBody:
required: true
content:
application/json:
schema:
$ref: '#/components/schemas/InviteUsersRequest'
examples:
single_user:
summary: Invite a single user
value:
users:
- email: jane.doe@example.com
multiple_users_with_roles:
summary: Invite multiple users with roles
value:
users:
- email: alice@example.com
role: admin
- email: bob@example.com
role: member
- email: carol@example.com
responses:
'200':
description: Invitations processed successfully
content:
application/json:
schema:
$ref: '#/components/schemas/InviteUsersResponse'
examples:
all_successful:
summary: All invitations sent
value:
status: success
message: Invitations processed
successfulInvites:
- alice@example.com
- bob@example.com
invalidEmails: []
partial_success:
summary: Some emails were invalid
value:
status: success
message: Invitations processed
successfulInvites:
- alice@example.com
invalidEmails:
- not-a-valid-email
'400':
description: Invalid request body
content:
application/json:
schema:
$ref: '#/components/schemas/InviteUsersError'
examples:
missing_users:
summary: Missing or empty users array
value:
message: Invalid request body
errors:
- code: too_small
minimum: 1
type: array
inclusive: true
exact: false
message: Array must contain at least 1 element(s)
path:
- users
invalid_role:
summary: Invalid role value
value:
message: Invalid request body
errors:
- code: invalid_enum_value
options:
- member
- editor
- admin
received: superadmin
message: Invalid enum value. Expected 'member' | 'editor' | 'admin', received 'superadmin'
path:
- users
- 0
- role
'401':
description: Unauthorized - API key is missing, invalid, or the key creator was not found
content:
application/json:
schema:
$ref: '#/components/schemas/InviteUsersError'
'500':
description: Internal server error
content:
application/json:
schema:
$ref: '#/components/schemas/InviteUsersError'
operationId: postUserManagementV1Invite
x-operation-id-source: derived
/user-management/v1/deactivate-user:
post:
tags:
- User Management
summary: Deactivate a workspace user
description: 'Removes a user from the workspace by email. The user immediately loses access,
but all their data (conversations, assistants, files, integrations) is preserved
and restored if they are re-added later.'
parameters: []
requestBody:
required: true
content:
application/json:
schema:
$ref: '#/components/schemas/UserEmailRequest'
examples:
deactivate_user:
summary: Deactivate a user
value:
email: user@example.com
responses:
'200':
description: User deactivated successfully
content:
application/json:
schema:
$ref: '#/components/schemas/UserManagementResponse'
examples:
success:
summary: User deactivated
value:
status: success
message: User deactivated
'401':
description: Unauthorized - API key is missing, invalid, or the key creator was not found
content:
application/json:
schema:
$ref: '#/components/schemas/UserManagementError'
'404':
description: User not found or not an active member
content:
application/json:
schema:
$ref: '#/components/schemas/UserManagementError'
examples:
not_found:
summary: User not found
value:
message: User not found or not an active member
'500':
description: Internal server error
content:
application/json:
schema:
$ref: '#/components/schemas/UserManagementError'
operationId: postUserManagementV1DeactivateUser
x-operation-id-source: derived
/user-management/v1/update-user-role:
post:
tags:
- User Management
summary: Change a member's system role
description: 'Changes an active human member''s workspace system role by email.
Send `member`, `editor`, or `admin`. Custom roles are not part of this endpoint.
The call is authorized by the workspace API key''s `USER_MANAGEMENT_API` scope
and does not run as the person who created the key.'
parameters: []
requestBody:
required: true
content:
application/json:
schema:
$ref: '#/components/schemas/UpdateUserRoleRequest'
examples:
update_role:
summary: Change a member to editor
value:
email: user@example.com
role: editor
responses:
'200':
description: Role updated successfully
content:
application/json:
schema:
$ref: '#/components/schemas/UpdateUserRoleResponse'
examples:
success:
summary: Role updated
value:
status: success
email: user@example.com
role: editor
'400':
description: Invalid role or request body, or the change would leave the workspace without an active admin
content:
application/json:
schema:
$ref: '#/components/schemas/UserManagementError'
examples:
last_admin:
summary: Last remaining admin
value:
code: BAD_REQUEST
message: A workspace must retain at least one active admin.
invalid_role:
summary: Invalid role value
value:
message: Invalid request
errors:
- code: invalid_value
values:
- member
- editor
- admin
path:
- role
message: 'Invalid option: expected one of "member"|"editor"|"admin"'
'401':
description: API key is missing, invalid, or expired
content:
application/json:
schema:
$ref: '#/components/schemas/UserManagementError'
'403':
description: API key is missing the USER_MANAGEMENT_API scope
content:
application/json:
schema:
$ref: '#/components/schemas/UserManagementError'
examples:
insufficient_scopes:
summary: Missing scope
value:
message: Insufficient API key permissions.
error: INSUFFICIENT_SCOPES
details:
required:
- USER_MANAGEMENT_API
missing:
- USER_MANAGEMENT_API
'404':
description: User is not an active human member of this workspace
content:
application/json:
schema:
$ref: '#/components/schemas/UserManagementError'
examples:
not_found:
summary: User not found
value:
code: NOT_FOUND
message: User is not an active member of this workspace
'500':
description: Internal server error
content:
application/json:
schema:
$ref: '#/components/schemas/UserManagementError'
operationId: postUserManagementV1UpdateUserRole
x-operation-id-source: derived
components:
schemas:
UserManagementResponse:
type: object
properties:
status:
type: string
enum:
- success
description: Always "success" when the request is processed
example: success
message:
type: string
description: Human-readable summary of the result
example: User deactivated
required:
- status
- message
InviteUsersError:
type: object
properties:
message:
type: string
description: Error message
example: Invalid request body
errors:
type: array
items:
type: object
description: Detailed validation errors (present on 400 responses)
error:
type: string
description: Additional error details (present on 500 responses)
required:
- message
UpdateUserRoleRequest:
type: object
additionalProperties: false
required:
- email
- role
properties:
email:
type: string
format: email
description: Email address of the active workspace member
example: user@example.com
role:
type: string
enum:
- member
- editor
- admin
description: Workspace system role. Values are lowercase.
example: editor
UserEmailRequest:
type: object
required:
- email
properties:
email:
type: string
format: email
description: Email address of the user
example: user@example.com
InviteUsersRequest:
type: object
required:
- users
properties:
users:
type: array
minItems: 1
description: List of users to invite. At least one user is required.
items:
type: object
required:
- email
properties:
email:
type: string
format: email
description: Email address of the user to invite
example: jane.doe@example.com
role:
type: string
enum:
- member
- editor
- admin
description: Role to assign. If omitted, defaults to `member`.
example: member
UpdateUserRoleResponse:
type: object
properties:
status:
type: string
enum:
- success
description: Always "success" when the role is updated
example: success
email:
type: string
format: email
description: Email address of the updated member
example: user@example.com
role:
type: string
enum:
- member
- editor
- admin
description: System role after the update
example: editor
required:
- status
- email
- role
InviteUsersResponse:
type: object
properties:
status:
type: string
enum:
- success
description: Always "success" when the request is processed
example: success
message:
type: string
description: Human-readable summary of the result
example: Invitations processed
successfulInvites:
type: array
items:
type: string
format: email
description: Email addresses that were successfully invited
example:
- alice@example.com
- bob@example.com
invalidEmails:
type: array
items:
type: string
description: Email addresses that failed deeper validation (e.g., unreachable domain)
example: []
required:
- status
- message
- successfulInvites
- invalidEmails
UserManagementError:
type: object
properties:
message:
type: string
description: Error message
example: User not found or not an active member
required:
- message
securitySchemes:
bearerAuth:
type: http
scheme: bearer
bearerFormat: API Key
description: API key as Bearer token. Format "Bearer YOUR_API_KEY"
x-provenance:
method: harvested
publisher: Langdock
source: https://docs.langdock.com/openapi.yaml
note: split by refine-openapis from the provider's own published document, verified by fetch (openapi/_original/*.fetch.json);
stamped by stamp-openapi-provenance.py (roadmap#793)