Skip to main content
POST
/
api
/
v1
/
api-key
Error
A valid request URL is required to generate request examples
{
  "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "short_key": "<string>",
  "description": "<string>",
  "key": "<string>",
  "created_at": "2023-11-07T05:31:56Z",
  "read_only": false,
  "last_used_at": "2023-11-07T05:31:56Z",
  "expires_at": "2023-11-07T05:31:56Z",
  "workspace_names": [
    "<string>"
  ],
  "default_workspace_name": "<string>"
}

Documentation Index

Fetch the complete documentation index at: https://docs.langchain.com/llms.txt

Use this file to discover all available pages before exploring further.

Authorizations

X-API-Key
string
header
required

Body

application/json

API key POST schema.

expires_at: Optional datetime when the API key will expire. workspaces: List of workspace UUIDs this key can access (feature-flagged). role_id: Optional UUID of the role to assign to API key. If not provided, uses default role based on read_only flag: - WORKSPACE_ADMIN if read_only is False - WORKSPACE_READER if read_only is True org_role_id: UUID of a org role for org-scoped keys If not provided, defaults to ORG_USER default_workspace_id: UUID of the default workspace for PATs. If not provided, uses the current logic (first available workspace).

description
string
default:Default API key
read_only
boolean
default:false
deprecated
expires_at
string<date-time> | null
workspaces
string<uuid>[] | null
role_id
string<uuid> | null
org_role_id
string<uuid> | null
default_workspace_id
string<uuid> | null

Response

Successful Response

API key POST schema.

id
string<uuid>
required
short_key
string
required
description
string
required
key
string
required
created_at
string<date-time> | null
read_only
boolean
default:false
deprecated
last_used_at
string<date-time> | null
expires_at
string<date-time> | null
workspace_names
string[] | null
default_workspace_name
string | null