Response signature
The API can generate JWS tokens instead of JSON responses.
This may be useful if you or one of your clients needs to assert
the data's origin,
which request was used exactly,
the timestamp the request was executed at.
Get signed responses
To get a signed response, add the following query parameter to your request:
sign_response=trueToken format
As any JWS, the structure is header.payload.signature, where
headeris a base64-encoded JSON with information about the signature process (see Verify token signature),payloadis a base64-encoded JSON with the following structure:{ "request_url": ..., "response_timestamp": ..., "response_payload": ..., }signatureis a base64-encoded bytes section.
Verify token signature
Get the
key_urlin the header,Fetch the key (see Get a key),
Check if the
deprecatedfield isnull,Use the
public_keyfield to check the signature using your favorite JWS library.
Keys resource
List keys
The list of past and present keys can be obtained at
/sign-keysGet a key
GET /sign-keys/{key_id}Keys format
id
Number
ID of the key.
public_key
String
PEM of the public key.
deprecated
DateTime or null
If set, this key is deprecated and any signature using it should not be trusted.
Last updated
Was this helpful?