Receipts
Verify a signed receipt
Checks a receipt from any analyze or lookup response. No API key, free, limited to 60 requests per minute per IP. It never reads our database, so anyone can reproduce the answer with the public key set at /.well-known/phototology-keys.json.
- signature: the detached ES256 JWS over the RFC 8785 canonical payload, checked against the key set. unknown_key when the key id is not published.
- timestamp: the RFC 3161 token, checked against SHA-256 of the signature and the pinned time-stamping authority roots, and the receipt's timestamp.time checked against the time inside the token (to the second; a different or missing time is invalid). pending and unavailable pass through from the receipt.
- timestampedAt: the time read from the token when the timestamp is valid, else null.
- valid: true when the signature is valid and the timestamp is valid, pending or unavailable.
A sandbox receipt (pt_test_ keys) reads { valid: true, livemode: false, keyId: "sandbox" }: it proves the integration works and nothing about any photo. A valid signature proves we issued the receipt; payload.registry.url says whether we kept the analysis, and answers only for the API key of the account the receipt was issued to (Bearer required).
post/v1/verify
Request
- Base URL: https://api.phototology.com
- URL: https://api.phototology.com/v1/verify
- Auth: none required
Request body
Response
The verification result.
Changes
No recorded changes to this operation across all 1 revision of this API.