Update token attributes
Partially updates a token: fields left out are unchanged. Only visual_number, issuer, language, valid_until, whitelist and metadata can be changed here. contract_id never changes after create, so sending it is a 422; any other unknown field is ignored. Send null to clear visual_number, language, valid_until or metadata. metadata replaces the stored map and is validated against the tenant TOKEN metadata schema. A tenant without a TOKEN metadata schema cannot store metadata: any non-empty map is a 422. Status changes go through the lifecycle actions.
Requires the emsp:tokens:write scope.
Authorizations
The access token received from the authorization server in the OAuth 2.0 flow.
Headers
Client-generated unique key per operation intent (UUID). Same key + identical body replays the original response; same key + different body returns 409.
Path Parameters
The token id
Body
Send null to clear it
1 - 64Cannot be cleared
1 - 100Preferred language, e.g. en or da. Send null to clear it
2 - 10Send null to remove the expiry
Cannot be cleared
ALWAYS, ALLOWED, ALLOWED_OFFLINE, NEVER Replaces the stored map rather than merging into it, and is validated against the tenant's active TOKEN metadata schema. A tenant without a TOKEN metadata schema cannot store metadata: any non-empty map is a 422. Send null to clear it
Response
The updated token
Canonical schema version
v1 Stable internal token id, commonly a UUIDv7
64Owning tenant, set by the platform
RFID, APP_USER, AD_HOC_USER, EMAID, OTHER Primary credential identifier, unique across every tenant on the platform
50Contract or credential identity, e.g. an eMAID
50Issuer name associated with the credential
100OCPI whitelist policy
ALWAYS, ALLOWED, ALLOWED_OFFLINE, NEVER PROVISIONED, ACTIVE, SUSPENDED, EXPIRED, REVOKED Whether the token has been distributed to whitelist-capable CPO networks
When the token was created in the platform registry
Canonical publication timestamp propagated to roaming partners
Derived from the EMSP identity that issues the token. Null when the registry does not carry it
2Derived from the EMSP identity that issues the token. Null when the registry does not carry it
364Preferred language of the token owner
OCPI token group id used in roaming payloads. Unrelated to Spirii EMSP token groups
50Primary Spirii EMSP token group. A convenience only: membership is many-to-many and is managed through POST /emsp/v1/token-groups/{groupId}/tokens. Null when the registry names no primary group
50Name/value pairs validated against the tenant's active TOKEN metadata schema