Getting started

Authentication

Authenticate Public API and MCP requests with your organization API key and understand what each scope allows.

Every request is authenticated with an organization API key. Keys start with pk_postiv_ and are generated in Settings → Integrations inside Postiv. The key identifies your workspace, so requests never need an organization id.

Authenticated request
curl https://postiv.ai/api/public/workspace \
  -H "Authorization: Bearer pk_postiv_..."

Headers

Send the key with either header. If both are present, x-api-key wins:

HeaderFormat
AuthorizationBearer pk_postiv_...
x-api-keypk_postiv_...

Scopes

Each key carries a set of scopes, and every endpoint requires one. GET /api/public/workspace returns the scopes your key actually has.

ScopeGrants
workspace:readRead workspace identity and the scopes granted to the key.
knowledge:readSemantically search the workspace knowledge base.
knowledge:writeAdd items to the workspace knowledge base.
posts:readList and read posts, templates, carousels, and infographics.
posts:writeCreate and update drafts, carousels, infographics, and slide edits.
posts:scheduleSchedule, reschedule, and unschedule posts; set Comment Plug defaults.
images:writeGenerate and edit branded post images.
profiles:readList LinkedIn profiles and read trained writing styles.
analytics:readRead cached analytics: accounts, KPIs, performance, and top posts.
inspiration:readSearch the moderated LinkedIn inspiration library.
plans:readRead Bob content plans, plan items, and content pillars.
scratchpad:readList and read scratchpad items.
scratchpad:writeCreate, update, delete, and promote scratchpad items.
Legacy knowledge-base keys are limited to knowledge:write. New keys receive the full scope set; use Regenerate Key (adds new scopes) in Settings → Integrations to explicitly replace a legacy key. Regeneration invalidates the previous key.

Auth errors

StatusMeaning
401The key is missing, malformed, or revoked.
403The key is valid but does not carry the scope this endpoint requires.
Treat the key like a password: it grants workspace automation access according to its scopes. Never commit it to version control, and regenerate it immediately if it leaks.