pbs-library

POST /v1/pbs-library/items

Save a section, page or style.

All pbs-library endpoints

All developer docs →

Zinn®, our Viking, hammering at his anvil beside an API endpoint sending events to several listeners.

Authentication

This endpoint does not take an API key. It takes its own credential, issued to the plugin or service that calls it, as a bearer token; see the description above.

This endpoint takes no organisation id. Your key already identifies the organisation it belongs to, and the response is scoped to it.

Try it

Replace anything in angle brackets with your own values, and the key placeholder with a key from your dashboard.

curl -X POST https://api.zinndigital.com/v1/pbs-library/items \
  -H "Authorization: Bearer zdk_live_…" \
  -H "Content-Type: application/json" \
  -d '{  }'

Signed in? The API console in your dashboard fills in your real organisation id and your own key, and runs the request against the live API so you can see the actual response. Open this endpoint in the API console

Details

The content (block markup and styles, at most 2 MB) goes to object storage; images are uploaded first with createPbsLibraryImage and referenced by SHA-256. Refused with 409 quota_exceeded / item_limit_reached when the plan's ceiling would be passed (nothing is stored), 413 item_too_large, 403 licence_inactive (lapsed licence) or read_only (a read-only team member). Budget 600 writes/hour per session.

Request body

NameTypeRequiredWhat it is
kindstring<section, page, style>No—
titlestringNo—
tagsstring[]No—
contentobjectNoThe design (block markup + styles)
imagesstring[]No—
team_idstringNo—

Response

NameTypeRequiredWhat it is
idstringYes—
kindstring<section, page, style>Yes—
titlestringYes—
tagsstring[]Yes—
team_idstringYes—
content_bytesintegerYes—
created_atstringYes—
updated_atstringYes—
accountPbsLibraryAccountYes—

Errors this endpoint can return

401 · 403 · 404 · 409 · 413 · 422 · 429 · 503