r2.1
Pre-release
Pre-release
Release Notes
This release candidate contains the definition and documentation of
- knowledge-base 0.2.0-rc.1
- qa-assistant-manage 0.2.0-rc.1
- qa-assistant-service 0.2.0-rc.1
The API definition(s) are based on
- Commonalities 0.8.0
- Identity and Consent Management 0.5.0
knowledge-base 0.2.0-rc.1
knowledge-base 0.2.0-rc.1 is a release-candidate version of this API.
Changes documented below are compared to version 0.1.0.
- API definition with inline documentation:
Breaking changes
- API-specific error codes renamed to align with the Commonalities
{{API_NAME}}.{{SPECIFIC_CODE}}format (issue #38). The API name isknowledge-base, so all API-specific codes are now prefixed withKNOWLEDGE_BASE.and the specific code is a single SCREAMING_SNAKE_CASE token:TOOL.INVALID_INPUT->KNOWLEDGE_BASE.TOOL_INVALID_INPUTTOOL.DISABLED->KNOWLEDGE_BASE.TOOL_DISABLEDTOOL.EXECUTION_FAILED->KNOWLEDGE_BASE.TOOL_EXECUTION_FAILEDTOOL.TIMEOUT->KNOWLEDGE_BASE.TOOL_TIMEOUT- The renamed codes appear both in the HTTP 422
ToolInvalidInput422response (codeenum) and in the HTTP 200ToolCallResponse.contextCodeenum.
- The
headersfield of a tool is nowwriteOnly: true(issue #41). It is still accepted oncreateToolandupdateToolrequests, but is no longer returned bygetToolorlistTools. This prevents secret-bearing header values (e.g. API keys inX-Api-Key) from being read back by callers holding the broaderknowledge-base:tools:readscope. API consumers MUST NOT rely on reading back stored header values; the platform stores them securely and injects them only when invoking the tool. Theheadersfield example was also updated from the forbiddenAuthorization: Bearer {{token}}toX-Api-Key: '{{apiKey}}'. - The
callTooloperation no longer returns HTTP 429 for upstream tool rate-limiting (issue #44). Upstream tool outcomes - including rate-limit (HTTP 429 from the tool) and failures (HTTP 5xx from the tool) - are now consistently reported through the HTTP 200ToolCallResponseenvelope (success=false,statusCodemirrors the upstream status,contextCodeidentifies the reason, e.g.KNOWLEDGE_BASE.TOOL_RATE_LIMITED/KNOWLEDGE_BASE.TOOL_EXECUTION_FAILED), per the business-outcome modelling in CAMARA API Design Guide §3.1. The500response is retained only for platform-internal errors, not upstream failures. API consumers that relied on HTTP 429 to detect upstream rate-limiting MUST instead inspect the 200 envelope'scontextCode. - Removed
KNOWLEDGE_BASE.TOOL_INVALID_INPUTandKNOWLEDGE_BASE.TOOL_DISABLEDfrom theToolCallResponse.contextCodeenum (issue #45). These two conditions (semantically invalid arguments, disabled tool) are now reported exclusively through HTTP 422ToolInvalidInput422(pre-invocation checks), while thecontextCodeenum is reserved for outcomes of the actual upstream tool invocation (KNOWLEDGE_BASE.TOOL_EXECUTION_FAILED,KNOWLEDGE_BASE.TOOL_TIMEOUT,KNOWLEDGE_BASE.TOOL_RATE_LIMITED). This gives each condition exactly one response channel, so implementations cannot choose between 422 and the 200 envelope for the same condition. API consumers that inspected the 200 envelope'scontextCodefor these two values MUST instead handle the HTTP 422 response. - The
uploadDocument201 response body is replaced by aDocumentresource (issue #48). The previous body was a{ "message": "Document uploaded successfully" }confirmation object with no identifier; the new body is theDocumentschema (documentId,knowledgeBaseId,filename,format,uploadDate,status). ALocationresponse header pointing atGET /knowledge-bases/{knowledgeBaseId}/documents/{documentId}is also added. API consumers that read themessagefield MUST update to the newDocumentbody; consumers that needed a handle to the uploaded document now usedocumentId/Location.
Added
- New API-specific context code
KNOWLEDGE_BASE.TOOL_RATE_LIMITEDadded to theToolCallResponse.contextCodeenum, aligned with the renamed format and the existing test assertion for upstream rate-limit outcomes (issue #38). - Documented the intended tool usage model in the
createToolandcallTooloperation descriptions: tools registered under a knowledge base may be associated with a Q&A assistant viaqa-assistant-manage, and the assistant's LLM may invoke them automatically during answer generation;callToolis the API consumer-facing execution channel for testing a registered tool through the platform's execution path before associating it with an assistant (issue #39). - Documented security considerations for server-side outbound requests to tool URLs (callTool and LLM-initiated tool invocations): the API provider MUST enforce SSRF protections - URL scheme restricted to
https, destination address blocklist (private/loopback/link-local ranges and cloud metadata endpoints), port allow-list, no redirect following unless re-validated, bounded response size and timeouts. Theurlfield is constrained tohttpsvia apatternand its description references the security constraints; thecallTooldescription reiterates the security note (issue #40). - Documented the tool call authentication model in the
headersfield description and thecallTooloperation description (issue #42): credentials for authenticating the outbound tool call to the upstream tool MUST be supplied through non-reserved custom headers (e.g.X-Api-Key,X-Auth-Token) and MUST NOT be placed in the reservedAuthorizationheader; excludingAuthorizationis deliberate (the platform may need to set it itself, and consumer-supplied values would create an ambiguity). BecauseheadersiswriteOnly(see issue #41), credentials are accepted on write and never returned on read. A structured credential model (e.g. the CAMARAsinkCredentialpattern) is not adopted in this API version; it may be evaluated for a future release. - Documented HTTP 409 responses for
createKnowledgeBase,createToolandupdateTool(issue #46):createKnowledgeBaseandcreateToolreturn409 ALREADY_EXISTSwhen thenameviolates the documented uniqueness rule;updateToolreturns409 ABORTEDon concurrent modification. Both codes are standard CAMARA error codes already present inGeneric409. This aligns the API definitions with the existing test scenarios@knowledge_base_tool_create_409_01_duplicate_nameand@knowledge_base_tool_update_409_01_concurrent_modification. - Modelled documents as a sub-resource of the knowledge base, with their own identifier and lifecycle (issue #48):
- New
Documentschema (documentId,knowledgeBaseId,filename,format,uploadDate,status) shared by theuploadDocument201 response, the newgetDocument200 response, and theKnowledgeBase.documentsembedded array (the array items now$refthe sameDocumentschema, so the three representations are consistent). - New
statusfield on documents (PROCESSING/READY/FAILED) reflecting asynchronous indexing; only documents withstatus = READYparticipate in answer generation viaqueryAssistanton theqa-assistant-serviceAPI. - New
GET /knowledge-bases/{knowledgeBaseId}/documents/{documentId}(getDocument) andDELETE /knowledge-bases/{knowledgeBaseId}/documents/{documentId}(deleteDocument) operations. - New scopes
knowledge-base:documents:readandknowledge-base:documents:delete. uploadDocument201 response now returns aDocumentresource and aLocationheader (see Breaking changes above).
- New
- Documented the partial-update semantics of the PUT update operations
updateKnowledgeBaseandupdateTool(issue #50). The operation and*UpdateRequestschema descriptions now state explicitly that omitted fields are left unchanged (not cleared), that providing a field replaces its stored value, and that at least one updatable field MUST be provided. ForupdateTool, theheadersfield (writeOnly, issue #41) behaviour is also clarified: providingheadersreplaces the stored headers as a whole, while omittingheaderspreserves the previously stored headers (so an API consumer can update other fields without re-supplying credentials). This is a documentation-only change; the request/response structure and HTTP method (PUT) are unchanged. CAMARA API Design Guide §5.7.2 permits eitherPUTorPATCHfor update operations, soPUTwith documented partial-update semantics is retained.
Changed
- API-specific error codes renamed to the
KNOWLEDGE_BASE.<SPECIFIC_CODE>format defined in the CAMARA API Design Guide. This is a breaking change (see Breaking changes above). Renamed codes:TOOL.INVALID_INPUT->KNOWLEDGE_BASE.TOOL_INVALID_INPUT,TOOL.DISABLED->KNOWLEDGE_BASE.TOOL_DISABLED,TOOL.EXECUTION_FAILED->KNOWLEDGE_BASE.TOOL_EXECUTION_FAILED,TOOL.TIMEOUT->KNOWLEDGE_BASE.TOOL_TIMEOUT(issue #38). - The
headersfield of a tool is nowwriteOnly: true. This is a breaking change (see Breaking changes above).createToolandupdateToolstill accept the field;getToolandlistToolsno longer return it (issue #41). - The
headersfield example corrected from the forbiddenAuthorization: Bearer {{token}}(self-contradictory with the reserved-header list) to a non-credential exampleAccept-Language: en-US, so the example no longer presupposes that credentials belong inheaders(issue #42). callToolupstream response behaviour unified to the HTTP 200 envelope (issue #44). This is a breaking change (see Breaking changes above). The429response was removed; upstream rate-limit and upstream failures are reported via the 200ToolCallResponseenvelope (success=false,statusCode,contextCode). The500response is retained only for platform-internal errors. The operation description's Response Characteristics clarify this.- Removed
KNOWLEDGE_BASE.TOOL_INVALID_INPUTandKNOWLEDGE_BASE.TOOL_DISABLEDfrom theToolCallResponse.contextCodeenum. This is a breaking change (see Breaking changes above). These conditions are now reported exclusively via HTTP 422ToolInvalidInput422(pre-invocation checks);contextCodeis reserved for upstream invocation outcomes (issue #45). - Marked
itemsandpaginationasrequiredin thelistKnowledgeBasesandlistTools200 response schemas, per CAMARA API Design Guide §4.1.3 which states that both MUST always be present in a paginated response body (issue #47). This is not a breaking change: the response structure is unchanged, only the contract is made explicit. (Note: theperPagequery parameter description incode/common/CAMARA_common.yamlreads "Number of subscriptions to return per page", which is a Commonalities-ownedcache-commonfile that this repository must not modify; that wording originates from Commonalities r4.3 and is to be raised upstream.) - All CAMARA common components (
securitySchemes.openId,x-correlatorparameter/header,page/perPageparameters,ErrorInfoschema,DateTimeschema,Paginationschema, and theGeneric4xx/Generic5xxresponse objects) are now referenced via external$reftocode/common/CAMARA_common.yamlinstead of being copied inline into each API definition (issue #37). This aligns with the Commonalitiescache-commongovernance: the common file is owned by the Commonalities Working Group and must be byte-identical to the upstream release; the API repository only$refs it. Test definitions reference the same components via local$ref(e.g.#/components/schemas/Pagination), matching the local references that result from the release bundling process. No public API surface change.
Fixed
- Removed
additionalProperties: falsefrom theallOfinline branch ofToolCreateRequestandToolUpdateRequest. In OpenAPI 3.0,additionalPropertiesdoes not propagate throughallOf, so afalsevalue on a branch with no own properties rejected every property (including requiredname/url), making the request schemas unsatisfiable for strict validators. Request body strictness for these composed schemas is now enforced by therequest-body-strictnessrule ininfo.description, as required by CAMARA API Design Guide §2.3 (issue #43).
Removed
- N/A
qa-assistant-manage 0.2.0-rc.1
qa-assistant-manage 0.2.0-rc.1 is a release-candidate version of this API.
Changes documented below are compared to version 0.1.0.
- API definition with inline documentation:
Breaking changes
- The
createAssistant201 response and theupdateAssistant200 response no longer return theAssistantResponseenvelope{ success, assistantId, message }; they now return the created/updatedAssistantresource itself (issue #49). This alignsqa-assistant-managewithknowledge-base, wherecreateKnowledgeBase/createTool/updateToolalready return the resource itself. TheAssistantResponseschema is removed. API consumers that read the envelope'ssuccess/assistantId/messagefields MUST update to read the corresponding fields on theAssistantresource (assistantIdis now a property ofAssistant; thesuccessboolean andmessagestring are no longer returned). - The
largeModelParametersschema is flattened: the intermediateparametersobject is removed andmodel,temperature,maxTokens(andtopP) are now direct properties oflargeModelParameters(issue #52). API consumers that referencedlargeModelParameters.parameters.temperature(etc.) MUST update tolargeModelParameters.temperature. The change applies toAssistantCreateRequest,AssistantUpdateRequest, andAssistantconsistently.
Added
- Documented the intended tool usage model in the
toolIdsfield description: tools associated with an assistant viatoolIdsmay be invoked automatically by the assistant's LLM during answer generation (viaqueryAssistanton theqa-assistant-serviceAPI), turning the assistant into an agent that can take actions to ground or enrich its answers (issue #39). - Documented the partial-update semantics of the PUT
updateAssistantoperation (issue #50). The operation andAssistantUpdateRequestschema descriptions now state explicitly that omitted fields are left unchanged (not cleared), that providing a field replaces its stored value, and that at least one updatable field MUST be provided. Merge rules for nested objects are also clarified:largeModelParametersis replaced as a whole when provided (nested merge is NOT supported - to change a single parameter the API consumer MUST provide the completelargeModelParametersobject), andtoolIdsis replaced as a whole when provided (overwritten, not appended to). This is a documentation-only change; the request/response structure and HTTP method (PUT) are unchanged. CAMARA API Design Guide §5.7.2 permits eitherPUTorPATCHfor update operations, soPUTwith documented partial-update semantics is retained. - Documented that the hard bounds on
largeModelParameters.temperature(max 1) andmaxTokens(max 128000) are reference defaults and that the provider MAY adjust them to match the supported range of the underlying LLM backend (issue #52). The provider's actual enforced range MUST be documented in the API provider's documentation. Thegpt-4example is retained as an example and is not a constraint.
Changed
- Marked
itemsandpaginationasrequiredin thelistAssistants200 response schema, per CAMARA API Design Guide §4.1.3 which states that both MUST always be present in a paginated response body (issue #47). This is not a breaking change: the response structure is unchanged, only the contract is made explicit. - All CAMARA common components (
securitySchemes.openId,x-correlatorparameter/header,page/perPageparameters,ErrorInfoschema,DateTimeschema,Paginationschema, and theGeneric4xx/Generic5xxresponse objects) are now referenced via external$reftocode/common/CAMARA_common.yamlinstead of being copied inline (issue #37). No public API surface change. createAssistantandupdateAssistantnow return the created/updatedAssistantresource instead of theAssistantResponseenvelope. This is a breaking change (see Breaking changes above). TheAssistantResponseschema is removed (issue #49).- Defined a single behaviour for what happens to an assistant's
toolIdswhen a referenced tool is deleted (issue #51). The previous spec allowed the server to either retain the dangling reference (returning422 KNOWLEDGE_BASE.TOOL_NOT_FOUNDon read) or silently drop it. The spec now mandates the latter (prune): when a tool is deleted viaDELETE /knowledge-bases/{id}/tools/{toolId}on theknowledge-baseAPI, the server MUST silently drop the deleted tool's ID from any assistanttoolIdsthat referenced it, on the next read (getAssistant/listAssistants); reads do NOT return422for a pruned tool. This makes the cross-API contract dependable across implementations: thetoolIdsarray always reflects the currently existing tools. The write-time validation (422 KNOWLEDGE_BASE.TOOL_NOT_FOUND/KNOWLEDGE_BASE.TOOL_CROSS_KBoncreateAssistant/updateAssistant) is unchanged: a tool ID supplied at write time MUST still exist at that moment. ThedeleteTooloperation description on theknowledge-baseAPI documents the cross-API effect.
Fixed
- N/A
Removed
- N/A
qa-assistant-service 0.2.0-rc.1
qa-assistant-service 0.2.0-rc.1 is a release-candidate version of this API.
Changes documented below are compared to version 0.1.0.
- API definition with inline documentation:
Breaking changes
- N/A
Added
- Documented the intended tool usage model in the
queryAssistantoperation description: when the assistant has tools associated viatoolIds(configured throughqa-assistant-manage), the platform's LLM may invoke those tools automatically during answer generation; tool invocation details are not surfaced in theQueryResponsein this API version, and tool failures during generation are reflected in thefinishedstatus rather than HTTP error codes (issue #39). - Added a security note to the
queryAssistantoperation description: LLM-initiated tool invocations cause the API provider's server to send outbound HTTP requests to consumer-registered tool URLs, and the SSRF protections the provider MUST enforce for such outbound calls are documented in the "Security considerations" section of theknowledge-baseAPI (issue #40). - Documented the relationship between
successandfinishedinQueryResponse, per CAMARA API Design Guide §3.1.2 (issue #47). The schema description now includes the full mapping table (STOP/LENGTH->success=true;ERROR/FILTER->success=false), and thesuccess,finishedandanswerTextfield descriptions clarify that the two outcome fields MUST be consistent and thatanswerTextis empty or a short diagnostic string whensuccess=false. ThequeryAssistantoperation description's Response Characteristics section also summarises this relationship. The HTTP status ofqueryAssistantremains200for every value offinished;success=falsedoes not change the HTTP status. - All CAMARA common components (
securitySchemes.openId,x-correlatorparameter/header,page/perPageparameters,ErrorInfoschema,DateTimeschema,Paginationschema, and theGeneric4xx/Generic5xxresponse objects) are now referenced via external$reftocode/common/CAMARA_common.yamlinstead of being copied inline (issue #37). No public API surface change.
Changed
- Clarified in the
queryAssistantoperation description that only documents with indexingstatus = READYin the associated knowledge bases participate in answer generation (issue #48). Documents inPROCESSINGorFAILEDstatus are excluded. This is a documentation-only change; the request/response structure is unchanged.
Fixed
- N/A
Removed
- N/A
Full Changelog: r1.2...r2.1