Create an assistant
Creates an assistant. Its knowledge mode chooses what it reads, one mode at a time: every workspace resource (all), chosen resource_ids (selected), or every resource carrying one of follow_tags (tags).
POST/v1/assistants
Requires assistants:write.
Creating an assistant is free. Asking it questions is not: see Ask an assistant.
knowledge decides what it reads: all, selected (the resource_ids) or tags (the follow_tags). When you omit it, Lookio infers tags if you sent only tags and selected otherwise. Send all to read every resource.
A resource id that does not exist fails with resource_not_found. An API key limited to specific assistants cannot create new ones and gets permission_denied.
Send an Idempotency-Key header so a retried request does not create two assistants. See Assistants.
Authorizations
Authorizationbearerin headerrequiredHeader parameters
Idempotency-Keystringlength: 1–255 charsA unique key for this request, such as a UUID, 1 to 255 visible ASCII characters. Send the same key when you retry: the first response is returned (with Idempotent-Replayed: true) instead of running the request again, for 24 hours, per credential. The same key on a different request is a 409 conflict. A streamed answer is not recorded.
Body
application/jsonrequirednamestringrequiredlength: 1–120 charscontextstringdefault: ""length: ≤ 12000 charsWhat the assistant is and who it talks to: its role and its audience.
output_guidelinesstringdefault: ""length: ≤ 12000 charsHow answers are written: length, format, language.
resource_idsstring[]default: []items: ≤ 200 itemsThe resources it answers from.
follow_tagsstring[]items: ≤ 30 itemsTags it follows when knowledge is tags: every resource carrying one, now or later, is used (one knowledge mode applies at a time).
knowledgeenum<string>one of: all, selected, tagsOmit to infer it: tags when only tags are given, otherwise selected. Send all to read every resource.
Response
Create an assistant
dataobjectrequiredrequest_idstringrequiredPossible codes: invalid_request, unknown_field, invalid_parameter, invalid_cursor
errorobjectrequiredrequest_idstringrequiredPossible codes: authentication_required, invalid_api_key, api_key_expired, api_key_revoked, invalid_access_key
errorobjectrequiredrequest_idstringrequiredPossible codes: insufficient_scope, feature_not_available, admin_required, permission_denied
errorobjectrequiredrequest_idstringrequiredPossible codes: resource_not_found
errorobjectrequiredrequest_idstringrequiredPossible codes: conflict, assistant_has_no_resources
errorobjectrequiredrequest_idstringrequiredPossible codes: request_too_large
errorobjectrequiredrequest_idstringrequiredPossible codes: rate_limited
errorobjectrequiredrequest_idstringrequiredPossible codes: internal_error
errorobjectrequiredrequest_idstringrequired