Protect Content (Consumer Mint)

POSThttps://sandbox-api.truthlocks.com/v1/consumer/mintAuth required

Mint a cryptographic attestation for a piece of content. The consumer's personal issuer and signing key are automatically resolved. The content is hashed client-side (SHA-256) and the hash is submitted along with metadata. Returns the attestation ID, protection record, and shareable proof URL. Rate limited to the consumer's plan tier (Free: 50/mo, Creator: 500/mo, Pro: unlimited).

Body Parameters

content_hashstringrequired

SHA-256 hex digest of the content being protected. Computed client-side.

Defaults to e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855

titlestringrequired

Human-readable title for the protected content.

Defaults to My Photograph

descriptionstring

Optional description of the content.

Defaults to Sunset photo taken in Big Sur, CA

file_namestring

Original file name for reference.

Defaults to sunset-bigsur.jpg

file_sizenumber

File size in bytes.

Defaults to 4521984

content_typestring

MIME type or category of content. Values: file, image, document, audio, video, code, text.

Defaults to image

categorystring

Content category. Values: photography, digital_art, document, music, video, code, writing, design, other.

Defaults to photography

visibilitystring

Visibility for the protection. 'public' makes it visible on your portfolio. Default: 'private'.

Defaults to public

ai_metadataobject

Optional AI-extracted metadata (from /api/ai/extract) to store alongside the protection.

Defaults to {}

Responses

{
  "protection_id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
  "attestation_id": "b2c3d4e5-f6a7-8901-bcde-f12345678901",
  "verify_url": "https://verify.truthlocks.com/proof/b2c3d4e5-f6a7-8901-bcde-f12345678901",
  "share_url": "https://verify.truthlocks.com/proof/b2c3d4e5-f6a7-8901-bcde-f12345678901"
}
POST/v1/consumer/mint
Language
CredentialsHEADER
Authorization
cURL Request
Examples ▾
curl --request POST \
  --url https://sandbox-api.truthlocks.com/v1/consumer/mint \
  --header 'accept: application/json' \
  --header 'content-type: application/json' \
  --data '{
  "content_hash": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",
  "title": "My Photograph",
  "description": "Sunset photo taken in Big Sur, CA",
  "file_name": "sunset-bigsur.jpg",
  "file_size": "4521984",
  "content_type": "image",
  "category": "photography",
  "visibility": "public",
  "ai_metadata": "{}"
}'
Response

Click Try It! to send a real request, or view sample responses: