Skip to main content
Install the distribution whose source package is truthlock:
The import is from truthlock import TruthlockClient. Package names for MAIP integrations are separate distributions and do not imply the same API.

Mint with an existing signing key

Set the four environment variables first. Use a sandbox key, issuer, and key available for signing in that environment. Public-key registration does not provision a private signing key.

Verify

Call client.verify.verify_online(attestation_id=record.attestation_id) and inspect the verdict. Add payload_b64url when checking the original bytes. The backend uses uppercase wire verdicts; the corrected SDK normalizes them to its lowercase enum values. Version 0.4.0 and later include the corrected verdict parsing.

Version and retry boundaries

The implemented core resource groups are issuers, keys, attestations, verify, and receipts. Do not call hypothetical consumer, governance, or audit resource methods on this client. Minting generates an idempotency header. Retrying the same internal request can retain it, but calling mint again creates a new operation unless the same key is supplied. Preserve keys and request bodies in durable application jobs. A timeout does not prove that a write failed. Use the HTTP quickstart to compare a release with the actual wire contract. Install version 0.4.0 or later to use the corrected transport and proof-bundle fields.