Makes a short-lived credential that lets the browser of ONE of your managed users use Widgetic’s editor
pieces, such as the File Browser and the Composition Editor, without your API key ever reaching that
browser. Call this from your server when the page that hosts the editor opens, and hand the token in
the answer to that page.
The token is shown once. It starts with wgt_ses_ and the browser sends it as
Authorization: Bearer <token>. It can do only what the surfaces you name allow, and only for this
managed user:
files: upload a file (uploadFile) and list the files uploaded for this user (listUploads). Every
file is filed for this user and stored in your own storage destination, never in Widgetic’s: a file a
customer uploads is yours to keep, and takes none of your storage allowance. Partner storage is not
optional, so no session, whatever its surfaces, can be made until you have set a destination
(setPartnerStorageDestination); until then it is refused with 409 and PARTNER_STORAGE_REQUIRED, and
when the destination cannot be used with 503 and STORAGE_DESTINATION_UNAVAILABLE. A destination you
remove after the session was made stops its uploads too (the same 409; the browser is only told that
the feature is not available right now). To keep a customer from uploading, leave files out of the
session and hand the editors your own media library instead (mediaLibrary).
editor: edit one of this user’s compositions: read it (getCompositionById, its content, design,
embed settings and schemas), check a content change (validateCompositionContent), and change its
name, content, design and embed settings (updateComposition, setDynamicContent). For a widget that
answers visitors’ questions from documents (the ai-answers adapter), it also lists those documents,
adds one as text or as a file (a text file or a picture; a PDF once PDFs are read), and removes one
(getAiAnswersKnowledge, addAiAnswersKnowledgeDocument, addAiAnswersKnowledgeFile,
removeAiAnswersKnowledgeDocument); adding costs no credits, and is limited for each of your users
separately. It can reach
only compositions you created for this managed user (tag them with managedUserId when you create
them); any other composition, including another of your users’, answers 404.
creator: use Widgetic’s Widget Creator for this user, including its AI. Draw on canvases and save
them (getAllCanvases, getCanvas, createCanvas, updateCanvas, previewDeleteCanvas,
deleteCanvas); make, change, copy and delete the widgets on them (createWidget, getWidgets,
getWidgetsBatch, updateWidget, uploadWidgetThumbnail, duplicateWidget, deleteWidget);
list and make the compositions of a widget it built (getAllCompositions, createComposition), which
is how it shows the widget with sample values; keep the
conversation of each widget (getConversationsByWidgetId, createConversationForWidget,
updateConversation, getMessages, createMessage, updateMessage, restoreCheckpoint); and read a
widget’s schemas and give it its repository (getWidgetContentSchema, getWidgetDesignSchema,
updateWidgetRepository). The AI that builds a widget is part of it: list the models
(listLlmModels), open the widget’s repository (createRepository,
getRepository), start a generation and follow or cancel it (generateCode,
streamOperationUpdates, getOperation, cancelOperation), build and preview the result
(getWidgetRepositoryHead, buildWidgetFromRepo, previewWidgetVersion), publish a
version of the widget and move between its versions (publishBuiltWidget,
getWidgetPublishHistory, setWidgetPublishHistoryLive, renameWidgetPublishHistoryTitle), and
turn a stroke or a sentence into a decision (recognizeShape, resolveDesignProperty). It can
also offer the customer your presets as starting points: read them and ask for a copy for this customer
(listMyPresets, copyMyPreset; you choose the presets with setPartnerPreset).
What the session makes is filed for this managed user, and the lists it reads hold only this user’s
canvases, widgets and compositions. It can reach only canvases, widgets, compositions, repositories,
uploaded files and operations made for this managed user (tag the canvases and widgets you create
with managedUserId); any other canvas, widget, composition, conversation, message, repository, file
or operation, including another of your users’, answers 404. The creator also saves the composition
it is editing (updateComposition, from the editor surface) and attaches pictures to its chat
(uploadFile, from the files surface), and the surfaces do not imply one another: to open the
whole creator for a user, ask for creator, editor and files together. A generation or a build
one user starts can be followed and cancelled by that user and by you, never by another of your
users. The AI is paid for by your account, as your own calls are: its credits and allowances are
yours. A session cannot make a widget public (publishing a version does not), file one under a
project or an organization, or set anything the creator does not set: a body with another field is
refused with 403 and EDITOR_SESSION_FIELD_NOT_ALLOWED.
workflows: use Widgetic’s Workflows editor for this user. List their workflows and the compositions
a workflow of theirs can chain (listWorkspaceWorkflows, listWorkspaceWorkflowCompositionOptions);
list the starting points you offer them and make a workflow from one, which gives the user their own copy
of every widget it chains, a composition of their own on each copy, and a draft
(listWorkspaceWorkflowPresets, createWorkspaceWorkflowFromPreset; you offer them with
setPartnerWorkflowPreset);
make, open, change and delete one (createWorkspaceWorkflow, getWorkspaceWorkflow,
saveWorkspaceWorkflow, deleteWorkspaceWorkflow) and copy it (duplicateWorkspaceWorkflow); publish
it or discard the changes of its draft (publishWorkspaceWorkflow,
discardWorkspaceWorkflowChanges); read and restore its versions (listWorkspaceWorkflowVersions,
getWorkspaceWorkflowVersion, restoreWorkspaceWorkflowVersion); pause, resume, archive and unarchive it
(pauseWorkspaceWorkflow, resumeWorkspaceWorkflow, archiveWorkspaceWorkflow,
unarchiveWorkspaceWorkflow); and read its counts (getWorkspaceWorkflowStats). The editor’s assistant
chat, beside the canvas, is part of this surface too: the page sends the messages itself (they are not an
operation you call), and it works for this managed user alone. It reads, tries and changes the draft of the
workflow that is open, from the compositions you made for this managed user, and it does not build widgets,
copy templates, make plans, read Open MCPs or suggest what to type next. Its messages use none of your
credits (30 a minute for each of your users), and a message that names a workflow, a composition or a file
that is not this managed user’s answers 404. The workspace in each
path is your partner workspace, the workspaceId the session answers with: a session has no other, and a
path that names any other workspace (a team you belong to included) answers 404. What the
session makes is filed for this managed user (managedUserId), the lists hold only this user’s workflows,
and it can reach only workflows made for this managed user; any other workflow, including one of yours
or of another of your users, answers 404. A workflow can chain only the compositions you made for this
managed user (tag them with managedUserId): one that belongs to anybody else is not available, and
publishing a workflow that uses it is refused. What a customer’s session reads never says who published a
version. A session cannot set who a workflow belongs
to or which workspace it is in: a body with another field is refused with 403 and
EDITOR_SESSION_FIELD_NOT_ALLOWED.
Everything else is refused with 403 and EDITOR_SESSION_ROUTE_NOT_ALLOWED: a session cannot read your
account, make more sessions, change your presets or delete a composition, and a session without the creator surface cannot
create or list compositions. Create the composition yourself with your API key, then open the editor on it.
A session ends at expiresAt (at most four hours), when you end it (revokeManagedUserEditorSession),
or when the managed user is switched off or deleted. A managed user can have at most 100 live sessions at
once (429 EDITOR_SESSION_LIMIT_REACHED). A session that is bound to a web page (allowedOrigin) is
refused from any other origin.
The AI the session runs is paid for with your credits. Set maxCredits to hold the session to a number
of them: once its generations have taken that many (a generation that fails is refunded and does not
count), the next one is refused with 402 and EDITOR_SESSION_CREDIT_LIMIT_REACHED, and the browser is told
only that the feature is not available right now. Without it, the limit Widgetic has set for your account
applies when it has set one (the same limit for every session you make, and maxCredits: null asks for
none), and otherwise the credits of your account are the only ceiling. What each of your users’ sessions
has spent is in getManagedUserUsage.
Each call makes a new session. It does not take an Idempotency-Key: the answer holds the token, and
the token is never stored where a retry could read it back. The answer is sent with
Cache-Control: no-store.
For partners. Send your partner key as a bearer token: Authorization: Bearer <your partner key>. It starts with wgt_prt_ and you make it in your partner's home workspace, under Settings → API keys; any other key is refused with 403. See API keys and Partners.
Path Parameters
id
string<uuid>
required
The managed user the session is for (Widgetic's id for the user)
Body
application/json
surfaces
enum<string>[]
required
The pieces of Widgetic's editor the session may drive. files is the media library (the File Browser: upload a file, list the files uploaded for this user); what a user uploads is kept in your own storage destination. Partner storage is not optional: a session of any surface can be made only once you have set a destination up (setPartnerStorageDestination), and is refused with 409 PARTNER_STORAGE_REQUIRED until then. editor is editing one of this user's compositions: read it, change its name, content, design and embed settings, read its schemas, and ask where to show it (getCompositionPreview: the widget's published page). creator is Widgetic's Widget Creator, with its drawing canvas and its AI: this user's canvases, the widgets on them and the conversation of each widget, the generation, build and publish calls that make a widget, and the compositions of those widgets (list, make). The surfaces do not imply one another: the whole creator also saves a composition (editor) and attaches pictures to its chat (files), so ask for ["creator", "editor", "files"]. workflows is the Workflows editor: this user's own workflows (list, make, make from one of your starting points, draw, publish, pause, resume, archive, delete, the version history and the counts) under /workspaces/{workspaceId}/workflows, where workspaceId is the one the session answers with (your partner workspace, and no other), and the compositions made for this user, which are the only ones a workflow of theirs can chain. A workflow is filed under the user it was made for (managedUserId), and the session reaches nothing of another user's, nor of yours.
Minimum array length: 1
Available options:
files,
editor,
creator,
workflows
Example:
["files", "editor"]
expiresInSeconds
integer
default:3600
How long the session lasts, in seconds. It cannot be extended; make a new session when it ends.
Required range: 60 <= x <= 14400
Example:
3600
allowedOrigin
string | null
Bind the session to one web page origin, such as https://app.example.com (no path; http is accepted only for localhost). The session is then refused from any other origin, and from a request that carries no Origin header. Leave it out for a session that can be used from anywhere, which is what a server-side caller needs.
Example:
"https://app.example.com"
maxCredits
integer
The most credits this session may spend on Widgetic's AI, one credit being one generation. Once the operations it ran have taken that many, the next one is refused (402, EDITOR_SESSION_CREDIT_LIMIT_REACHED) and the browser is only told that the feature is not available right now. A generation that fails is refunded and does not count. Leave it out to get the limit Widgetic has set for your account, if it has set one (it sets none unless you ask), and otherwise no limit of its own, which leaves the credits of your account as the only ceiling. Send null to ask for no limit of its own even when a default is set.
Required range: 1 <= x <= 1000000
Example:
20
Response
The session, with its token (shown once)
success
boolean
required
Always true on a success.
Example:
true
data
object
required
An editor session you have just made. token is shown once and cannot be read again: hand it to the browser of this one user and keep it out of logs and storage.
Extra information about the answer: where a page sits in a list, the cursor of the next page, or warnings about a call that succeeded with a caveat.
Show child attributes
{"docsConfig":{"theme":"mint","$schema":"https://mintlify.com/docs.json","name":"Developer documentation","colors":{"primary":"#204427","light":"#4cbf61","dark":"#204427"},"logo":{"light":"https://mintcdn.com/widgetic/HN5UMRJIol5DDGOU/brand/logo-light.svg?fit=max\u0026auto=format\u0026n=HN5UMRJIol5DDGOU\u0026q=85\u0026s=a76d6a0ea3ca3b56f89acbc1abc6ea7d","dark":"https://mintcdn.com/widgetic/HN5UMRJIol5DDGOU/brand/logo-dark.svg?fit=max\u0026auto=format\u0026n=HN5UMRJIol5DDGOU\u0026q=85\u0026s=4c81361572aff3e7d536aa46355976df"},"favicon":"https://mintcdn.com/widgetic/iwJu9rJlcIK3wC2N/brand/favicon.svg?fit=max\u0026auto=format\u0026n=iwJu9rJlcIK3wC2N\u0026q=85\u0026s=cbe476975e26f7169190143fcae185ea","api":{"examples":{"autogenerate":false}},"appearance":{"default":"system"},"background":{"color":{"light":"#ffffff","dark":"#152e1a"}},"navbar":{"links":[{"href":"https://widgetic.com/workspaces","label":"Dashboard"}],"primary":{"type":"button","label":"Get an API key","href":"https://widgetic.com/workspaces?settings=api-keys"}},"footer":{"socials":{"x":"https://x.com/widgetic","github":"https://github.com/widgetic"},"links":[{"header":"Build","items":[{"label":"Quickstart","href":"/docs/quickstart"},{"label":"API reference","href":"/api-reference/introduction"},{"label":"AI agents (MCP)","href":"/docs/agents/overview"},{"label":"CLI","href":"/docs/cli/getting-started"}]},{"header":"Resources","items":[{"label":"Code examples","href":"/resources/examples"},{"label":"SDKs","href":"/docs/sdks/overview"},{"label":"Security","href":"/resources/security"},{"label":"Changelog","href":"/docs/reference/changelog"}]},{"header":"Widgetic","items":[{"label":"Website","href":"https://widgetic.com"},{"label":"Dashboard","href":"https://widgetic.com/workspaces"},{"label":"Pricing","href":"https://widgetic.com/pricing"},{"label":"Support","href":"/docs/introduction"}]},{"header":"Legal","items":[{"label":"Privacy","href":"https://widgetic.com/legal/privacy"},{"label":"Terms","href":"https://widgetic.com/legal/terms"},{"label":"License","href":"/resources/license"}]}]},"seo":{"metatags":{"og:site_name":"Widgetic Developers","twitter:card":"summary_large_image","twitter:site":"@widgetic"}},"fonts":{"family":"Inter"},"styling":{"codeblocks":{"theme":"css-variables"},"latex":false},"errors":{"404":{"redirect":false,"title":"Page not found","description":"We couldn't find the page you were looking for.\n\n\u003cCardGroup cols={2}>\n \u003cCard title=\"Documentation\" icon=\"book\" href=\"/docs/introduction\">\n Return to the home page\n \u003c/Card>\n \u003cCard title=\"Quickstart\" icon=\"rocket\" href=\"/docs/quickstart\">\n Get started in minutes\n \u003c/Card>\n \u003cCard title=\"API Reference\" icon=\"code\" href=\"/api-reference/introduction\">\n Explore API endpoints\n \u003c/Card>\n \u003cCard title=\"SDKs\" icon=\"cube\" href=\"/docs/sdks/overview\">\n Explore our SDKs\n \u003c/Card>\n\u003c/CardGroup>\n\n\u003cInfo>\n Think this is a broken link? Tell [the support team](/docs/introduction#need-help).\n\u003c/Info>"}},"contextual":{"options":["copy","view","chatgpt","claude","perplexity","mcp","cursor","vscode"],"display":"header"},"thumbnails":{"preset":"classic","appearance":"light","surface":"neutral","fonts":{"family":"Inter"}},"variables":{"bashSdkVersion":"1.11.151","cliContractOperations":"169","cliContractsVersion":"3.1.1","cliMcpTools":"56","cliRestOperations":"159","cliToolContractVersion":"1.26.0","cliVersion":"0.1.17","csharpSdkVersion":"1.11.151","embedSdkVersion":"2.1.10","goSdkVersion":"1.11.151","javaSdkVersion":"1.11.151","phpSdkVersion":"1.11.151","pythonSdkVersion":"1.11.151","rubySdkVersion":"1.11.151","typescriptSdkVersion":"3.1.1","uiSdkVersion":"0.1.21"},"navigation":{"global":{"anchors":[{"anchor":"GitHub","icon":"github","href":"https://github.com/widgetic"},{"anchor":"npm","icon":"npm","href":"https://www.npmjs.com/org/widgetic"}]},"pages":[]}},"deployment":{"deploymentMetadataValue":{"subdomain":"widgetic","hasAudioNarration":false,"actualSubdomain":"widgetic","customDomains":["docs.widgetic.com"],"gitSource":{"type":"github","owner":"widgetic","repo":"docs","deployBranch":"main","contentDirectory":"","isPrivate":true,"mountPath":"","label":"","_id":"6b10aa909ffae5051c3fc2bf"},"entitlements":{},"buildId":"6b12b692fbab6d15d8a6f378","clientVersion":"0.0.4453","searchFilterCounts":[{"language":"default","tag":"API reference","count":230},{"language":"default","tag":"Partners","count":83},{"language":"default","tag":"Guides","count":54},{"language":"default","tag":"Compositions","count":42},{"language":"default","tag":"Webhook events","count":23},{"language":"default","tag":"Workflows","count":21},{"language":"default","tag":"Account","count":16},{"language":"default","tag":"A/B tests","count":15},{"language":"default","tag":"Content","count":12},{"language":"default","tag":"Managed users","count":12}]},"assistantConfig":{},"basePath":"","hasChatPermissions":false,"hasWebMcpPermissions":false,"toggles":[{"name":"kill-isr","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":"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":"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":"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":"turbopuffer-dual-write","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":"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},{"name":"starter-pricing","enabled":true,"variant":{"name":"control","enabled":true,"payload":{"type":"string","value":"control"},"feature_enabled":true},"impressionData":false},{"name":"llms-txt-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"auth-vite-origin","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false}],"starterQuestions":[],"googleFontsInlined":false},"customCss":[{"filePath":"style.css","content":"@font-face{font-family:\"JetBrains Mono\";src:url(\"/fonts/jetbrains-mono-latin-wght-normal.woff2\") format(\"woff2\");font-weight:100 800;font-style:normal;font-display:swap}:root{--widgetic-white: #ffffff;--widgetic-neutral-100: #f5f5f5;--widgetic-neutral-200: #e5e5e5;--widgetic-neutral-550: #676767;--widgetic-ink: #152e1a;--widgetic-deep-forest: #204427;--widgetic-sage: #4cbf61;--widgetic-light-green: #d5fadb;--widgetic-lightest-green: #edfbef;--widgetic-radius-control: 8px;--widgetic-radius-field: 12px;--widgetic-radius-card: 18px;--widgetic-shadow-floating: 0 4px 12px 0 rgb(21 46 26 / 8%);--mint-foreground: var(--widgetic-ink);--mint-background: var(--widgetic-neutral-100);--mint-token-keyword: #2b5fc2;--mint-token-constant: #2b5fc2;--mint-token-function: #2b5fc2;--mint-token-string: #8d2a1b;--mint-token-string-expression: #8d2a1b;--mint-token-parameter: var(--widgetic-ink);--mint-token-comment: var(--widgetic-neutral-550);--mint-token-punctuation: var(--widgetic-ink);--mint-token-link: #2b5fc2;--content-width: 46rem}.dark{--mint-foreground: var(--widgetic-white);--mint-background: var(--widgetic-deep-forest);--mint-token-keyword: #8ab4ff;--mint-token-constant: #8ab4ff;--mint-token-function: #8ab4ff;--mint-token-string: #f0a89a;--mint-token-string-expression: #f0a89a;--mint-token-parameter: var(--widgetic-white);--mint-token-comment: #b9c9bc;--mint-token-punctuation: var(--widgetic-white);--mint-token-link: #8ab4ff}code,pre,kbd,samp{font-family:\"JetBrains Mono\", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace}#content-area table td code{word-break:normal;overflow-wrap:normal}#content-area table td:first-child code{white-space:nowrap}@media (min-width: 1440px){#content-area table td{min-width:0}}.code-block{border:1px solid var(--widgetic-neutral-200);border-radius:var(--widgetic-radius-field)}.code-block [data-component-part=\"code-block-root\"]{border-radius:calc(var(--widgetic-radius-field) - 1px)}.dark .code-block{border-color:rgb(255 255 255 / 12%)}div.code-group{border-radius:var(--widgetic-radius-field)}.code-group [data-component-part=\"code-block-root\"]{border-radius:calc(var(--widgetic-radius-field) - 2px)}.code-group .code-block{border:0}:root:not(.dark) div.code-group{background-color:var(--widgetic-white);border-color:var(--widgetic-neutral-200);color:var(--widgetic-ink)}:root:not(.dark) .code-group [role=\"tab\"]{color:var(--widgetic-neutral-550)}:root:not(.dark) .code-group [role=\"tab\"][data-active]{color:var(--widgetic-deep-forest)}:root:not(.dark) .code-group [role=\"tab\"]:hover>div{background-color:var(--widgetic-neutral-100);color:var(--widgetic-ink)}:root:not(.dark) .code-block-copy-button button{background-color:var(--widgetic-white)!important;border:1px solid var(--widgetic-neutral-200)}:root:not(.dark) .code-block-copy-button svg{color:var(--widgetic-neutral-550)}:root:not(.dark) .code-block-copy-button button:hover svg{color:var(--widgetic-ink)}.card{border-radius:var(--widgetic-radius-card);box-shadow:none;transition:box-shadow 160ms ease}.card:hover{box-shadow:var(--widgetic-shadow-floating)}.callout{border-radius:var(--widgetic-radius-field)}.callout[data-callout-type=\"note\"],.callout[data-callout-type=\"info\"]{background-color:var(--widgetic-neutral-100);border-color:var(--widgetic-neutral-200)}.callout[data-callout-type=\"note\"] [data-component-part=\"callout-content\"],.callout[data-callout-type=\"info\"] [data-component-part=\"callout-content\"],.callout[data-callout-type=\"note\"] [data-component-part=\"callout-icon\"] svg,.callout[data-callout-type=\"info\"] [data-component-part=\"callout-icon\"] svg{color:var(--widgetic-ink)}.callout[data-callout-type=\"tip\"],.callout[data-callout-type=\"check\"]{background-color:var(--widgetic-lightest-green);border-color:var(--widgetic-light-green)}.callout[data-callout-type=\"tip\"] [data-component-part=\"callout-content\"],.callout[data-callout-type=\"check\"] [data-component-part=\"callout-content\"],.callout[data-callout-type=\"tip\"] [data-component-part=\"callout-icon\"] svg,.callout[data-callout-type=\"check\"] [data-component-part=\"callout-icon\"] svg{color:var(--widgetic-deep-forest)}.dark .callout[data-callout-type=\"note\"],.dark .callout[data-callout-type=\"info\"]{background-color:rgb(255 255 255 / 6%);border-color:rgb(255 255 255 / 12%)}.dark .callout[data-callout-type=\"note\"] [data-component-part=\"callout-content\"],.dark .callout[data-callout-type=\"info\"] [data-component-part=\"callout-content\"],.dark .callout[data-callout-type=\"note\"] [data-component-part=\"callout-icon\"] svg,.dark .callout[data-callout-type=\"info\"] [data-component-part=\"callout-icon\"] svg{color:var(--widgetic-neutral-200)}.dark .callout[data-callout-type=\"tip\"],.dark .callout[data-callout-type=\"check\"]{background-color:rgb(76 191 97 / 12%);border-color:rgb(76 191 97 / 30%)}.dark .callout[data-callout-type=\"tip\"] [data-component-part=\"callout-content\"],.dark .callout[data-callout-type=\"check\"] [data-component-part=\"callout-content\"],.dark .callout[data-callout-type=\"tip\"] [data-component-part=\"callout-icon\"] svg,.dark .callout[data-callout-type=\"check\"] [data-component-part=\"callout-icon\"] svg{color:var(--widgetic-light-green)}[data-search-item=\"dialog\"]{border-radius:var(--widgetic-radius-card);box-shadow:var(--widgetic-shadow-floating)}#sidebar-content li[data-active]>a,#sidebar-content li[data-active]>div{background-color:var(--widgetic-light-green);color:var(--widgetic-ink)}.dark #sidebar-content li[data-active]>a,.dark #sidebar-content li[data-active]>div{background-color:var(--widgetic-deep-forest);color:var(--widgetic-white)}#topbar-cta-button a>span:first-child{border-radius:var(--widgetic-radius-control)}.tryit-button{background-color:var(--widgetic-deep-forest)!important;border-radius:var(--widgetic-radius-control)}.dark #topbar-cta-button a>span:first-child,.dark .tryit-button{background-color:var(--widgetic-sage)!important}.dark #topbar-cta-button a span,.dark #topbar-cta-button a svg,.dark .tryit-button{color:var(--widgetic-ink)!important}#page-title{letter-spacing:-0.02em}#content-area h2,#content-area h3{letter-spacing:-0.01em}:focus-visible{outline:2px solid var(--widgetic-deep-forest);outline-offset:2px}.dark :focus-visible{outline-color:var(--widgetic-sage)}@media (prefers-reduced-motion: reduce){*,*::before,*::after{animation-duration:0.01ms!important;animation-iteration-count:1!important;transition-duration:0.01ms!important;scroll-behavior:auto!important}}"}]}
{"page":{"pagePath":"api-reference/managed-users/create-managed-user-editor-session","slug":"/api-reference/managed-users/create-managed-user-editor-session","pageMetadata":{"title":"Create an editor session","description":"Makes a short-lived credential that lets the browser of ONE of your managed users use Widgetic's editor\npieces, such as the File Browser and the Composition Editor, without your API key ever reaching that\nbrowser. Call this from your server when the page that hosts the editor opens, and hand the `token` in\nthe answer to that page.\n\nThe token is shown once. It starts with `wgt_ses_` and the browser sends it as\n`Authorization: Bearer \u003ctoken>`. It can do only what the `surfaces` you name allow, and only for this\nmanaged user:\n\n- `files`: upload a file (`uploadFile`) and list the files uploaded for this user (`listUploads`). Every\n file is filed for this user and stored in your own storage destination, never in Widgetic's: a file a\n customer uploads is yours to keep, and takes none of your storage allowance. Partner storage is not\n optional, so no session, whatever its surfaces, can be made until you have set a destination\n (`setPartnerStorageDestination`); until then it is refused with 409 and `PARTNER_STORAGE_REQUIRED`, and\n when the destination cannot be used with 503 and `STORAGE_DESTINATION_UNAVAILABLE`. A destination you\n remove after the session was made stops its uploads too (the same 409; the browser is only told that\n the feature is not available right now). To keep a customer from uploading, leave `files` out of the\n session and hand the editors your own media library instead (`mediaLibrary`).\n- `editor`: edit one of this user's compositions: read it (`getCompositionById`, its content, design,\n embed settings and schemas), check a content change (`validateCompositionContent`), and change its\n name, content, design and embed settings (`updateComposition`, `setDynamicContent`). For a widget that\n answers visitors' questions from documents (the `ai-answers` adapter), it also lists those documents,\n adds one as text or as a file (a text file or a picture; a PDF once PDFs are read), and removes one\n (`getAiAnswersKnowledge`, `addAiAnswersKnowledgeDocument`, `addAiAnswersKnowledgeFile`,\n `removeAiAnswersKnowledgeDocument`); adding costs no credits, and is limited for each of your users\n separately. It can reach\n only compositions you created for this managed user (tag them with `managedUserId` when you create\n them); any other composition, including another of your users', answers 404.\n- `creator`: use Widgetic's Widget Creator for this user, including its AI. Draw on canvases and save\n them (`getAllCanvases`, `getCanvas`, `createCanvas`, `updateCanvas`, `previewDeleteCanvas`,\n `deleteCanvas`); make, change, copy and delete the widgets on them (`createWidget`, `getWidgets`,\n `getWidgetsBatch`, `updateWidget`, `uploadWidgetThumbnail`, `duplicateWidget`, `deleteWidget`);\n list and make the compositions of a widget it built (`getAllCompositions`, `createComposition`), which\n is how it shows the widget with sample values; keep the\n conversation of each widget (`getConversationsByWidgetId`, `createConversationForWidget`,\n `updateConversation`, `getMessages`, `createMessage`, `updateMessage`, `restoreCheckpoint`); and read a\n widget's schemas and give it its repository (`getWidgetContentSchema`, `getWidgetDesignSchema`,\n `updateWidgetRepository`). The AI that builds a widget is part of it: list the models\n (`listLlmModels`), open the widget's repository (`createRepository`,\n `getRepository`), start a generation and follow or cancel it (`generateCode`,\n `streamOperationUpdates`, `getOperation`, `cancelOperation`), build and preview the result\n (`getWidgetRepositoryHead`, `buildWidgetFromRepo`, `previewWidgetVersion`), publish a\n version of the widget and move between its versions (`publishBuiltWidget`,\n `getWidgetPublishHistory`, `setWidgetPublishHistoryLive`, `renameWidgetPublishHistoryTitle`), and\n turn a stroke or a sentence into a decision (`recognizeShape`, `resolveDesignProperty`). It can\n also offer the customer your presets as starting points: read them and ask for a copy for this customer\n (`listMyPresets`, `copyMyPreset`; you choose the presets with `setPartnerPreset`).\n What the session makes is filed for this managed user, and the lists it reads hold only this user's\n canvases, widgets and compositions. It can reach only canvases, widgets, compositions, repositories,\n uploaded files and operations made for this managed user (tag the canvases and widgets you create\n with `managedUserId`); any other canvas, widget, composition, conversation, message, repository, file\n or operation, including another of your users', answers 404. The creator also saves the composition\n it is editing (`updateComposition`, from the `editor` surface) and attaches pictures to its chat\n (`uploadFile`, from the `files` surface), and the surfaces do not imply one another: to open the\n whole creator for a user, ask for `creator`, `editor` and `files` together. A generation or a build\n one user starts can be followed and cancelled by that user and by you, never by another of your\n users. The AI is paid for by your account, as your own calls are: its credits and allowances are\n yours. A session cannot make a widget public (publishing a version does not), file one under a\n project or an organization, or set anything the creator does not set: a body with another field is\n refused with 403 and `EDITOR_SESSION_FIELD_NOT_ALLOWED`.\n- `workflows`: use Widgetic's Workflows editor for this user. List their workflows and the compositions\n a workflow of theirs can chain (`listWorkspaceWorkflows`, `listWorkspaceWorkflowCompositionOptions`);\n list the starting points you offer them and make a workflow from one, which gives the user their own copy\n of every widget it chains, a composition of their own on each copy, and a draft\n (`listWorkspaceWorkflowPresets`, `createWorkspaceWorkflowFromPreset`; you offer them with\n `setPartnerWorkflowPreset`);\n make, open, change and delete one (`createWorkspaceWorkflow`, `getWorkspaceWorkflow`,\n `saveWorkspaceWorkflow`, `deleteWorkspaceWorkflow`) and copy it (`duplicateWorkspaceWorkflow`); publish\n it or discard the changes of its draft (`publishWorkspaceWorkflow`,\n `discardWorkspaceWorkflowChanges`); read and restore its versions (`listWorkspaceWorkflowVersions`,\n `getWorkspaceWorkflowVersion`, `restoreWorkspaceWorkflowVersion`); pause, resume, archive and unarchive it\n (`pauseWorkspaceWorkflow`, `resumeWorkspaceWorkflow`, `archiveWorkspaceWorkflow`,\n `unarchiveWorkspaceWorkflow`); and read its counts (`getWorkspaceWorkflowStats`). The editor's assistant\n chat, beside the canvas, is part of this surface too: the page sends the messages itself (they are not an\n operation you call), and it works for this managed user alone. It reads, tries and changes the draft of the\n workflow that is open, from the compositions you made for this managed user, and it does not build widgets,\n copy templates, make plans, read Open MCPs or suggest what to type next. Its messages use none of your\n credits (30 a minute for each of your users), and a message that names a workflow, a composition or a file\n that is not this managed user's answers 404. The workspace in each\n path is your partner workspace, the `workspaceId` the session answers with: a session has no other, and a\n path that names any other workspace (a team you belong to included) answers 404. What the\n session makes is filed for this managed user (`managedUserId`), the lists hold only this user's workflows,\n and it can reach only workflows made for this managed user; any other workflow, including one of yours\n or of another of your users, answers 404. A workflow can chain only the compositions you made for this\n managed user (tag them with `managedUserId`): one that belongs to anybody else is not available, and\n publishing a workflow that uses it is refused. What a customer's session reads never says who published a\n version. A session cannot set who a workflow belongs\n to or which workspace it is in: a body with another field is refused with 403 and\n `EDITOR_SESSION_FIELD_NOT_ALLOWED`.\n\nEverything else is refused with 403 and `EDITOR_SESSION_ROUTE_NOT_ALLOWED`: a session cannot read your\naccount, make more sessions, change your presets or delete a composition, and a session without the `creator` surface cannot\ncreate or list compositions. Create the composition yourself with your API key, then open the editor on it.\n\nA session ends at `expiresAt` (at most four hours), when you end it (`revokeManagedUserEditorSession`),\nor when the managed user is switched off or deleted. A managed user can have at most 100 live sessions at\nonce (`429 EDITOR_SESSION_LIMIT_REACHED`). A session that is bound to a web page (`allowedOrigin`) is\nrefused from any other origin.\n\nThe AI the session runs is paid for with your credits. Set `maxCredits` to hold the session to a number\nof them: once its generations have taken that many (a generation that fails is refunded and does not\ncount), the next one is refused with 402 and `EDITOR_SESSION_CREDIT_LIMIT_REACHED`, and the browser is told\nonly that the feature is not available right now. Without it, the limit Widgetic has set for your account\napplies when it has set one (the same limit for every session you make, and `maxCredits: null` asks for\nnone), and otherwise the credits of your account are the only ceiling. What each of your users' sessions\nhas spent is in `getManagedUserUsage`.\n\nEach call makes a new session. It does not take an `Idempotency-Key`: the answer holds the token, and\nthe token is never stored where a retry could read it back. The answer is sent with\n`Cache-Control: no-store`.\n","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json post /managed-users/{id}/editor-sessions","href":"/api-reference/managed-users/create-managed-user-editor-session","autogeneratedByOpenApi":true},"description":{"compiledSource":"\"use strict\";\nconst {Fragment: _Fragment, jsx: _jsx, jsxs: _jsxs} = arguments[0];\nconst {useMDXComponents: _provideComponents} = arguments[0];\nfunction _createMdxContent(props) {\n const _components = {\n code: \"code\",\n li: \"li\",\n p: \"p\",\n ul: \"ul\",\n ..._provideComponents(),\n ...props.components\n };\n return _jsxs(_Fragment, {\n children: [_jsxs(_components.p, {\n children: [\"Makes a short-lived credential that lets the browser of ONE of your managed users use Widgetic’s editor\\npieces, such as the File Browser and the Composition Editor, without your API key ever reaching that\\nbrowser. Call this from your server when the page that hosts the editor opens, and hand the \", _jsx(_components.code, {\n children: \"token\"\n }), \" in\\nthe answer to that page.\"]\n }), \"\\n\", _jsxs(_components.p, {\n children: [\"The token is shown once. It starts with \", _jsx(_components.code, {\n children: \"wgt_ses_\"\n }), \" and the browser sends it as\\n\", _jsx(_components.code, {\n children: \"Authorization: Bearer \u003ctoken>\"\n }), \". It can do only what the \", _jsx(_components.code, {\n children: \"surfaces\"\n }), \" you name allow, and only for this\\nmanaged user:\"]\n }), \"\\n\", _jsxs(_components.ul, {\n children: [\"\\n\", _jsxs(_components.li, {\n children: [_jsx(_components.code, {\n children: \"files\"\n }), \": upload a file (\", _jsx(_components.code, {\n children: \"uploadFile\"\n }), \") and list the files uploaded for this user (\", _jsx(_components.code, {\n children: \"listUploads\"\n }), \"). Every\\nfile is filed for this user and stored in your own storage destination, never in Widgetic’s: a file a\\ncustomer uploads is yours to keep, and takes none of your storage allowance. Partner storage is not\\noptional, so no session, whatever its surfaces, can be made until you have set a destination\\n(\", _jsx(_components.code, {\n children: \"setPartnerStorageDestination\"\n }), \"); until then it is refused with 409 and \", _jsx(_components.code, {\n children: \"PARTNER_STORAGE_REQUIRED\"\n }), \", and\\nwhen the destination cannot be used with 503 and \", _jsx(_components.code, {\n children: \"STORAGE_DESTINATION_UNAVAILABLE\"\n }), \". A destination you\\nremove after the session was made stops its uploads too (the same 409; the browser is only told that\\nthe feature is not available right now). To keep a customer from uploading, leave \", _jsx(_components.code, {\n children: \"files\"\n }), \" out of the\\nsession and hand the editors your own media library instead (\", _jsx(_components.code, {\n children: \"mediaLibrary\"\n }), \").\"]\n }), \"\\n\", _jsxs(_components.li, {\n children: [_jsx(_components.code, {\n children: \"editor\"\n }), \": edit one of this user’s compositions: read it (\", _jsx(_components.code, {\n children: \"getCompositionById\"\n }), \", its content, design,\\nembed settings and schemas), check a content change (\", _jsx(_components.code, {\n children: \"validateCompositionContent\"\n }), \"), and change its\\nname, content, design and embed settings (\", _jsx(_components.code, {\n children: \"updateComposition\"\n }), \", \", _jsx(_components.code, {\n children: \"setDynamicContent\"\n }), \"). For a widget that\\nanswers visitors’ questions from documents (the \", _jsx(_components.code, {\n children: \"ai-answers\"\n }), \" adapter), it also lists those documents,\\nadds one as text or as a file (a text file or a picture; a PDF once PDFs are read), and removes one\\n(\", _jsx(_components.code, {\n children: \"getAiAnswersKnowledge\"\n }), \", \", _jsx(_components.code, {\n children: \"addAiAnswersKnowledgeDocument\"\n }), \", \", _jsx(_components.code, {\n children: \"addAiAnswersKnowledgeFile\"\n }), \",\\n\", _jsx(_components.code, {\n children: \"removeAiAnswersKnowledgeDocument\"\n }), \"); adding costs no credits, and is limited for each of your users\\nseparately. It can reach\\nonly compositions you created for this managed user (tag them with \", _jsx(_components.code, {\n children: \"managedUserId\"\n }), \" when you create\\nthem); any other composition, including another of your users’, answers 404.\"]\n }), \"\\n\", _jsxs(_components.li, {\n children: [_jsx(_components.code, {\n children: \"creator\"\n }), \": use Widgetic’s Widget Creator for this user, including its AI. Draw on canvases and save\\nthem (\", _jsx(_components.code, {\n children: \"getAllCanvases\"\n }), \", \", _jsx(_components.code, {\n children: \"getCanvas\"\n }), \", \", _jsx(_components.code, {\n children: \"createCanvas\"\n }), \", \", _jsx(_components.code, {\n children: \"updateCanvas\"\n }), \", \", _jsx(_components.code, {\n children: \"previewDeleteCanvas\"\n }), \",\\n\", _jsx(_components.code, {\n children: \"deleteCanvas\"\n }), \"); make, change, copy and delete the widgets on them (\", _jsx(_components.code, {\n children: \"createWidget\"\n }), \", \", _jsx(_components.code, {\n children: \"getWidgets\"\n }), \",\\n\", _jsx(_components.code, {\n children: \"getWidgetsBatch\"\n }), \", \", _jsx(_components.code, {\n children: \"updateWidget\"\n }), \", \", _jsx(_components.code, {\n children: \"uploadWidgetThumbnail\"\n }), \", \", _jsx(_components.code, {\n children: \"duplicateWidget\"\n }), \", \", _jsx(_components.code, {\n children: \"deleteWidget\"\n }), \");\\nlist and make the compositions of a widget it built (\", _jsx(_components.code, {\n children: \"getAllCompositions\"\n }), \", \", _jsx(_components.code, {\n children: \"createComposition\"\n }), \"), which\\nis how it shows the widget with sample values; keep the\\nconversation of each widget (\", _jsx(_components.code, {\n children: \"getConversationsByWidgetId\"\n }), \", \", _jsx(_components.code, {\n children: \"createConversationForWidget\"\n }), \",\\n\", _jsx(_components.code, {\n children: \"updateConversation\"\n }), \", \", _jsx(_components.code, {\n children: \"getMessages\"\n }), \", \", _jsx(_components.code, {\n children: \"createMessage\"\n }), \", \", _jsx(_components.code, {\n children: \"updateMessage\"\n }), \", \", _jsx(_components.code, {\n children: \"restoreCheckpoint\"\n }), \"); and read a\\nwidget’s schemas and give it its repository (\", _jsx(_components.code, {\n children: \"getWidgetContentSchema\"\n }), \", \", _jsx(_components.code, {\n children: \"getWidgetDesignSchema\"\n }), \",\\n\", _jsx(_components.code, {\n children: \"updateWidgetRepository\"\n }), \"). The AI that builds a widget is part of it: list the models\\n(\", _jsx(_components.code, {\n children: \"listLlmModels\"\n }), \"), open the widget’s repository (\", _jsx(_components.code, {\n children: \"createRepository\"\n }), \",\\n\", _jsx(_components.code, {\n children: \"getRepository\"\n }), \"), start a generation and follow or cancel it (\", _jsx(_components.code, {\n children: \"generateCode\"\n }), \",\\n\", _jsx(_components.code, {\n children: \"streamOperationUpdates\"\n }), \", \", _jsx(_components.code, {\n children: \"getOperation\"\n }), \", \", _jsx(_components.code, {\n children: \"cancelOperation\"\n }), \"), build and preview the result\\n(\", _jsx(_components.code, {\n children: \"getWidgetRepositoryHead\"\n }), \", \", _jsx(_components.code, {\n children: \"buildWidgetFromRepo\"\n }), \", \", _jsx(_components.code, {\n children: \"previewWidgetVersion\"\n }), \"), publish a\\nversion of the widget and move between its versions (\", _jsx(_components.code, {\n children: \"publishBuiltWidget\"\n }), \",\\n\", _jsx(_components.code, {\n children: \"getWidgetPublishHistory\"\n }), \", \", _jsx(_components.code, {\n children: \"setWidgetPublishHistoryLive\"\n }), \", \", _jsx(_components.code, {\n children: \"renameWidgetPublishHistoryTitle\"\n }), \"), and\\nturn a stroke or a sentence into a decision (\", _jsx(_components.code, {\n children: \"recognizeShape\"\n }), \", \", _jsx(_components.code, {\n children: \"resolveDesignProperty\"\n }), \"). It can\\nalso offer the customer your presets as starting points: read them and ask for a copy for this customer\\n(\", _jsx(_components.code, {\n children: \"listMyPresets\"\n }), \", \", _jsx(_components.code, {\n children: \"copyMyPreset\"\n }), \"; you choose the presets with \", _jsx(_components.code, {\n children: \"setPartnerPreset\"\n }), \").\\nWhat the session makes is filed for this managed user, and the lists it reads hold only this user’s\\ncanvases, widgets and compositions. It can reach only canvases, widgets, compositions, repositories,\\nuploaded files and operations made for this managed user (tag the canvases and widgets you create\\nwith \", _jsx(_components.code, {\n children: \"managedUserId\"\n }), \"); any other canvas, widget, composition, conversation, message, repository, file\\nor operation, including another of your users’, answers 404. The creator also saves the composition\\nit is editing (\", _jsx(_components.code, {\n children: \"updateComposition\"\n }), \", from the \", _jsx(_components.code, {\n children: \"editor\"\n }), \" surface) and attaches pictures to its chat\\n(\", _jsx(_components.code, {\n children: \"uploadFile\"\n }), \", from the \", _jsx(_components.code, {\n children: \"files\"\n }), \" surface), and the surfaces do not imply one another: to open the\\nwhole creator for a user, ask for \", _jsx(_components.code, {\n children: \"creator\"\n }), \", \", _jsx(_components.code, {\n children: \"editor\"\n }), \" and \", _jsx(_components.code, {\n children: \"files\"\n }), \" together. A generation or a build\\none user starts can be followed and cancelled by that user and by you, never by another of your\\nusers. The AI is paid for by your account, as your own calls are: its credits and allowances are\\nyours. A session cannot make a widget public (publishing a version does not), file one under a\\nproject or an organization, or set anything the creator does not set: a body with another field is\\nrefused with 403 and \", _jsx(_components.code, {\n children: \"EDITOR_SESSION_FIELD_NOT_ALLOWED\"\n }), \".\"]\n }), \"\\n\", _jsxs(_components.li, {\n children: [_jsx(_components.code, {\n children: \"workflows\"\n }), \": use Widgetic’s Workflows editor for this user. List their workflows and the compositions\\na workflow of theirs can chain (\", _jsx(_components.code, {\n children: \"listWorkspaceWorkflows\"\n }), \", \", _jsx(_components.code, {\n children: \"listWorkspaceWorkflowCompositionOptions\"\n }), \");\\nlist the starting points you offer them and make a workflow from one, which gives the user their own copy\\nof every widget it chains, a composition of their own on each copy, and a draft\\n(\", _jsx(_components.code, {\n children: \"listWorkspaceWorkflowPresets\"\n }), \", \", _jsx(_components.code, {\n children: \"createWorkspaceWorkflowFromPreset\"\n }), \"; you offer them with\\n\", _jsx(_components.code, {\n children: \"setPartnerWorkflowPreset\"\n }), \");\\nmake, open, change and delete one (\", _jsx(_components.code, {\n children: \"createWorkspaceWorkflow\"\n }), \", \", _jsx(_components.code, {\n children: \"getWorkspaceWorkflow\"\n }), \",\\n\", _jsx(_components.code, {\n children: \"saveWorkspaceWorkflow\"\n }), \", \", _jsx(_components.code, {\n children: \"deleteWorkspaceWorkflow\"\n }), \") and copy it (\", _jsx(_components.code, {\n children: \"duplicateWorkspaceWorkflow\"\n }), \"); publish\\nit or discard the changes of its draft (\", _jsx(_components.code, {\n children: \"publishWorkspaceWorkflow\"\n }), \",\\n\", _jsx(_components.code, {\n children: \"discardWorkspaceWorkflowChanges\"\n }), \"); read and restore its versions (\", _jsx(_components.code, {\n children: \"listWorkspaceWorkflowVersions\"\n }), \",\\n\", _jsx(_components.code, {\n children: \"getWorkspaceWorkflowVersion\"\n }), \", \", _jsx(_components.code, {\n children: \"restoreWorkspaceWorkflowVersion\"\n }), \"); pause, resume, archive and unarchive it\\n(\", _jsx(_components.code, {\n children: \"pauseWorkspaceWorkflow\"\n }), \", \", _jsx(_components.code, {\n children: \"resumeWorkspaceWorkflow\"\n }), \", \", _jsx(_components.code, {\n children: \"archiveWorkspaceWorkflow\"\n }), \",\\n\", _jsx(_components.code, {\n children: \"unarchiveWorkspaceWorkflow\"\n }), \"); and read its counts (\", _jsx(_components.code, {\n children: \"getWorkspaceWorkflowStats\"\n }), \"). The editor’s assistant\\nchat, beside the canvas, is part of this surface too: the page sends the messages itself (they are not an\\noperation you call), and it works for this managed user alone. It reads, tries and changes the draft of the\\nworkflow that is open, from the compositions you made for this managed user, and it does not build widgets,\\ncopy templates, make plans, read Open MCPs or suggest what to type next. Its messages use none of your\\ncredits (30 a minute for each of your users), and a message that names a workflow, a composition or a file\\nthat is not this managed user’s answers 404. The workspace in each\\npath is your partner workspace, the \", _jsx(_components.code, {\n children: \"workspaceId\"\n }), \" the session answers with: a session has no other, and a\\npath that names any other workspace (a team you belong to included) answers 404. What the\\nsession makes is filed for this managed user (\", _jsx(_components.code, {\n children: \"managedUserId\"\n }), \"), the lists hold only this user’s workflows,\\nand it can reach only workflows made for this managed user; any other workflow, including one of yours\\nor of another of your users, answers 404. A workflow can chain only the compositions you made for this\\nmanaged user (tag them with \", _jsx(_components.code, {\n children: \"managedUserId\"\n }), \"): one that belongs to anybody else is not available, and\\npublishing a workflow that uses it is refused. What a customer’s session reads never says who published a\\nversion. A session cannot set who a workflow belongs\\nto or which workspace it is in: a body with another field is refused with 403 and\\n\", _jsx(_components.code, {\n children: \"EDITOR_SESSION_FIELD_NOT_ALLOWED\"\n }), \".\"]\n }), \"\\n\"]\n }), \"\\n\", _jsxs(_components.p, {\n children: [\"Everything else is refused with 403 and \", _jsx(_components.code, {\n children: \"EDITOR_SESSION_ROUTE_NOT_ALLOWED\"\n }), \": a session cannot read your\\naccount, make more sessions, change your presets or delete a composition, and a session without the \", _jsx(_components.code, {\n children: \"creator\"\n }), \" surface cannot\\ncreate or list compositions. Create the composition yourself with your API key, then open the editor on it.\"]\n }), \"\\n\", _jsxs(_components.p, {\n children: [\"A session ends at \", _jsx(_components.code, {\n children: \"expiresAt\"\n }), \" (at most four hours), when you end it (\", _jsx(_components.code, {\n children: \"revokeManagedUserEditorSession\"\n }), \"),\\nor when the managed user is switched off or deleted. A managed user can have at most 100 live sessions at\\nonce (\", _jsx(_components.code, {\n children: \"429 EDITOR_SESSION_LIMIT_REACHED\"\n }), \"). A session that is bound to a web page (\", _jsx(_components.code, {\n children: \"allowedOrigin\"\n }), \") is\\nrefused from any other origin.\"]\n }), \"\\n\", _jsxs(_components.p, {\n children: [\"The AI the session runs is paid for with your credits. Set \", _jsx(_components.code, {\n children: \"maxCredits\"\n }), \" to hold the session to a number\\nof them: once its generations have taken that many (a generation that fails is refunded and does not\\ncount), the next one is refused with 402 and \", _jsx(_components.code, {\n children: \"EDITOR_SESSION_CREDIT_LIMIT_REACHED\"\n }), \", and the browser is told\\nonly that the feature is not available right now. Without it, the limit Widgetic has set for your account\\napplies when it has set one (the same limit for every session you make, and \", _jsx(_components.code, {\n children: \"maxCredits: null\"\n }), \" asks for\\nnone), and otherwise the credits of your account are the only ceiling. What each of your users’ sessions\\nhas spent is in \", _jsx(_components.code, {\n children: \"getManagedUserUsage\"\n }), \".\"]\n }), \"\\n\", _jsxs(_components.p, {\n children: [\"Each call makes a new session. It does not take an \", _jsx(_components.code, {\n children: \"Idempotency-Key\"\n }), \": the answer holds the token, and\\nthe token is never stored where a retry could read it back. The answer is sent with\\n\", _jsx(_components.code, {\n children: \"Cache-Control: no-store\"\n }), \".\"]\n })]\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":{"codeStyling":{"theme":"css-variables"},"config":{},"pageMetadata":{"title":"Create an editor session","description":"Makes a short-lived credential that lets the browser of ONE of your managed users use Widgetic's editor\npieces, such as the File Browser and the Composition Editor, without your API key ever reaching that\nbrowser. Call this from your server when the page that hosts the editor opens, and hand the `token` in\nthe answer to that page.\n\nThe token is shown once. It starts with `wgt_ses_` and the browser sends it as\n`Authorization: Bearer \u003ctoken>`. It can do only what the `surfaces` you name allow, and only for this\nmanaged user:\n\n- `files`: upload a file (`uploadFile`) and list the files uploaded for this user (`listUploads`). Every\n file is filed for this user and stored in your own storage destination, never in Widgetic's: a file a\n customer uploads is yours to keep, and takes none of your storage allowance. Partner storage is not\n optional, so no session, whatever its surfaces, can be made until you have set a destination\n (`setPartnerStorageDestination`); until then it is refused with 409 and `PARTNER_STORAGE_REQUIRED`, and\n when the destination cannot be used with 503 and `STORAGE_DESTINATION_UNAVAILABLE`. A destination you\n remove after the session was made stops its uploads too (the same 409; the browser is only told that\n the feature is not available right now). To keep a customer from uploading, leave `files` out of the\n session and hand the editors your own media library instead (`mediaLibrary`).\n- `editor`: edit one of this user's compositions: read it (`getCompositionById`, its content, design,\n embed settings and schemas), check a content change (`validateCompositionContent`), and change its\n name, content, design and embed settings (`updateComposition`, `setDynamicContent`). For a widget that\n answers visitors' questions from documents (the `ai-answers` adapter), it also lists those documents,\n adds one as text or as a file (a text file or a picture; a PDF once PDFs are read), and removes one\n (`getAiAnswersKnowledge`, `addAiAnswersKnowledgeDocument`, `addAiAnswersKnowledgeFile`,\n `removeAiAnswersKnowledgeDocument`); adding costs no credits, and is limited for each of your users\n separately. It can reach\n only compositions you created for this managed user (tag them with `managedUserId` when you create\n them); any other composition, including another of your users', answers 404.\n- `creator`: use Widgetic's Widget Creator for this user, including its AI. Draw on canvases and save\n them (`getAllCanvases`, `getCanvas`, `createCanvas`, `updateCanvas`, `previewDeleteCanvas`,\n `deleteCanvas`); make, change, copy and delete the widgets on them (`createWidget`, `getWidgets`,\n `getWidgetsBatch`, `updateWidget`, `uploadWidgetThumbnail`, `duplicateWidget`, `deleteWidget`);\n list and make the compositions of a widget it built (`getAllCompositions`, `createComposition`), which\n is how it shows the widget with sample values; keep the\n conversation of each widget (`getConversationsByWidgetId`, `createConversationForWidget`,\n `updateConversation`, `getMessages`, `createMessage`, `updateMessage`, `restoreCheckpoint`); and read a\n widget's schemas and give it its repository (`getWidgetContentSchema`, `getWidgetDesignSchema`,\n `updateWidgetRepository`). The AI that builds a widget is part of it: list the models\n (`listLlmModels`), open the widget's repository (`createRepository`,\n `getRepository`), start a generation and follow or cancel it (`generateCode`,\n `streamOperationUpdates`, `getOperation`, `cancelOperation`), build and preview the result\n (`getWidgetRepositoryHead`, `buildWidgetFromRepo`, `previewWidgetVersion`), publish a\n version of the widget and move between its versions (`publishBuiltWidget`,\n `getWidgetPublishHistory`, `setWidgetPublishHistoryLive`, `renameWidgetPublishHistoryTitle`), and\n turn a stroke or a sentence into a decision (`recognizeShape`, `resolveDesignProperty`). It can\n also offer the customer your presets as starting points: read them and ask for a copy for this customer\n (`listMyPresets`, `copyMyPreset`; you choose the presets with `setPartnerPreset`).\n What the session makes is filed for this managed user, and the lists it reads hold only this user's\n canvases, widgets and compositions. It can reach only canvases, widgets, compositions, repositories,\n uploaded files and operations made for this managed user (tag the canvases and widgets you create\n with `managedUserId`); any other canvas, widget, composition, conversation, message, repository, file\n or operation, including another of your users', answers 404. The creator also saves the composition\n it is editing (`updateComposition`, from the `editor` surface) and attaches pictures to its chat\n (`uploadFile`, from the `files` surface), and the surfaces do not imply one another: to open the\n whole creator for a user, ask for `creator`, `editor` and `files` together. A generation or a build\n one user starts can be followed and cancelled by that user and by you, never by another of your\n users. The AI is paid for by your account, as your own calls are: its credits and allowances are\n yours. A session cannot make a widget public (publishing a version does not), file one under a\n project or an organization, or set anything the creator does not set: a body with another field is\n refused with 403 and `EDITOR_SESSION_FIELD_NOT_ALLOWED`.\n- `workflows`: use Widgetic's Workflows editor for this user. List their workflows and the compositions\n a workflow of theirs can chain (`listWorkspaceWorkflows`, `listWorkspaceWorkflowCompositionOptions`);\n list the starting points you offer them and make a workflow from one, which gives the user their own copy\n of every widget it chains, a composition of their own on each copy, and a draft\n (`listWorkspaceWorkflowPresets`, `createWorkspaceWorkflowFromPreset`; you offer them with\n `setPartnerWorkflowPreset`);\n make, open, change and delete one (`createWorkspaceWorkflow`, `getWorkspaceWorkflow`,\n `saveWorkspaceWorkflow`, `deleteWorkspaceWorkflow`) and copy it (`duplicateWorkspaceWorkflow`); publish\n it or discard the changes of its draft (`publishWorkspaceWorkflow`,\n `discardWorkspaceWorkflowChanges`); read and restore its versions (`listWorkspaceWorkflowVersions`,\n `getWorkspaceWorkflowVersion`, `restoreWorkspaceWorkflowVersion`); pause, resume, archive and unarchive it\n (`pauseWorkspaceWorkflow`, `resumeWorkspaceWorkflow`, `archiveWorkspaceWorkflow`,\n `unarchiveWorkspaceWorkflow`); and read its counts (`getWorkspaceWorkflowStats`). The editor's assistant\n chat, beside the canvas, is part of this surface too: the page sends the messages itself (they are not an\n operation you call), and it works for this managed user alone. It reads, tries and changes the draft of the\n workflow that is open, from the compositions you made for this managed user, and it does not build widgets,\n copy templates, make plans, read Open MCPs or suggest what to type next. Its messages use none of your\n credits (30 a minute for each of your users), and a message that names a workflow, a composition or a file\n that is not this managed user's answers 404. The workspace in each\n path is your partner workspace, the `workspaceId` the session answers with: a session has no other, and a\n path that names any other workspace (a team you belong to included) answers 404. What the\n session makes is filed for this managed user (`managedUserId`), the lists hold only this user's workflows,\n and it can reach only workflows made for this managed user; any other workflow, including one of yours\n or of another of your users, answers 404. A workflow can chain only the compositions you made for this\n managed user (tag them with `managedUserId`): one that belongs to anybody else is not available, and\n publishing a workflow that uses it is refused. What a customer's session reads never says who published a\n version. A session cannot set who a workflow belongs\n to or which workspace it is in: a body with another field is refused with 403 and\n `EDITOR_SESSION_FIELD_NOT_ALLOWED`.\n\nEverything else is refused with 403 and `EDITOR_SESSION_ROUTE_NOT_ALLOWED`: a session cannot read your\naccount, make more sessions, change your presets or delete a composition, and a session without the `creator` surface cannot\ncreate or list compositions. Create the composition yourself with your API key, then open the editor on it.\n\nA session ends at `expiresAt` (at most four hours), when you end it (`revokeManagedUserEditorSession`),\nor when the managed user is switched off or deleted. A managed user can have at most 100 live sessions at\nonce (`429 EDITOR_SESSION_LIMIT_REACHED`). A session that is bound to a web page (`allowedOrigin`) is\nrefused from any other origin.\n\nThe AI the session runs is paid for with your credits. Set `maxCredits` to hold the session to a number\nof them: once its generations have taken that many (a generation that fails is refunded and does not\ncount), the next one is refused with 402 and `EDITOR_SESSION_CREDIT_LIMIT_REACHED`, and the browser is told\nonly that the feature is not available right now. Without it, the limit Widgetic has set for your account\napplies when it has set one (the same limit for every session you make, and `maxCredits: null` asks for\nnone), and otherwise the credits of your account are the only ceiling. What each of your users' sessions\nhas spent is in `getManagedUserUsage`.\n\nEach call makes a new session. It does not take an `Idempotency-Key`: the answer holds the token, and\nthe token is never stored where a retry could read it back. The answer is sent with\n`Cache-Control: no-store`.\n","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json post /managed-users/{id}/editor-sessions","href":"/api-reference/managed-users/create-managed-user-editor-session","autogeneratedByOpenApi":true}}},"mdxSourceWithNoJs":null},"mdxExtracts":{"tableOfContents":[],"codeExamples":{}},"jsLinks":[],"openApiReferenceData":{"operation":{"operationId":"createManagedUserEditorSession","summary":"Create an editor session for a managed user","description":"Makes a short-lived credential that lets the browser of ONE of your managed users use Widgetic's editor\npieces, such as the File Browser and the Composition Editor, without your API key ever reaching that\nbrowser. Call this from your server when the page that hosts the editor opens, and hand the `token` in\nthe answer to that page.\n\nThe token is shown once. It starts with `wgt_ses_` and the browser sends it as\n`Authorization: Bearer \u003ctoken>`. It can do only what the `surfaces` you name allow, and only for this\nmanaged user:\n\n- `files`: upload a file (`uploadFile`) and list the files uploaded for this user (`listUploads`). Every\n file is filed for this user and stored in your own storage destination, never in Widgetic's: a file a\n customer uploads is yours to keep, and takes none of your storage allowance. Partner storage is not\n optional, so no session, whatever its surfaces, can be made until you have set a destination\n (`setPartnerStorageDestination`); until then it is refused with 409 and `PARTNER_STORAGE_REQUIRED`, and\n when the destination cannot be used with 503 and `STORAGE_DESTINATION_UNAVAILABLE`. A destination you\n remove after the session was made stops its uploads too (the same 409; the browser is only told that\n the feature is not available right now). To keep a customer from uploading, leave `files` out of the\n session and hand the editors your own media library instead (`mediaLibrary`).\n- `editor`: edit one of this user's compositions: read it (`getCompositionById`, its content, design,\n embed settings and schemas), check a content change (`validateCompositionContent`), and change its\n name, content, design and embed settings (`updateComposition`, `setDynamicContent`). For a widget that\n answers visitors' questions from documents (the `ai-answers` adapter), it also lists those documents,\n adds one as text or as a file (a text file or a picture; a PDF once PDFs are read), and removes one\n (`getAiAnswersKnowledge`, `addAiAnswersKnowledgeDocument`, `addAiAnswersKnowledgeFile`,\n `removeAiAnswersKnowledgeDocument`); adding costs no credits, and is limited for each of your users\n separately. It can reach\n only compositions you created for this managed user (tag them with `managedUserId` when you create\n them); any other composition, including another of your users', answers 404.\n- `creator`: use Widgetic's Widget Creator for this user, including its AI. Draw on canvases and save\n them (`getAllCanvases`, `getCanvas`, `createCanvas`, `updateCanvas`, `previewDeleteCanvas`,\n `deleteCanvas`); make, change, copy and delete the widgets on them (`createWidget`, `getWidgets`,\n `getWidgetsBatch`, `updateWidget`, `uploadWidgetThumbnail`, `duplicateWidget`, `deleteWidget`);\n list and make the compositions of a widget it built (`getAllCompositions`, `createComposition`), which\n is how it shows the widget with sample values; keep the\n conversation of each widget (`getConversationsByWidgetId`, `createConversationForWidget`,\n `updateConversation`, `getMessages`, `createMessage`, `updateMessage`, `restoreCheckpoint`); and read a\n widget's schemas and give it its repository (`getWidgetContentSchema`, `getWidgetDesignSchema`,\n `updateWidgetRepository`). The AI that builds a widget is part of it: list the models\n (`listLlmModels`), open the widget's repository (`createRepository`,\n `getRepository`), start a generation and follow or cancel it (`generateCode`,\n `streamOperationUpdates`, `getOperation`, `cancelOperation`), build and preview the result\n (`getWidgetRepositoryHead`, `buildWidgetFromRepo`, `previewWidgetVersion`), publish a\n version of the widget and move between its versions (`publishBuiltWidget`,\n `getWidgetPublishHistory`, `setWidgetPublishHistoryLive`, `renameWidgetPublishHistoryTitle`), and\n turn a stroke or a sentence into a decision (`recognizeShape`, `resolveDesignProperty`). It can\n also offer the customer your presets as starting points: read them and ask for a copy for this customer\n (`listMyPresets`, `copyMyPreset`; you choose the presets with `setPartnerPreset`).\n What the session makes is filed for this managed user, and the lists it reads hold only this user's\n canvases, widgets and compositions. It can reach only canvases, widgets, compositions, repositories,\n uploaded files and operations made for this managed user (tag the canvases and widgets you create\n with `managedUserId`); any other canvas, widget, composition, conversation, message, repository, file\n or operation, including another of your users', answers 404. The creator also saves the composition\n it is editing (`updateComposition`, from the `editor` surface) and attaches pictures to its chat\n (`uploadFile`, from the `files` surface), and the surfaces do not imply one another: to open the\n whole creator for a user, ask for `creator`, `editor` and `files` together. A generation or a build\n one user starts can be followed and cancelled by that user and by you, never by another of your\n users. The AI is paid for by your account, as your own calls are: its credits and allowances are\n yours. A session cannot make a widget public (publishing a version does not), file one under a\n project or an organization, or set anything the creator does not set: a body with another field is\n refused with 403 and `EDITOR_SESSION_FIELD_NOT_ALLOWED`.\n- `workflows`: use Widgetic's Workflows editor for this user. List their workflows and the compositions\n a workflow of theirs can chain (`listWorkspaceWorkflows`, `listWorkspaceWorkflowCompositionOptions`);\n list the starting points you offer them and make a workflow from one, which gives the user their own copy\n of every widget it chains, a composition of their own on each copy, and a draft\n (`listWorkspaceWorkflowPresets`, `createWorkspaceWorkflowFromPreset`; you offer them with\n `setPartnerWorkflowPreset`);\n make, open, change and delete one (`createWorkspaceWorkflow`, `getWorkspaceWorkflow`,\n `saveWorkspaceWorkflow`, `deleteWorkspaceWorkflow`) and copy it (`duplicateWorkspaceWorkflow`); publish\n it or discard the changes of its draft (`publishWorkspaceWorkflow`,\n `discardWorkspaceWorkflowChanges`); read and restore its versions (`listWorkspaceWorkflowVersions`,\n `getWorkspaceWorkflowVersion`, `restoreWorkspaceWorkflowVersion`); pause, resume, archive and unarchive it\n (`pauseWorkspaceWorkflow`, `resumeWorkspaceWorkflow`, `archiveWorkspaceWorkflow`,\n `unarchiveWorkspaceWorkflow`); and read its counts (`getWorkspaceWorkflowStats`). The editor's assistant\n chat, beside the canvas, is part of this surface too: the page sends the messages itself (they are not an\n operation you call), and it works for this managed user alone. It reads, tries and changes the draft of the\n workflow that is open, from the compositions you made for this managed user, and it does not build widgets,\n copy templates, make plans, read Open MCPs or suggest what to type next. Its messages use none of your\n credits (30 a minute for each of your users), and a message that names a workflow, a composition or a file\n that is not this managed user's answers 404. The workspace in each\n path is your partner workspace, the `workspaceId` the session answers with: a session has no other, and a\n path that names any other workspace (a team you belong to included) answers 404. What the\n session makes is filed for this managed user (`managedUserId`), the lists hold only this user's workflows,\n and it can reach only workflows made for this managed user; any other workflow, including one of yours\n or of another of your users, answers 404. A workflow can chain only the compositions you made for this\n managed user (tag them with `managedUserId`): one that belongs to anybody else is not available, and\n publishing a workflow that uses it is refused. What a customer's session reads never says who published a\n version. A session cannot set who a workflow belongs\n to or which workspace it is in: a body with another field is refused with 403 and\n `EDITOR_SESSION_FIELD_NOT_ALLOWED`.\n\nEverything else is refused with 403 and `EDITOR_SESSION_ROUTE_NOT_ALLOWED`: a session cannot read your\naccount, make more sessions, change your presets or delete a composition, and a session without the `creator` surface cannot\ncreate or list compositions. Create the composition yourself with your API key, then open the editor on it.\n\nA session ends at `expiresAt` (at most four hours), when you end it (`revokeManagedUserEditorSession`),\nor when the managed user is switched off or deleted. A managed user can have at most 100 live sessions at\nonce (`429 EDITOR_SESSION_LIMIT_REACHED`). A session that is bound to a web page (`allowedOrigin`) is\nrefused from any other origin.\n\nThe AI the session runs is paid for with your credits. Set `maxCredits` to hold the session to a number\nof them: once its generations have taken that many (a generation that fails is refunded and does not\ncount), the next one is refused with 402 and `EDITOR_SESSION_CREDIT_LIMIT_REACHED`, and the browser is told\nonly that the feature is not available right now. Without it, the limit Widgetic has set for your account\napplies when it has set one (the same limit for every session you make, and `maxCredits: null` asks for\nnone), and otherwise the credits of your account are the only ceiling. What each of your users' sessions\nhas spent is in `getManagedUserUsage`.\n\nEach call makes a new session. It does not take an `Idempotency-Key`: the answer holds the token, and\nthe token is never stored where a retry could read it back. The answer is sent with\n`Cache-Control: no-store`.\n","tags":["Managed Users"],"x-access-level":"partner","x-visibility":"public","parameters":["c0f2ccad-16ec-4917-a3d1-c205ff6e3cf0"],"requestBody":"42c37464-d635-4b05-8762-276fee9ac87a","responses":{"201":"42ac365f-d3ad-4760-9ae6-6412062375e1","400":"ebdb8fff-aef2-4850-acf8-53f2ac7f6b64","401":"c2effcdc-293e-45d6-8e37-1d8e1f45526f","403":"5d359879-9221-40f7-b91c-af32e4f2af80","404":"026dbe50-e608-4381-9658-84eca4466bff","409":"85b4f271-8b95-451c-b7ba-6e4353ec654b","429":"2c9944b0-1407-4be2-b85d-934800d77bb1","503":"6ffc15c2-b37e-4c90-938e-82e6ea130a02"},"x-mint":{"metadata":{"title":"Create an editor session","tag":"Partner key"}},"security":["3a640e01-45e9-47cb-9706-ce0bba6e1693"],"x-codeSamples":[{"lang":"bash","label":"cURL","source":"curl --request POST \\\n --url 'https://api.widgetic.com/v1/managed-users/123e4567-e89b-12d3-a456-426614174000/editor-sessions' \\\n --header \"Authorization: Bearer $WIDGETIC_API_KEY\" \\\n --header 'Content-Type: application/json' \\\n --data '{\n \"surfaces\": [\n \"files\",\n \"editor\"\n ],\n \"expiresInSeconds\": 3600,\n \"allowedOrigin\": \"https://app.example.com\",\n \"maxCredits\": 20\n}'"},{"lang":"typescript","label":"TypeScript","source":"import { ManagedUsersApi } from '@widgetic/api-sdk-ts';\n\nconst managedUsersApi = new ManagedUsersApi(process.env.WIDGETIC_API_KEY!);\n\nconst result = await managedUsersApi.createManagedUserEditorSession({\n id: '123e4567-e89b-12d3-a456-426614174000',\n newEditorSession: {\n surfaces: ['files', 'editor'],\n expiresInSeconds: 3600,\n allowedOrigin: 'https://app.example.com',\n maxCredits: 20,\n },\n});\nconsole.log(result);"},{"lang":"python","label":"Python","source":"import os\n\nimport api_sdk_py\n\nconfiguration = api_sdk_py.Configuration(access_token=os.environ[\"WIDGETIC_API_KEY\"])\n\nwith api_sdk_py.ApiClient(configuration) as api_client:\n managed_users_api = api_sdk_py.ManagedUsersApi(api_client)\n result = managed_users_api.create_managed_user_editor_session(\n id=\"123e4567-e89b-12d3-a456-426614174000\",\n new_editor_session={\n \"surfaces\": [\"files\", \"editor\"],\n \"expiresInSeconds\": 3600,\n \"allowedOrigin\": \"https://app.example.com\",\n \"maxCredits\": 20,\n },\n )\n print(result)"},{"lang":"go","label":"Go","source":"package main\n\nimport (\n\t\"context\"\n\t\"encoding/json\"\n\t\"fmt\"\n\t\"log\"\n\t\"os\"\n\n\twidgetic \"github.com/widgetic/api-sdk-go\"\n)\n\nfunc main() {\n\tctx := context.WithValue(context.Background(), widgetic.ContextAccessToken, os.Getenv(\"WIDGETIC_API_KEY\"))\n\tclient := widgetic.NewAPIClient(widgetic.NewConfiguration())\n\n\tcreateEditorSessionRequestJSON := `{\n \"surfaces\": [\n \"files\",\n \"editor\"\n ],\n \"expiresInSeconds\": 3600,\n \"allowedOrigin\": \"https://app.example.com\",\n \"maxCredits\": 20\n}`\n\tvar createEditorSessionRequest widgetic.CreateEditorSessionRequest\n\tif err := json.Unmarshal([]byte(createEditorSessionRequestJSON), \u0026createEditorSessionRequest); err != nil {\n\t\tlog.Fatal(err)\n\t}\n\n\tresult, _, err := client.ManagedUsersAPI.CreateManagedUserEditorSession(ctx, \"123e4567-e89b-12d3-a456-426614174000\").\n\t\tCreateEditorSessionRequest(createEditorSessionRequest).\n\t\tExecute()\n\tif err != nil {\n\t\tfmt.Fprintln(os.Stderr, err)\n\t\tos.Exit(1)\n\t}\n\tfmt.Println(result)\n}"},{"lang":"java","label":"Java","source":"import com.widgetic.api.ApiClient;\nimport com.widgetic.api.ApiException;\nimport com.widgetic.api.Configuration;\nimport com.widgetic.api.JSON;\nimport com.widgetic.api.api.ManagedUsersApi;\nimport com.widgetic.api.model.NewEditorSession;\nimport java.util.UUID;\n\npublic class Example {\n public static void main(String[] args) throws ApiException {\n ApiClient client = Configuration.getDefaultApiClient();\n client.setBearerToken(System.getenv(\"WIDGETIC_API_KEY\"));\n\n ManagedUsersApi managedUsersApi = new ManagedUsersApi(client);\n\n String newEditorSessionJson = \"\"\"\n {\n \"surfaces\": [\n \"files\",\n \"editor\"\n ],\n \"expiresInSeconds\": 3600,\n \"allowedOrigin\": \"https://app.example.com\",\n \"maxCredits\": 20\n }\n \"\"\";\n NewEditorSession newEditorSession = JSON.deserialize(newEditorSessionJson, NewEditorSession.class);\n\n var result = managedUsersApi.createManagedUserEditorSession(\n UUID.fromString(\"123e4567-e89b-12d3-a456-426614174000\"),\n newEditorSession\n );\n System.out.println(result);\n }\n}"},{"lang":"csharp","label":"C#","source":"using System;\nusing Newtonsoft.Json;\nusing Widgetic.ApiSdk.Cs.Api;\nusing Widgetic.ApiSdk.Cs.Client;\nusing Widgetic.ApiSdk.Cs.Model;\n\nvar configuration = new Configuration\n{\n AccessToken = Environment.GetEnvironmentVariable(\"WIDGETIC_API_KEY\")!,\n};\nvar managedUsersApi = new ManagedUsersApi(configuration);\n\nvar newEditorSession = JsonConvert.DeserializeObject\u003cNewEditorSession>(\"\"\"\n {\n \"surfaces\": [\n \"files\",\n \"editor\"\n ],\n \"expiresInSeconds\": 3600,\n \"allowedOrigin\": \"https://app.example.com\",\n \"maxCredits\": 20\n }\n \"\"\")!;\n\nvar result = managedUsersApi.CreateManagedUserEditorSession(\n id: Guid.Parse(\"123e4567-e89b-12d3-a456-426614174000\"),\n newEditorSession: newEditorSession\n);\nConsole.WriteLine(result);"},{"lang":"ruby","label":"Ruby","source":"require 'api-sdk-rb'\n\nApiSdkRb.configure do |config|\n config.access_token = ENV['WIDGETIC_API_KEY']\nend\n\nmanaged_users_api = ApiSdkRb::ManagedUsersApi.new\n\nresult = managed_users_api.create_managed_user_editor_session(\n '123e4567-e89b-12d3-a456-426614174000',\n {\n surfaces: ['files', 'editor'],\n expiresInSeconds: 3600,\n allowedOrigin: 'https://app.example.com',\n maxCredits: 20\n }\n)\nputs result"},{"lang":"php","label":"PHP","source":"\u003c?php\n\nrequire_once __DIR__ . '/vendor/autoload.php';\n\nuse WidgeticApi\\Api\\ManagedUsersApi;\nuse WidgeticApi\\Configuration;\nuse WidgeticApi\\Model\\NewEditorSession;\nuse WidgeticApi\\ObjectSerializer;\n\n$config = Configuration::getDefaultConfiguration()->setAccessToken(getenv('WIDGETIC_API_KEY'));\n$managedUsersApi = new ManagedUsersApi(new GuzzleHttp\\Client(), $config);\n\n$newEditorSessionJson = '{\n \"surfaces\": [\n \"files\",\n \"editor\"\n ],\n \"expiresInSeconds\": 3600,\n \"allowedOrigin\": \"https://app.example.com\",\n \"maxCredits\": 20\n}';\n$newEditorSession = ObjectSerializer::deserialize(json_decode($newEditorSessionJson), NewEditorSession::class);\n\n$result = $managedUsersApi->createManagedUserEditorSession(\n id: '123e4567-e89b-12d3-a456-426614174000',\n new_editor_session: $newEditorSession,\n);\nprint_r($result);"},{"lang":"bash","label":"CLI","source":"widgetic api managed-users create-managed-user-editor-session \\\n --id 123e4567-e89b-12d3-a456-426614174000 \\\n --data - \u003c\u003c'EOF'\n{\n \"surfaces\": [\n \"files\",\n \"editor\"\n ],\n \"expiresInSeconds\": 3600,\n \"allowedOrigin\": \"https://app.example.com\",\n \"maxCredits\": 20\n}\nEOF"}],"method":"post","type":"path","servers":["8b04452c-988d-4c1b-b77f-b768793de7f0"],"path":"/managed-users/{id}/editor-sessions","baseUrlOptions":["https://api.widgetic.com/v1"],"title":"Create an editor session for a managed user","codeSamples":[{"label":"cURL","lang":"bash","source":"curl --request POST \\\n --url 'https://api.widgetic.com/v1/managed-users/123e4567-e89b-12d3-a456-426614174000/editor-sessions' \\\n --header \"Authorization: Bearer $WIDGETIC_API_KEY\" \\\n --header 'Content-Type: application/json' \\\n --data '{\n \"surfaces\": [\n \"files\",\n \"editor\"\n ],\n \"expiresInSeconds\": 3600,\n \"allowedOrigin\": \"https://app.example.com\",\n \"maxCredits\": 20\n}'"},{"label":"TypeScript","lang":"typescript","source":"import { ManagedUsersApi } from '@widgetic/api-sdk-ts';\n\nconst managedUsersApi = new ManagedUsersApi(process.env.WIDGETIC_API_KEY!);\n\nconst result = await managedUsersApi.createManagedUserEditorSession({\n id: '123e4567-e89b-12d3-a456-426614174000',\n newEditorSession: {\n surfaces: ['files', 'editor'],\n expiresInSeconds: 3600,\n allowedOrigin: 'https://app.example.com',\n maxCredits: 20,\n },\n});\nconsole.log(result);"},{"label":"Python","lang":"python","source":"import os\n\nimport api_sdk_py\n\nconfiguration = api_sdk_py.Configuration(access_token=os.environ[\"WIDGETIC_API_KEY\"])\n\nwith api_sdk_py.ApiClient(configuration) as api_client:\n managed_users_api = api_sdk_py.ManagedUsersApi(api_client)\n result = managed_users_api.create_managed_user_editor_session(\n id=\"123e4567-e89b-12d3-a456-426614174000\",\n new_editor_session={\n \"surfaces\": [\"files\", \"editor\"],\n \"expiresInSeconds\": 3600,\n \"allowedOrigin\": \"https://app.example.com\",\n \"maxCredits\": 20,\n },\n )\n print(result)"},{"label":"Go","lang":"go","source":"package main\n\nimport (\n\t\"context\"\n\t\"encoding/json\"\n\t\"fmt\"\n\t\"log\"\n\t\"os\"\n\n\twidgetic \"github.com/widgetic/api-sdk-go\"\n)\n\nfunc main() {\n\tctx := context.WithValue(context.Background(), widgetic.ContextAccessToken, os.Getenv(\"WIDGETIC_API_KEY\"))\n\tclient := widgetic.NewAPIClient(widgetic.NewConfiguration())\n\n\tcreateEditorSessionRequestJSON := `{\n \"surfaces\": [\n \"files\",\n \"editor\"\n ],\n \"expiresInSeconds\": 3600,\n \"allowedOrigin\": \"https://app.example.com\",\n \"maxCredits\": 20\n}`\n\tvar createEditorSessionRequest widgetic.CreateEditorSessionRequest\n\tif err := json.Unmarshal([]byte(createEditorSessionRequestJSON), \u0026createEditorSessionRequest); err != nil {\n\t\tlog.Fatal(err)\n\t}\n\n\tresult, _, err := client.ManagedUsersAPI.CreateManagedUserEditorSession(ctx, \"123e4567-e89b-12d3-a456-426614174000\").\n\t\tCreateEditorSessionRequest(createEditorSessionRequest).\n\t\tExecute()\n\tif err != nil {\n\t\tfmt.Fprintln(os.Stderr, err)\n\t\tos.Exit(1)\n\t}\n\tfmt.Println(result)\n}"},{"label":"Java","lang":"java","source":"import com.widgetic.api.ApiClient;\nimport com.widgetic.api.ApiException;\nimport com.widgetic.api.Configuration;\nimport com.widgetic.api.JSON;\nimport com.widgetic.api.api.ManagedUsersApi;\nimport com.widgetic.api.model.NewEditorSession;\nimport java.util.UUID;\n\npublic class Example {\n public static void main(String[] args) throws ApiException {\n ApiClient client = Configuration.getDefaultApiClient();\n client.setBearerToken(System.getenv(\"WIDGETIC_API_KEY\"));\n\n ManagedUsersApi managedUsersApi = new ManagedUsersApi(client);\n\n String newEditorSessionJson = \"\"\"\n {\n \"surfaces\": [\n \"files\",\n \"editor\"\n ],\n \"expiresInSeconds\": 3600,\n \"allowedOrigin\": \"https://app.example.com\",\n \"maxCredits\": 20\n }\n \"\"\";\n NewEditorSession newEditorSession = JSON.deserialize(newEditorSessionJson, NewEditorSession.class);\n\n var result = managedUsersApi.createManagedUserEditorSession(\n UUID.fromString(\"123e4567-e89b-12d3-a456-426614174000\"),\n newEditorSession\n );\n System.out.println(result);\n }\n}"},{"label":"C#","lang":"csharp","source":"using System;\nusing Newtonsoft.Json;\nusing Widgetic.ApiSdk.Cs.Api;\nusing Widgetic.ApiSdk.Cs.Client;\nusing Widgetic.ApiSdk.Cs.Model;\n\nvar configuration = new Configuration\n{\n AccessToken = Environment.GetEnvironmentVariable(\"WIDGETIC_API_KEY\")!,\n};\nvar managedUsersApi = new ManagedUsersApi(configuration);\n\nvar newEditorSession = JsonConvert.DeserializeObject\u003cNewEditorSession>(\"\"\"\n {\n \"surfaces\": [\n \"files\",\n \"editor\"\n ],\n \"expiresInSeconds\": 3600,\n \"allowedOrigin\": \"https://app.example.com\",\n \"maxCredits\": 20\n }\n \"\"\")!;\n\nvar result = managedUsersApi.CreateManagedUserEditorSession(\n id: Guid.Parse(\"123e4567-e89b-12d3-a456-426614174000\"),\n newEditorSession: newEditorSession\n);\nConsole.WriteLine(result);"},{"label":"Ruby","lang":"ruby","source":"require 'api-sdk-rb'\n\nApiSdkRb.configure do |config|\n config.access_token = ENV['WIDGETIC_API_KEY']\nend\n\nmanaged_users_api = ApiSdkRb::ManagedUsersApi.new\n\nresult = managed_users_api.create_managed_user_editor_session(\n '123e4567-e89b-12d3-a456-426614174000',\n {\n surfaces: ['files', 'editor'],\n expiresInSeconds: 3600,\n allowedOrigin: 'https://app.example.com',\n maxCredits: 20\n }\n)\nputs result"},{"label":"PHP","lang":"php","source":"\u003c?php\n\nrequire_once __DIR__ . '/vendor/autoload.php';\n\nuse WidgeticApi\\Api\\ManagedUsersApi;\nuse WidgeticApi\\Configuration;\nuse WidgeticApi\\Model\\NewEditorSession;\nuse WidgeticApi\\ObjectSerializer;\n\n$config = Configuration::getDefaultConfiguration()->setAccessToken(getenv('WIDGETIC_API_KEY'));\n$managedUsersApi = new ManagedUsersApi(new GuzzleHttp\\Client(), $config);\n\n$newEditorSessionJson = '{\n \"surfaces\": [\n \"files\",\n \"editor\"\n ],\n \"expiresInSeconds\": 3600,\n \"allowedOrigin\": \"https://app.example.com\",\n \"maxCredits\": 20\n}';\n$newEditorSession = ObjectSerializer::deserialize(json_decode($newEditorSessionJson), NewEditorSession::class);\n\n$result = $managedUsersApi->createManagedUserEditorSession(\n id: '123e4567-e89b-12d3-a456-426614174000',\n new_editor_session: $newEditorSession,\n);\nprint_r($result);"},{"label":"CLI","lang":"bash","source":"widgetic api managed-users create-managed-user-editor-session \\\n --id 123e4567-e89b-12d3-a456-426614174000 \\\n --data - \u003c\u003c'EOF'\n{\n \"surfaces\": [\n \"files\",\n \"editor\"\n ],\n \"expiresInSeconds\": 3600,\n \"allowedOrigin\": \"https://app.example.com\",\n \"maxCredits\": 20\n}\nEOF"}],"requiredOnlyExamples":false,"disableCodeSampleGeneration":true,"requestExampleType":"codeSamples","responseExampleType":"generated"},"dependencies":{"parameters":{"c0f2ccad-16ec-4917-a3d1-c205ff6e3cf0":{"in":"path","name":"id","required":true,"schema":{"type":"string","format":"uuid","isRequired":true,"description":"The managed user the session is for (Widgetic's id for the user)","uniqueKey":"","typeLabel":"string\u003cuuid>"},"description":"The managed user the session is for (Widgetic's id for the user)"}},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["surfaces"],"properties":{"surfaces":{"type":"array","minItems":1,"items":{"type":"string","enum":["files","editor","creator","workflows"],"uniqueKey":"surfaces.items.[INDEX]","typeLabel":"enum\u003cstring>"},"description":"The pieces of Widgetic's editor the session may drive. `files` is the media library (the File Browser: upload a file, list the files uploaded for this user); what a user uploads is kept in your own storage destination. Partner storage is not optional: a session of any surface can be made only once you have set a destination up (`setPartnerStorageDestination`), and is refused with `409 PARTNER_STORAGE_REQUIRED` until then. `editor` is editing one of this user's compositions: read it, change its name, content, design and embed settings, read its schemas, and ask where to show it (`getCompositionPreview`: the widget's published page). `creator` is Widgetic's Widget Creator, with its drawing canvas and its AI: this user's canvases, the widgets on them and the conversation of each widget, the generation, build and publish calls that make a widget, and the compositions of those widgets (list, make). The surfaces do not imply one another: the whole creator also saves a composition (`editor`) and attaches pictures to its chat (`files`), so ask for `[\"creator\", \"editor\", \"files\"]`. `workflows` is the Workflows editor: this user's own workflows (list, make, make from one of your starting points, draw, publish, pause, resume, archive, delete, the version history and the counts) under `/workspaces/{workspaceId}/workflows`, where `workspaceId` is the one the session answers with (your partner workspace, and no other), and the compositions made for this user, which are the only ones a workflow of theirs can chain. A workflow is filed under the user it was made for (`managedUserId`), and the session reaches nothing of another user's, nor of yours.\n","example":["files","editor"],"isRequired":true,"uniqueKey":"surfaces","typeLabel":"enum\u003cstring>[]"},"expiresInSeconds":{"type":"integer","minimum":60,"maximum":14400,"default":3600,"description":"How long the session lasts, in seconds. It cannot be extended; make a new session when it ends.","example":3600,"uniqueKey":"expiresInSeconds","typeLabel":"integer"},"allowedOrigin":{"oneOf":[{"type":"string","description":"Bind the session to one web page origin, such as `https://app.example.com` (no path; `http` is accepted only for `localhost`). The session is then refused from any other origin, and from a request that carries no `Origin` header. Leave it out for a session that can be used from anywhere, which is what a server-side caller needs.\n","example":"https://app.example.com","uniqueKey":"allowedOrigin.oneOf.0","typeLabel":"string"},{"type":"null","description":"Bind the session to one web page origin, such as `https://app.example.com` (no path; `http` is accepted only for `localhost`). The session is then refused from any other origin, and from a request that carries no `Origin` header. Leave it out for a session that can be used from anywhere, which is what a server-side caller needs.\n","example":"https://app.example.com","uniqueKey":"allowedOrigin.oneOf.1","typeLabel":"null"}],"uniqueKey":"allowedOrigin","typeLabel":"string | null"},"maxCredits":{"type":"integer","minimum":1,"maximum":1000000,"description":"The most credits this session may spend on Widgetic's AI, one credit being one generation. Once the operations it ran have taken that many, the next one is refused (402, `EDITOR_SESSION_CREDIT_LIMIT_REACHED`) and the browser is only told that the feature is not available right now. A generation that fails is refunded and does not count. Leave it out to get the limit Widgetic has set for your account, if it has set one (it sets none unless you ask), and otherwise no limit of its own, which leaves the credits of your account as the only ceiling. Send `null` to ask for no limit of its own even when a default is set.\n","example":20,"uniqueKey":"maxCredits","typeLabel":"integer"}},"example":{"surfaces":["files","editor"],"expiresInSeconds":3600,"allowedOrigin":"https://app.example.com","maxCredits":20},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"surfaces":["files","editor"],"expiresInSeconds":3600,"allowedOrigin":"https://app.example.com","maxCredits":20}}},"exampleType":"generated"}},"exampleType":"generated"},"responses":{"42ac365f-d3ad-4760-9ae6-6412062375e1":{"description":"The session, with its token (shown once)","content":{"application/json":{"schema":{"type":"object","required":["success","data"],"properties":{"success":{"type":"boolean","description":"Always `true` on a success.","example":true,"isRequired":true,"uniqueKey":"success","typeLabel":"boolean"},"data":{"type":"object","description":"An editor session you have just made. `token` is shown once and cannot be read again: hand it to the browser of this one user and keep it out of logs and storage.\n","required":["token","sessionId","managedUserId","managedUserExternalId","workspaceId","surfaces","expiresAt","createdAt"],"properties":{"token":{"type":"string","description":"The credential the browser sends as `Authorization: Bearer \u003ctoken>`. It starts with `wgt_ses_`. It works only for the calls of the session's surfaces, only for this managed user's content, and only until `expiresAt`.\n","example":"wgt_ses_3q2-7wA9vJm5cH1xT0uY8pZkR4nLd6BfGeSoVi2tMqE","isRequired":true,"uniqueKey":"data.token","typeLabel":"string"},"sessionId":{"type":"string","format":"uuid","description":"Identifies the session, so you can end it (`revokeManagedUserEditorSession`). It is not a credential.","isRequired":true,"uniqueKey":"data.sessionId","typeLabel":"string\u003cuuid>"},"managedUserId":{"type":"string","format":"uuid","isRequired":true,"uniqueKey":"data.managedUserId","typeLabel":"string\u003cuuid>"},"managedUserExternalId":{"type":"string","description":"Your own identifier for the managed user","isRequired":true,"uniqueKey":"data.managedUserExternalId","typeLabel":"string"},"workspaceId":{"oneOf":[{"type":"string","format":"uuid","description":"The workspace this user's content is filed in: your partner workspace, the one made with your partner account (your customers have no workspace of their own). The `workflows` surface names it in every path (`/workspaces/{workspaceId}/workflows`), and the Workflows editor takes it as its `workspaceId`. Any other workspace, your teams included, is refused. Null only when your account has no partner workspace.\n","isRequired":true,"uniqueKey":"data.workspaceId.oneOf.0","typeLabel":"string\u003cuuid>"},{"type":"null","format":"uuid","description":"The workspace this user's content is filed in: your partner workspace, the one made with your partner account (your customers have no workspace of their own). The `workflows` surface names it in every path (`/workspaces/{workspaceId}/workflows`), and the Workflows editor takes it as its `workspaceId`. Any other workspace, your teams included, is refused. Null only when your account has no partner workspace.\n","isRequired":true,"uniqueKey":"data.workspaceId.oneOf.1","typeLabel":"null"}],"isRequired":true,"uniqueKey":"data.workspaceId","typeLabel":"string\u003cuuid> | null"},"surfaces":{"type":"array","items":{"type":"string","enum":["files","editor","creator","workflows"],"uniqueKey":"data.surfaces.items.[INDEX]","typeLabel":"enum\u003cstring>"},"isRequired":true,"uniqueKey":"data.surfaces","typeLabel":"enum\u003cstring>[]"},"expiresAt":{"type":"string","format":"date-time","isRequired":true,"uniqueKey":"data.expiresAt","typeLabel":"string\u003cdate-time>"},"createdAt":{"type":"string","format":"date-time","isRequired":true,"uniqueKey":"data.createdAt","typeLabel":"string\u003cdate-time>"},"allowedOrigin":{"oneOf":[{"type":"string","description":"The web page origin the session is bound to, or null when it is not bound","uniqueKey":"data.allowedOrigin.oneOf.0","typeLabel":"string"},{"type":"null","description":"The web page origin the session is bound to, or null when it is not bound","uniqueKey":"data.allowedOrigin.oneOf.1","typeLabel":"null"}],"uniqueKey":"data.allowedOrigin","typeLabel":"string | null"},"maxCredits":{"oneOf":[{"type":"integer","description":"The most credits the session may spend on Widgetic's AI (`max_credits`), or null when it has no limit of its own","uniqueKey":"data.maxCredits.oneOf.0","typeLabel":"integer"},{"type":"null","description":"The most credits the session may spend on Widgetic's AI (`max_credits`), or null when it has no limit of its own","uniqueKey":"data.maxCredits.oneOf.1","typeLabel":"null"}],"uniqueKey":"data.maxCredits","typeLabel":"integer | null"}},"example":{"token":"wgt_ses_3q2-7wA9vJm5cH1xT0uY8pZkR4nLd6BfGeSoVi2tMqE","sessionId":"3fa85f64-5717-4562-b3fc-2c963f66afa6","managedUserId":"3fa85f64-5717-4562-b3fc-2c963f66afa6","managedUserExternalId":"Example managedUserExternalId","workspaceId":"3fa85f64-5717-4562-b3fc-2c963f66afa6","surfaces":[],"allowedOrigin":"Example allowedOrigin","maxCredits":42,"expiresAt":"2026-01-15T09:30:00.000Z","createdAt":"2026-01-15T09:30:00.000Z"},"isRequired":true,"uniqueKey":"data","typeLabel":"object"},"meta":{"type":"object","description":"Extra information about the answer: where a page sits in a list, the cursor of the next page, or warnings about a call that succeeded with a caveat.","additionalProperties":true,"properties":{"page":{"type":"integer","description":"The page that was read, counting from 1.","example":1,"uniqueKey":"meta.page","typeLabel":"integer"},"size":{"type":"integer","description":"How many items one page holds.","example":20,"uniqueKey":"meta.size","typeLabel":"integer"},"total":{"type":"integer","description":"How many items the whole list has.","example":135,"uniqueKey":"meta.total","typeLabel":"integer"},"limit":{"type":"integer","description":"The same as `size`.","example":20,"uniqueKey":"meta.limit","typeLabel":"integer"},"offset":{"type":"integer","description":"How many items come before this page.","example":0,"uniqueKey":"meta.offset","typeLabel":"integer"},"hasNextPage":{"type":"boolean","example":true,"uniqueKey":"meta.hasNextPage","typeLabel":"boolean"},"hasPreviousPage":{"type":"boolean","example":false,"uniqueKey":"meta.hasPreviousPage","typeLabel":"boolean"},"nextCursor":{"oneOf":[{"type":"string","description":"Pass this as `cursor` to read the next page of a list that is read by cursor. `null` on the last page.","uniqueKey":"meta.nextCursor.oneOf.0","typeLabel":"string"},{"type":"null","description":"Pass this as `cursor` to read the next page of a list that is read by cursor. `null` on the last page.","uniqueKey":"meta.nextCursor.oneOf.1","typeLabel":"null"}],"uniqueKey":"meta.nextCursor","typeLabel":"string | null"},"warnings":{"type":"array","items":{"type":"string","uniqueKey":"meta.warnings.items.[INDEX]","typeLabel":"string"},"description":"Things the call did not do, though it succeeded (for example a table that could not be created just now).","uniqueKey":"meta.warnings","typeLabel":"string[]"}},"uniqueKey":"meta","typeLabel":"object"}},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"success":true,"data":{"token":"wgt_ses_3q2-7wA9vJm5cH1xT0uY8pZkR4nLd6BfGeSoVi2tMqE","sessionId":"3fa85f64-5717-4562-b3fc-2c963f66afa6","managedUserId":"3fa85f64-5717-4562-b3fc-2c963f66afa6","managedUserExternalId":"Example managedUserExternalId","workspaceId":"3fa85f64-5717-4562-b3fc-2c963f66afa6","surfaces":[],"allowedOrigin":"Example allowedOrigin","maxCredits":42,"expiresAt":"2026-01-15T09:30:00.000Z","createdAt":"2026-01-15T09:30:00.000Z"},"meta":{"page":1,"size":20,"total":135,"limit":20,"offset":0,"hasNextPage":true,"hasPreviousPage":false,"nextCursor":"\u003cstring>","warnings":["\u003cstring>"]}}}},"exampleType":"generated"}},"exampleType":"generated"},"ebdb8fff-aef2-4850-acf8-53f2ac7f6b64":{"description":"A surface is not one that exists, `expiresInSeconds` or `maxCredits` is out of range, or `allowedOrigin` is not an origin","content":{"application/json":{"schema":{"type":"object","required":["success","message","error"],"additionalProperties":true,"properties":{"success":{"type":"boolean","description":"Always `false` on a failure.","example":false,"isRequired":true,"uniqueKey":"success","typeLabel":"boolean"},"message":{"type":"string","description":"The same text as `error.message`, for a caller that reads one line.","isRequired":true,"uniqueKey":"message","typeLabel":"string"},"error":{"type":"object","required":["code","message","timestamp"],"properties":{"code":{"type":"string","description":"Machine-readable error code.","example":"RESOURCE_NOT_FOUND","isRequired":true,"uniqueKey":"error.code","typeLabel":"string"},"message":{"type":"string","description":"Human-readable explanation.","example":"Composition not found","isRequired":true,"uniqueKey":"error.message","typeLabel":"string"},"timestamp":{"type":"string","format":"date-time","example":"2026-10-15T10:00:00.000Z","isRequired":true,"uniqueKey":"error.timestamp","typeLabel":"string\u003cdate-time>"},"param":{"type":"string","description":"The field that caused the error, when one did.","example":"name","uniqueKey":"error.param","typeLabel":"string"},"docUrl":{"type":"string","description":"Where this error is explained.","uniqueKey":"error.docUrl","typeLabel":"string"},"suggestedAction":{"type":"string","description":"What to do about it.","uniqueKey":"error.suggestedAction","typeLabel":"string"},"retryAfter":{"type":"integer","description":"Seconds to wait before trying again (rate limits). The same number is in the `Retry-After` header.","example":60,"uniqueKey":"error.retryAfter","typeLabel":"integer"},"details":{"type":"object","additionalProperties":true,"description":"More about the error: the fields that failed, a limit that was reached.","uniqueKey":"error.details","typeLabel":"object"},"correlationId":{"type":"string","description":"Quote this when you ask support about the call.","example":"req_123e4567-e89b-12d3-a456-426614174000","uniqueKey":"error.correlationId","typeLabel":"string"}},"isRequired":true,"uniqueKey":"error","typeLabel":"object"}},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"success":false,"message":"\u003cstring>","error":{"code":"RESOURCE_NOT_FOUND","message":"Composition not found","timestamp":"2026-10-15T10:00:00.000Z","param":"name","docUrl":"\u003cstring>","suggestedAction":"\u003cstring>","retryAfter":60,"details":{},"correlationId":"req_123e4567-e89b-12d3-a456-426614174000"}}}},"exampleType":"generated"}},"exampleType":"generated"},"c2effcdc-293e-45d6-8e37-1d8e1f45526f":{"description":"Unauthorized","content":{"application/json":{"schema":{"type":"object","required":["success","message","error"],"additionalProperties":true,"properties":{"success":{"type":"boolean","description":"Always `false` on a failure.","example":false,"isRequired":true,"uniqueKey":"success","typeLabel":"boolean"},"message":{"type":"string","description":"The same text as `error.message`, for a caller that reads one line.","isRequired":true,"uniqueKey":"message","typeLabel":"string"},"error":{"type":"object","required":["code","message","timestamp"],"properties":{"code":{"type":"string","description":"Machine-readable error code.","example":"RESOURCE_NOT_FOUND","isRequired":true,"uniqueKey":"error.code","typeLabel":"string"},"message":{"type":"string","description":"Human-readable explanation.","example":"Composition not found","isRequired":true,"uniqueKey":"error.message","typeLabel":"string"},"timestamp":{"type":"string","format":"date-time","example":"2026-10-15T10:00:00.000Z","isRequired":true,"uniqueKey":"error.timestamp","typeLabel":"string\u003cdate-time>"},"param":{"type":"string","description":"The field that caused the error, when one did.","example":"name","uniqueKey":"error.param","typeLabel":"string"},"docUrl":{"type":"string","description":"Where this error is explained.","uniqueKey":"error.docUrl","typeLabel":"string"},"suggestedAction":{"type":"string","description":"What to do about it.","uniqueKey":"error.suggestedAction","typeLabel":"string"},"retryAfter":{"type":"integer","description":"Seconds to wait before trying again (rate limits). The same number is in the `Retry-After` header.","example":60,"uniqueKey":"error.retryAfter","typeLabel":"integer"},"details":{"type":"object","additionalProperties":true,"description":"More about the error: the fields that failed, a limit that was reached.","uniqueKey":"error.details","typeLabel":"object"},"correlationId":{"type":"string","description":"Quote this when you ask support about the call.","example":"req_123e4567-e89b-12d3-a456-426614174000","uniqueKey":"error.correlationId","typeLabel":"string"}},"isRequired":true,"uniqueKey":"error","typeLabel":"object"}},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"success":false,"message":"\u003cstring>","error":{"code":"RESOURCE_NOT_FOUND","message":"Composition not found","timestamp":"2026-10-15T10:00:00.000Z","param":"name","docUrl":"\u003cstring>","suggestedAction":"\u003cstring>","retryAfter":60,"details":{},"correlationId":"req_123e4567-e89b-12d3-a456-426614174000"}}}},"exampleType":"generated"}},"exampleType":"generated"},"5d359879-9221-40f7-b91c-af32e4f2af80":{"description":"Forbidden - the caller is not a partner, or Widgetic has switched editor sessions off for your account (`EDITOR_SESSIONS_DISABLED_FOR_PARTNER`)","content":{"application/json":{"schema":{"type":"object","required":["success","message","error"],"additionalProperties":true,"properties":{"success":{"type":"boolean","description":"Always `false` on a failure.","example":false,"isRequired":true,"uniqueKey":"success","typeLabel":"boolean"},"message":{"type":"string","description":"The same text as `error.message`, for a caller that reads one line.","isRequired":true,"uniqueKey":"message","typeLabel":"string"},"error":{"type":"object","required":["code","message","timestamp"],"properties":{"code":{"type":"string","description":"Machine-readable error code.","example":"RESOURCE_NOT_FOUND","isRequired":true,"uniqueKey":"error.code","typeLabel":"string"},"message":{"type":"string","description":"Human-readable explanation.","example":"Composition not found","isRequired":true,"uniqueKey":"error.message","typeLabel":"string"},"timestamp":{"type":"string","format":"date-time","example":"2026-10-15T10:00:00.000Z","isRequired":true,"uniqueKey":"error.timestamp","typeLabel":"string\u003cdate-time>"},"param":{"type":"string","description":"The field that caused the error, when one did.","example":"name","uniqueKey":"error.param","typeLabel":"string"},"docUrl":{"type":"string","description":"Where this error is explained.","uniqueKey":"error.docUrl","typeLabel":"string"},"suggestedAction":{"type":"string","description":"What to do about it.","uniqueKey":"error.suggestedAction","typeLabel":"string"},"retryAfter":{"type":"integer","description":"Seconds to wait before trying again (rate limits). The same number is in the `Retry-After` header.","example":60,"uniqueKey":"error.retryAfter","typeLabel":"integer"},"details":{"type":"object","additionalProperties":true,"description":"More about the error: the fields that failed, a limit that was reached.","uniqueKey":"error.details","typeLabel":"object"},"correlationId":{"type":"string","description":"Quote this when you ask support about the call.","example":"req_123e4567-e89b-12d3-a456-426614174000","uniqueKey":"error.correlationId","typeLabel":"string"}},"isRequired":true,"uniqueKey":"error","typeLabel":"object"}},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"success":false,"message":"\u003cstring>","error":{"code":"RESOURCE_NOT_FOUND","message":"Composition not found","timestamp":"2026-10-15T10:00:00.000Z","param":"name","docUrl":"\u003cstring>","suggestedAction":"\u003cstring>","retryAfter":60,"details":{},"correlationId":"req_123e4567-e89b-12d3-a456-426614174000"}}}},"exampleType":"generated"}},"exampleType":"generated"},"026dbe50-e608-4381-9658-84eca4466bff":{"description":"No managed user with this id on your account (`MANAGED_USER_NOT_FOUND`). Another partner's managed user answers 404 as well.","content":{"application/json":{"schema":{"type":"object","required":["success","message","error"],"additionalProperties":true,"properties":{"success":{"type":"boolean","description":"Always `false` on a failure.","example":false,"isRequired":true,"uniqueKey":"success","typeLabel":"boolean"},"message":{"type":"string","description":"The same text as `error.message`, for a caller that reads one line.","isRequired":true,"uniqueKey":"message","typeLabel":"string"},"error":{"type":"object","required":["code","message","timestamp"],"properties":{"code":{"type":"string","description":"Machine-readable error code.","example":"RESOURCE_NOT_FOUND","isRequired":true,"uniqueKey":"error.code","typeLabel":"string"},"message":{"type":"string","description":"Human-readable explanation.","example":"Composition not found","isRequired":true,"uniqueKey":"error.message","typeLabel":"string"},"timestamp":{"type":"string","format":"date-time","example":"2026-10-15T10:00:00.000Z","isRequired":true,"uniqueKey":"error.timestamp","typeLabel":"string\u003cdate-time>"},"param":{"type":"string","description":"The field that caused the error, when one did.","example":"name","uniqueKey":"error.param","typeLabel":"string"},"docUrl":{"type":"string","description":"Where this error is explained.","uniqueKey":"error.docUrl","typeLabel":"string"},"suggestedAction":{"type":"string","description":"What to do about it.","uniqueKey":"error.suggestedAction","typeLabel":"string"},"retryAfter":{"type":"integer","description":"Seconds to wait before trying again (rate limits). The same number is in the `Retry-After` header.","example":60,"uniqueKey":"error.retryAfter","typeLabel":"integer"},"details":{"type":"object","additionalProperties":true,"description":"More about the error: the fields that failed, a limit that was reached.","uniqueKey":"error.details","typeLabel":"object"},"correlationId":{"type":"string","description":"Quote this when you ask support about the call.","example":"req_123e4567-e89b-12d3-a456-426614174000","uniqueKey":"error.correlationId","typeLabel":"string"}},"isRequired":true,"uniqueKey":"error","typeLabel":"object"}},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"success":false,"message":"\u003cstring>","error":{"code":"RESOURCE_NOT_FOUND","message":"Composition not found","timestamp":"2026-10-15T10:00:00.000Z","param":"name","docUrl":"\u003cstring>","suggestedAction":"\u003cstring>","retryAfter":60,"details":{},"correlationId":"req_123e4567-e89b-12d3-a456-426614174000"}}}},"exampleType":"generated"}},"exampleType":"generated"},"85b4f271-8b95-451c-b7ba-6e4353ec654b":{"description":"The managed user is switched off, so no session can be made for it (`MANAGED_USER_INACTIVE`); or you have not set a storage destination (`PARTNER_STORAGE_REQUIRED`)","content":{"application/json":{"schema":{"type":"object","required":["success","message","error"],"additionalProperties":true,"properties":{"success":{"type":"boolean","description":"Always `false` on a failure.","example":false,"isRequired":true,"uniqueKey":"success","typeLabel":"boolean"},"message":{"type":"string","description":"The same text as `error.message`, for a caller that reads one line.","isRequired":true,"uniqueKey":"message","typeLabel":"string"},"error":{"type":"object","required":["code","message","timestamp"],"properties":{"code":{"type":"string","description":"Machine-readable error code.","example":"RESOURCE_NOT_FOUND","isRequired":true,"uniqueKey":"error.code","typeLabel":"string"},"message":{"type":"string","description":"Human-readable explanation.","example":"Composition not found","isRequired":true,"uniqueKey":"error.message","typeLabel":"string"},"timestamp":{"type":"string","format":"date-time","example":"2026-10-15T10:00:00.000Z","isRequired":true,"uniqueKey":"error.timestamp","typeLabel":"string\u003cdate-time>"},"param":{"type":"string","description":"The field that caused the error, when one did.","example":"name","uniqueKey":"error.param","typeLabel":"string"},"docUrl":{"type":"string","description":"Where this error is explained.","uniqueKey":"error.docUrl","typeLabel":"string"},"suggestedAction":{"type":"string","description":"What to do about it.","uniqueKey":"error.suggestedAction","typeLabel":"string"},"retryAfter":{"type":"integer","description":"Seconds to wait before trying again (rate limits). The same number is in the `Retry-After` header.","example":60,"uniqueKey":"error.retryAfter","typeLabel":"integer"},"details":{"type":"object","additionalProperties":true,"description":"More about the error: the fields that failed, a limit that was reached.","uniqueKey":"error.details","typeLabel":"object"},"correlationId":{"type":"string","description":"Quote this when you ask support about the call.","example":"req_123e4567-e89b-12d3-a456-426614174000","uniqueKey":"error.correlationId","typeLabel":"string"}},"isRequired":true,"uniqueKey":"error","typeLabel":"object"}},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"success":false,"message":"\u003cstring>","error":{"code":"RESOURCE_NOT_FOUND","message":"Composition not found","timestamp":"2026-10-15T10:00:00.000Z","param":"name","docUrl":"\u003cstring>","suggestedAction":"\u003cstring>","retryAfter":60,"details":{},"correlationId":"req_123e4567-e89b-12d3-a456-426614174000"}}}},"exampleType":"generated"}},"exampleType":"generated"},"2c9944b0-1407-4be2-b85d-934800d77bb1":{"description":"The managed user already has the most live sessions allowed (`EDITOR_SESSION_LIMIT_REACHED`)","content":{"application/json":{"schema":{"type":"object","required":["success","message","error"],"additionalProperties":true,"properties":{"success":{"type":"boolean","description":"Always `false` on a failure.","example":false,"isRequired":true,"uniqueKey":"success","typeLabel":"boolean"},"message":{"type":"string","description":"The same text as `error.message`, for a caller that reads one line.","isRequired":true,"uniqueKey":"message","typeLabel":"string"},"error":{"type":"object","required":["code","message","timestamp"],"properties":{"code":{"type":"string","description":"Machine-readable error code.","example":"RESOURCE_NOT_FOUND","isRequired":true,"uniqueKey":"error.code","typeLabel":"string"},"message":{"type":"string","description":"Human-readable explanation.","example":"Composition not found","isRequired":true,"uniqueKey":"error.message","typeLabel":"string"},"timestamp":{"type":"string","format":"date-time","example":"2026-10-15T10:00:00.000Z","isRequired":true,"uniqueKey":"error.timestamp","typeLabel":"string\u003cdate-time>"},"param":{"type":"string","description":"The field that caused the error, when one did.","example":"name","uniqueKey":"error.param","typeLabel":"string"},"docUrl":{"type":"string","description":"Where this error is explained.","uniqueKey":"error.docUrl","typeLabel":"string"},"suggestedAction":{"type":"string","description":"What to do about it.","uniqueKey":"error.suggestedAction","typeLabel":"string"},"retryAfter":{"type":"integer","description":"Seconds to wait before trying again (rate limits). The same number is in the `Retry-After` header.","example":60,"uniqueKey":"error.retryAfter","typeLabel":"integer"},"details":{"type":"object","additionalProperties":true,"description":"More about the error: the fields that failed, a limit that was reached.","uniqueKey":"error.details","typeLabel":"object"},"correlationId":{"type":"string","description":"Quote this when you ask support about the call.","example":"req_123e4567-e89b-12d3-a456-426614174000","uniqueKey":"error.correlationId","typeLabel":"string"}},"isRequired":true,"uniqueKey":"error","typeLabel":"object"}},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"success":false,"message":"\u003cstring>","error":{"code":"RESOURCE_NOT_FOUND","message":"Composition not found","timestamp":"2026-10-15T10:00:00.000Z","param":"name","docUrl":"\u003cstring>","suggestedAction":"\u003cstring>","retryAfter":60,"details":{},"correlationId":"req_123e4567-e89b-12d3-a456-426614174000"}}}},"exampleType":"generated"}},"exampleType":"generated"},"6ffc15c2-b37e-4c90-938e-82e6ea130a02":{"description":"Editor sessions are switched off for the moment (`EDITOR_SESSIONS_DISABLED`), or your storage destination cannot be used (`STORAGE_DESTINATION_UNAVAILABLE`). Try again later.","content":{"application/json":{"schema":{"type":"object","required":["success","message","error"],"additionalProperties":true,"properties":{"success":{"type":"boolean","description":"Always `false` on a failure.","example":false,"isRequired":true,"uniqueKey":"success","typeLabel":"boolean"},"message":{"type":"string","description":"The same text as `error.message`, for a caller that reads one line.","isRequired":true,"uniqueKey":"message","typeLabel":"string"},"error":{"type":"object","required":["code","message","timestamp"],"properties":{"code":{"type":"string","description":"Machine-readable error code.","example":"RESOURCE_NOT_FOUND","isRequired":true,"uniqueKey":"error.code","typeLabel":"string"},"message":{"type":"string","description":"Human-readable explanation.","example":"Composition not found","isRequired":true,"uniqueKey":"error.message","typeLabel":"string"},"timestamp":{"type":"string","format":"date-time","example":"2026-10-15T10:00:00.000Z","isRequired":true,"uniqueKey":"error.timestamp","typeLabel":"string\u003cdate-time>"},"param":{"type":"string","description":"The field that caused the error, when one did.","example":"name","uniqueKey":"error.param","typeLabel":"string"},"docUrl":{"type":"string","description":"Where this error is explained.","uniqueKey":"error.docUrl","typeLabel":"string"},"suggestedAction":{"type":"string","description":"What to do about it.","uniqueKey":"error.suggestedAction","typeLabel":"string"},"retryAfter":{"type":"integer","description":"Seconds to wait before trying again (rate limits). The same number is in the `Retry-After` header.","example":60,"uniqueKey":"error.retryAfter","typeLabel":"integer"},"details":{"type":"object","additionalProperties":true,"description":"More about the error: the fields that failed, a limit that was reached.","uniqueKey":"error.details","typeLabel":"object"},"correlationId":{"type":"string","description":"Quote this when you ask support about the call.","example":"req_123e4567-e89b-12d3-a456-426614174000","uniqueKey":"error.correlationId","typeLabel":"string"}},"isRequired":true,"uniqueKey":"error","typeLabel":"object"}},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"success":false,"message":"\u003cstring>","error":{"code":"RESOURCE_NOT_FOUND","message":"Composition not found","timestamp":"2026-10-15T10:00:00.000Z","param":"name","docUrl":"\u003cstring>","suggestedAction":"\u003cstring>","retryAfter":60,"details":{},"correlationId":"req_123e4567-e89b-12d3-a456-426614174000"}}}},"exampleType":"generated"}},"exampleType":"generated"}},"security":{"3a640e01-45e9-47cb-9706-ce0bba6e1693":{"partnerAuth":{"type":"http","scheme":"bearer","bearerFormat":"Partner key","description":"For partners. Send your partner key as a bearer token: `Authorization: Bearer \u003cyour partner key>`. It starts with `wgt_prt_` and you make it in your partner's home workspace, under **Settings → API keys**; any other key is refused with `403`. See [API keys](/docs/api-keys) and [Partners](/docs/partners/overview).","scopes":[],"schemeName":"partnerAuth"}}},"servers":{"8b04452c-988d-4c1b-b77f-b768793de7f0":{"url":"https://api.widgetic.com/v1","description":"Production server"}},"processedSecurityOptions":[{"schemes":[{"scheme":{"type":"http","scheme":"bearer","bearerFormat":"Partner key","description":"For partners. Send your partner key as a bearer token: `Authorization: Bearer \u003cyour partner key>`. It starts with `wgt_prt_` and you make it in your partner's home workspace, under **Settings → API keys**; any other key is refused with `403`. See [API keys](/docs/api-keys) and [Partners](/docs/partners/overview).","scopes":[],"schemeName":"partnerAuth"},"schema":{"title":"Bearer Auth","type":"string","isRequired":true,"description":"For partners. Send your partner key as a bearer token: `Authorization: Bearer \u003cyour partner key>`. It starts with `wgt_prt_` and you make it in your partner's home workspace, under **Settings → API keys**; any other key is refused with `403`. See [API keys](/docs/api-keys) and [Partners](/docs/partners/overview).","format":"bearer","typeLabel":"string\u003cbearer>","deprecated":false},"schemeName":"partnerAuth","name":"Authorization"}],"title":"partnerAuth"}]},"originalFileLocation":"openapi/widgetic-api-public.json"},"subdomain":"widgetic","siteName":"Developer documentation","title":"Create an editor session - Developer documentation","contextualStarterQuestions":[],"navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{}},"lastModified":"2026-12-03T18:18:30.477Z","originalFileLocation":"api-reference/managed-users/create-managed-user-editor-session.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=\"Makes a short-lived credential that lets the browser of ONE of your managed users use Widgetic\u0026#x27;s editor pieces, such as the File Browser and the Composition Editor, without your API key ever reaching that browser. Call this from your server when the page that hosts the editor opens, and hand the token in the answer to that page. The token is shown once. It starts with wgt_ses_ and the browser sends it as Authorization: Bearer . It can do only what the surfaces you name allow, and only for this managed user: - files: upload a file (uploadFile) and list the files uploaded for this user (listUploads). Every file is filed for this user and stored in your own storage destination, never in Widgetic\u0026#x27;s: a file a customer uploads is yours to keep, and takes none of your storage allowance. Partner storage is not optional, so no session, whatever its surfaces, can be made until you have set a destination (setPartnerStorageDestination); until then it is refused with 409 and PARTNER_STORAGE_REQUIRED, and when the destination cannot be used with 503 and STORAGE_DESTINATION_UNAVAILABLE. A destination you remove after the session was made stops its uploads too (the same 409; the browser is only told that the feature is not available right now). To keep a customer from uploading, leave files out of the session and hand the editors your own media library instead (mediaLibrary). - editor: edit one of this user\u0026#x27;s compositions: read it (getCompositionById, its content, design, embed settings and schemas), check a content change (validateCompositionContent), and change its name, content, design and embed settings (updateComposition, setDynamicContent). For a widget that answers visitors\u0026#x27; questions from documents (the ai-answers adapter), it also lists those documents, adds one as text or as a file (a text file or a picture; a PDF once PDFs are read), and removes one (getAiAnswersKnowledge, addAiAnswersKnowledgeDocument, addAiAnswersKnowledgeFile, removeAiAnswersKnowledgeDocument); adding costs no credits, and is limited for each of your users separately. It can reach only compositions you created for this managed user (tag them with managedUserId when you create them); any other composition, including another of your users\u0026#x27;, answers 404. - creator: use Widgetic\u0026#x27;s Widget Creator for this user, including its AI. Draw on canvases and save them (getAllCanvases, getCanvas, createCanvas, updateCanvas, previewDeleteCanvas, deleteCanvas); make, change, copy and delete the widgets on them (createWidget, getWidgets, getWidgetsBatch, updateWidget, uploadWidgetThumbnail, duplicateWidget, deleteWidget); list and make the compositions of a widget it built (getAllCompositions, createComposition), which is how it shows the widget with sample values; keep the conversation of each widget (getConversationsByWidgetId, createConversationForWidget, updateConversation, getMessages, createMessage, updateMessage, restoreCheckpoint); and read a widget\u0026#x27;s schemas and give it its repository (getWidgetContentSchema, getWidgetDesignSchema, updateWidgetRepository). The AI that builds a widget is part of it: list the models (listLlmModels), open the widget\u0026#x27;s repository (createRepository, getRepository), start a generation and follow or cancel it (generateCode, streamOperationUpdates, getOperation, cancelOperation), build and preview the result (getWidgetRepositoryHead, buildWidgetFromRepo, previewWidgetVersion), publish a version of the widget and move between its versions (publishBuiltWidget, getWidgetPublishHistory, setWidgetPublishHistoryLive, renameWidgetPublishHistoryTitle), and turn a stroke or a sentence into a decision (recognizeShape, resolveDesignProperty). It can also offer the customer your presets as starting points: read them and ask for a copy for this customer (listMyPresets, copyMyPreset; you choose the presets with setPartnerPreset). What the session makes is filed for this managed user, and the lists it reads hold only this user\u0026#x27;s canvases, widgets and compositions. It can reach only canvases, widgets, compositions, repositories, uploaded files and operations made for this managed user (tag the canvases and widgets you create with managedUserId); any other canvas, widget, composition, conversation, message, repository, file or operation, including another of your users\u0026#x27;, answers 404. The creator also saves the composition it is editing (updateComposition, from the editor surface) and attaches pictures to its chat (uploadFile, from the files surface), and the surfaces do not imply one another: to open the whole creator for a user, ask for creator, editor and files together. A generation or a build one user starts can be followed and cancelled by that user and by you, never by another of your users. The AI is paid for by your account, as your own calls are: its credits and allowances are yours. A session cannot make a widget public (publishing a version does not), file one under a project or an organization, or set anything the creator does not set: a body with another field is refused with 403 and EDITOR_SESSION_FIELD_NOT_ALLOWED. - workflows: use Widgetic\u0026#x27;s Workflows editor for this user. List their workflows and the compositions a workflow of theirs can chain (listWorkspaceWorkflows, listWorkspaceWorkflowCompositionOptions); list the starting points you offer them and make a workflow from one, which gives the user their own copy of every widget it chains, a composition of their own on each copy, and a draft (listWorkspaceWorkflowPresets, createWorkspaceWorkflowFromPreset; you offer them with setPartnerWorkflowPreset); make, open, change and delete one (createWorkspaceWorkflow, getWorkspaceWorkflow, saveWorkspaceWorkflow, deleteWorkspaceWorkflow) and copy it (duplicateWorkspaceWorkflow); publish it or discard the changes of its draft (publishWorkspaceWorkflow, discardWorkspaceWorkflowChanges); read and restore its versions (listWorkspaceWorkflowVersions, getWorkspaceWorkflowVersion, restoreWorkspaceWorkflowVersion); pause, resume, archive and unarchive it (pauseWorkspaceWorkflow, resumeWorkspaceWorkflow, archiveWorkspaceWorkflow, unarchiveWorkspaceWorkflow); and read its counts (getWorkspaceWorkflowStats). The editor\u0026#x27;s assistant chat, beside the canvas, is part of this surface too: the page sends the messages itself (they are not an operation you call), and it works for this managed user alone. It reads, tries and changes the draft of the workflow that is open, from the compositions you made for this managed user, and it does not build widgets, copy templates, make plans, read Open MCPs or suggest what to type next. Its messages use none of your credits (30 a minute for each of your users), and a message that names a workflow, a composition or a file that is not this managed user\u0026#x27;s answers 404. The workspace in each path is your partner workspace, the workspaceId the session answers with: a session has no other, and a path that names any other workspace (a team you belong to included) answers 404. What the session makes is filed for this managed user (managedUserId), the lists hold only this user\u0026#x27;s workflows, and it can reach only workflows made for this managed user; any other workflow, including one of yours or of another of your users, answers 404. A workflow can chain only the compositions you made for this managed user (tag them with managedUserId): one that belongs to anybody else is not available, and publishing a workflow that uses it is refused. What a customer\u0026#x27;s session reads never says who published a version. A session cannot set who a workflow belongs to or which workspace it is in: a body with another field is refused with 403 and EDITOR_SESSION_FIELD_NOT_ALLOWED. Everything else is refused with 403 and EDITOR_SESSION_ROUTE_NOT_ALLOWED: a session cannot read your account, make more sessions, change your presets or delete a composition, and a session without the creator surface cannot create or list compositions. Create the composition yourself with your API key, then open the editor on it. A session ends at expiresAt (at most four hours), when you end it (revokeManagedUserEditorSession), or when the managed user is switched off or deleted. A managed user can have at most 100 live sessions at once (429 EDITOR_SESSION_LIMIT_REACHED). A session that is bound to a web page (allowedOrigin) is refused from any other origin. The AI the session runs is paid for with your credits. Set maxCredits to hold the session to a number of them: once its generations have taken that many (a generation that fails is refunded and does not count), the next one is refused with 402 and EDITOR_SESSION_CREDIT_LIMIT_REACHED, and the browser is told only that the feature is not available right now. Without it, the limit Widgetic has set for your account applies when it has set one (the same limit for every session you make, and maxCredits: null asks for none), and otherwise the credits of your account are the only ceiling. What each of your users\u0026#x27; sessions has spent is in getManagedUserUsage. Each call makes a new session. It does not take an Idempotency-Key: the answer holds the token, and the token is never stored where a retry could read it back. The answer is sent with Cache-Control: no-store.\">\u003cmeta data-mint-head name=\"application-name\" content=\"Developer documentation\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/widgetic/KpZqnIZ3Xt05XVQ0/_generated/favicon/android-chrome-192x192.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"apple-touch-icon\" type=\"image/png\" sizes=\"180x180\" href=\"/mintlify-assets/_mintlify/favicons/widgetic/KpZqnIZ3Xt05XVQ0/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/widgetic/KpZqnIZ3Xt05XVQ0/_generated/favicon/favicon-16x16.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/widgetic/KpZqnIZ3Xt05XVQ0/_generated/favicon/favicon-32x32.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/widgetic/KpZqnIZ3Xt05XVQ0/_generated/favicon/favicon.ico\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/widgetic/KpZqnIZ3Xt05XVQ0/_generated/favicon-dark/android-chrome-192x192.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/widgetic/KpZqnIZ3Xt05XVQ0/_generated/favicon-dark/favicon-16x16.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/widgetic/KpZqnIZ3Xt05XVQ0/_generated/favicon-dark/favicon-32x32.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/widgetic/KpZqnIZ3Xt05XVQ0/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"Create an editor session - Developer documentation\">\u003cmeta data-mint-head property=\"og:description\" content=\"Makes a short-lived credential that lets the browser of ONE of your managed users use Widgetic\u0026#x27;s editor pieces, such as the File Browser and the Composition Editor, without your API key ever reaching that browser. Call this from your server when the page that hosts the editor opens, and hand the token in the answer to that page. The token is shown once. It starts with wgt_ses_ and the browser sends it as Authorization: Bearer . It can do only what the surfaces you name allow, and only for this managed user: - files: upload a file (uploadFile) and list the files uploaded for this user (listUploads). Every file is filed for this user and stored in your own storage destination, never in Widgetic\u0026#x27;s: a file a customer uploads is yours to keep, and takes none of your storage allowance. Partner storage is not optional, so no session, whatever its surfaces, can be made until you have set a destination (setPartnerStorageDestination); until then it is refused with 409 and PARTNER_STORAGE_REQUIRED, and when the destination cannot be used with 503 and STORAGE_DESTINATION_UNAVAILABLE. A destination you remove after the session was made stops its uploads too (the same 409; the browser is only told that the feature is not available right now). To keep a customer from uploading, leave files out of the session and hand the editors your own media library instead (mediaLibrary). - editor: edit one of this user\u0026#x27;s compositions: read it (getCompositionById, its content, design, embed settings and schemas), check a content change (validateCompositionContent), and change its name, content, design and embed settings (updateComposition, setDynamicContent). For a widget that answers visitors\u0026#x27; questions from documents (the ai-answers adapter), it also lists those documents, adds one as text or as a file (a text file or a picture; a PDF once PDFs are read), and removes one (getAiAnswersKnowledge, addAiAnswersKnowledgeDocument, addAiAnswersKnowledgeFile, removeAiAnswersKnowledgeDocument); adding costs no credits, and is limited for each of your users separately. It can reach only compositions you created for this managed user (tag them with managedUserId when you create them); any other composition, including another of your users\u0026#x27;, answers 404. - creator: use Widgetic\u0026#x27;s Widget Creator for this user, including its AI. Draw on canvases and save them (getAllCanvases, getCanvas, createCanvas, updateCanvas, previewDeleteCanvas, deleteCanvas); make, change, copy and delete the widgets on them (createWidget, getWidgets, getWidgetsBatch, updateWidget, uploadWidgetThumbnail, duplicateWidget, deleteWidget); list and make the compositions of a widget it built (getAllCompositions, createComposition), which is how it shows the widget with sample values; keep the conversation of each widget (getConversationsByWidgetId, createConversationForWidget, updateConversation, getMessages, createMessage, updateMessage, restoreCheckpoint); and read a widget\u0026#x27;s schemas and give it its repository (getWidgetContentSchema, getWidgetDesignSchema, updateWidgetRepository). The AI that builds a widget is part of it: list the models (listLlmModels), open the widget\u0026#x27;s repository (createRepository, getRepository), start a generation and follow or cancel it (generateCode, streamOperationUpdates, getOperation, cancelOperation), build and preview the result (getWidgetRepositoryHead, buildWidgetFromRepo, previewWidgetVersion), publish a version of the widget and move between its versions (publishBuiltWidget, getWidgetPublishHistory, setWidgetPublishHistoryLive, renameWidgetPublishHistoryTitle), and turn a stroke or a sentence into a decision (recognizeShape, resolveDesignProperty). It can also offer the customer your presets as starting points: read them and ask for a copy for this customer (listMyPresets, copyMyPreset; you choose the presets with setPartnerPreset). What the session makes is filed for this managed user, and the lists it reads hold only this user\u0026#x27;s canvases, widgets and compositions. It can reach only canvases, widgets, compositions, repositories, uploaded files and operations made for this managed user (tag the canvases and widgets you create with managedUserId); any other canvas, widget, composition, conversation, message, repository, file or operation, including another of your users\u0026#x27;, answers 404. The creator also saves the composition it is editing (updateComposition, from the editor surface) and attaches pictures to its chat (uploadFile, from the files surface), and the surfaces do not imply one another: to open the whole creator for a user, ask for creator, editor and files together. A generation or a build one user starts can be followed and cancelled by that user and by you, never by another of your users. The AI is paid for by your account, as your own calls are: its credits and allowances are yours. A session cannot make a widget public (publishing a version does not), file one under a project or an organization, or set anything the creator does not set: a body with another field is refused with 403 and EDITOR_SESSION_FIELD_NOT_ALLOWED. - workflows: use Widgetic\u0026#x27;s Workflows editor for this user. List their workflows and the compositions a workflow of theirs can chain (listWorkspaceWorkflows, listWorkspaceWorkflowCompositionOptions); list the starting points you offer them and make a workflow from one, which gives the user their own copy of every widget it chains, a composition of their own on each copy, and a draft (listWorkspaceWorkflowPresets, createWorkspaceWorkflowFromPreset; you offer them with setPartnerWorkflowPreset); make, open, change and delete one (createWorkspaceWorkflow, getWorkspaceWorkflow, saveWorkspaceWorkflow, deleteWorkspaceWorkflow) and copy it (duplicateWorkspaceWorkflow); publish it or discard the changes of its draft (publishWorkspaceWorkflow, discardWorkspaceWorkflowChanges); read and restore its versions (listWorkspaceWorkflowVersions, getWorkspaceWorkflowVersion, restoreWorkspaceWorkflowVersion); pause, resume, archive and unarchive it (pauseWorkspaceWorkflow, resumeWorkspaceWorkflow, archiveWorkspaceWorkflow, unarchiveWorkspaceWorkflow); and read its counts (getWorkspaceWorkflowStats). The editor\u0026#x27;s assistant chat, beside the canvas, is part of this surface too: the page sends the messages itself (they are not an operation you call), and it works for this managed user alone. It reads, tries and changes the draft of the workflow that is open, from the compositions you made for this managed user, and it does not build widgets, copy templates, make plans, read Open MCPs or suggest what to type next. Its messages use none of your credits (30 a minute for each of your users), and a message that names a workflow, a composition or a file that is not this managed user\u0026#x27;s answers 404. The workspace in each path is your partner workspace, the workspaceId the session answers with: a session has no other, and a path that names any other workspace (a team you belong to included) answers 404. What the session makes is filed for this managed user (managedUserId), the lists hold only this user\u0026#x27;s workflows, and it can reach only workflows made for this managed user; any other workflow, including one of yours or of another of your users, answers 404. A workflow can chain only the compositions you made for this managed user (tag them with managedUserId): one that belongs to anybody else is not available, and publishing a workflow that uses it is refused. What a customer\u0026#x27;s session reads never says who published a version. A session cannot set who a workflow belongs to or which workspace it is in: a body with another field is refused with 403 and EDITOR_SESSION_FIELD_NOT_ALLOWED. Everything else is refused with 403 and EDITOR_SESSION_ROUTE_NOT_ALLOWED: a session cannot read your account, make more sessions, change your presets or delete a composition, and a session without the creator surface cannot create or list compositions. Create the composition yourself with your API key, then open the editor on it. A session ends at expiresAt (at most four hours), when you end it (revokeManagedUserEditorSession), or when the managed user is switched off or deleted. A managed user can have at most 100 live sessions at once (429 EDITOR_SESSION_LIMIT_REACHED). A session that is bound to a web page (allowedOrigin) is refused from any other origin. The AI the session runs is paid for with your credits. Set maxCredits to hold the session to a number of them: once its generations have taken that many (a generation that fails is refunded and does not count), the next one is refused with 402 and EDITOR_SESSION_CREDIT_LIMIT_REACHED, and the browser is told only that the feature is not available right now. Without it, the limit Widgetic has set for your account applies when it has set one (the same limit for every session you make, and maxCredits: null asks for none), and otherwise the credits of your account are the only ceiling. What each of your users\u0026#x27; sessions has spent is in getManagedUserUsage. Each call makes a new session. It does not take an Idempotency-Key: the answer holds the token, and the token is never stored where a retry could read it back. The answer is sent with Cache-Control: no-store.\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"Widgetic Developers\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://docs.widgetic.com/api-reference/managed-users/create-managed-user-editor-session\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://widgetic.mintlify.site/_mintlify/api/og/v2?division=Editor+sessions\u0026amp;title=Create+an+editor+session\u0026amp;description=Makes+a+short-lived+credential+that+lets+the+browser+of+ONE+of+your+managed+users+use+Widgetic%27s+editor%0Apieces%2C+such+as+the+File+Browser+and+the+Composition+Edi\u0026amp;theme=44d0f7268a29a11a0c549719\u0026amp;signature=98b25c62ec0571c0bc2ad071eae0d17806efff1ce9018f945238a14d8c8f4319\">\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 editor session - Developer documentation\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"Makes a short-lived credential that lets the browser of ONE of your managed users use Widgetic\u0026#x27;s editor pieces, such as the File Browser and the Composition Editor, without your API key ever reaching that browser. Call this from your server when the page that hosts the editor opens, and hand the token in the answer to that page. The token is shown once. It starts with wgt_ses_ and the browser sends it as Authorization: Bearer . It can do only what the surfaces you name allow, and only for this managed user: - files: upload a file (uploadFile) and list the files uploaded for this user (listUploads). Every file is filed for this user and stored in your own storage destination, never in Widgetic\u0026#x27;s: a file a customer uploads is yours to keep, and takes none of your storage allowance. Partner storage is not optional, so no session, whatever its surfaces, can be made until you have set a destination (setPartnerStorageDestination); until then it is refused with 409 and PARTNER_STORAGE_REQUIRED, and when the destination cannot be used with 503 and STORAGE_DESTINATION_UNAVAILABLE. A destination you remove after the session was made stops its uploads too (the same 409; the browser is only told that the feature is not available right now). To keep a customer from uploading, leave files out of the session and hand the editors your own media library instead (mediaLibrary). - editor: edit one of this user\u0026#x27;s compositions: read it (getCompositionById, its content, design, embed settings and schemas), check a content change (validateCompositionContent), and change its name, content, design and embed settings (updateComposition, setDynamicContent). For a widget that answers visitors\u0026#x27; questions from documents (the ai-answers adapter), it also lists those documents, adds one as text or as a file (a text file or a picture; a PDF once PDFs are read), and removes one (getAiAnswersKnowledge, addAiAnswersKnowledgeDocument, addAiAnswersKnowledgeFile, removeAiAnswersKnowledgeDocument); adding costs no credits, and is limited for each of your users separately. It can reach only compositions you created for this managed user (tag them with managedUserId when you create them); any other composition, including another of your users\u0026#x27;, answers 404. - creator: use Widgetic\u0026#x27;s Widget Creator for this user, including its AI. Draw on canvases and save them (getAllCanvases, getCanvas, createCanvas, updateCanvas, previewDeleteCanvas, deleteCanvas); make, change, copy and delete the widgets on them (createWidget, getWidgets, getWidgetsBatch, updateWidget, uploadWidgetThumbnail, duplicateWidget, deleteWidget); list and make the compositions of a widget it built (getAllCompositions, createComposition), which is how it shows the widget with sample values; keep the conversation of each widget (getConversationsByWidgetId, createConversationForWidget, updateConversation, getMessages, createMessage, updateMessage, restoreCheckpoint); and read a widget\u0026#x27;s schemas and give it its repository (getWidgetContentSchema, getWidgetDesignSchema, updateWidgetRepository). The AI that builds a widget is part of it: list the models (listLlmModels), open the widget\u0026#x27;s repository (createRepository, getRepository), start a generation and follow or cancel it (generateCode, streamOperationUpdates, getOperation, cancelOperation), build and preview the result (getWidgetRepositoryHead, buildWidgetFromRepo, previewWidgetVersion), publish a version of the widget and move between its versions (publishBuiltWidget, getWidgetPublishHistory, setWidgetPublishHistoryLive, renameWidgetPublishHistoryTitle), and turn a stroke or a sentence into a decision (recognizeShape, resolveDesignProperty). It can also offer the customer your presets as starting points: read them and ask for a copy for this customer (listMyPresets, copyMyPreset; you choose the presets with setPartnerPreset). What the session makes is filed for this managed user, and the lists it reads hold only this user\u0026#x27;s canvases, widgets and compositions. It can reach only canvases, widgets, compositions, repositories, uploaded files and operations made for this managed user (tag the canvases and widgets you create with managedUserId); any other canvas, widget, composition, conversation, message, repository, file or operation, including another of your users\u0026#x27;, answers 404. The creator also saves the composition it is editing (updateComposition, from the editor surface) and attaches pictures to its chat (uploadFile, from the files surface), and the surfaces do not imply one another: to open the whole creator for a user, ask for creator, editor and files together. A generation or a build one user starts can be followed and cancelled by that user and by you, never by another of your users. The AI is paid for by your account, as your own calls are: its credits and allowances are yours. A session cannot make a widget public (publishing a version does not), file one under a project or an organization, or set anything the creator does not set: a body with another field is refused with 403 and EDITOR_SESSION_FIELD_NOT_ALLOWED. - workflows: use Widgetic\u0026#x27;s Workflows editor for this user. List their workflows and the compositions a workflow of theirs can chain (listWorkspaceWorkflows, listWorkspaceWorkflowCompositionOptions); list the starting points you offer them and make a workflow from one, which gives the user their own copy of every widget it chains, a composition of their own on each copy, and a draft (listWorkspaceWorkflowPresets, createWorkspaceWorkflowFromPreset; you offer them with setPartnerWorkflowPreset); make, open, change and delete one (createWorkspaceWorkflow, getWorkspaceWorkflow, saveWorkspaceWorkflow, deleteWorkspaceWorkflow) and copy it (duplicateWorkspaceWorkflow); publish it or discard the changes of its draft (publishWorkspaceWorkflow, discardWorkspaceWorkflowChanges); read and restore its versions (listWorkspaceWorkflowVersions, getWorkspaceWorkflowVersion, restoreWorkspaceWorkflowVersion); pause, resume, archive and unarchive it (pauseWorkspaceWorkflow, resumeWorkspaceWorkflow, archiveWorkspaceWorkflow, unarchiveWorkspaceWorkflow); and read its counts (getWorkspaceWorkflowStats). The editor\u0026#x27;s assistant chat, beside the canvas, is part of this surface too: the page sends the messages itself (they are not an operation you call), and it works for this managed user alone. It reads, tries and changes the draft of the workflow that is open, from the compositions you made for this managed user, and it does not build widgets, copy templates, make plans, read Open MCPs or suggest what to type next. Its messages use none of your credits (30 a minute for each of your users), and a message that names a workflow, a composition or a file that is not this managed user\u0026#x27;s answers 404. The workspace in each path is your partner workspace, the workspaceId the session answers with: a session has no other, and a path that names any other workspace (a team you belong to included) answers 404. What the session makes is filed for this managed user (managedUserId), the lists hold only this user\u0026#x27;s workflows, and it can reach only workflows made for this managed user; any other workflow, including one of yours or of another of your users, answers 404. A workflow can chain only the compositions you made for this managed user (tag them with managedUserId): one that belongs to anybody else is not available, and publishing a workflow that uses it is refused. What a customer\u0026#x27;s session reads never says who published a version. A session cannot set who a workflow belongs to or which workspace it is in: a body with another field is refused with 403 and EDITOR_SESSION_FIELD_NOT_ALLOWED. Everything else is refused with 403 and EDITOR_SESSION_ROUTE_NOT_ALLOWED: a session cannot read your account, make more sessions, change your presets or delete a composition, and a session without the creator surface cannot create or list compositions. Create the composition yourself with your API key, then open the editor on it. A session ends at expiresAt (at most four hours), when you end it (revokeManagedUserEditorSession), or when the managed user is switched off or deleted. A managed user can have at most 100 live sessions at once (429 EDITOR_SESSION_LIMIT_REACHED). A session that is bound to a web page (allowedOrigin) is refused from any other origin. The AI the session runs is paid for with your credits. Set maxCredits to hold the session to a number of them: once its generations have taken that many (a generation that fails is refunded and does not count), the next one is refused with 402 and EDITOR_SESSION_CREDIT_LIMIT_REACHED, and the browser is told only that the feature is not available right now. Without it, the limit Widgetic has set for your account applies when it has set one (the same limit for every session you make, and maxCredits: null asks for none), and otherwise the credits of your account are the only ceiling. What each of your users\u0026#x27; sessions has spent is in getManagedUserUsage. Each call makes a new session. It does not take an Idempotency-Key: the answer holds the token, and the token is never stored where a retry could read it back. The answer is sent with Cache-Control: no-store.\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://widgetic.mintlify.site/_mintlify/api/og/v2?division=Editor+sessions\u0026amp;title=Create+an+editor+session\u0026amp;description=Makes+a+short-lived+credential+that+lets+the+browser+of+ONE+of+your+managed+users+use+Widgetic%27s+editor%0Apieces%2C+such+as+the+File+Browser+and+the+Composition+Edi\u0026amp;theme=44d0f7268a29a11a0c549719\u0026amp;signature=98b25c62ec0571c0bc2ad071eae0d17806efff1ce9018f945238a14d8c8f4319\">\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=\"/mintlify-assets/_mintlify/favicons/widgetic/KpZqnIZ3Xt05XVQ0/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"Developer documentation\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#204427\">\u003clink data-mint-head rel=\"canonical\" href=\"https://docs.widgetic.com/api-reference/managed-users/create-managed-user-editor-session\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/api-reference/managed-users/create-managed-user-editor-session.md\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://docs.widgetic.com/#organization\",\"name\":\"Developer documentation\",\"url\":\"https://docs.widgetic.com\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https://mintcdn.com/widgetic/HN5UMRJIol5DDGOU/brand/logo-light.svg?fit=max\u0026auto=format\u0026n=HN5UMRJIol5DDGOU\u0026q=85\u0026s=a76d6a0ea3ca3b56f89acbc1abc6ea7d\"}},{\"@type\":\"WebSite\",\"@id\":\"https://docs.widgetic.com#website\",\"name\":\"Developer documentation\",\"url\":\"https://docs.widgetic.com\",\"publisher\":{\"@id\":\"https://docs.widgetic.com/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://docs.widgetic.com/api-reference/managed-users/create-managed-user-editor-session#webpage\",\"url\":\"https://docs.widgetic.com/api-reference/managed-users/create-managed-user-editor-session\",\"name\":\"Create an editor session\",\"description\":\"Makes a short-lived credential that lets the browser of ONE of your managed users use Widgetic's editor pieces, such as the File Browser and the Composition Editor, without your API key ever reaching that browser. Call this from your server when the page that hosts the editor opens, and hand the token in the answer to that page. The token is shown once. It starts with wgt_ses_ and the browser sends it as Authorization: Bearer . It can do only what the surfaces you name allow, and only for this managed user: - files: upload a file (uploadFile) and list the files uploaded for this user (listUploads). Every file is filed for this user and stored in your own storage destination, never in Widgetic's: a file a customer uploads is yours to keep, and takes none of your storage allowance. Partner storage is not optional, so no session, whatever its surfaces, can be made until you have set a destination (setPartnerStorageDestination); until then it is refused with 409 and PARTNER_STORAGE_REQUIRED, and when the destination cannot be used with 503 and STORAGE_DESTINATION_UNAVAILABLE. A destination you remove after the session was made stops its uploads too (the same 409; the browser is only told that the feature is not available right now). To keep a customer from uploading, leave files out of the session and hand the editors your own media library instead (mediaLibrary). - editor: edit one of this user's compositions: read it (getCompositionById, its content, design, embed settings and schemas), check a content change (validateCompositionContent), and change its name, content, design and embed settings (updateComposition, setDynamicContent). For a widget that answers visitors' questions from documents (the ai-answers adapter), it also lists those documents, adds one as text or as a file (a text file or a picture; a PDF once PDFs are read), and removes one (getAiAnswersKnowledge, addAiAnswersKnowledgeDocument, addAiAnswersKnowledgeFile, removeAiAnswersKnowledgeDocument); adding costs no credits, and is limited for each of your users separately. It can reach only compositions you created for this managed user (tag them with managedUserId when you create them); any other composition, including another of your users', answers 404. - creator: use Widgetic's Widget Creator for this user, including its AI. Draw on canvases and save them (getAllCanvases, getCanvas, createCanvas, updateCanvas, previewDeleteCanvas, deleteCanvas); make, change, copy and delete the widgets on them (createWidget, getWidgets, getWidgetsBatch, updateWidget, uploadWidgetThumbnail, duplicateWidget, deleteWidget); list and make the compositions of a widget it built (getAllCompositions, createComposition), which is how it shows the widget with sample values; keep the conversation of each widget (getConversationsByWidgetId, createConversationForWidget, updateConversation, getMessages, createMessage, updateMessage, restoreCheckpoint); and read a widget's schemas and give it its repository (getWidgetContentSchema, getWidgetDesignSchema, updateWidgetRepository). The AI that builds a widget is part of it: list the models (listLlmModels), open the widget's repository (createRepository, getRepository), start a generation and follow or cancel it (generateCode, streamOperationUpdates, getOperation, cancelOperation), build and preview the result (getWidgetRepositoryHead, buildWidgetFromRepo, previewWidgetVersion), publish a version of the widget and move between its versions (publishBuiltWidget, getWidgetPublishHistory, setWidgetPublishHistoryLive, renameWidgetPublishHistoryTitle), and turn a stroke or a sentence into a decision (recognizeShape, resolveDesignProperty). It can also offer the customer your presets as starting points: read them and ask for a copy for this customer (listMyPresets, copyMyPreset; you choose the presets with setPartnerPreset). What the session makes is filed for this managed user, and the lists it reads hold only this user's canvases, widgets and compositions. It can reach only canvases, widgets, compositions, repositories, uploaded files and operations made for this managed user (tag the canvases and widgets you create with managedUserId); any other canvas, widget, composition, conversation, message, repository, file or operation, including another of your users', answers 404. The creator also saves the composition it is editing (updateComposition, from the editor surface) and attaches pictures to its chat (uploadFile, from the files surface), and the surfaces do not imply one another: to open the whole creator for a user, ask for creator, editor and files together. A generation or a build one user starts can be followed and cancelled by that user and by you, never by another of your users. The AI is paid for by your account, as your own calls are: its credits and allowances are yours. A session cannot make a widget public (publishing a version does not), file one under a project or an organization, or set anything the creator does not set: a body with another field is refused with 403 and EDITOR_SESSION_FIELD_NOT_ALLOWED. - workflows: use Widgetic's Workflows editor for this user. List their workflows and the compositions a workflow of theirs can chain (listWorkspaceWorkflows, listWorkspaceWorkflowCompositionOptions); list the starting points you offer them and make a workflow from one, which gives the user their own copy of every widget it chains, a composition of their own on each copy, and a draft (listWorkspaceWorkflowPresets, createWorkspaceWorkflowFromPreset; you offer them with setPartnerWorkflowPreset); make, open, change and delete one (createWorkspaceWorkflow, getWorkspaceWorkflow, saveWorkspaceWorkflow, deleteWorkspaceWorkflow) and copy it (duplicateWorkspaceWorkflow); publish it or discard the changes of its draft (publishWorkspaceWorkflow, discardWorkspaceWorkflowChanges); read and restore its versions (listWorkspaceWorkflowVersions, getWorkspaceWorkflowVersion, restoreWorkspaceWorkflowVersion); pause, resume, archive and unarchive it (pauseWorkspaceWorkflow, resumeWorkspaceWorkflow, archiveWorkspaceWorkflow, unarchiveWorkspaceWorkflow); and read its counts (getWorkspaceWorkflowStats). The editor's assistant chat, beside the canvas, is part of this surface too: the page sends the messages itself (they are not an operation you call), and it works for this managed user alone. It reads, tries and changes the draft of the workflow that is open, from the compositions you made for this managed user, and it does not build widgets, copy templates, make plans, read Open MCPs or suggest what to type next. Its messages use none of your credits (30 a minute for each of your users), and a message that names a workflow, a composition or a file that is not this managed user's answers 404. The workspace in each path is your partner workspace, the workspaceId the session answers with: a session has no other, and a path that names any other workspace (a team you belong to included) answers 404. What the session makes is filed for this managed user (managedUserId), the lists hold only this user's workflows, and it can reach only workflows made for this managed user; any other workflow, including one of yours or of another of your users, answers 404. A workflow can chain only the compositions you made for this managed user (tag them with managedUserId): one that belongs to anybody else is not available, and publishing a workflow that uses it is refused. What a customer's session reads never says who published a version. A session cannot set who a workflow belongs to or which workspace it is in: a body with another field is refused with 403 and EDITOR_SESSION_FIELD_NOT_ALLOWED. Everything else is refused with 403 and EDITOR_SESSION_ROUTE_NOT_ALLOWED: a session cannot read your account, make more sessions, change your presets or delete a composition, and a session without the creator surface cannot create or list compositions. Create the composition yourself with your API key, then open the editor on it. A session ends at expiresAt (at most four hours), when you end it (revokeManagedUserEditorSession), or when the managed user is switched off or deleted. A managed user can have at most 100 live sessions at once (429 EDITOR_SESSION_LIMIT_REACHED). A session that is bound to a web page (allowedOrigin) is refused from any other origin. The AI the session runs is paid for with your credits. Set maxCredits to hold the session to a number of them: once its generations have taken that many (a generation that fails is refunded and does not count), the next one is refused with 402 and EDITOR_SESSION_CREDIT_LIMIT_REACHED, and the browser is told only that the feature is not available right now. Without it, the limit Widgetic has set for your account applies when it has set one (the same limit for every session you make, and maxCredits: null asks for none), and otherwise the credits of your account are the only ceiling. What each of your users' sessions has spent is in getManagedUserUsage. Each call makes a new session. It does not take an Idempotency-Key: the answer holds the token, and the token is never stored where a retry could read it back. The answer is sent with Cache-Control: no-store.\",\"dateModified\":\"2026-12-03T18:18:30.477Z\",\"isPartOf\":{\"@id\":\"https://docs.widgetic.com#website\"},\"breadcrumb\":{\"@id\":\"https://docs.widgetic.com/api-reference/managed-users/create-managed-user-editor-session#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://docs.widgetic.com/api-reference/managed-users/create-managed-user-editor-session#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Partners\",\"item\":\"https://docs.widgetic.com/api-reference/partners/get-my-partners\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Create an editor session\",\"item\":\"https://docs.widgetic.com/api-reference/managed-users/create-managed-user-editor-session\"}]},{\"@type\":[\"TechArticle\",\"APIReference\"],\"@id\":\"https://docs.widgetic.com/api-reference/managed-users/create-managed-user-editor-session#apireference\",\"headline\":\"Create an editor session\",\"name\":\"Create an editor session\",\"description\":\"Makes a short-lived credential that lets the browser of ONE of your managed users use Widgetic's editor pieces, such as the File Browser and the Composition Editor, without your API key ever reaching that browser. Call this from your server when the page that hosts the editor opens, and hand the token in the answer to that page. The token is shown once. It starts with wgt_ses_ and the browser sends it as Authorization: Bearer . It can do only what the surfaces you name allow, and only for this managed user: - files: upload a file (uploadFile) and list the files uploaded for this user (listUploads). Every file is filed for this user and stored in your own storage destination, never in Widgetic's: a file a customer uploads is yours to keep, and takes none of your storage allowance. Partner storage is not optional, so no session, whatever its surfaces, can be made until you have set a destination (setPartnerStorageDestination); until then it is refused with 409 and PARTNER_STORAGE_REQUIRED, and when the destination cannot be used with 503 and STORAGE_DESTINATION_UNAVAILABLE. A destination you remove after the session was made stops its uploads too (the same 409; the browser is only told that the feature is not available right now). To keep a customer from uploading, leave files out of the session and hand the editors your own media library instead (mediaLibrary). - editor: edit one of this user's compositions: read it (getCompositionById, its content, design, embed settings and schemas), check a content change (validateCompositionContent), and change its name, content, design and embed settings (updateComposition, setDynamicContent). For a widget that answers visitors' questions from documents (the ai-answers adapter), it also lists those documents, adds one as text or as a file (a text file or a picture; a PDF once PDFs are read), and removes one (getAiAnswersKnowledge, addAiAnswersKnowledgeDocument, addAiAnswersKnowledgeFile, removeAiAnswersKnowledgeDocument); adding costs no credits, and is limited for each of your users separately. It can reach only compositions you created for this managed user (tag them with managedUserId when you create them); any other composition, including another of your users', answers 404. - creator: use Widgetic's Widget Creator for this user, including its AI. Draw on canvases and save them (getAllCanvases, getCanvas, createCanvas, updateCanvas, previewDeleteCanvas, deleteCanvas); make, change, copy and delete the widgets on them (createWidget, getWidgets, getWidgetsBatch, updateWidget, uploadWidgetThumbnail, duplicateWidget, deleteWidget); list and make the compositions of a widget it built (getAllCompositions, createComposition), which is how it shows the widget with sample values; keep the conversation of each widget (getConversationsByWidgetId, createConversationForWidget, updateConversation, getMessages, createMessage, updateMessage, restoreCheckpoint); and read a widget's schemas and give it its repository (getWidgetContentSchema, getWidgetDesignSchema, updateWidgetRepository). The AI that builds a widget is part of it: list the models (listLlmModels), open the widget's repository (createRepository, getRepository), start a generation and follow or cancel it (generateCode, streamOperationUpdates, getOperation, cancelOperation), build and preview the result (getWidgetRepositoryHead, buildWidgetFromRepo, previewWidgetVersion), publish a version of the widget and move between its versions (publishBuiltWidget, getWidgetPublishHistory, setWidgetPublishHistoryLive, renameWidgetPublishHistoryTitle), and turn a stroke or a sentence into a decision (recognizeShape, resolveDesignProperty). It can also offer the customer your presets as starting points: read them and ask for a copy for this customer (listMyPresets, copyMyPreset; you choose the presets with setPartnerPreset). What the session makes is filed for this managed user, and the lists it reads hold only this user's canvases, widgets and compositions. It can reach only canvases, widgets, compositions, repositories, uploaded files and operations made for this managed user (tag the canvases and widgets you create with managedUserId); any other canvas, widget, composition, conversation, message, repository, file or operation, including another of your users', answers 404. The creator also saves the composition it is editing (updateComposition, from the editor surface) and attaches pictures to its chat (uploadFile, from the files surface), and the surfaces do not imply one another: to open the whole creator for a user, ask for creator, editor and files together. A generation or a build one user starts can be followed and cancelled by that user and by you, never by another of your users. The AI is paid for by your account, as your own calls are: its credits and allowances are yours. A session cannot make a widget public (publishing a version does not), file one under a project or an organization, or set anything the creator does not set: a body with another field is refused with 403 and EDITOR_SESSION_FIELD_NOT_ALLOWED. - workflows: use Widgetic's Workflows editor for this user. List their workflows and the compositions a workflow of theirs can chain (listWorkspaceWorkflows, listWorkspaceWorkflowCompositionOptions); list the starting points you offer them and make a workflow from one, which gives the user their own copy of every widget it chains, a composition of their own on each copy, and a draft (listWorkspaceWorkflowPresets, createWorkspaceWorkflowFromPreset; you offer them with setPartnerWorkflowPreset); make, open, change and delete one (createWorkspaceWorkflow, getWorkspaceWorkflow, saveWorkspaceWorkflow, deleteWorkspaceWorkflow) and copy it (duplicateWorkspaceWorkflow); publish it or discard the changes of its draft (publishWorkspaceWorkflow, discardWorkspaceWorkflowChanges); read and restore its versions (listWorkspaceWorkflowVersions, getWorkspaceWorkflowVersion, restoreWorkspaceWorkflowVersion); pause, resume, archive and unarchive it (pauseWorkspaceWorkflow, resumeWorkspaceWorkflow, archiveWorkspaceWorkflow, unarchiveWorkspaceWorkflow); and read its counts (getWorkspaceWorkflowStats). The editor's assistant chat, beside the canvas, is part of this surface too: the page sends the messages itself (they are not an operation you call), and it works for this managed user alone. It reads, tries and changes the draft of the workflow that is open, from the compositions you made for this managed user, and it does not build widgets, copy templates, make plans, read Open MCPs or suggest what to type next. Its messages use none of your credits (30 a minute for each of your users), and a message that names a workflow, a composition or a file that is not this managed user's answers 404. The workspace in each path is your partner workspace, the workspaceId the session answers with: a session has no other, and a path that names any other workspace (a team you belong to included) answers 404. What the session makes is filed for this managed user (managedUserId), the lists hold only this user's workflows, and it can reach only workflows made for this managed user; any other workflow, including one of yours or of another of your users, answers 404. A workflow can chain only the compositions you made for this managed user (tag them with managedUserId): one that belongs to anybody else is not available, and publishing a workflow that uses it is refused. What a customer's session reads never says who published a version. A session cannot set who a workflow belongs to or which workspace it is in: a body with another field is refused with 403 and EDITOR_SESSION_FIELD_NOT_ALLOWED. Everything else is refused with 403 and EDITOR_SESSION_ROUTE_NOT_ALLOWED: a session cannot read your account, make more sessions, change your presets or delete a composition, and a session without the creator surface cannot create or list compositions. Create the composition yourself with your API key, then open the editor on it. A session ends at expiresAt (at most four hours), when you end it (revokeManagedUserEditorSession), or when the managed user is switched off or deleted. A managed user can have at most 100 live sessions at once (429 EDITOR_SESSION_LIMIT_REACHED). A session that is bound to a web page (allowedOrigin) is refused from any other origin. The AI the session runs is paid for with your credits. Set maxCredits to hold the session to a number of them: once its generations have taken that many (a generation that fails is refunded and does not count), the next one is refused with 402 and EDITOR_SESSION_CREDIT_LIMIT_REACHED, and the browser is told only that the feature is not available right now. Without it, the limit Widgetic has set for your account applies when it has set one (the same limit for every session you make, and maxCredits: null asks for none), and otherwise the credits of your account are the only ceiling. What each of your users' sessions has spent is in getManagedUserUsage. Each call makes a new session. It does not take an Idempotency-Key: the answer holds the token, and the token is never stored where a retry could read it back. The answer is sent with Cache-Control: no-store.\",\"url\":\"https://docs.widgetic.com/api-reference/managed-users/create-managed-user-editor-session\",\"mainEntityOfPage\":{\"@id\":\"https://docs.widgetic.com/api-reference/managed-users/create-managed-user-editor-session#webpage\"},\"dateModified\":\"2026-12-03T18:18:30.477Z\",\"publisher\":{\"@id\":\"https://docs.widgetic.com/#organization\"},\"isPartOf\":{\"@id\":\"https://docs.widgetic.com#website\"}}]}\u003c/script>\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"Developer documentation\",\"publisher\":{\"@type\":\"Organization\",\"name\":\"Developer documentation\"},\"provider\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","agentPointerHref":"/api-reference/managed-users/create-managed-user-editor-session.md","siteName":"Developer documentation","nav":{"global":{"anchors":[{"anchor":"GitHub","icon":"github","href":"https://github.com/widgetic"},{"anchor":"npm","icon":"npm","href":"https://www.npmjs.com/org/widgetic"}]},"tabs":[{"tab":"Guides","pages":[{"title":"Guides","href":"/docs/introduction"}]},{"tab":"API reference","groups":[{"group":"Overview","pages":[{"title":"API reference","sidebarTitle":"Introduction","href":"/api-reference/introduction"},{"title":"Pagination","href":"/api-reference/pagination"},{"title":"Usage Limits","href":"/api-reference/usage-limits"},{"title":"Errors","href":"/api-reference/errors"}]},{"group":"Widgets","pages":[{"title":"List widgets","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json get /widgets","href":"/api-reference/widgets/get-widgets"},{"title":"Create a widget","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json post /widgets","href":"/api-reference/widgets/create-widget"},{"title":"Get widgets in a batch","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json post /widgets/batch","href":"/api-reference/widgets/get-widgets-batch"},{"title":"Create a composition from a widget","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json post /widgets/{id}/composition","href":"/api-reference/widgets/create-composition-from-widget"},{"title":"Set a widget's managed user","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json put /widgets/{id}/managed-user","href":"/api-reference/widgets/set-widget-managed-user"},{"title":"Remove a widget's managed user","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json delete /widgets/{id}/managed-user","href":"/api-reference/widgets/remove-widget-managed-user"}]},{"group":"Compositions","pages":[{"title":"List compositions","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json get /compositions","href":"/api-reference/compositions/get-all-compositions"},{"title":"Create a composition","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json post /compositions","href":"/api-reference/compositions/create-composition"},{"title":"Get compositions in a batch","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json post /compositions/batch","href":"/api-reference/compositions/get-compositions-batch"},{"title":"Get a composition","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json get /compositions/{id}","href":"/api-reference/compositions/get-composition-by-id"},{"title":"Update a composition","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json put /compositions/{id}","href":"/api-reference/compositions/update-composition"},{"title":"Delete a composition","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json delete /compositions/{id}","href":"/api-reference/compositions/delete-composition"},{"title":"Duplicate a composition","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json post /compositions/{id}/duplicate","href":"/api-reference/compositions/duplicate-composition"},{"title":"Get an operation's status","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json get /operations/{id}","href":"/api-reference/operations/get-operation"},{"title":"Change a composition's status","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json put /compositions/{id}/status","href":"/api-reference/compositions/update-composition-status"},{"title":"Set a composition's managed user","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json put /compositions/{id}/managed-user","href":"/api-reference/compositions/set-composition-managed-user"},{"title":"Remove a composition's managed user","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json delete /compositions/{id}/managed-user","href":"/api-reference/compositions/remove-composition-managed-user"},{"title":"List composition versions","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json get /compositions/{id}/versions","href":"/api-reference/compositions/get-composition-versions"},{"title":"Check access to a composition","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json get /compositions/{id}/access","href":"/api-reference/compositions/check-composition-access"},{"title":"Get a composition preview","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json get /compositions/{id}/preview","href":"/api-reference/compositions/get-composition-preview"},{"title":"Get a composition's design","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json get /compositions/{id}/design","href":"/api-reference/compositions/get-composition-design"},{"title":"Get a composition's embed settings","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json get /compositions/{id}/embed-settings","href":"/api-reference/compositions/get-composition-embed-settings"},{"group":"Content","pages":[{"title":"Get a composition's content","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json get /compositions/{id}/content","href":"/api-reference/compositions/get-composition-content"},{"title":"Update a composition's content","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json put /compositions/{id}/content","href":"/api-reference/compositions/set-dynamic-content"},{"title":"Validate content","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json post /compositions/{id}/content/validate","href":"/api-reference/compositions/validate-composition-content"},{"title":"Add a content list item","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json post /compositions/{id}/content/{list}/items","href":"/api-reference/compositions/create-composition-content-item"},{"title":"Update a content list item","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json patch /compositions/{id}/content/{list}/items/{itemId}","href":"/api-reference/compositions/patch-composition-content-item"},{"title":"Delete a content list item","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json delete /compositions/{id}/content/{list}/items/{itemId}","href":"/api-reference/compositions/delete-composition-content-item"},{"title":"Get a composition's data source","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json get /compositions/{id}/data-source","href":"/api-reference/compositions/get-composition-data-source"},{"title":"Bind a data source to a composition","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json put /compositions/{id}/data-source","href":"/api-reference/compositions/set-composition-data-source"},{"title":"Remove a composition's data source","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json delete /compositions/{id}/data-source","href":"/api-reference/compositions/delete-composition-data-source"},{"title":"Get the content schema","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json get /compositions/{id}/schema/content","href":"/api-reference/compositions/get-composition-content-schema"},{"title":"Get the design schema","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json get /compositions/{id}/schema/design","href":"/api-reference/compositions/get-composition-design-schema"},{"title":"Get the embed schema","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json get /compositions/{id}/schema/embed","href":"/api-reference/compositions/get-composition-embed-schema"}]},{"group":"Entries and records","pages":[{"title":"Describe a composition's entry tables","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json get /compositions/{id}/entries","href":"/api-reference/compositions/describe-composition-entries"},{"title":"Count and tally entries","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json get /compositions/{id}/entries/{table}","href":"/api-reference/compositions/read-composition-entries"},{"title":"List entry items","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json get /compositions/{id}/entries/{table}/items","href":"/api-reference/compositions/list-composition-entry-items"},{"title":"Export entry items","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json get /compositions/{id}/entries/{table}/export","href":"/api-reference/compositions/export-composition-entry-items"},{"title":"Delete entry items","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json delete /compositions/{id}/entries/{table}/items","href":"/api-reference/compositions/delete-composition-entry-items"},{"title":"List database records","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json get /compositions/{id}/database/{table}","href":"/api-reference/compositions/get-composition-database-records"},{"title":"Create a database record","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json post /compositions/{id}/database/{table}","href":"/api-reference/compositions/create-composition-database-record"},{"title":"Get a database record","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json get /compositions/{id}/database/{table}/{recordId}","href":"/api-reference/compositions/get-composition-database-record"},{"title":"Update a database record","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json put /compositions/{id}/database/{table}/{recordId}","href":"/api-reference/compositions/update-composition-database-record"},{"title":"Delete a database record","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json delete /compositions/{id}/database/{table}/{recordId}","href":"/api-reference/compositions/delete-composition-database-record"}]},{"group":"AI answers","pages":[{"title":"List AI knowledge documents","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json get /compositions/{id}/adapters/ai-answers/knowledge","href":"/api-reference/compositions/get-ai-answers-knowledge"},{"title":"Add an AI knowledge document","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json post /compositions/{id}/adapters/ai-answers/knowledge/documents","href":"/api-reference/compositions/add-ai-answers-knowledge-document"},{"title":"Add an AI knowledge file","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json post /compositions/{id}/adapters/ai-answers/knowledge/documents/file","href":"/api-reference/compositions/add-ai-answers-knowledge-file"},{"title":"Remove an AI knowledge document","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json delete /compositions/{id}/adapters/ai-answers/knowledge/documents/{documentId}","href":"/api-reference/compositions/remove-ai-answers-knowledge-document"}]}]},{"group":"Canvases","pages":[{"title":"List canvases","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json get /canvases","href":"/api-reference/canvases/get-all-canvases"},{"title":"Create a canvas","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json post /canvases","href":"/api-reference/canvases/create-canvas"},{"title":"Get a canvas","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json get /canvases/{id}","href":"/api-reference/canvases/get-canvas"},{"title":"Update a canvas","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json put /canvases/{id}","href":"/api-reference/canvases/update-canvas"},{"title":"Delete a canvas","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json delete /canvases/{id}","href":"/api-reference/canvases/delete-canvas"}]},{"group":"Workflows","pages":[{"title":"List workflows","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json get /workspaces/{workspaceId}/workflows","href":"/api-reference/workflows/list-workspace-workflows"},{"title":"Create a workflow","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json post /workspaces/{workspaceId}/workflows","href":"/api-reference/workflows/create-workspace-workflow"},{"title":"Get a workflow","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json get /workspaces/{workspaceId}/workflows/{workflowId}","href":"/api-reference/workflows/get-workspace-workflow"},{"title":"Save a workflow draft","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json put /workspaces/{workspaceId}/workflows/{workflowId}","href":"/api-reference/workflows/save-workspace-workflow"},{"title":"Delete a workflow","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json delete /workspaces/{workspaceId}/workflows/{workflowId}","href":"/api-reference/workflows/delete-workspace-workflow"},{"title":"Duplicate a workflow","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json post /workspaces/{workspaceId}/workflows/{workflowId}/duplicate","href":"/api-reference/workflows/duplicate-workspace-workflow"},{"title":"Publish a workflow","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json post /workspaces/{workspaceId}/workflows/{workflowId}/publish","href":"/api-reference/workflows/publish-workspace-workflow"},{"title":"Discard workflow changes","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json post /workspaces/{workspaceId}/workflows/{workflowId}/discard","href":"/api-reference/workflows/discard-workspace-workflow-changes"},{"title":"Pause a workflow","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json post /workspaces/{workspaceId}/workflows/{workflowId}/pause","href":"/api-reference/workflows/pause-workspace-workflow"},{"title":"Resume a workflow","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json post /workspaces/{workspaceId}/workflows/{workflowId}/resume","href":"/api-reference/workflows/resume-workspace-workflow"},{"title":"Archive a workflow","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json post /workspaces/{workspaceId}/workflows/{workflowId}/archive","href":"/api-reference/workflows/archive-workspace-workflow"},{"title":"Unarchive a workflow","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json post /workspaces/{workspaceId}/workflows/{workflowId}/unarchive","href":"/api-reference/workflows/unarchive-workspace-workflow"},{"title":"Set a workflow's managed user","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json put /workspaces/{workspaceId}/workflows/{workflowId}/managed-user","href":"/api-reference/workflows/set-workspace-workflow-managed-user"},{"title":"Remove a workflow's managed user","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json delete /workspaces/{workspaceId}/workflows/{workflowId}/managed-user","href":"/api-reference/workflows/remove-workspace-workflow-managed-user"},{"title":"Get workflow statistics","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json get /workspaces/{workspaceId}/workflows/{workflowId}/stats","href":"/api-reference/workflows/get-workspace-workflow-stats"},{"group":"Versions","pages":[{"title":"List workflow versions","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json get /workspaces/{workspaceId}/workflows/{workflowId}/versions","href":"/api-reference/workflows/list-workspace-workflow-versions"},{"title":"Get a workflow version","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json get /workspaces/{workspaceId}/workflows/{workflowId}/versions/{versionId}","href":"/api-reference/workflows/get-workspace-workflow-version"},{"title":"Restore a workflow version","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json post /workspaces/{workspaceId}/workflows/{workflowId}/versions/{versionId}/restore","href":"/api-reference/workflows/restore-workspace-workflow-version"}]},{"group":"Starting points","pages":[{"title":"List compositions for a workflow","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json get /workspaces/{workspaceId}/workflows/composition-options","href":"/api-reference/workflows/list-workspace-workflow-composition-options"},{"title":"List workflow starting points","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json get /workspaces/{workspaceId}/workflows/presets","href":"/api-reference/workflows/list-workspace-workflow-presets"},{"title":"Create a workflow from a starting point","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json post /workspaces/{workspaceId}/workflows/from-preset","href":"/api-reference/workflows/create-workspace-workflow-from-preset"}]}]},{"group":"A/B tests","pages":[{"title":"List A/B tests","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json get /workspaces/{workspaceId}/ab-tests","href":"/api-reference/ab-testing/list-workspace-ab-tests"},{"title":"Create an A/B test","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json post /workspaces/{workspaceId}/ab-tests","href":"/api-reference/ab-testing/create-workspace-ab-test"},{"title":"Get an A/B test","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json get /workspaces/{workspaceId}/ab-tests/{testId}","href":"/api-reference/ab-testing/get-workspace-ab-test"},{"title":"Update an A/B test","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json put /workspaces/{workspaceId}/ab-tests/{testId}","href":"/api-reference/ab-testing/update-workspace-ab-test"},{"title":"Delete an A/B test","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json delete /workspaces/{workspaceId}/ab-tests/{testId}","href":"/api-reference/ab-testing/delete-workspace-ab-test"},{"title":"Start an A/B test","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json post /workspaces/{workspaceId}/ab-tests/{testId}/start","href":"/api-reference/ab-testing/start-workspace-ab-test"},{"title":"Pause an A/B test","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json post /workspaces/{workspaceId}/ab-tests/{testId}/pause","href":"/api-reference/ab-testing/pause-workspace-ab-test"},{"title":"Stop an A/B test","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json post /workspaces/{workspaceId}/ab-tests/{testId}/stop","href":"/api-reference/ab-testing/stop-workspace-ab-test"},{"title":"Check whether an A/B test should stop","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json get /workspaces/{workspaceId}/ab-tests/{testId}/auto-stop-check","href":"/api-reference/ab-testing/check-workspace-ab-test-auto-stop"},{"title":"Set an A/B test's duration","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json put /workspaces/{workspaceId}/ab-tests/{testId}/duration","href":"/api-reference/ab-testing/set-workspace-ab-test-duration"},{"group":"Goals","pages":[{"title":"List the goals a test can measure","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json get /metrics/available","href":"/api-reference/ab-testing/get-available-metrics"},{"title":"Validate goal tracking","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json post /workspaces/{workspaceId}/ab-tests/validate-goal-tracking","href":"/api-reference/ab-testing/validate-workspace-goal-tracking"},{"title":"List a composition's goal elements","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json get /workspaces/{workspaceId}/compositions/{id}/ab-goal-targets","href":"/api-reference/ab-testing/get-composition-ab-goal-targets"}]},{"group":"Results","pages":[{"title":"Get an A/B test's statistics","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json get /workspaces/{workspaceId}/ab-tests/{testId}/statistics","href":"/api-reference/ab-testing/get-workspace-ab-test-statistics"},{"title":"Get an AI review of an A/B test","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json get /workspaces/{workspaceId}/ab-tests/{testId}/diagnosis","href":"/api-reference/ab-testing/get-workspace-ab-test-diagnosis"}]}]},{"group":"Translations","pages":[{"title":"List translations","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json get /organizations/{orgId}/translations","href":"/api-reference/organizations/list-organization-translations"},{"title":"Create a translation","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json post /organizations/{orgId}/translations","href":"/api-reference/organizations/create-organization-translation"},{"title":"Get a translation","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json get /translations/{id}","href":"/api-reference/translations/get-translation"},{"title":"Delete a translation","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json delete /translations/{id}","href":"/api-reference/translations/delete-translation"},{"title":"Add languages to a translation","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json post /translations/{id}/languages","href":"/api-reference/translations/add-languages-to-translation"},{"title":"Remove a language from a translation","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json delete /translations/{id}/languages/{languageCode}","href":"/api-reference/translations/remove-language-from-translation"},{"title":"Retranslate a translation","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json post /translations/{id}/retranslate","href":"/api-reference/translations/retranslate-experiment"},{"title":"Change a translation's status","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json put /translations/{id}/status","href":"/api-reference/translations/update-translation-status"},{"title":"Get a translation's analytics","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json get /translations/{id}/analytics","href":"/api-reference/translations/get-translation-analytics"},{"group":"Languages","pages":[{"title":"List supported languages","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json get /translations/supported-languages","href":"/api-reference/translations/get-supported-languages"},{"title":"List language presets","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json get /translations/language-presets","href":"/api-reference/translations/get-language-presets"}]}]},{"group":"Uploads","pages":[{"title":"Upload a file","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json post /uploads","href":"/api-reference/uploads/upload-file"},{"title":"List uploads","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json get /uploads","href":"/api-reference/uploads/list-uploads"},{"title":"Get an upload","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json get /uploads/{id}","href":"/api-reference/uploads/get-upload"},{"title":"Delete an upload","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json delete /uploads/{id}","href":"/api-reference/uploads/delete-upload"},{"title":"Set an upload's managed user","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json put /uploads/{id}/managed-user","href":"/api-reference/uploads/set-upload-managed-user"},{"title":"Remove an upload's managed user","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json delete /uploads/{id}/managed-user","href":"/api-reference/uploads/remove-upload-managed-user"},{"title":"Get upload limits","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json get /uploads/limits","href":"/api-reference/uploads/get-upload-limits"}]},{"group":"Brand Kit","pages":[{"title":"Get the Brand Kit","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json get /brand-kit","href":"/api-reference/brand-kit/get-brand-kit"},{"title":"Save the Brand Kit","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json put /brand-kit","href":"/api-reference/brand-kit/put-brand-kit"},{"title":"Update the Brand Kit","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json patch /brand-kit","href":"/api-reference/brand-kit/patch-brand-kit"},{"title":"Reset the Brand Kit","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json delete /brand-kit","href":"/api-reference/brand-kit/delete-brand-kit"},{"title":"Upload a Brand Kit font","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json post /brand-kit/fonts","href":"/api-reference/brand-kit/post-brand-kit-font"},{"title":"Add a Brand Kit icon","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json post /brand-kit/icons","href":"/api-reference/brand-kit/post-brand-kit-icon"},{"title":"Update a Brand Kit asset","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json patch /brand-kit/assets/{assetId}","href":"/api-reference/brand-kit/patch-brand-kit-asset"},{"title":"Remove a Brand Kit asset","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json delete /brand-kit/assets/{assetId}","href":"/api-reference/brand-kit/delete-brand-kit-asset"}]},{"group":"Account","pages":[{"group":"API keys","pages":[{"title":"Validate an API key","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json get /tokens/validate","href":"/api-reference/tokens/validate-token"},{"title":"List API keys","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json get /organizations/{orgId}/api-keys","href":"/api-reference/organizations/get-organization-api-keys"},{"title":"Create an API key","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json post /organizations/{orgId}/api-keys","href":"/api-reference/organizations/create-organization-api-key"},{"title":"Update an API key","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json put /organizations/{orgId}/api-keys/{keyId}","href":"/api-reference/organizations/update-organization-api-key"},{"title":"Delete an API key","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json delete /organizations/{orgId}/api-keys/{keyId}","href":"/api-reference/organizations/delete-organization-api-key"},{"title":"Get API key usage logs","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json get /organizations/{orgId}/api-keys/{keyId}/logs","href":"/api-reference/organizations/get-organization-api-key-usage-logs"}]},{"group":"Credits","pages":[{"title":"Get the credit balance","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json get /credits/user/{userId}/balance","href":"/api-reference/credits/get-user-credit-balance"},{"title":"List credit transactions","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json get /credits/user/{userId}/transactions","href":"/api-reference/credits/get-user-credit-transactions"}]},{"group":"Workspace domains","pages":[{"title":"List allowed domains","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json get /organizations/{orgId}/domains","href":"/api-reference/organizations/get-organization-domains"},{"title":"Add an allowed domain","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json post /organizations/{orgId}/domains","href":"/api-reference/organizations/add-organization-domain"},{"title":"Update an allowed domain","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json put /organizations/{orgId}/domains/{domainId}","href":"/api-reference/organizations/update-organization-domain"},{"title":"Delete an allowed domain","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json delete /organizations/{orgId}/domains/{domainId}","href":"/api-reference/organizations/delete-organization-domain"}]},{"group":"Adapter connections","pages":[{"title":"List adapter connections","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json get /users/{userId}/adapter-connections","href":"/api-reference/users/get-user-adapter-connections"},{"title":"Connect an adapter","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json put /users/{userId}/adapter-connections/{adapterId}/{credentialKey}","href":"/api-reference/users/set-user-adapter-connection"},{"title":"Remove an adapter connection","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json delete /users/{userId}/adapter-connections/{adapterId}/{credentialKey}","href":"/api-reference/users/remove-user-adapter-connection"},{"title":"Confirm an adapter connection","deprecated":null,"version":null,"openapi":"/openapi/widgetic-api-public.json post /users/{userId}/adapter-connections/{adapterId}/{credentialKey}/confirm","href":"/api-reference/users/confirm-user-adapter-connection"}]}]},{"group":"Partners","pages":[{"group":"Partner account","pages":[{"title":"Find your partner account","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json get /partners/mine","href":"/api-reference/partners/get-my-partners"},{"title":"Get a partner contract","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json get /partners/{partnerId}/contract","href":"/api-reference/partners/get-partner-contract"},{"title":"Get partner entitlements","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json get /entitlements/partners/{partnerId}","href":"/api-reference/entitlements/get-partner-entitlements"}]},{"group":"Credits and billing","pages":[{"title":"Get the partner credit balance","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json get /partners/{partnerId}/credits/balance","href":"/api-reference/partners/get-partner-credit-balance"},{"title":"List partner credit transactions","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json get /partners/{partnerId}/credits/transactions","href":"/api-reference/partners/get-partner-credit-transactions"},{"title":"Buy extra credits","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json post /partners/{partnerId}/credits/extra-invoice","href":"/api-reference/partners/create-partner-extra-credits-invoice"},{"title":"Get the billing overview","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json get /partners/{partnerId}/billing-overview","href":"/api-reference/partners/get-partner-billing-overview"},{"title":"List invoices","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json get /invoices/partner/{partnerId}","href":"/api-reference/invoices/get-invoices-by-partner-id"}]},{"group":"Managed users","pages":[{"title":"List managed users","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json get /managed-users","href":"/api-reference/managed-users/get-all-managed-users"},{"title":"Create a managed user","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json post /managed-users","href":"/api-reference/managed-users/create-managed-user"},{"title":"Get a managed user","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json get /managed-users/{id}","href":"/api-reference/managed-users/get-managed-user-by-id"},{"title":"Update a managed user","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json put /managed-users/{id}","href":"/api-reference/managed-users/update-managed-user"},{"title":"Delete a managed user","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json delete /managed-users/{id}","href":"/api-reference/managed-users/delete-managed-user"},{"title":"List the managed users of a manager","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json get /users/{managerId}/managed-users","href":"/api-reference/managed-users/get-managed-users-by-manager-id"},{"title":"Get managed user entitlements","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json get /entitlements/managed-users/{managedUserId}","href":"/api-reference/entitlements/get-managed-user-entitlements"},{"title":"Get a managed user's limits","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json get /managed-users/{id}/limits","href":"/api-reference/managed-users/get-managed-user-limits"},{"title":"Set a managed user's limits","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json put /managed-users/{id}/limits","href":"/api-reference/managed-users/set-managed-user-limits"},{"title":"Get a managed user's usage","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json get /managed-users/{id}/usage","href":"/api-reference/managed-users/get-managed-user-usage"},{"title":"Get a managed user's storage usage","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json get /managed-users/{id}/storage-usage","href":"/api-reference/managed-users/get-managed-user-storage-usage"},{"title":"List a managed user's entries","description":"Merges eligible tables (time and id columns) across the managed user's compositions in global time order, then compositionId, table, and id (byte order). Only tables with both a time and an id column take part. Rate limit 30 requests per minute.","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json get /managed-users/{id}/entries","href":"/api-reference/managed-users/list-managed-user-entries"}]},{"group":"Editor sessions","pages":[{"title":"Create an editor session","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json post /managed-users/{id}/editor-sessions","href":"/api-reference/managed-users/create-managed-user-editor-session"},{"title":"End an editor session","description":"Ends the session at once: its token stops working on the next request (on another server of ours, within\na few seconds). Ending a session that has already ended is fine.\n","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json delete /managed-users/{id}/editor-sessions/{sessionId}","href":"/api-reference/managed-users/revoke-managed-user-editor-session"},{"title":"End all editor sessions","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json delete /managed-users/{id}/editor-sessions","href":"/api-reference/managed-users/revoke-managed-user-editor-sessions"}]},{"group":"Presets and design defaults","pages":[{"title":"List presets","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json get /partners/{partnerId}/presets","href":"/api-reference/partners/list-partner-presets"},{"title":"Set a preset","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json put /partners/{partnerId}/presets/{key}","href":"/api-reference/partners/set-partner-preset"},{"title":"Remove a preset","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json delete /partners/{partnerId}/presets/{key}","href":"/api-reference/partners/remove-partner-preset"},{"title":"Copy a preset for a managed user","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json post /managed-users/{id}/presets/{key}/copy","href":"/api-reference/managed-users/copy-preset-for-managed-user"},{"title":"Create a composition from a preset","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json post /managed-users/{id}/presets/{key}/composition","href":"/api-reference/managed-users/create-composition-from-preset"},{"title":"List workflow presets","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json get /partners/{partnerId}/workflow-presets","href":"/api-reference/partners/list-partner-workflow-presets"},{"title":"Set a workflow preset","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json put /partners/{partnerId}/workflow-presets/{key}","href":"/api-reference/partners/set-partner-workflow-preset"},{"title":"Remove a workflow preset","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json delete /partners/{partnerId}/workflow-presets/{key}","href":"/api-reference/partners/remove-partner-workflow-preset"},{"title":"Get partner design defaults","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json get /partners/{partnerId}/design-defaults","href":"/api-reference/partners/get-partner-design-defaults"},{"title":"Set partner design defaults","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json put /partners/{partnerId}/design-defaults","href":"/api-reference/partners/set-partner-design-defaults"},{"title":"Get a managed user's design defaults","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json get /managed-users/{id}/design-defaults","href":"/api-reference/managed-users/get-managed-user-design-defaults"},{"title":"Set a managed user's design defaults","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json put /managed-users/{id}/design-defaults","href":"/api-reference/managed-users/set-managed-user-design-defaults"}]},{"group":"Storage and data","pages":[{"title":"Get the storage destination","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json get /partners/{partnerId}/storage","href":"/api-reference/partners/get-partner-storage-destination"},{"title":"Set the storage destination","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json put /partners/{partnerId}/storage","href":"/api-reference/partners/set-partner-storage-destination"},{"title":"Remove the storage destination","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json delete /partners/{partnerId}/storage","href":"/api-reference/partners/remove-partner-storage-destination"},{"title":"Verify the storage destination","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json post /partners/{partnerId}/storage/verify","href":"/api-reference/partners/verify-partner-storage-destination"},{"title":"Get partner storage usage","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json get /partners/{partnerId}/storage/usage","href":"/api-reference/partners/get-partner-storage-usage"},{"title":"Get the data database","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json get /partners/{partnerId}/data-database","href":"/api-reference/partners/get-partner-data-database"},{"title":"Set the data database","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json put /partners/{partnerId}/data-database","href":"/api-reference/partners/set-partner-data-database"},{"title":"Remove the data database","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json delete /partners/{partnerId}/data-database","href":"/api-reference/partners/remove-partner-data-database"},{"title":"Verify the data database","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json post /partners/{partnerId}/data-database/verify","href":"/api-reference/partners/verify-partner-data-database"}]},{"group":"Notifications","pages":[{"title":"List notifications","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json get /partners/{partnerId}/notifications","href":"/api-reference/partners/list-partner-notifications"},{"title":"List notification deliveries","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json get /partners/{partnerId}/notifications/deliveries","href":"/api-reference/partners/list-partner-notification-deliveries"},{"title":"Get notification settings","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json get /partners/{partnerId}/notifications/settings","href":"/api-reference/partners/get-partner-notification-settings"},{"title":"Update notification settings","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json put /partners/{partnerId}/notifications/settings","href":"/api-reference/partners/update-partner-notification-settings"},{"title":"Rotate the webhook secret","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json post /partners/{partnerId}/notifications/webhook-secret","href":"/api-reference/partners/rotate-partner-webhook-secret"},{"title":"Send a test event","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json post /partners/{partnerId}/notifications/test-event","href":"/api-reference/partners/send-partner-notification-test-event"},{"title":"Replay a delivery","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json post /partners/{partnerId}/notifications/deliveries/{deliveryId}/replay","href":"/api-reference/partners/replay-partner-notification-delivery"}]},{"group":"Analytics","pages":[{"title":"Get the analytics summary","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json get /partners/{partnerId}/analytics/summary","href":"/api-reference/partners/get-partner-analytics-summary"},{"title":"Get the analytics timeline","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json get /partners/{partnerId}/analytics/timeline","href":"/api-reference/partners/get-partner-analytics-timeline"},{"title":"Get the top widgets","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json get /partners/{partnerId}/analytics/top-widgets","href":"/api-reference/partners/get-partner-analytics-top-widgets"},{"title":"Get analytics by managed user","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json get /partners/{partnerId}/analytics/managed-users","href":"/api-reference/partners/get-partner-analytics-by-managed-user"}]},{"group":"Embeds and adapters","pages":[{"title":"Get entry context signing","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json get /partners/{partnerId}/entry-context-signing","href":"/api-reference/partners/get-partner-entry-context-signing"},{"title":"Update entry context signing","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json put /partners/{partnerId}/entry-context-signing","href":"/api-reference/partners/update-partner-entry-context-signing"},{"title":"Rotate the entry context secret","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json post /partners/{partnerId}/entry-context-signing/secret","href":"/api-reference/partners/rotate-partner-entry-context-secret"},{"title":"List partner adapter connections","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json get /partners/{partnerId}/adapter-connections","href":"/api-reference/partners/get-partner-adapter-connections"},{"title":"Connect a partner adapter","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json put /partners/{partnerId}/adapter-connections/{adapterId}/{credentialKey}","href":"/api-reference/partners/set-partner-adapter-connection"},{"title":"Remove a partner adapter connection","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json delete /partners/{partnerId}/adapter-connections/{adapterId}/{credentialKey}","href":"/api-reference/partners/remove-partner-adapter-connection"},{"title":"Confirm a partner adapter connection","deprecated":null,"version":null,"tag":"Partner key","openapi":"/openapi/widgetic-api-public.json post /partners/{partnerId}/adapter-connections/{adapterId}/{credentialKey}/confirm","href":"/api-reference/partners/confirm-partner-adapter-connection"}]}]},{"group":"Public embed","pages":[{"title":"Resolve a composition embed","deprecated":null,"version":null,"tag":"No key","openapi":"/openapi/widgetic-api-public.json get /embed/compositions/{compositionId}","href":"/api-reference/public-embed/get-public-composition-embed"},{"title":"Get a composition frame","deprecated":null,"version":null,"tag":"No key","openapi":"/openapi/widgetic-api-public.json get /embed/compositions/{compositionId}/frame","href":"/api-reference/public-embed/get-public-composition-iframe"},{"title":"Check embed status in a batch","deprecated":null,"version":null,"tag":"No key","openapi":"/openapi/widgetic-api-public.json post /embed/compositions/status","href":"/api-reference/public-embed/post-public-composition-embed-status"},{"title":"Add a visitor entry","deprecated":null,"version":null,"tag":"No key","openapi":"/openapi/widgetic-api-public.json post /embed/compositions/{compositionId}/entries/{table}","href":"/api-reference/public-embed/create-public-composition-entry"},{"title":"Call an adapter","deprecated":null,"version":null,"tag":"No key","openapi":"/openapi/widgetic-api-public.json post /embed/compositions/{compositionId}/adapters/{adapterId}/{operation}","href":"/api-reference/public-embed/call-public-composition-adapter"},{"title":"Upload an adapter file","deprecated":null,"version":null,"tag":"No key","openapi":"/openapi/widgetic-api-public.json put /embed/compositions/{compositionId}/adapters/upload/files/{ticket}","href":"/api-reference/public-embed/upload-public-composition-adapter-file"},{"title":"Get a published workflow","deprecated":null,"version":null,"tag":"No key","openapi":"/openapi/widgetic-api-public.json get /embed/workflows/{workflowId}","href":"/api-reference/public-embed/get-public-workflow"},{"title":"Get a published workflow version","deprecated":null,"version":null,"tag":"No key","openapi":"/openapi/widgetic-api-public.json get /embed/workflows/{workflowId}/versions/{versionId}","href":"/api-reference/public-embed/get-public-workflow-version"},{"title":"Get a workflow frame","deprecated":null,"version":null,"tag":"No key","openapi":"/openapi/widgetic-api-public.json get /embed/workflows/{workflowId}/frame","href":"/api-reference/public-embed/get-public-workflow-frame"},{"title":"Report workflow events","deprecated":null,"version":null,"tag":"No key","openapi":"/openapi/widgetic-api-public.json post /embed/workflows/{workflowId}/events","href":"/api-reference/public-embed/report-public-workflow-events"}]},{"group":"Webhook events","pages":[{"group":"Payments","pages":[{"title":"Invoice issued","openapi":"openapi/widgetic-webhooks.json webhook invoice.issued","href":"/api-reference/events/invoice-issued"},{"title":"Invoice due soon","openapi":"openapi/widgetic-webhooks.json webhook invoice.due_soon","href":"/api-reference/events/invoice-due-soon"},{"title":"Invoice overdue","openapi":"openapi/widgetic-webhooks.json webhook invoice.overdue","href":"/api-reference/events/invoice-overdue"},{"title":"Payment received","openapi":"openapi/widgetic-webhooks.json webhook invoice.paid","href":"/api-reference/events/invoice-paid"},{"title":"Payment failed","openapi":"openapi/widgetic-webhooks.json webhook invoice.failed","href":"/api-reference/events/invoice-failed"}]},{"group":"Credits","pages":[{"title":"Credits running low","openapi":"openapi/widgetic-webhooks.json webhook credits.low","href":"/api-reference/events/credits-low"},{"title":"Managed user reached its monthly credits","openapi":"openapi/widgetic-webhooks.json webhook credits.managed_user_cap_reached","href":"/api-reference/events/credits-managed-user-cap-reached"}]},{"group":"Your account","pages":[{"title":"Account activated","openapi":"openapi/widgetic-webhooks.json webhook partner.activated","href":"/api-reference/events/partner-activated"},{"title":"Account paused","openapi":"openapi/widgetic-webhooks.json webhook partner.paused","href":"/api-reference/events/partner-paused"},{"title":"Account resumed","openapi":"openapi/widgetic-webhooks.json webhook partner.resumed","href":"/api-reference/events/partner-resumed"},{"title":"Partnership ending","openapi":"openapi/widgetic-webhooks.json webhook partner.ending","href":"/api-reference/events/partner-ending"}]},{"group":"Storage","pages":[{"title":"Storage check failed","openapi":"openapi/widgetic-webhooks.json webhook storage.check_failed","href":"/api-reference/events/storage-check-failed"}]},{"group":"Customer activity","pages":[{"title":"Composition created","openapi":"openapi/widgetic-webhooks.json webhook composition.created","href":"/api-reference/events/composition-created"},{"title":"Composition saved","openapi":"openapi/widgetic-webhooks.json webhook composition.updated","href":"/api-reference/events/composition-updated"},{"title":"Widget published","openapi":"openapi/widgetic-webhooks.json webhook widget.published","href":"/api-reference/events/widget-published"},{"title":"Upload created","openapi":"openapi/widgetic-webhooks.json webhook upload.created","href":"/api-reference/events/upload-created"},{"title":"Entry created","openapi":"openapi/widgetic-webhooks.json webhook entry.created","href":"/api-reference/events/entry-created"},{"title":"Workflow created","openapi":"openapi/widgetic-webhooks.json webhook workflow.created","href":"/api-reference/events/workflow-created"},{"title":"Workflow published","openapi":"openapi/widgetic-webhooks.json webhook workflow.published","href":"/api-reference/events/workflow-published"},{"title":"Workflow state changed","openapi":"openapi/widgetic-webhooks.json webhook workflow.state_changed","href":"/api-reference/events/workflow-state-changed"},{"title":"Workflow deleted","openapi":"openapi/widgetic-webhooks.json webhook workflow.deleted","href":"/api-reference/events/workflow-deleted"}]},{"group":"MCP events","pages":[{"title":"Submission created","openapi":"openapi/widgetic-webhooks.json webhook submission.created","href":"/api-reference/events/submission-created"},{"title":"Subscription verification","openapi":"openapi/widgetic-webhooks.json webhook verification","href":"/api-reference/events/verification"}]}]}]},{"tab":"Resources","pages":[{"title":"Resources","href":"/resources/examples"}]}]},"basePath":"","title":"Create an editor session - Developer documentation","deploymentId":"dpl_BLZw3QngerHodH9E8mGgC4v752y3","buildId":"dpl_BLZw3QngerHodH9E8mGgC4v752y3","dynamics":["c2aa737661","2b790eda92","b0f84f53ff","a9bb46feb3"],"chunks":["OpenApiReferenceProvider-CaRkHcld.js","snippetPresets-CbOVSLWB.js","utils-cjri0g4r.js","style-to-object-BY3JEAdk.js","utils-DINdUa17.js","v4-DIgz8zy6.js","addTypeLabelsToSchema-B6z-PJGf.js","conditional-requirements-CFM0id0Q.js","cloneDeep-BldndzCM.js","_Uint8Array-BFUkDgJK.js","isObject-FP1Yky1u.js","ApiExamples-gah5G0c1.js","usePlaygroundInputsStore-DMbftGRK.js","shallow-BPuQ-dV8.js","isEqual-Du6c450V.js","CodeSnippets-BSVM0Ibi.js","CodeSnippet-BtGQRZnK.js","use-playground-group-access-98JyaSW7.js","Page-DuvGhd6e.js","api-description-markdown-ja0XM5Ae.js","DynamicMarkdown-DgKZ4_wp.js","SectionHeading-S4Jc_qPe.js","MethodPill-HIsDH_bI.js","getPastedJson-BKEmMYEO.js","Check2Icon-CRFAnWm9.js","axios-CsQoIw0U.js","Markdown-CexXCNoj.js","AssistantPageLink-C2AZnMAs.js","dist-CjxLTLs9.js","lib-DMeTj1gb.js","lib-B8HbPgcC.js","katex-Dbtb6Wk7.js","html-void-elements-mCSPHezU.js","marked.esm-CZWythHk.js"]}