VocalDocscontracts 1.65.0

Check one member of a platform key pool with the vendor

POST /v1/platform/credentials/{provider}/{key_id}/verify

PropertyValue
Operationverify_platform_credential
GroupPlatform
Scopeplatform:write
Route classcontrol
IdempotencyIdempotency-Key accepted: a retry with the same key replays the first answer
AuditAudited platform.credential.verify (mutation)
Released in1.41.0
Phase 0 hostServed (the hosted api pins 1.65.0)

Asks the vendor whether it accepts the stored key of one active member of the Provider's key pool and, where the vendor offers an account request, what the account behind it can serve (1.41.0, boards #121 and #135). A key the vendor refuses answers 200 with ok false and account null, and the check changes nothing else; a vendor that does not answer is dependency_unavailable. When the check reads the account, the api stores the reading as the credential's account in the transaction of the Audit event; a refused key or a failed account request leaves the stored account as it was. The secret is never returned, logged or written to the Audit event, which names the Provider, the version and the outcome. A revoked member, or one of another Provider, is not_found. The check never disables a member; an operator does that with PATCH.

Request

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

curl -X POST "$VOCAL_API/v1/platform/credentials/mock/plk_.../verify" \
  -H "Authorization: Bearer $VOCAL_API_KEY" \
  -H "Idempotency-Key: $(uuidgen)"

Parameters

NameInTypeRequiredDescription
providerpathProviderIdyesA Provider: a vendor or in-process model behind a stage. The provider catalog says which stages each serves and whether it is available. From 1.38.0 openai is deprecated (workspace ADR 0085): its descriptors read deprecated, a deprecated Provider still resolves, and the id is kept until a major release; deepseek is new. From 1.53.0 amazon_titan serves embeddings, reserved until its adapter is built.
key_idpathPlatformCredentialIdyesThe id of a platform credential, one member of a Provider key pool: plk_ and the row's UUIDv7 in 26 Crockford base32 characters. Opaque and safe to log.
idempotency-keyheaderstringnoA client-chosen key, kept 24 hours per Organization, environment and route. A replay returns the stored response.

Responses

StatusContent typeShapeError codes
200application/jsonCredentialVerifyResult
400application/jsonErrorEnvelopeinvalid_request
401application/jsonErrorEnvelopeunauthenticated
403application/jsonErrorEnvelopeforbidden
404application/jsonErrorEnvelopenot_found
409application/jsonErrorEnvelopeidempotency_in_progress, idempotency_key_reused
429application/jsonErrorEnveloperate_limited
500application/jsonErrorEnvelopeinternal_error
503application/jsonErrorEnvelopedependency_unavailable

Fields of the 200 answer

The shape is CredentialVerifyResult.

FieldTypeRequiredDescription
accountVendorAccountUsage or nullyesThe account reading the check took; null when the key was refused, when the vendor has no account request or when the account request failed.
checked_atTimestampyesWhen the api asked the vendor.
okbooleanyesTrue when the vendor accepted the key. It says nothing about quota: read account.status for that.