VocalDocscontracts 1.65.0

Read a case of a decision corpus

GET /v1/agents/{agent_id}/decision-corpora/{corpus_id}/cases/{case_id}

PropertyValue
Operationget_decision_case
GroupDecision corpora
Scopeagents:read
Route classread
IdempotencyNo Idempotency-Key
AuditAn audited content read decision_case.read
Released in1.58.0
Phase 0 hostServed (the hosted api pins 1.65.0)

Answers one case with its state (1.58.0), an audited content read. From 1.59.0 the state of a production case is of the content class transcripts of its Call: an API key needs transcripts:read beside agents:read, and a Member reads it when get_call_content_access answers allowed for that class of the Call; otherwise the read is 403 forbidden with the detail permission_required, class_denied or reveal_grant_required, as the trace route words them.

Request

Set VOCAL_API to the base URL of your API and VOCAL_API_KEY to an API key with the agents:read scope (Authentication and keys). Replace each placeholder, such as agt_... or <name>, with your own value.

curl "$VOCAL_API/v1/agents/agt_.../decision-corpora/dcp_.../cases/dcs_..." \
  -H "Authorization: Bearer $VOCAL_API_KEY"

Parameters

NameInTypeRequiredDescription
agent_idpathAgentIdyesThe id of an Agent: agt_ and the row's UUIDv7 in 26 Crockford base32 characters. Opaque and safe to log.
corpus_idpathDecisionCorpusIdyesThe id of a decision corpus: dcp_ and the row's UUIDv7 in 26 Crockford base32 characters. Opaque and safe to log.
case_idpathDecisionCaseIdyesThe id of one case of a decision corpus: dcs_ and the row's UUIDv7 in 26 Crockford base32 characters. Opaque and safe to log.

Responses

StatusContent typeShapeError codes
200application/jsonDecisionCase
400application/jsonErrorEnvelopeinvalid_request
401application/jsonErrorEnvelopeunauthenticated
403application/jsonErrorEnvelopeforbidden
404application/jsonErrorEnvelopenot_found
429application/jsonErrorEnveloperate_limited
500application/jsonErrorEnvelopeinternal_error

Fields of the 200 answer

The shape is DecisionCase.

FieldTypeRequiredDescription
call_idCallId or nullyesThe Call of a production case; null otherwise.
corpus_idDecisionCorpusIdyes
created_atTimestampyes
expectedmap of DecisionExpectedAnsweryesThe answer expected of each question by id; a question left out is not scored.
idDecisionCaseIdyes
labelled_byActorRefyes
object"decision_case"yes
sourceDecisionCaseSourceyes
stateDecisionStateDocumentyesThe state the questions are asked of; content, read under an audited content read. From 1.59.0 the state of a production case is of the content class transcripts of its Call (the reads of the case say what that asks of the reader); the state of another case is not Call content.
turn_seqinteger or nullyesThe Turn of a production case; null otherwise.