Update AI copilot
Changed onThis endpoint updates an existing AI copilot's configuration. Corresponds to liveblocks.updateAiCopilot.
This endpoint returns a 422 response if the update doesn't apply due to validation failures. For example, if the existing copilot uses the "openai" provider and you attempt to update the provider model to an incompatible value for the provider, like "gemini-2.5-pro", you'll receive a 422 response with an error message explaining where the validation failed.
Request
- Base URL: https://api.liveblocks.io/v2
- URL: https://api.liveblocks.io/v2/ai/copilots/{copilotId}
- Auth: none declared
Path parameters
ID of the AI copilot
Request body
Example request
{
"name": "Updated Copilot",
"systemPrompt": "You are an updated helpful assistant.",
"providerModel": "gpt-4o",
"settings": {
"maxTokens": 8192
}
}Response
Success. Returns the updated AI copilot.
Example response
{
"type": "copilot",
"id": "cp_abc123",
"name": "My Copilot",
"systemPrompt": "You are a helpful assistant.",
"alwaysUseKnowledge": true,
"createdAt": "2024-06-01T12:00:00.000Z",
"updatedAt": "2024-06-01T12:00:00.000Z",
"provider": "openai",
"providerModel": "gpt-4o",
"settings": {
"maxTokens": 4096,
"temperature": 0.7
}
}Changes
- warning
added the new
claude-opus-4-5-20251101enum value to the//response property for the response status - warning
added the new
claude-opus-4-6enum value to the//response property for the response status - warning
added the new
claude-opus-4-7enum value to the//response property for the response status - warning
added the new
claude-sonnet-4-6enum value to the//response property for the response status - warning
added the new
gemini-3-flash-previewenum value to the//response property for the response status - warning
added the new
gemini-3.1-pro-previewenum value to the//response property for the response status - warning
added the new
gpt-5-proenum value to the//response property for the response status - warning
added the new
gpt-5.2enum value to the//response property for the response status - warning
added the new
gpt-5.2-proenum value to the//response property for the response status - warning
added the new
gpt-5.4enum value to the//response property for the response status - warning
added the new
gpt-5.4-minienum value to the//response property for the response status - warning
added the new
gpt-5.4-nanoenum value to the//response property for the response status - warning
added the new
gpt-5.4-proenum value to the//response property for the response status - warning
added the new
gpt-5.5enum value to the//response property for the response status
- warning
- breaking
request body became required
- breaking
the request property
became not nullable - breaking
the request property
became not nullable - breaking
the request property
became not nullable - breaking
the request property
became not nullable - breaking
the request property
became not nullable - breaking
removed
subschema #1subschema #2subschema #3from therequest propertyoneOflist - breaking
the
request property type changed fromobjectto no type - breaking
added to the response body
oneOflist for the response status - warning
removed the request property
/ - warning
removed the request property
/ - warning
removed the request property
/ - warning
removed the request property
/ - warning
removed the request property
/ - warning
removed the request property
/ - warning
removed the request property
/ - warning
removed the request property
/ - warning
removed the request property
/ - info
request property
list-of-types was widened by adding typesnullto media typeapplication/json - info
request property
list-of-types was widened by adding typesnullto media typeapplication/json - info
added
subschema #2to therequest propertyoneOflist - info
added
subschema #4to therequest propertyoneOflist - info
added
openaianthropicgoogleopenai-compatiblemapping keys to the response discriminator for the response status - info
removed
subschema #1subschema #2subschema #3subschema #4from the response bodyoneOflist for the response status
- breaking