Authentication

The Delivery API authenticates with project-scoped API keys, sent as a Bearer token. A key only ever reaches the project it was created in.

Creating a key

In the dashboard, open your project → API Keys → create a key. Choose a scope, then copy the token. The full token is shown once and stored only as a hash.

Scopes

ParamTypeDescription
readwrk_live_…Published content only. Safe to use from production sites.
previewwrk_preview_…Drafts + published. For preview / staging builds. Never cached.
managewrk_admin_…Full access. Keep server-side only — never expose in a browser.

Sending the token

Pass the token in the Authorization header:

http
GET /v1/projects/PROJECT_ID/content/blog_post HTTP/1.1
Host: api.wriven.com
Authorization: Bearer wrk_live_xxx
// KEEP KEYS SECRETStore keys in server environment variables (e.g. process.env.WRIVEN_TOKEN). Never commit them. Only a read key is safe in client-side code, and even then prefer fetching on the server.

Revoking

Revoke a key from the same page. Revocation is immediate (within a short cache window) and permanent — sites using it stop working, so rotate first.

Errors

ParamTypeDescription
401UnauthorizedMissing, invalid, revoked, or expired key.
403ForbiddenKey lacks the required scope, or targets another project.
404Not FoundUnknown content type or entry slug.
Content Modeling