{
"error": {
"code": "not_found",
"message": "No such document."
}
}
{
"error": {
"code": "not_found",
"message": "No such document."
}
}
{
"error": {
"code": "not_found",
"message": "No such document."
}
}
API Keys
Create an API key
Creates an org-scoped API key together with its agent user — the member identity the key acts as on every other endpoint — and returns the secret token exactly once. Sessions need the admin role or higher; an API key with edit access can also mint keys, attributed to its agent identity via createdBy. Note that keys minted by an agent outlive that agent’s own revocation, so audit an agent’s keys (filter by createdBy) after revoking it.
{"docsConfig":{"theme":"mint","$schema":"https://mintlify.com/docs.json","name":"Scribe","description":"Collaborative markdown WYSIWYG editor built on Cloudflare, with an API-first design.","colors":{"primary":"#57534e","light":"#d6d3d1","dark":"#44403c"},"background":{"color":{"light":"#fafaf9","dark":"#0c0a09"}},"navbar":{"primary":{"type":"button","label":"Open Scribe","href":"https://scribe.skeptrune.com"}},"footer":{"socials":{"github":"https://github.com/mintlify/scribe"}},"styling":{"latex":false},"navigation":{"pages":[]}},"deployment":{"deploymentMetadataValue":{"subdomain":"scribeskept","hasAudioNarration":false,"actualSubdomain":"scribeskept","customDomains":["demo.skeptrune.com"],"gitSource":{"type":"github","owner":"skeptrunedev","repo":"scribe-docs","deployBranch":"main","contentDirectory":"","isPrivate":true,"mountPath":"","label":""},"entitlements":{},"buildId":"6ae95c546c00b4612dbc64ba:success","clientVersion":"0.0.4111","searchFilterCounts":[{"language":"default","tag":"API reference","count":50},{"language":"default","tag":"Docs","count":8},{"language":"default","tag":"Documentation","count":7},{"language":"default","tag":"Threads","count":7},{"language":"default","tag":"Shares","count":6},{"language":"default","tag":"Folders","count":4},{"language":"default","tag":"Me","count":4},{"language":"default","tag":"Organization","count":4},{"language":"default","tag":"API Keys","count":3},{"language":"default","tag":"Members","count":3}]},"assistantConfig":{"enableAskAiButton":false,"enableStarterQuestions":false,"enableContextualStarterQuestions":false,"enableAskAiSearchBar":true},"basePath":"/help-center","hasChatPermissions":false,"hasWebMcpPermissions":false,"toggles":[{"name":"kill-isr","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-rbac-roles","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-mintlify-slack","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-integrations-settings","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"rbac-expansion","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-pr-grouping","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-prefix","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"analytics-v7","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"user-flows-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"no-publish-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-onboarding","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"llms-txt-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving-live","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"stripTemperatureMiddleware","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"support-platform-pylon-zendesk","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"instant-rollback","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications-server","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-fable","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fixed-ai-action-pricing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automation-resolve-merge-conflict","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"scoped-publishing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"mintql","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"page-level-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-version-history-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-page-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"full-page-search","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workspace-projects","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"assistant-v5","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fork-pr-previews","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"revalidation-jwt","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-sso-scim","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"hobby-abuse-scan","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"dashboard-inbox","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-signup","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-dual-write","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-enabled","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"approve-review-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-metadata","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"sso-setup-deadline-banner","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-serve","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"live-agents","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false}],"googleFontsInlined":false},"customCss":[],"page":{"pagePath":"api-reference/api-keys/create-an-api-key","slug":"/api-reference/api-keys/create-an-api-key","pageMetadata":{"title":"Create an API key","description":"Creates an org-scoped API key together with its agent user — the member identity the key acts as on every other endpoint — and returns the secret token exactly once. Sessions need the admin role or higher; an API key with edit access can also mint keys, attributed to its agent identity via createdBy. Note that keys minted by an agent outlive that agent’s own revocation, so audit an agent’s keys (filter by createdBy) after revoking it.","deprecated":null,"version":null,"openapi":"/help-center/api-reference/openapi.json post /api/org/api-keys","href":"/api-reference/api-keys/create-an-api-key","autogeneratedByOpenApi":true},"description":{"compiledSource":"\"use strict\";\nconst {jsx: _jsx} = arguments[0];\nconst {useMDXComponents: _provideComponents} = arguments[0];\nfunction _createMdxContent(props) {\n const _components = {\n p: \"p\",\n ..._provideComponents(),\n ...props.components\n };\n return _jsx(_components.p, {\n children: \"Creates an org-scoped API key together with its agent user — the member identity the key acts as on every other endpoint — and returns the secret token exactly once. Sessions need the admin role or higher; an API key with edit access can also mint keys, attributed to its agent identity via createdBy. Note that keys minted by an agent outlive that agent’s own revocation, so audit an agent’s keys (filter by createdBy) after revoking it.\"\n });\n}\nfunction MDXContent(props = {}) {\n const {wrapper: MDXLayout} = {\n ..._provideComponents(),\n ...props.components\n };\n return MDXLayout ? _jsx(MDXLayout, {\n ...props,\n children: _jsx(_createMdxContent, {\n ...props\n })\n }) : _createMdxContent(props);\n}\nreturn {\n default: MDXContent\n};\n","frontmatter":{},"scope":{}},"pageType":"default","mdx":{"mdxSource":{"compiledSource":"\"use strict\";const{Fragment:_Fragment,jsx:_jsx}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){return _jsx(_Fragment,{})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent}","frontmatter":{},"scope":{"config":{},"pageMetadata":{"title":"Create an API key","description":"Creates an org-scoped API key together with its agent user — the member identity the key acts as on every other endpoint — and returns the secret token exactly once. Sessions need the admin role or higher; an API key with edit access can also mint keys, attributed to its agent identity via createdBy. Note that keys minted by an agent outlive that agent’s own revocation, so audit an agent’s keys (filter by createdBy) after revoking it.","deprecated":null,"version":null,"openapi":"/help-center/api-reference/openapi.json post /api/org/api-keys","href":"/api-reference/api-keys/create-an-api-key","autogeneratedByOpenApi":true}}},"mdxSourceWithNoJs":null},"mdxExtracts":{"tableOfContents":[],"codeExamples":{}},"jsLinks":[],"openApiReferenceData":{"operation":{"tags":["API Keys"],"summary":"Create an API key","description":"Creates an org-scoped API key together with its agent user — the member identity the key acts as on every other endpoint — and returns the secret token exactly once. Sessions need the admin role or higher; an API key with edit access can also mint keys, attributed to its agent identity via createdBy. Note that keys minted by an agent outlive that agent’s own revocation, so audit an agent’s keys (filter by createdBy) after revoking it.","operationId":"createApiKey","security":["f76ba08b-64a9-4c6a-be63-f1edaed28e1f","89bbe895-4f44-4830-893d-0b2d2493a812"],"requestBody":"6a7471b1-d484-4116-8380-ae581be3e16f","responses":{"201":"837b110c-8331-4ff6-954b-57decb1bb71d","400":"9b93ed0d-22e9-4eef-b551-13ef3eb72683","401":"2f25e847-9fb7-4bc8-9435-077db6737ee4","403":"2951786b-ea9f-4015-9cf6-5a544365c9d2"},"method":"post","type":"path","servers":["563ebf6e-9bdc-4d2b-b429-c4af5c386ebb"],"path":"/api/org/api-keys","baseUrlOptions":["https://scribe.skeptrune.com"],"title":"Create an API key","codeSamples":[],"requiredOnlyExamples":false,"requestExampleType":"generated","responseExampleType":"generated"},"dependencies":{"parameters":{},"requestBody":{"description":"Key name, access level, and optional expiry.","required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":120,"description":"Human-readable name for the new key.","example":"CI docs bot","isRequired":true,"uniqueKey":"name","typeLabel":"string"},"access":{"type":"string","enum":["read","edit"],"description":"Access level to grant the new key: read or edit.","example":"read","isRequired":true,"uniqueKey":"access","typeLabel":"enum\u003cstring>"},"expiresInDays":{"type":"integer","minimum":1,"maximum":3650,"description":"Days until the key expires. Omit for a non-expiring key.","example":90,"uniqueKey":"expiresInDays","typeLabel":"integer"}},"required":["name","access"],"description":"Create a new API key.","example":{"name":"CI docs bot","access":"read","expiresInDays":90},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"name":"CI docs bot","access":"read","expiresInDays":90}}},"exampleType":"generated"}},"exampleType":"generated"},"responses":{"837b110c-8331-4ff6-954b-57decb1bb71d":{"description":"The created key with its secret token. The token cannot be retrieved again.","content":{"application/json":{"schema":{"type":"object","properties":{"key":{"type":"object","properties":{"id":{"type":"string","description":"API key id.","example":"key_2mNbVcXzLkJhGfDsAqWe","isRequired":true,"uniqueKey":"key.id","typeLabel":"string"},"name":{"type":"string","description":"Human-readable key name.","example":"CI docs bot","isRequired":true,"uniqueKey":"key.name","typeLabel":"string"},"keyPrefix":{"type":"string","description":"Display prefix of the token (first characters). The full token is never stored.","example":"scrb_agt_AbC","isRequired":true,"uniqueKey":"key.keyPrefix","typeLabel":"string"},"access":{"type":"string","enum":["read","edit"],"description":"Access level granted to an API key.","example":"read","isRequired":true,"uniqueKey":"key.access","typeLabel":"enum\u003cstring>"},"createdBy":{"type":"string","description":"User id of the creator.","example":"usr_V1StGXR8_Z5jdHi6BmyT","isRequired":true,"uniqueKey":"key.createdBy","typeLabel":"string"},"agentUserId":{"oneOf":[{"type":"string","description":"User id of the agent identity the key acts as (it owns documents and authors comments on behalf of the key). Null only for legacy keys created before agent identities existed.","example":"usr_9wQxAgEnTbOtIdEf7g8h","isRequired":true,"uniqueKey":"key.agentUserId.oneOf.0","typeLabel":"string"},{"type":"null","description":"User id of the agent identity the key acts as (it owns documents and authors comments on behalf of the key). Null only for legacy keys created before agent identities existed.","example":"usr_9wQxAgEnTbOtIdEf7g8h","isRequired":true,"uniqueKey":"key.agentUserId.oneOf.1","typeLabel":"null"}],"isRequired":true,"uniqueKey":"key.agentUserId","typeLabel":"string | null"},"expiresAt":{"oneOf":[{"type":"integer","description":"Expiry timestamp (epoch millis), or null when the key never expires.","example":1752624000000,"isRequired":true,"uniqueKey":"key.expiresAt.oneOf.0","typeLabel":"integer"},{"type":"null","description":"Expiry timestamp (epoch millis), or null when the key never expires.","example":1752624000000,"isRequired":true,"uniqueKey":"key.expiresAt.oneOf.1","typeLabel":"null"}],"isRequired":true,"uniqueKey":"key.expiresAt","typeLabel":"integer | null"},"lastUsedAt":{"oneOf":[{"type":"integer","description":"When the key last authenticated a request, or null.","example":1752624000000,"isRequired":true,"uniqueKey":"key.lastUsedAt.oneOf.0","typeLabel":"integer"},{"type":"null","description":"When the key last authenticated a request, or null.","example":1752624000000,"isRequired":true,"uniqueKey":"key.lastUsedAt.oneOf.1","typeLabel":"null"}],"isRequired":true,"uniqueKey":"key.lastUsedAt","typeLabel":"integer | null"},"revokedAt":{"oneOf":[{"type":"integer","description":"When the key was revoked, or null while active.","example":1752624000000,"isRequired":true,"uniqueKey":"key.revokedAt.oneOf.0","typeLabel":"integer"},{"type":"null","description":"When the key was revoked, or null while active.","example":1752624000000,"isRequired":true,"uniqueKey":"key.revokedAt.oneOf.1","typeLabel":"null"}],"isRequired":true,"uniqueKey":"key.revokedAt","typeLabel":"integer | null"},"createdAt":{"type":"integer","description":"When the API key was created (epoch milliseconds).","example":1752624000000,"isRequired":true,"uniqueKey":"key.createdAt","typeLabel":"integer"}},"required":["id","name","keyPrefix","access","createdBy","agentUserId","expiresAt","lastUsedAt","revokedAt","createdAt"],"description":"An organization-scoped API key (agent credential). Never contains the secret token.","example":{"id":"key_2mNbVcXzLkJhGfDsAqWe","name":"CI docs bot","keyPrefix":"scrb_agt_AbC","access":"read","createdBy":"usr_V1StGXR8_Z5jdHi6BmyT","agentUserId":"usr_9wQxAgEnTbOtIdEf7g8h","expiresAt":1752624000000,"lastUsedAt":1752624000000,"revokedAt":null,"createdAt":1752624000000},"isRequired":true,"uniqueKey":"key","typeLabel":"object"},"token":{"type":"string","description":"The full secret token. Shown exactly once — it cannot be retrieved again.","example":"scrb_agt_AbCdEfGhIjKlMnOpQrStUvWxYz0123456789AbCdEfGh","isRequired":true,"uniqueKey":"token","typeLabel":"string"}},"required":["key","token"],"description":"A freshly created API key together with its secret token (returned only once).","example":{"key":{"id":"key_2mNbVcXzLkJhGfDsAqWe","name":"CI docs bot","keyPrefix":"scrb_agt_AbC","access":"read","createdBy":"usr_V1StGXR8_Z5jdHi6BmyT","agentUserId":"usr_9wQxAgEnTbOtIdEf7g8h","expiresAt":1752624000000,"lastUsedAt":1752624000000,"revokedAt":null,"createdAt":1752624000000},"token":"scrb_agt_AbCdEfGhIjKlMnOpQrStUvWxYz0123456789AbCdEfGh"},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"key":{"id":"key_2mNbVcXzLkJhGfDsAqWe","name":"CI docs bot","keyPrefix":"scrb_agt_AbC","access":"read","createdBy":"usr_V1StGXR8_Z5jdHi6BmyT","agentUserId":"usr_9wQxAgEnTbOtIdEf7g8h","expiresAt":1752624000000,"lastUsedAt":1752624000000,"revokedAt":null,"createdAt":1752624000000},"token":"scrb_agt_AbCdEfGhIjKlMnOpQrStUvWxYz0123456789AbCdEfGh"}}},"exampleType":"generated"}},"exampleType":"generated"},"9b93ed0d-22e9-4eef-b551-13ef3eb72683":{"description":"Returned when the new key has an invalid name, access level, or expiry.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"object","properties":{"code":{"type":"string","enum":["validation_error","unauthorized","user_session_required","forbidden","not_found","conflict","payload_too_large","unsupported_media_type","internal_error"],"description":"Stable machine-readable error code.","example":"not_found","isRequired":true,"uniqueKey":"error.code","typeLabel":"enum\u003cstring>"},"message":{"type":"string","description":"Human-readable explanation of the error.","example":"No such document.","isRequired":true,"uniqueKey":"error.message","typeLabel":"string"}},"required":["code","message"],"description":"Error detail.","example":{"code":"not_found","message":"No such document."},"isRequired":true,"uniqueKey":"error","typeLabel":"object"}},"required":["error"],"description":"Standard error envelope returned by every non-2xx response.","example":{"error":{"code":"not_found","message":"No such document."}},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"error":{"code":"not_found","message":"No such document."}}}},"exampleType":"generated"}},"exampleType":"generated"},"2f25e847-9fb7-4bc8-9435-077db6737ee4":{"description":"Returned when an API key is created without a user session or agent-backed API key.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"object","properties":{"code":{"type":"string","enum":["validation_error","unauthorized","user_session_required","forbidden","not_found","conflict","payload_too_large","unsupported_media_type","internal_error"],"description":"Stable machine-readable error code.","example":"not_found","isRequired":true,"uniqueKey":"error.code","typeLabel":"enum\u003cstring>"},"message":{"type":"string","description":"Human-readable explanation of the error.","example":"No such document.","isRequired":true,"uniqueKey":"error.message","typeLabel":"string"}},"required":["code","message"],"description":"Error detail.","example":{"code":"not_found","message":"No such document."},"isRequired":true,"uniqueKey":"error","typeLabel":"object"}},"required":["error"],"description":"Standard error envelope returned by every non-2xx response.","example":{"error":{"code":"not_found","message":"No such document."}},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"error":{"code":"not_found","message":"No such document."}}}},"exampleType":"generated"}},"exampleType":"generated"},"2951786b-ea9f-4015-9cf6-5a544365c9d2":{"description":"Returned when a non-admin member tries to create an API key, or the calling key is read-only.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"object","properties":{"code":{"type":"string","enum":["validation_error","unauthorized","user_session_required","forbidden","not_found","conflict","payload_too_large","unsupported_media_type","internal_error"],"description":"Stable machine-readable error code.","example":"not_found","isRequired":true,"uniqueKey":"error.code","typeLabel":"enum\u003cstring>"},"message":{"type":"string","description":"Human-readable explanation of the error.","example":"No such document.","isRequired":true,"uniqueKey":"error.message","typeLabel":"string"}},"required":["code","message"],"description":"Error detail.","example":{"code":"not_found","message":"No such document."},"isRequired":true,"uniqueKey":"error","typeLabel":"object"}},"required":["error"],"description":"Standard error envelope returned by every non-2xx response.","example":{"error":{"code":"not_found","message":"No such document."}},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"error":{"code":"not_found","message":"No such document."}}}},"exampleType":"generated"}},"exampleType":"generated"}},"security":{"f76ba08b-64a9-4c6a-be63-f1edaed28e1f":{"cookieAuth":{"type":"apiKey","in":"cookie","name":"scribe_session","description":"Browser session cookie set by the WorkOS sign-in flow.","scopes":[]}},"89bbe895-4f44-4830-893d-0b2d2493a812":{"bearerAuth":{"type":"http","scheme":"bearer","description":"Org-scoped API key token (scrb_agt_...) created via POST /api/org/api-keys. The key acts as its agent identity — a member-like user that owns documents, authors comments, and appears in activity feeds.","scopes":[]}}},"servers":{"563ebf6e-9bdc-4d2b-b429-c4af5c386ebb":{"url":"https://scribe.skeptrune.com","description":"Production"}},"processedSecurityOptions":[{"schemes":[{"scheme":{"type":"apiKey","in":"cookie","name":"scribe_session","description":"Browser session cookie set by the WorkOS sign-in flow.","scopes":[]},"schema":{"title":"scribe_session","type":"string","description":"Browser session cookie set by the WorkOS sign-in flow.","isRequired":true,"typeLabel":"string","deprecated":false},"schemeName":"cookieAuth","name":"scribe_session"}],"title":"cookieAuth"},{"schemes":[{"scheme":{"type":"http","scheme":"bearer","description":"Org-scoped API key token (scrb_agt_...) created via POST /api/org/api-keys. The key acts as its agent identity — a member-like user that owns documents, authors comments, and appears in activity feeds.","scopes":[]},"schema":{"title":"Bearer Auth","type":"string","isRequired":true,"description":"Org-scoped API key token (scrb_agt_...) created via POST /api/org/api-keys. The key acts as its agent identity — a member-like user that owns documents, authors comments, and appears in activity feeds.","format":"bearer","typeLabel":"string\u003cbearer>","deprecated":false},"schemeName":"bearerAuth","name":"Authorization"}],"title":"bearerAuth"}]},"originalFileLocation":"help-center/api-reference/openapi.json"},"subdomain":"scribeskept","siteName":"Scribe","title":"Create an API key - Scribe","navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{}},"lastModified":"2026-07-17T06:04:56.473Z","originalFileLocation":"api-reference/api-keys/create-an-api-key.mdx"},"headHtml":"\u003cscript data-mint-head>(function(){var d=document.documentElement,p=null;if(!p){try{p=localStorage.getItem(\"isDarkMode\")}catch(e){}if(p==='true')p='dark';else if(p==='false')p='light';if(p!=='light'\u0026\u0026p!=='dark'\u0026\u0026p!=='system')p=\"system\"}var r=p==='system'?(matchMedia(\"(prefers-color-scheme: dark)\").matches?'dark':'light'):p;d.classList.remove(r==='dark'?'light':'dark');d.classList.add(r);d.setAttribute(\"data-theme-preference\",p)})();\u003c/script>\u003cmeta data-mint-head name=\"description\" content=\"Creates an org-scoped API key together with its agent user — the member identity the key acts as on every other endpoint — and returns the secret token exactly once. Sessions need the admin role or higher; an API key with edit access can also mint keys, attributed to its agent identity via createdBy. Note that keys minted by an agent outlive that agent’s own revocation, so audit an agent’s keys (filter by createdBy) after revoking it.\">\u003cmeta data-mint-head name=\"application-name\" content=\"Scribe\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003clink data-mint-head rel=\"apple-touch-icon\" type=\"image/png\" sizes=\"180x180\" href=\"https://mintlify.s3.us-west-1.amazonaws.com/scribeskept/_generated/favicon/apple-touch-icon.png?v=3\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"https://mintlify.s3.us-west-1.amazonaws.com/scribeskept/_generated/favicon/favicon-32x32.png?v=3\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"https://mintlify.s3.us-west-1.amazonaws.com/scribeskept/_generated/favicon/favicon-16x16.png?v=3\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"https://mintlify.s3.us-west-1.amazonaws.com/scribeskept/_generated/favicon/favicon.ico?v=3\">\u003cmeta data-mint-head property=\"og:title\" content=\"Create an API key - Scribe\">\u003cmeta data-mint-head property=\"og:description\" content=\"Creates an org-scoped API key together with its agent user — the member identity the key acts as on every other endpoint — and returns the secret token exactly once. Sessions need the admin role or higher; an API key with edit access can also mint keys, attributed to its agent identity via createdBy. Note that keys minted by an agent outlive that agent’s own revocation, so audit an agent’s keys (filter by createdBy) after revoking it.\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"Scribe\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://demo.skeptrune.com/api-reference/api-keys/create-an-api-key\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://scribeskept.mintlify.site/_mintlify/api/og/v2?division=API+Keys\u0026amp;title=Create+an+API+key\u0026amp;description=Creates+an+org-scoped+API+key+together+with+its+agent+user+%E2%80%94+the+member+identity+the+key+acts+as+on+every+other+endpoint+%E2%80%94+and+returns+the+secret+token+exactly+\u0026amp;theme=84b3a3a3d031a8d5a20353bf\u0026amp;signature=06b4d1d462d975868af4f98bf32d26c37ecf690c4d27a831ffc024a79926c7b6\">\u003cmeta data-mint-head property=\"og:image:width\" content=\"1200\">\u003cmeta data-mint-head property=\"og:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"twitter:card\" content=\"summary_large_image\">\u003cmeta data-mint-head name=\"twitter:title\" content=\"Create an API key - Scribe\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"Creates an org-scoped API key together with its agent user — the member identity the key acts as on every other endpoint — and returns the secret token exactly once. Sessions need the admin role or higher; an API key with edit access can also mint keys, attributed to its agent identity via createdBy. Note that keys minted by an agent outlive that agent’s own revocation, so audit an agent’s keys (filter by createdBy) after revoking it.\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://scribeskept.mintlify.site/_mintlify/api/og/v2?division=API+Keys\u0026amp;title=Create+an+API+key\u0026amp;description=Creates+an+org-scoped+API+key+together+with+its+agent+user+%E2%80%94+the+member+identity+the+key+acts+as+on+every+other+endpoint+%E2%80%94+and+returns+the+secret+token+exactly+\u0026amp;theme=84b3a3a3d031a8d5a20353bf\u0026amp;signature=06b4d1d462d975868af4f98bf32d26c37ecf690c4d27a831ffc024a79926c7b6\">\u003cmeta data-mint-head name=\"twitter:image:width\" content=\"1200\">\u003cmeta data-mint-head name=\"twitter:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"msapplication-config\" content=\"https://mintlify.s3.us-west-1.amazonaws.com/scribeskept/_generated/favicon/browserconfig.xml?v=3\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"Scribe\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#57534e\">\u003clink data-mint-head rel=\"canonical\" href=\"https://demo.skeptrune.com/api-reference/api-keys/create-an-api-key\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/api-reference/api-keys/create-an-api-key.md\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://demo.skeptrune.com/#organization\",\"name\":\"Scribe\",\"url\":\"https://demo.skeptrune.com\"},{\"@type\":\"WebSite\",\"@id\":\"https://demo.skeptrune.com#website\",\"name\":\"Scribe\",\"url\":\"https://demo.skeptrune.com\",\"publisher\":{\"@id\":\"https://demo.skeptrune.com/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://demo.skeptrune.com/api-reference/api-keys/create-an-api-key#webpage\",\"url\":\"https://demo.skeptrune.com/api-reference/api-keys/create-an-api-key\",\"name\":\"Create an API key\",\"description\":\"Creates an org-scoped API key together with its agent user — the member identity the key acts as on every other endpoint — and returns the secret token exactly once. Sessions need the admin role or higher; an API key with edit access can also mint keys, attributed to its agent identity via createdBy. Note that keys minted by an agent outlive that agent’s own revocation, so audit an agent’s keys (filter by createdBy) after revoking it.\",\"dateModified\":\"2026-07-17T06:04:56.473Z\",\"isPartOf\":{\"@id\":\"https://demo.skeptrune.com#website\"},\"breadcrumb\":{\"@id\":\"https://demo.skeptrune.com/api-reference/api-keys/create-an-api-key#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://demo.skeptrune.com/api-reference/api-keys/create-an-api-key#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"API Keys\",\"item\":\"https://demo.skeptrune.com/api-reference/api-keys/list-api-keys\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Create an API key\",\"item\":\"https://demo.skeptrune.com/api-reference/api-keys/create-an-api-key\"}]},{\"@type\":[\"TechArticle\",\"APIReference\"],\"@id\":\"https://demo.skeptrune.com/api-reference/api-keys/create-an-api-key#apireference\",\"headline\":\"Create an API key\",\"name\":\"Create an API key\",\"description\":\"Creates an org-scoped API key together with its agent user — the member identity the key acts as on every other endpoint — and returns the secret token exactly once. Sessions need the admin role or higher; an API key with edit access can also mint keys, attributed to its agent identity via createdBy. Note that keys minted by an agent outlive that agent’s own revocation, so audit an agent’s keys (filter by createdBy) after revoking it.\",\"url\":\"https://demo.skeptrune.com/api-reference/api-keys/create-an-api-key\",\"mainEntityOfPage\":{\"@id\":\"https://demo.skeptrune.com/api-reference/api-keys/create-an-api-key#webpage\"},\"dateModified\":\"2026-07-17T06:04:56.473Z\",\"publisher\":{\"@id\":\"https://demo.skeptrune.com/#organization\"},\"isPartOf\":{\"@id\":\"https://demo.skeptrune.com#website\"}}]}\u003c/script>\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"Scribe\",\"publisher\":{\"@type\":\"Organization\",\"name\":\"Scribe\"},\"provider\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","agentPointerHref":"/api-reference/api-keys/create-an-api-key.md","siteName":"Scribe","nav":{"global":null,"tabs":[{"tab":"Documentation","pages":[{"title":"Documentation","href":"/help-center"}]},{"tab":"API reference","groups":[{"group":"Using the API","pages":[{"title":"API overview","href":"/help-center/api-reference/overview"}]},{"group":"Health","pages":[{"title":"Health check","deprecated":null,"version":null,"openapi":"/help-center/api-reference/openapi.json get /api/health","href":"/api-reference/health/health-check"}]},{"group":"Me","pages":[{"title":"Get my profile","deprecated":null,"version":null,"openapi":"/help-center/api-reference/openapi.json get /api/me","href":"/api-reference/me/get-my-profile"},{"title":"Update my profile","deprecated":null,"version":null,"openapi":"/help-center/api-reference/openapi.json patch /api/me","href":"/api-reference/me/update-my-profile"},{"title":"Upload my avatar","deprecated":null,"version":null,"openapi":"/help-center/api-reference/openapi.json put /api/me/avatar","href":"/api-reference/me/upload-my-avatar"},{"title":"Delete my avatar","deprecated":null,"version":null,"openapi":"/help-center/api-reference/openapi.json delete /api/me/avatar","href":"/api-reference/me/delete-my-avatar"}]},{"group":"Organization","pages":[{"title":"Get the current organization","deprecated":null,"version":null,"openapi":"/help-center/api-reference/openapi.json get /api/org","href":"/api-reference/organization/get-the-current-organization"},{"title":"Update the organization","deprecated":null,"version":null,"openapi":"/help-center/api-reference/openapi.json patch /api/org","href":"/api-reference/organization/update-the-organization"},{"title":"Upload the organization icon","deprecated":null,"version":null,"openapi":"/help-center/api-reference/openapi.json put /api/org/icon","href":"/api-reference/organization/upload-the-organization-icon"},{"title":"Delete the organization icon","deprecated":null,"version":null,"openapi":"/help-center/api-reference/openapi.json delete /api/org/icon","href":"/api-reference/organization/delete-the-organization-icon"}]},{"group":"Members","pages":[{"title":"List members and pending invites","deprecated":null,"version":null,"openapi":"/help-center/api-reference/openapi.json get /api/org/members","href":"/api-reference/members/list-members-and-pending-invites"},{"title":"Remove a member","deprecated":null,"version":null,"openapi":"/help-center/api-reference/openapi.json delete /api/org/members/{userId}","href":"/api-reference/members/remove-a-member"},{"title":"Change a member role","deprecated":null,"version":null,"openapi":"/help-center/api-reference/openapi.json patch /api/org/members/{userId}","href":"/api-reference/members/change-a-member-role"}]},{"group":"Invites","pages":[{"title":"Invite a member","deprecated":null,"version":null,"openapi":"/help-center/api-reference/openapi.json post /api/org/invites","href":"/api-reference/invites/invite-a-member"},{"title":"Revoke an invite","deprecated":null,"version":null,"openapi":"/help-center/api-reference/openapi.json delete /api/org/invites/{id}","href":"/api-reference/invites/revoke-an-invite"}]},{"group":"API Keys","pages":[{"title":"List API keys","description":"Returns every API key of the organization (including revoked ones). Responses never contain the token or its hash — only the display prefix. Callable by organization members and by any valid API key of the organization, whatever its access level.","deprecated":null,"version":null,"openapi":"/help-center/api-reference/openapi.json get /api/org/api-keys","href":"/api-reference/api-keys/list-api-keys"},{"title":"Create an API key","deprecated":null,"version":null,"openapi":"/help-center/api-reference/openapi.json post /api/org/api-keys","href":"/api-reference/api-keys/create-an-api-key"},{"title":"Revoke an API key","description":"Revokes an API key immediately, cutting off authentication. The agent user behind the key is kept so its documents, comments, and activity stay attributed. Sessions need the admin role or higher; an API key with edit access can revoke any key of its organization, including itself. Keys the revoked agent minted earlier keep working — audit them via createdBy.","deprecated":null,"version":null,"openapi":"/help-center/api-reference/openapi.json delete /api/org/api-keys/{id}","href":"/api-reference/api-keys/revoke-an-api-key"}]},{"group":"Folders","pages":[{"title":"List folders","deprecated":null,"version":null,"openapi":"/help-center/api-reference/openapi.json get /api/folders","href":"/api-reference/folders/list-folders"},{"title":"Create a folder","deprecated":null,"version":null,"openapi":"/help-center/api-reference/openapi.json post /api/folders","href":"/api-reference/folders/create-a-folder"},{"title":"Delete a folder","deprecated":null,"version":null,"openapi":"/help-center/api-reference/openapi.json delete /api/folders/{id}","href":"/api-reference/folders/delete-a-folder"},{"title":"Rename or move a folder","deprecated":null,"version":null,"openapi":"/help-center/api-reference/openapi.json patch /api/folders/{id}","href":"/api-reference/folders/rename-or-move-a-folder"}]},{"group":"Docs","pages":[{"title":"List documents","deprecated":null,"version":null,"openapi":"/help-center/api-reference/openapi.json get /api/docs","href":"/api-reference/docs/list-documents"},{"title":"Create a document","deprecated":null,"version":null,"openapi":"/help-center/api-reference/openapi.json post /api/docs","href":"/api-reference/docs/create-a-document"},{"title":"List trashed documents","deprecated":null,"version":null,"openapi":"/help-center/api-reference/openapi.json get /api/trash","href":"/api-reference/docs/list-trashed-documents"},{"title":"Get a document","deprecated":null,"version":null,"openapi":"/help-center/api-reference/openapi.json get /api/docs/{id}","href":"/api-reference/docs/get-a-document"},{"title":"Trash a document","deprecated":null,"version":null,"openapi":"/help-center/api-reference/openapi.json delete /api/docs/{id}","href":"/api-reference/docs/trash-a-document"},{"title":"Update a document","deprecated":null,"version":null,"openapi":"/help-center/api-reference/openapi.json patch /api/docs/{id}","href":"/api-reference/docs/update-a-document"},{"title":"Restore a document from the trash","deprecated":null,"version":null,"openapi":"/help-center/api-reference/openapi.json post /api/docs/{id}/restore","href":"/api-reference/docs/restore-a-document-from-the-trash"},{"title":"Permanently delete a document","deprecated":null,"version":null,"openapi":"/help-center/api-reference/openapi.json delete /api/docs/{id}/purge","href":"/api-reference/docs/permanently-delete-a-document"}]},{"group":"Content","pages":[{"title":"Get document content","deprecated":null,"version":null,"openapi":"/help-center/api-reference/openapi.json get /api/docs/{id}/content","href":"/api-reference/content/get-document-content"},{"title":"Replace document content","deprecated":null,"version":null,"openapi":"/help-center/api-reference/openapi.json put /api/docs/{id}/content","href":"/api-reference/content/replace-document-content"}]},{"group":"Shares","pages":[{"title":"List document shares","deprecated":null,"version":null,"openapi":"/help-center/api-reference/openapi.json get /api/docs/{id}/shares","href":"/api-reference/shares/list-document-shares"},{"title":"Share with a user by email","deprecated":null,"version":null,"openapi":"/help-center/api-reference/openapi.json post /api/docs/{id}/shares","href":"/api-reference/shares/share-with-a-user-by-email"},{"title":"Share with a user (upsert)","deprecated":null,"version":null,"openapi":"/help-center/api-reference/openapi.json put /api/docs/{id}/shares/{userId}","href":"/api-reference/shares/share-with-a-user-upsert"},{"title":"Remove a share","deprecated":null,"version":null,"openapi":"/help-center/api-reference/openapi.json delete /api/docs/{id}/shares/{userId}","href":"/api-reference/shares/remove-a-share"},{"title":"Enable the public link","deprecated":null,"version":null,"openapi":"/help-center/api-reference/openapi.json post /api/docs/{id}/public-link","href":"/api-reference/shares/enable-the-public-link"},{"title":"Disable the public link","deprecated":null,"version":null,"openapi":"/help-center/api-reference/openapi.json delete /api/docs/{id}/public-link","href":"/api-reference/shares/disable-the-public-link"}]},{"group":"Public","pages":[{"title":"Read a publicly linked document","deprecated":null,"version":null,"openapi":"/help-center/api-reference/openapi.json get /api/public/{publicToken}","href":"/api-reference/public/read-a-publicly-linked-document"}]},{"group":"Search","pages":[{"title":"Search documents","deprecated":null,"version":null,"openapi":"/help-center/api-reference/openapi.json get /api/search","href":"/api-reference/search/search-documents"}]},{"group":"Threads","pages":[{"title":"List threads of a document","deprecated":null,"version":null,"openapi":"/help-center/api-reference/openapi.json get /api/docs/{id}/threads","href":"/api-reference/threads/list-threads-of-a-document"},{"title":"Start a thread","deprecated":null,"version":null,"openapi":"/help-center/api-reference/openapi.json post /api/docs/{id}/threads","href":"/api-reference/threads/start-a-thread"},{"title":"Reply to a thread","deprecated":null,"version":null,"openapi":"/help-center/api-reference/openapi.json post /api/threads/{id}/messages","href":"/api-reference/threads/reply-to-a-thread"},{"title":"Resolve a thread","deprecated":null,"version":null,"openapi":"/help-center/api-reference/openapi.json post /api/threads/{id}/resolve","href":"/api-reference/threads/resolve-a-thread"},{"title":"Reopen a thread","deprecated":null,"version":null,"openapi":"/help-center/api-reference/openapi.json post /api/threads/{id}/reopen","href":"/api-reference/threads/reopen-a-thread"},{"title":"Accept a suggestion","deprecated":null,"version":null,"openapi":"/help-center/api-reference/openapi.json post /api/threads/{id}/accept","href":"/api-reference/threads/accept-a-suggestion"},{"title":"Reject a suggestion","deprecated":null,"version":null,"openapi":"/help-center/api-reference/openapi.json post /api/threads/{id}/reject","href":"/api-reference/threads/reject-a-suggestion"}]},{"group":"Activity","pages":[{"title":"Document activity feed","deprecated":null,"version":null,"openapi":"/help-center/api-reference/openapi.json get /api/docs/{id}/activity","href":"/api-reference/activity/document-activity-feed"},{"title":"Organization activity feed","deprecated":null,"version":null,"openapi":"/help-center/api-reference/openapi.json get /api/org/activity","href":"/api-reference/activity/organization-activity-feed"}]},{"group":"Uploads","pages":[{"title":"Fetch an uploaded image","deprecated":null,"version":null,"openapi":"/help-center/api-reference/openapi.json get /api/uploads/{namespace}/{ownerId}/{file}","href":"/api-reference/uploads/fetch-an-uploaded-image"}]}]}]},"basePath":"","title":"Create an API key - Scribe","buildId":"dpl_DqYu5MPb49gWBBbUGgpHQUmCHY3P","deploymentId":"dpl_DqYu5MPb49gWBBbUGgpHQUmCHY3P","dynamics":["c2aa737661","2b790eda92","b0f84f53ff","a9bb46feb3"],"chunks":["OpenApiReferenceProvider-CybtLBIt.js","utils-BMLj2fvV.js","cloneDeep-izs3Hzxb.js","_Uint8Array-BVIqJ90l.js","isObjectLike-C8vmzPEN.js","isArray-Dcu1dQ5t.js","utils-B6In562Y.js","toString-BX-iyh8G.js","isSymbol-CSH9U2Gm.js","addUniqueKeysToSchema-Dr8Mfhp9.js","snippetPresets-2rmQvMVl.js","style-to-object-BY3JEAdk.js","v4-DIgz8zy6.js","conditional-requirements-CFM0id0Q.js","ApiExamples-WMqJYdZj.js","isEqual-BfaiBbcl.js","usePlaygroundInputsStore-CJ-MlPHu.js","shallow-dY3TMRCk.js","getApiPlaygroundDisplay-v-1B2bKm.js","CodeSnippet-BDhiTB7U.js","CodeSnippets-D9hnzQcS.js","Page-C4GwDT3_.js","getPastedJson-Th2V45jI.js","icon-BQXch1W9.js","MethodPill-BCqUneP3.js","DuplicateIcon-Q_-bhurZ.js","createIcon-DUjLHRqp.js","DynamicMarkdown-B-f2cqXQ.js","SectionHeading-Da5NsV4v.js","axios-vUo_bRtp.js","Markdown-D13FWkIM.js","clsx-D3Isdib3.js","lib-DuNMoZ05.js","lib-B8HbPgcC.js","html-void-elements-mCSPHezU.js","dist-C-XZBk9h.js","katex-YMM-FMeD.js","marked.esm-CZWythHk.js","AssistantPageLink--qIqmmVG.js"]}