C2PA Viewer API Documentation

C2PA Verify API

Verify content authenticity programmatically: C2PA manifest validation, trust-chain verification against the official trust lists, provenance extraction, and nutritional-label metadata — as a synchronous API, an asynchronous job pipeline for large assets, or an MCP server for AI agents.

Base URL: https://c2pa.creds.im  ·  OpenAPI 3.1: GET /v1/openapi.json

Quickstart

1. Get a free key at the dashboard (500 verifications/month, no card required) or programmatically:

curl -X POST https://c2pa.creds.im/v1/signup/free \
  -H 'content-type: application/json' \
  -d '{"turnstile_token": "<token from the Turnstile widget>"}'

2. Verify an image:

curl -X POST https://c2pa.creds.im/v1/verify \
  -H "authorization: Bearer c2pa_live_…" \
  -H 'content-type: application/json' \
  -d '{"url": "https://example.com/photo.jpg"}'

3. Read the verdict: status is one of trusted, valid_untrusted, invalid, unverified.

Authentication

Every endpoint except the public ones uses a bearer key: Authorization: Bearer c2pa_live_…

Key kindPrefixBehavior
Livec2pa_live_Production. Counted against monthly quota.
Testc2pa_test_Sandbox — only accepts the fixture corpus, never metered.

Keys are shown exactly once at creation — only their SHA-256 hash is stored. Lost keys cannot be recovered; rotate instead (POST /v1/key/rotate needs the current key, so protect it).

Rate limit: 60 requests/minute per key (429 rate_limited with Retry-After).

Tiers & quotas

TierPriceVerifications / monthAsync jobs
Free$0500No — sync only
Sync Only$3.99/mo or $44.99/yr per unit10,000 per unit, in multiples up to 100×No — sync only
Sync+Async$9.99/mo or $99.99/yr per unit25,000 per unit, in multiples up to 100×Yes

Quotas are hard caps enforced atomically per key. A verification counts when it succeeds (sync) or is accepted (async jobs); failed verifications and every test-key call are free. Exhaustion returns 429 quota_exceeded; the count resets on the UTC month boundary. Job submissions charge at acceptance — a job that later fails is not refunded.

Verify synchronously

POST/v1/verify

Full verification of one asset up to 20 MiB. Input is one of:

Query parameters: include (sections: exif,iptc,gps,thumbnails,raw_manifest; default exif,iptc), trust (c2pa or c2pa_and_itl, default the latter), strip_gps (default true).

The response is the full VerifyResult — validation state, trust basis, active manifest, claim generator, signer chain, provenance rows, EXIF/IPTC sections, thumbnails, and the asset digest. See the schemas in the OpenAPI document.

GET/v1/verify/mini?url=… — compact trust card (the same payload the viewer's nutritional label uses).

Need results for files that take a while to fetch, or webhook delivery instead of polling? Use async jobs — assets up to 20 MiB by default; larger caps are negotiated per key (contact the operator).

Async jobs

POST/v1/jobs — submit; GET/v1/jobs/{job_id} — poll; GET/v1/jobs — list.

Two input modes:

curl -X POST https://c2pa.creds.im/v1/jobs \
  -H "authorization: Bearer c2pa_live_…" -H 'content-type: application/json' \
  -H 'Idempotency-Key: order-4173' \
  -d '{"url": "https://example.com/big.jpg", "filename": "big.jpg",
       "webhook_url": "https://you.example/hooks/c2pa"}'

States: queued → processing → succeeded | failed. The terminal job object embeds the full VerifyResult in result or an RFC 9457 problem in error.

Idempotency: send Idempotency-Key; a replay returns the original job (200 instead of 202) instead of charging a second verification.

Webhooks

Attach webhook_url at job creation. Delivery is at least once: the callback is retried after non-2xx responses, transport errors, or a 30-second timeout, up to four attempts total. Deduplicate by job identifier — the same terminal state may be delivered more than once. The callback is signed:

X-C2PA-Signature: t=1732300800,v1=<hex>

v1 is HMAC-SHA256 of the string "<t>.<raw body>" keyed by the webhook signing secret (available on the dashboard while rotating a key — store it when issued). Verify the timestamp is fresh (5 minutes), then compare constant-time.

Key management

EndpointPurpose
GET/v1/keyMetadata, tier, billing status, current-month usage
GET/v1/usageMonthly usage history (12 months)
POST/v1/key/rotateSuccessor key, effective immediately, no overlap window
POST/v1/key/revokePermanent revocation

Rotation inherits tier, quota, scopes and the Stripe billing linkage — a rotated paid key never loses its subscription.

Billing

Paid tiers run through Stripe checkout. Two flows:

Manage payment methods, invoices and cancellation through POST /v1/billing/portal (Stripe customer portal). Cancellation downgrades the key to free at the end of the subscription; failed payments mark it past_due but never hard-cut service.

Trust lists

GET/v1/trust-lists (public) — provenance and digests of the vendored trust lists. The trust parameter on verification selects which lists may produce a trusted verdict; trust.basis in the result reports which list actually matched.

MCP server

The API is also an MCP server at POST /mcp (streamable HTTP, bearer key). Tools:

ToolPurpose
verify_imageCompact trust card for a url or base64 image
verify_image_detailedFull VerifyResult
submit_verification_job / get_verification_jobAsync pipeline from MCP clients
explain_validation_codeHuman meaning of any validator code
list_trust_listsTrust-list provenance

Errors

Every error is RFC 9457 application/problem+json with a machine-readable code:

StatuscodeMeaning
401unauthorizedMissing/malformed/unknown key
403forbiddenRevoked key, sandbox violation, Turnstile failure
404job_not_foundUnknown job — or another key's job (ownership isolation)
413payload_too_largeAsset over the 20 MiB sync cap
415unsupported_media_typeFormat the engine cannot read
422invalid_requestMalformed input, unparseable asset
429rate_limited / quota_exceededPer-minute limit / monthly quota
502upstream_fetch_failedThe asset URL could not be fetched
503billing_not_configuredDeployment has no billing provider attached

SDKs

Thin idiomatic clients — no dependencies beyond the platform fetch/HTTP:

import { C2paClient } from 'c2pa-verify';
const api = new C2paClient('c2pa_live_…');
const result = await api.verify({ url: 'https://example.com/photo.jpg' });
console.log(result.status);
from c2pa_verify import C2paClient
api = C2paClient('c2pa_live_…')
result = api.verify(url='https://example.com/photo.jpg')
print(result['status'])