Skip to content
Connect an agent

HTTP API

Schemas

Every request and response type of the HTTP API, with its fields. Each endpoint page links the types it uses.

TL;DR

QuestionAnswer
What is a schema?The shape of a JSON body: its fields, their types, and which are required.
Where do I find the one an endpoint uses?On the endpoint page, whose request and response types link here.
Where is the machine-readable form?GET /openapi.json returns every schema as OpenAPI 3.1 JSON Schema.
How many are there?507.

HealthResponse

Liveness answer.

FieldTypeRequiredDescription
status"ok"yes
versionstringyesPackage version of the running service.
kindsstring[]yesDiagram kinds this build can render.

Accepted

FieldTypeRequiredDescription
acceptedtrueyes

ErrorResponse

Standard error envelope used by every failing response.

FieldTypeRequiredDescription
errortrueyesAlways true, so clients can branch without reading the status.
errorCodestringyesStable snake_case key such as validation.failed or diagram.invalid.
messagestringyesSafe, human-readable summary.
detailsanynoValidation issues or diagnostics, JSON-safe.
requestIdstringnoTrace id for correlating with logs.

RequestCodeBody

FieldTypeRequiredDescription
emailstringyesat least 3 characters; at most 254 characters.
turnstileTokenstringnoThe token the Cloudflare Turnstile widget on the sign-in page gave. Required when the server has a Turnstile secret. at most 2048 characters.

VerifyResponse

FieldTypeRequiredDescription

SignInResponse

FieldTypeRequiredDescription
userAccountyes
user.idstringyes
user.emailstringyes

Account

FieldTypeRequiredDescription
idstringyes
emailstringyes

TwoFactorStep

FieldTypeRequiredDescription
twoFactorobjectyes
twoFactor.challengestringyesSend it back with the code. It lives ten minutes and takes five wrong codes.
twoFactor.expiresAtintegeryesWhen the step ends, in milliseconds since the epoch.

VerifyCodeBody

FieldTypeRequiredDescription
emailstringyesat least 3 characters; at most 254 characters.
codestringyespattern ^\d{6}$.

TwoFactorSignInBody

FieldTypeRequiredDescription
challengestringyespattern ^[0-9a-f]{64}$.
codestringnoThe six digits the authenticator app shows now. pattern ^\d{6}$.
recoveryCodestringnoOne of the recovery codes made when two-step sign-in was turned on. Each works once. at least 10 characters; at most 32 characters.

SsoDiscover

FieldTypeRequiredDescription
ssobooleanyesTrue when the address's domain signs in through an organisation's identity provider. Names no organisation.

SsoDiscoverBody

FieldTypeRequiredDescription
emailstringyesat least 3 characters; at most 254 characters.

SsoStart

FieldTypeRequiredDescription
urlstringyesThe identity provider's authorization address to send the browser to.

SsoStartBody

FieldTypeRequiredDescription
emailstringyesat least 3 characters; at most 254 characters.
returnTostringnoWhere to send the browser after signing in. Kept only when its origin is one of Plotwork's; otherwise the portal. at most 2000 characters.
turnstileTokenstringnoThe token the Cloudflare Turnstile widget on the sign-in page gave. Required when the server has a Turnstile secret. at most 2048 characters.

SsoIssuerDocument

FieldTypeRequiredDescription
issuerstringyes
jwks_uristringyes
response_types_supportedstring[]yes
subject_types_supportedstring[]yes
id_token_signing_alg_values_supportedstring[]yes

SsoJwks

FieldTypeRequiredDescription
keysSsoPublicJwk[]yes
keys[].kty"RSA"yes
keys[].nstringyesThe modulus, base64url.
keys[].estringyesThe public exponent, base64url.
keys[].kidstringyesThe key id: the key's RFC 7638 thumbprint.
keys[].alg"RS256"yes
keys[].use"sig"yes

SsoPublicJwk

FieldTypeRequiredDescription
kty"RSA"yes
nstringyesThe modulus, base64url.
estringyesThe public exponent, base64url.
kidstringyesThe key id: the key's RFC 7638 thumbprint.
alg"RS256"yes
use"sig"yes

ConnectorIssuerDocument

FieldTypeRequiredDescription
issuerstringyesThe federated credential's Issuer, exactly.
jwks_uristringyes
response_types_supportedstring[]yes
subject_types_supportedstring[]yes
id_token_signing_alg_values_supportedstring[]yes
claims_supportedstring[]yes

ConnectorJwks

FieldTypeRequiredDescription
keysobject[]yes
keys[].kty"RSA"yes
keys[].nstringyesThe modulus, base64url.
keys[].estringyesThe public exponent, base64url.
keys[].kidstringyesThe key id: the key's RFC 7638 thumbprint.
keys[].alg"RS256"yes
keys[].use"sig"yes

OidcToken

FieldTypeRequiredDescription
tokenstringyesA Plotwork token, pwo_ and 64 hex characters. Send it as X-API-Key or Authorization: Bearer. Never stored by Plotwork, only its hash.
tokenType"Bearer"yes
expiresAtintegeryesWhen it stops working, in milliseconds since the epoch.
expiresInintegeryesSeconds until it stops working.
organizationobjectyes
organization.idstringyes
organization.slugstringyes
organization.namestringyes
publisherobjectyes
publisher.idstringyes
publisher.namestringyes
permissions("diagrams" | "drift:write")[]yesdiagrams: publish to the organisation's library (and read it and the style rules). drift:write: report drift runs to the Drift tab and read the style rules.

OidcTokenBody

FieldTypeRequiredDescription
tokenstringyesThe job's ID token: a GitHub Actions token asked for with this API's origin as the audience, an Azure Pipelines token from System.OidcRequestUri, or a GitLab CI/CD token the job names in id_tokens with this API's origin as aud. at least 1 character; at most 16384 characters.
organizationstringnoThe organisation to sign in to, by slug or id. Needed only when several organisations trust the run. at least 1 character; at most 64 characters.

AccountProfile

FieldTypeRequiredDescription
idstringyes
emailstringyes
namestring | nullyesThe name the account is shown by, or null for none.
createdAtintegeryesWhen the account was made, in milliseconds since the epoch.

ApiKeyList

FieldTypeRequiredDescription
itemsApiKeySummary[]yes
items[].idstringyes
items[].namestringyes
items[].prefixstringyes
items[].last4stringyes
items[].createdAtintegeryesMilliseconds since the epoch.
items[].lastUsedAtinteger | nullyesMilliseconds since the epoch, or null if never used.
items[].revealablebooleanyesTrue when the full key can be shown again with the reveal route. False for a key made before that was possible, or on a server that cannot seal keys.

ApiKeySummary

FieldTypeRequiredDescription
idstringyes
namestringyes
prefixstringyes
last4stringyes
createdAtintegeryesMilliseconds since the epoch.
lastUsedAtinteger | nullyesMilliseconds since the epoch, or null if never used.
revealablebooleanyesTrue when the full key can be shown again with the reveal route. False for a key made before that was possible, or on a server that cannot seal keys.

CreatedApiKey

FieldTypeRequiredDescription
idstringyes
namestringyes
prefixstringyes
last4stringyes
createdAtintegeryesMilliseconds since the epoch.
lastUsedAtinteger | nullyesMilliseconds since the epoch, or null if never used.
revealablebooleanyesTrue when the full key can be shown again with the reveal route. False for a key made before that was possible, or on a server that cannot seal keys.
keystringyesThe full key. When revealable is false this is the only time it is shown, so store it now.

CreateApiKeyBody

FieldTypeRequiredDescription
namestringyesat least 1 character; at most 60 characters; pattern \S.

RevealedApiKey

FieldTypeRequiredDescription
idstringyes
keystringyesThe full key.

Approval

FieldTypeRequiredDescription
approvalstringyesThe signed approval. It carries the connection key sealed, so it is safe in an address.
expiresInintegeryesSeconds the approval stays usable.
redirectTostringyesWhere to send the browser: the MCP server callback with the request and the approval already attached.

ApproveConnectionBody

FieldTypeRequiredDescription
requeststringyesThe signed authorization request, exactly as the MCP server put it in the address. at least 1 character; at most 6144 characters.
organisationstringnoConnect the agent to this organisation, by its id, instead of your own account. Any role but reader may. The agent then works in the organisation's library as you, with the diagram permissions your role has and nothing more, and its calls count toward your own daily allowance.

Denial

FieldTypeRequiredDescription
redirectTostringyesWhere to send the browser: the MCP server callback with the request and error=access_denied attached.

DenyConnectionBody

FieldTypeRequiredDescription
requeststringyesThe signed authorization request, exactly as the MCP server put it in the address. at least 1 character; at most 6144 characters.

McpRequestState

FieldTypeRequiredDescription
state"open" | "used" | "expired" | "invalid"yesopen: it can be approved or denied. used: it was approved or denied already, by any account; each sign-in link works once. expired: its ten minutes are over. invalid: the MCP server did not sign it.
expiresIninteger | nullyesFor open, the seconds until it stops being good. Null otherwise.

ConnectableAccounts

FieldTypeRequiredDescription
personalobjectyes
personal.allowedbooleanyesFalse when an organisation you belong to asks that agents connect to it, and your address is on one of its verified domains.
personal.requiredByobject[]yesThe organisations that ask it. Empty when allowed is true.
personal.requiredBy[].idstringyes
personal.requiredBy[].slugstringyes
personal.requiredBy[].namestringyes
organisationsobject[]yesThe organisations where your role may publish (every role but reader), so an agent can be connected to them. Ordered by name.
organisations[].idstringyes
organisations[].slugstringyes
organisations[].namestringyes
organisations[].role"owner" | "admin" | "member" | "reader"yes
organisations[].agentAllowedbooleanyesFalse when the organisation allows only approved agents ("Only approved agents can connect") and the agent named by request is not one of them, or an organisation that holds you to organisation connections has not approved it. True when no request was sent.

ConnectionList

FieldTypeRequiredDescription
itemsConnection[]yes
items[].idstringyes
items[].clientIdstringyesThe OAuth client id the agent registered with.
items[].clientNamestringyesThe name the agent gave itself when it registered. It is a claim, not a fact.
items[].connectedAtintegeryesMilliseconds since the epoch.
items[].lastUsedAtinteger | nullyesMilliseconds since the epoch, or null if the agent has not made a call.
items[].organisationConnectionOrganisationyesThe organisation the agent was connected to, or null when it acts for your own account.
items[].organisation.idstringyes
items[].organisation.slugstringyes
items[].organisation.namestringyes

Connection

FieldTypeRequiredDescription
idstringyes
clientIdstringyesThe OAuth client id the agent registered with.
clientNamestringyesThe name the agent gave itself when it registered. It is a claim, not a fact.
connectedAtintegeryesMilliseconds since the epoch.
lastUsedAtinteger | nullyesMilliseconds since the epoch, or null if the agent has not made a call.
organisationConnectionOrganisationyesThe organisation the agent was connected to, or null when it acts for your own account.
organisation.idstringyes
organisation.slugstringyes
organisation.namestringyes

ConnectionOrganisation

The organisation the agent was connected to, or null when it acts for your own account.

FieldTypeRequiredDescription
idstringyes
slugstringyes
namestringyes

AppRequestState

FieldTypeRequiredDescription
state"open" | "used" | "expired" | "invalid"yes
expiresIninteger | nullyesSeconds left for an open link.
appobject | nullyes
app.idstringyesThe app's id, which is its OAuth client_id.
app.namestringyesA claim, not a fact.
app.homepagestring | nullyes
app.organisationobject | nullyesThe organisation that registered the app, or null for a person or for Plotwork.
app.organisation.idstringyes
app.organisation.slugstringyes
app.organisation.namestringyes
app.membersOnlybooleanyes
app.madeByPlotworkbooleanyesTrue for Plotwork's own app, registered by Plotwork rather than by a person or an organisation. Its name is then a fact, not a claim.
scopesarray | nullyes
redirectUristring | nullyesWhere the app receives its code. Show its host.

AppScope

diagrams:use computes (validate, draw, render, import), diagrams:publish publishes, library:read lists and shows the diagrams the account can see, profile reads the account id and name, email its address.

FieldTypeRequiredDescription

AppAccounts

FieldTypeRequiredDescription
personalobjectyes
personal.allowedbooleanyes
organisationsobject[]yes
organisations[].idstringyes
organisations[].slugstringyes
organisations[].namestringyes
organisations[].role"owner" | "admin" | "member" | "reader"yes
organisations[].appAllowedbooleanyesFalse when the organisation cannot take the app the request names; reason says why. True when no request was sent, or it did not verify: the approval checks again.
organisations[].reason"members_only" | "not_allowed" | nullyesWhy the organisation cannot take the app: members_only (another organisation registered it for its own members), not_allowed (the organisation's "Only approved apps can connect" does not list it). Null when it can.

AppAnswer

FieldTypeRequiredDescription
redirectTostringyesThe app's redirect address with code (or error), state and iss. Navigate there.

ApproveAppBody

FieldTypeRequiredDescription
requeststringyesThe signed authorization request, exactly as the API put it in the consent page address. at least 1 character; at most 6144 characters.
organisationstringnoConnect the app to this organisation, by its id, instead of your own account. Any role but reader may; the app then acts in the organisation's library as you, with your role's diagram permissions.

DenyAppBody

FieldTypeRequiredDescription
requeststringyesThe signed authorization request, exactly as the API put it in the consent page address. at least 1 character; at most 6144 characters.

RegisteredAppList

FieldTypeRequiredDescription
itemsRegisteredApp[]yes
items[].idstringyesThe app's id, which is its OAuth client_id.
items[].namestringyesShown to people as a claim on the consent page.
items[].homepagestring | nullyes
items[].clientType"confidential" | "public"yesconfidential holds a client secret on its server; public (a page or a tool with no server) holds none.
items[].redirectUrisstring[]yes
items[].membersOnlybooleanyesFor an organisation's app: only its members may connect it, to the organisation.
items[].hasSecretbooleanyes
items[].createdAtintegeryesMilliseconds since the epoch.
items[].updatedAtintegeryesMilliseconds since the epoch.

RegisteredApp

FieldTypeRequiredDescription
idstringyesThe app's id, which is its OAuth client_id.
namestringyesShown to people as a claim on the consent page.
homepagestring | nullyes
clientType"confidential" | "public"yesconfidential holds a client secret on its server; public (a page or a tool with no server) holds none.
redirectUrisstring[]yes
membersOnlybooleanyesFor an organisation's app: only its members may connect it, to the organisation.
hasSecretbooleanyes
createdAtintegeryesMilliseconds since the epoch.
updatedAtintegeryesMilliseconds since the epoch.

AppWithSecret

FieldTypeRequiredDescription
idstringyesThe app's id, which is its OAuth client_id.
namestringyesShown to people as a claim on the consent page.
homepagestring | nullyes
clientType"confidential" | "public"yesconfidential holds a client secret on its server; public (a page or a tool with no server) holds none.
redirectUrisstring[]yes
membersOnlybooleanyesFor an organisation's app: only its members may connect it, to the organisation.
hasSecretbooleanyes
createdAtintegeryesMilliseconds since the epoch.
updatedAtintegeryesMilliseconds since the epoch.
clientSecretstring | nullyesThe client secret (pws_...), shown once, or null for a public app. Store it on your server.

NewAppBody

FieldTypeRequiredDescription
namestringyesat least 3 characters; at most 60 characters.
homepagestring | nullnoAn https address, shown as a claim. at most 2048 characters.
clientType"confidential" | "public"yes
redirectUrisstring[]yesOne to ten addresses a code may be sent to, matched exactly: https, or http on localhost, 127.0.0.1 or [::1] with any port.

AppChangeBody

FieldTypeRequiredDescription
namestringnoat least 3 characters; at most 60 characters.
homepagestring | nullnoat most 2048 characters.
redirectUrisstring[]noOne to ten addresses a code may be sent to, matched exactly: https, or http on localhost, 127.0.0.1 or [::1] with any port.

AppConnectionList

FieldTypeRequiredDescription
itemsAppConnection[]yes
items[].idstringyes
items[].appobjectyes
items[].app.idstringyesThe app's id, which is its OAuth client_id.
items[].app.namestringyes
items[].app.homepagestring | nullyes
items[].scopesAppScope[]yes
items[].connectedAtintegeryes
items[].lastUsedAtinteger | nullyes
items[].organisationobject | nullyes
items[].organisation.idstringyes
items[].organisation.slugstringyes
items[].organisation.namestringyes

AppConnection

FieldTypeRequiredDescription
idstringyes
appobjectyes
app.idstringyesThe app's id, which is its OAuth client_id.
app.namestringyes
app.homepagestring | nullyes
scopesAppScope[]yes
connectedAtintegeryes
lastUsedAtinteger | nullyes
organisationobject | nullyes
organisation.idstringyes
organisation.slugstringyes
organisation.namestringyes

Usage

FieldTypeRequiredDescription
plan"free" | "pro"yesThe plan the account is on, which decides the limit.
limitintegeryesMetered calls the account may make per UTC day, across every key and connected agent.
usedintegeryesMetered calls made today. minimum 0.
remainingintegeryesCalls left today. Zero when the limit is used up. minimum 0.
resetsAtintegeryesWhen the count goes back to zero (00:00 UTC), in milliseconds since the epoch.
todayobjectyesToday's calls, split by how they reached the service.
today.apiintegeryesminimum 0.
today.mcpintegeryesminimum 0.
daysUsageDay[]yesThe last 30 days, oldest first, ending today. A day with no calls is present with zeros.
days[].daystringyesThe UTC date, as YYYY-MM-DD.
days[].apiintegeryesREST API calls that day. minimum 0.
days[].mcpintegeryesMCP tool calls that day. minimum 0.

UsageDay

FieldTypeRequiredDescription
daystringyesThe UTC date, as YYYY-MM-DD.
apiintegeryesREST API calls that day. minimum 0.
mcpintegeryesMCP tool calls that day. minimum 0.

UpdateProfileBody

FieldTypeRequiredDescription
namestring | nullyesThe name to be shown by, at most 80 characters once trimmed, with no line breaks. Empty or null clears it. at most 320 characters.

EmailChangeBody

FieldTypeRequiredDescription
emailstringyesat least 3 characters; at most 254 characters.

EmailVerifyBody

FieldTypeRequiredDescription
emailstringyesat least 3 characters; at most 254 characters.
codestringyespattern ^\d{6}$.

EndedSessions

FieldTypeRequiredDescription
endedintegeryes

DeleteAccountBody

FieldTypeRequiredDescription
confirmstringyesat most 254 characters.

Security

FieldTypeRequiredDescription
twoFactorTwoFactorStateyes
twoFactor.enabledbooleanyes
twoFactor.enabledAtinteger | nullyes
twoFactor.recoveryCodesLeftintegeryes
twoFactor.requiredByobject[]yesThe organisations the account is in that require two-step sign-in.
twoFactor.requiredBy[].slugstringyes
twoFactor.requiredBy[].namestringyes

TwoFactorState

FieldTypeRequiredDescription
enabledbooleanyes
enabledAtinteger | nullyes
recoveryCodesLeftintegeryes
requiredByobject[]yesThe organisations the account is in that require two-step sign-in.
requiredBy[].slugstringyes
requiredBy[].namestringyes

TwoFactorSetup

FieldTypeRequiredDescription
secretstringyesThe shared secret in base32, for typing into an app that cannot scan.
uristringyesThe otpauth:// address an authenticator app scans as a QR code.

RecoveryCodes

FieldTypeRequiredDescription
recoveryCodesstring[]yes

TotpCodeBody

FieldTypeRequiredDescription
codestringyesThe six digits the authenticator app shows now. pattern ^\d{6}$.

SecondFactorBody

FieldTypeRequiredDescription
codestringnoThe six digits the authenticator app shows now. pattern ^\d{6}$.
recoveryCodestringnoOne of the recovery codes made when two-step sign-in was turned on. Each works once. at least 10 characters; at most 32 characters.

AgentList

FieldTypeRequiredDescription
itemsAgent[]yes
items[].idstringyes
items[].credential"oauth" | "key"yesHow it signs in: a browser sign-in (OAuth) or an API key in its settings.
items[].namestringyesThe connection's registered agent name, or the key's name.
items[].agentobject | nullyesWhat the agent called itself (clientInfo) when it last opened an MCP session, or null when it never has.
items[].agent.namestringyes
items[].agent.versionstring | nullyes
items[].orgIdstring | nullyes
items[].createdAtintegeryes
items[].lastUsedAtinteger | nullyesIts last call, to within five minutes.
items[].sessionAtinteger | nullyesWhen it last opened an MCP session.
items[].expiresAtinteger | nullyes
items[].status"live" | "ready" | "idle" | "waiting" | "blocked"yeslive: a call in the last 15 minutes. ready: in the last 30 days. idle: earlier. waiting: never used. blocked: its next call would be refused, and blocked says why.
items[].blocked"expired" | "network" | "two_factor" | "membership" | "policy" | nullyes

Agent

FieldTypeRequiredDescription
idstringyes
credential"oauth" | "key"yesHow it signs in: a browser sign-in (OAuth) or an API key in its settings.
namestringyesThe connection's registered agent name, or the key's name.
agentobject | nullyesWhat the agent called itself (clientInfo) when it last opened an MCP session, or null when it never has.
agent.namestringyes
agent.versionstring | nullyes
orgIdstring | nullyes
createdAtintegeryes
lastUsedAtinteger | nullyesIts last call, to within five minutes.
sessionAtinteger | nullyesWhen it last opened an MCP session.
expiresAtinteger | nullyes
status"live" | "ready" | "idle" | "waiting" | "blocked"yeslive: a call in the last 15 minutes. ready: in the last 30 days. idle: earlier. waiting: never used. blocked: its next call would be refused, and blocked says why.
blocked"expired" | "network" | "two_factor" | "membership" | "policy" | nullyes

AgentCheck

FieldTypeRequiredDescription
agentAgentyes
agent.idstringyes
agent.credential"oauth" | "key"yesHow it signs in: a browser sign-in (OAuth) or an API key in its settings.
agent.namestringyesThe connection's registered agent name, or the key's name.
agent.agentobject | nullyesWhat the agent called itself (clientInfo) when it last opened an MCP session, or null when it never has.
agent.agent.namestringyes
agent.agent.versionstring | nullyes
agent.orgIdstring | nullyes
agent.createdAtintegeryes
agent.lastUsedAtinteger | nullyesIts last call, to within five minutes.
agent.sessionAtinteger | nullyesWhen it last opened an MCP session.
agent.expiresAtinteger | nullyes
agent.status"live" | "ready" | "idle" | "waiting" | "blocked"yeslive: a call in the last 15 minutes. ready: in the last 30 days. idle: earlier. waiting: never used. blocked: its next call would be refused, and blocked says why.
agent.blocked"expired" | "network" | "two_factor" | "membership" | "policy" | nullyes
checksobject[]yesEvery rule its next call would meet, in the order it meets them.
checks[].id"credential" | "expiry" | "network" | "organisation" | "two_factor" | "policy" | "allowance"yes
checks[].okbooleanyes
remainingintegeryesCalls left today on the allowance it spends.
checkedAtintegeryes

BillingState

FieldTypeRequiredDescription
plan"free" | "pro"yesThe plan the account gets right now. It is the free plan whenever the subscription is not paying, whatever plan was bought.
statusstringyesStripe's status for the subscription (active, trialing, past_due, canceled, unpaid, incomplete, and so on), or none when the account never started one.
currentPeriodEndinteger | nullyesWhen the period paid for ends, in milliseconds since the epoch, or null when there is no subscription.
cancelAtPeriodEndbooleanyesTrue while the subscription is scheduled to end at the close of the period already paid for.
hasCustomerbooleanyesTrue once the account has billing details at Stripe, which is when the billing portal can be opened.

BillingUrl

FieldTypeRequiredDescription
urlstringyesAn address on Stripe's own site. Send the browser there; it expires, so do not store it.

CheckoutBody

FieldTypeRequiredDescription
plan"pro"yesThe plan to subscribe to. pro is the only paid plan.

VerifyCheckoutBody

FieldTypeRequiredDescription
sessionIdstringyesThe Checkout Session id Stripe put in the return address. pattern ^cs_[A-Za-z0-9_]{8,200}$.

CancelBody

FieldTypeRequiredDescription
reasonstringnoWhy the person is cancelling, in their own words. Optional. Sent to Stripe as the cancellation comment; Plotwork does not store it. at most 500 characters.

BillingDocumentList

FieldTypeRequiredDescription
itemsBillingDocument[]yes
items[].idstringyesThe id to ask for the document and its PDF with.
items[].kind"invoice" | "receipt"yesA receipt is an invoice that has been paid; anything else is an invoice.
items[].numberstringyesThe number printed on the document, which an accounts department quotes back.
items[].descriptionstringyesWhat it was for, such as the plan. Empty when Stripe names nothing.
items[].currencystringyesThe three-letter currency, in capitals. at least 3 characters; at most 3 characters.
items[].totalCentsintegeryesThe total in whole cents (the currency's minor unit).
items[].statusstringyesThe invoice's own word: paid, open, void, or uncollectible. A draft is never listed.
items[].issuedAtintegeryesWhen it was issued, in milliseconds since the epoch.
items[].paidAtinteger | nullyesWhen it was paid, in milliseconds since the epoch, or null while it is not.
items[].downloadablebooleanyesFalse when there is no PDF to fetch, so the PDF route would answer 404.

BillingDocument

FieldTypeRequiredDescription
idstringyesThe id to ask for the document and its PDF with.
kind"invoice" | "receipt"yesA receipt is an invoice that has been paid; anything else is an invoice.
numberstringyesThe number printed on the document, which an accounts department quotes back.
descriptionstringyesWhat it was for, such as the plan. Empty when Stripe names nothing.
currencystringyesThe three-letter currency, in capitals. at least 3 characters; at most 3 characters.
totalCentsintegeryesThe total in whole cents (the currency's minor unit).
statusstringyesThe invoice's own word: paid, open, void, or uncollectible. A draft is never listed.
issuedAtintegeryesWhen it was issued, in milliseconds since the epoch.
paidAtinteger | nullyesWhen it was paid, in milliseconds since the epoch, or null while it is not.
downloadablebooleanyesFalse when there is no PDF to fetch, so the PDF route would answer 404.

BillingDocumentDetail

FieldTypeRequiredDescription
idstringyesThe id to ask for the document and its PDF with.
kind"invoice" | "receipt"yesA receipt is an invoice that has been paid; anything else is an invoice.
numberstringyesThe number printed on the document, which an accounts department quotes back.
descriptionstringyesWhat it was for, such as the plan. Empty when Stripe names nothing.
currencystringyesThe three-letter currency, in capitals. at least 3 characters; at most 3 characters.
totalCentsintegeryesThe total in whole cents (the currency's minor unit).
statusstringyesThe invoice's own word: paid, open, void, or uncollectible. A draft is never listed.
issuedAtintegeryesWhen it was issued, in milliseconds since the epoch.
paidAtinteger | nullyesWhen it was paid, in milliseconds since the epoch, or null while it is not.
downloadablebooleanyesFalse when there is no PDF to fetch, so the PDF route would answer 404.
linesDocumentLine[]yes
lines[].descriptionstringyes
lines[].quantityintegeryesminimum 1.
lines[].amountCentsintegeryes
lines[].periodStartinteger | nullyesThe start of the service period, in milliseconds since the epoch, or null.
lines[].periodEndinteger | nullyesThe end of the service period, in milliseconds since the epoch, or null.
subtotalCentsinteger | nullyes
taxCentsinteger | nullyesThe tax, or null when Stripe names none.
amountPaidCentsinteger | nullyes
billedToobjectyes
billedTo.namestring | nullyes
billedTo.emailstring | nullyes
issuerobject | nullyesThe Stripe account's business name and its tax numbers, from the invoice. There is no address: Stripe does not put one on an invoice.
issuer.namestringyes
issuer.linesstring[]yes
paidWithobject | nullyesThe card the payment was taken from: its brand and last four digits, and nothing more of it. Null when it was not paid by card.
paidWith.brandstringyes
paidWith.last4stringyespattern ^\d{4}$.

DocumentLine

FieldTypeRequiredDescription
descriptionstringyes
quantityintegeryesminimum 1.
amountCentsintegeryes
periodStartinteger | nullyesThe start of the service period, in milliseconds since the epoch, or null.
periodEndinteger | nullyesThe end of the service period, in milliseconds since the epoch, or null.

WebhookAck

FieldTypeRequiredDescription
receivedtrueyes
outcome"handled" | "duplicate" | "ignored"yeshandled when the event changed or confirmed an account, duplicate when it had been handled before, ignored when it is not about a Plotwork subscription.

AgentBoardList

FieldTypeRequiredDescription
organizationobjectyes
organization.idstringyes
organization.slugstringyes
organization.namestringyes
boardsAgentBoardItem[]yes
boards[].idstringyesat least 22 characters; at most 22 characters; pattern ^[0-9A-Za-z]+$.
boards[].namestringyes
boards[].classification"public" | "internal" | "confidential"yes
boards[].role"view" | "edit" | "manage"yesWhat the caller may do: view, edit, or manage. An agent has its member's role; a key the role every member gets.
boards[].tabsintegeryesminimum 0.
boards[].updatedAtintegeryes
boards[].livebooleanyesTrue when someone opened the board in the last two minutes.
totalintegeryesHow many boards matched, which can be more than the ones listed. minimum 0.

AgentBoardItem

FieldTypeRequiredDescription
idstringyesat least 22 characters; at most 22 characters; pattern ^[0-9A-Za-z]+$.
namestringyes
classification"public" | "internal" | "confidential"yes
role"view" | "edit" | "manage"yesWhat the caller may do: view, edit, or manage. An agent has its member's role; a key the role every member gets.
tabsintegeryesminimum 0.
updatedAtintegeryes
livebooleanyesTrue when someone opened the board in the last two minutes.

AgentBoard

FieldTypeRequiredDescription
idstringyesat least 22 characters; at most 22 characters; pattern ^[0-9A-Za-z]+$.
namestringyes
classification"public" | "internal" | "confidential"yes
role"view" | "edit" | "manage"yesWhat the caller may do: view, edit, or manage. An agent has its member's role; a key the role every member gets.
versionintegeryesThe version of the tab list: it moves when a tab is added, renamed, moved or deleted.
urlstringyesThe board's address in the portal, for the person.
tabsAgentBoardTab[]yes
tabs[].idstringyesat least 12 characters; at most 12 characters; pattern ^[0-9A-Za-z]+$.
tabs[].namestringyes
tabs[].kindstringyes
tabs[].positionnumberyes
tabs[].versionintegeryesSend it as baseVersion with the next edit, and as sinceVersion to learn what changed after it.
tabs[].updatedAtintegeryes
tabs[].updatedBystringyes
presentobject[]yesWho is on the board now: people with it open, and agents that acted in the last two minutes.
present[].labelstringyes
present[].kind"person" | "agent"yes
messagesBoardAgentMessage[]yesMessages the caller's person sent it on the board that it had not read, each given once. Answer each with reply_board_message.
messages[].idstringyes
messages[].atintegeryes
messages[].fromstringyes
messages[].textstringyes
messages[].tabstring | nullyes
messages[].tabNamestring | nullyes
messages[].revisionstring | nullyes
messages[].problemsBoardAgentProblem[]yes
messages[].problems[].codestringyespattern ^[A-Z]\d{3,4}$.
messages[].problems[].severity"error" | "warning"yes
messages[].problems[].lineintegeryesminimum 1; maximum 1000000.
messages[].problems[].columnintegeryesminimum 1; maximum 1000000.
messages[].problems[].messagestringyesat least 1 character; at most 500 characters.
messages[].problems[].hintstring | nullyesat least 1 character; at most 500 characters.

AgentBoardTab

FieldTypeRequiredDescription
idstringyesat least 12 characters; at most 12 characters; pattern ^[0-9A-Za-z]+$.
namestringyes
kindstringyes
positionnumberyes
versionintegeryesSend it as baseVersion with the next edit, and as sinceVersion to learn what changed after it.
updatedAtintegeryes
updatedBystringyes

BoardAgentMessage

FieldTypeRequiredDescription
idstringyes
atintegeryes
fromstringyes
textstringyes
tabstring | nullyes
tabNamestring | nullyes
revisionstring | nullyes
problemsBoardAgentProblem[]yes
problems[].codestringyespattern ^[A-Z]\d{3,4}$.
problems[].severity"error" | "warning"yes
problems[].lineintegeryesminimum 1; maximum 1000000.
problems[].columnintegeryesminimum 1; maximum 1000000.
problems[].messagestringyesat least 1 character; at most 500 characters.
problems[].hintstring | nullyesat least 1 character; at most 500 characters.

BoardAgentProblem

FieldTypeRequiredDescription
codestringyespattern ^[A-Z]\d{3,4}$.
severity"error" | "warning"yes
lineintegeryesminimum 1; maximum 1000000.
columnintegeryesminimum 1; maximum 1000000.
messagestringyesat least 1 character; at most 500 characters.
hintstring | nullyesat least 1 character; at most 500 characters.

AgentBoardTabRead

FieldTypeRequiredDescription
tabAgentBoardTabyes
tab.idstringyesat least 12 characters; at most 12 characters; pattern ^[0-9A-Za-z]+$.
tab.namestringyes
tab.kindstringyes
tab.positionnumberyes
tab.versionintegeryesSend it as baseVersion with the next edit, and as sinceVersion to learn what changed after it.
tab.updatedAtintegeryes
tab.updatedBystringyes
sourcestringyes
changesSinceBoardHistoryEntry[]yes
changesSince[].versionintegeryes
changesSince[].typestringyes
changesSince[].actorBoardActoryes
changesSince[].actor.kind"person" | "agent" | "key"yes
changesSince[].actor.labelstringyes
changesSince[].countsobjectyes
changesSince[].counts.addedintegeryes
changesSince[].counts.removedintegeryes
changesSince[].counts.renamedintegeryes
changesSince[].counts.movedintegeryes
changesSince[].counts.changedintegeryes
changesSince[].atintegeryes
changesSince[].restorablebooleanyes
svgstringnoThe picture, when asked for and the Engine could draw it.
messagesBoardAgentMessage[]yesMessages the caller's person sent it on the board that it had not read, each given once. Answer each with reply_board_message.
messages[].idstringyes
messages[].atintegeryes
messages[].fromstringyes
messages[].textstringyes
messages[].tabstring | nullyes
messages[].tabNamestring | nullyes
messages[].revisionstring | nullyes
messages[].problemsBoardAgentProblem[]yes
messages[].problems[].codestringyespattern ^[A-Z]\d{3,4}$.
messages[].problems[].severity"error" | "warning"yes
messages[].problems[].lineintegeryesminimum 1; maximum 1000000.
messages[].problems[].columnintegeryesminimum 1; maximum 1000000.
messages[].problems[].messagestringyesat least 1 character; at most 500 characters.
messages[].problems[].hintstring | nullyesat least 1 character; at most 500 characters.

BoardHistoryEntry

FieldTypeRequiredDescription
versionintegeryes
typestringyes
actorBoardActoryes
actor.kind"person" | "agent" | "key"yes
actor.labelstringyes
countsobjectyes
counts.addedintegeryes
counts.removedintegeryes
counts.renamedintegeryes
counts.movedintegeryes
counts.changedintegeryes
atintegeryes
restorablebooleanyes

BoardActor

FieldTypeRequiredDescription
kind"person" | "agent" | "key"yes
labelstringyes

AgentBoardWriteResult

FieldTypeRequiredDescription
changedbooleanyesFalse when the write changed nothing; nothing was stored.
versionintegeryesThe tab's version now: the baseVersion of the next edit.
tabanyyes
tab.idstringyesat least 12 characters; at most 12 characters; pattern ^[0-9A-Za-z]+$.
tab.namestringyes
tab.kindstringyes
tab.positionnumberyes
tab.versionintegeryesSend it as baseVersion with the next edit, and as sinceVersion to learn what changed after it.
tab.updatedAtintegeryes
tab.updatedBystringyes
resultsobject[]yes
results[].opstringyes
results[].appliedbooleanyes
results[].linesinteger[]yes
results[].messagestringyes
results[].hintstring | nullyes
changesobject[]yes
changes[].changestringyes
changes[].subjectstringyes
changes[].namestringyes
changes[].lineinteger | nullyes
changes[].detailstringyes
warningsDiagnostic[]yes
warnings[].code"E100" | "E101" | "E110" | "E111" | "E120" | "E121" | "E123" | "E124" | "E125" | "E130" | "E131" | "E132" | "E133" | "E134" | "E135" | "E136" | "E137" | "E138" | "E139" | "E140" | "W200" | "W201" | "W202" | "W203" | "W204" | "W205" | "W206" | "W207" | "W208" | "W209" | "W500" | "W600" | "W601" | "W700" | "W701" | "W702" | "W703" | "W704" | "W705" | "W706" | "W707" | "W708" | "W709" | "W710" | "M100" | "M101" | "M102" | "M103" | "M104" | "M110" | "M200" | "M201" | "M202" | "M203" | "M204" | "M205" | "M206" | "M207" | "M208" | "M209" | "M210" | "M211" | "M212" | "M213" | "M214" | "M215" | "M216" | "M217" | "M218" | "E300" | "E301" | "E302" | "E303" | "E304" | "W300" | "W301" | "W302" | "W303" | "M120" | "M220" | "M221" | "M222" | "E340" | "E341" | "E342" | "E343" | "E344" | "E345" | "W320" | "W321" | "W322" | "W323" | "M240" | "M241" | "M242" | "E360" | "E361" | "E362" | "E363" | "E364" | "E365" | "E366" | "E367" | "W330" | "W331" | "W332" | "W333" | "W334" | "M250" | "M251" | "E400" | "E401" | "E402" | "E403" | "W350" | "W351" | "W352" | "W353" | "M270" | "M271" | "E420" | "E421" | "E422" | "E423" | "E424" | "W360" | "W361" | "W362" | "W363" | "W364" | "M180" | "M280" | "M281" | "M282" | "E320" | "E321" | "E322" | "E323" | "E324" | "E325" | "E326" | "E327" | "E328" | "E329" | "E330" | "W310" | "W311" | "W312" | "W313" | "W314" | "M130" | "M131" | "M132" | "M230" | "M231" | "M232" | "M233" | "M234" | "M235" | "M236" | "M237" | "M238" | "E380" | "E381" | "E382" | "E383" | "W340" | "W341" | "W342" | "W343" | "M260" | "I100" | "I101" | "I102" | "I103" | "I104" | "I105" | "I200" | "I201" | "I202" | "I203" | "I204" | "I206" | "I207" | "R100" | "R101" | "R200" | "R201" | "R202" | "R203" | "R204" | "R205" | "R206" | "R207" | "S100" | "S200" | "S101" | "S102" | "S103" | "S104" | "S201" | "S202" | "S203" | "S204" | "S205"yesStable code to branch on; E-codes are errors, W-codes are warnings.
warnings[].severity"error" | "warning"yesErrors stop rendering; warnings never do.
warnings[].messagestringyesWhat is wrong, in one sentence.
warnings[].lineintegeryes1-based line in the submitted source. minimum 1.
warnings[].columnintegeryes1-based column in that line. minimum 1.
warnings[].lengthintegeryesNumber of characters the problem covers. minimum 1.
warnings[].hintstring | nullyesA concrete suggestion for fixing it, or null.
warnings[].fixobjectnoThe one certain fix, to apply as it is. Present only when exactly one fix is certain.
warnings[].fix.labelstringyesWhat the fix does, in a few words, for a button.
warnings[].fix.editsFixEdit[]yesThe edits, all against the source the diagnostic was found in.
secretsobjectyes
secrets.countintegeryes
secrets.kindsstring[]yes

Diagnostic

A located, actionable problem found in diagram source.

FieldTypeRequiredDescription
code"E100" | "E101" | "E110" | "E111" | "E120" | "E121" | "E123" | "E124" | "E125" | "E130" | "E131" | "E132" | "E133" | "E134" | "E135" | "E136" | "E137" | "E138" | "E139" | "E140" | "W200" | "W201" | "W202" | "W203" | "W204" | "W205" | "W206" | "W207" | "W208" | "W209" | "W500" | "W600" | "W601" | "W700" | "W701" | "W702" | "W703" | "W704" | "W705" | "W706" | "W707" | "W708" | "W709" | "W710" | "M100" | "M101" | "M102" | "M103" | "M104" | "M110" | "M200" | "M201" | "M202" | "M203" | "M204" | "M205" | "M206" | "M207" | "M208" | "M209" | "M210" | "M211" | "M212" | "M213" | "M214" | "M215" | "M216" | "M217" | "M218" | "E300" | "E301" | "E302" | "E303" | "E304" | "W300" | "W301" | "W302" | "W303" | "M120" | "M220" | "M221" | "M222" | "E340" | "E341" | "E342" | "E343" | "E344" | "E345" | "W320" | "W321" | "W322" | "W323" | "M240" | "M241" | "M242" | "E360" | "E361" | "E362" | "E363" | "E364" | "E365" | "E366" | "E367" | "W330" | "W331" | "W332" | "W333" | "W334" | "M250" | "M251" | "E400" | "E401" | "E402" | "E403" | "W350" | "W351" | "W352" | "W353" | "M270" | "M271" | "E420" | "E421" | "E422" | "E423" | "E424" | "W360" | "W361" | "W362" | "W363" | "W364" | "M180" | "M280" | "M281" | "M282" | "E320" | "E321" | "E322" | "E323" | "E324" | "E325" | "E326" | "E327" | "E328" | "E329" | "E330" | "W310" | "W311" | "W312" | "W313" | "W314" | "M130" | "M131" | "M132" | "M230" | "M231" | "M232" | "M233" | "M234" | "M235" | "M236" | "M237" | "M238" | "E380" | "E381" | "E382" | "E383" | "W340" | "W341" | "W342" | "W343" | "M260" | "I100" | "I101" | "I102" | "I103" | "I104" | "I105" | "I200" | "I201" | "I202" | "I203" | "I204" | "I206" | "I207" | "R100" | "R101" | "R200" | "R201" | "R202" | "R203" | "R204" | "R205" | "R206" | "R207" | "S100" | "S200" | "S101" | "S102" | "S103" | "S104" | "S201" | "S202" | "S203" | "S204" | "S205"yesStable code to branch on; E-codes are errors, W-codes are warnings.
severity"error" | "warning"yesErrors stop rendering; warnings never do.
messagestringyesWhat is wrong, in one sentence.
lineintegeryes1-based line in the submitted source. minimum 1.
columnintegeryes1-based column in that line. minimum 1.
lengthintegeryesNumber of characters the problem covers. minimum 1.
hintstring | nullyesA concrete suggestion for fixing it, or null.
fixobjectnoThe one certain fix, to apply as it is. Present only when exactly one fix is certain.
fix.labelstringyesWhat the fix does, in a few words, for a button.
fix.editsFixEdit[]yesThe edits, all against the source the diagnostic was found in.
fix.edits[].lineintegeryes1-based line the edit starts on. minimum 1.
fix.edits[].columnintegeryes1-based column it starts at. minimum 1.
fix.edits[].lengthintegeryesCharacters to replace from there, a line break counting one. minimum 0.
fix.edits[].textstringyesWhat replaces them; empty deletes.

FixEdit

Replace length characters from line:column with text.

FieldTypeRequiredDescription
lineintegeryes1-based line the edit starts on. minimum 1.
columnintegeryes1-based column it starts at. minimum 1.
lengthintegeryesCharacters to replace from there, a line break counting one. minimum 0.
textstringyesWhat replaces them; empty deletes.

AgentEditBoardTabBody

FieldTypeRequiredDescription
revisionstringnoA revision of the tab to change instead of main; baseVersion is then the revision's. at least 12 characters; at most 12 characters; pattern ^[0-9A-Za-z]+$.
baseVersionintegeryes
operationsobject[]no
operations[].op"rename" | "set" | "add_node" | "remove" | "add_edge" | "remove_edge" | "move" | "replace_text"yes
operations[].targetstringnoId, label, table.column, or "header". at most 2000 characters.
operations[].tostringnorename: the new name. Edges: the end. at most 2000 characters.
operations[].fromstringnoEdges: the start. at most 2000 characters.
operations[].optionstringnoat most 40 characters; pattern ^[a-z][A-Za-z0-9_-]*$.
operations[].valuestring | nullnoset: null removes the option. at most 2000 characters.
operations[].idstringnoat most 2000 characters.
operations[].labelstringnoadd_edge on sankey: the amount. at most 2000 characters.
operations[].typestringnoadd_node: node type, or statement word (c4 person, tree dir). at most 2000 characters.
operations[].optionsobjectno
operations[].statementstringnoadd_node: the whole line, for a kind with no plain node statement. at most 2000 characters.
operations[].intostring | nullnoA block; null is the top level. at most 2000 characters.
operations[].afterstringnoat most 2000 characters.
operations[].arrow"<-->" | "-->" | "<->" | "..>" | "->" | "--"no
operations[].findstringnoat most 2000 characters.
operations[].replacestringnoat most 2000 characters.
operations[].allbooleanno
sourcestringnoDiagram source; the first line is the header, such as flow "Title" (draw_diagram lists every kind). at least 1 character; at most 120000 characters.

AgentImportToBoardResult

FieldTypeRequiredDescription
changedbooleanyesFalse when the write changed nothing; nothing was stored.
versionintegeryesThe tab's version now: the baseVersion of the next edit.
tabanyyes
tab.idstringyesat least 12 characters; at most 12 characters; pattern ^[0-9A-Za-z]+$.
tab.namestringyes
tab.kindstringyes
tab.positionnumberyes
tab.versionintegeryesSend it as baseVersion with the next edit, and as sinceVersion to learn what changed after it.
tab.updatedAtintegeryes
tab.updatedBystringyes
resultsobject[]yes
results[].opstringyes
results[].appliedbooleanyes
results[].linesinteger[]yes
results[].messagestringyes
results[].hintstring | nullyes
changesobject[]yes
changes[].changestringyes
changes[].subjectstringyes
changes[].namestringyes
changes[].lineinteger | nullyes
changes[].detailstringyes
warningsDiagnostic[]yes
warnings[].code"E100" | "E101" | "E110" | "E111" | "E120" | "E121" | "E123" | "E124" | "E125" | "E130" | "E131" | "E132" | "E133" | "E134" | "E135" | "E136" | "E137" | "E138" | "E139" | "E140" | "W200" | "W201" | "W202" | "W203" | "W204" | "W205" | "W206" | "W207" | "W208" | "W209" | "W500" | "W600" | "W601" | "W700" | "W701" | "W702" | "W703" | "W704" | "W705" | "W706" | "W707" | "W708" | "W709" | "W710" | "M100" | "M101" | "M102" | "M103" | "M104" | "M110" | "M200" | "M201" | "M202" | "M203" | "M204" | "M205" | "M206" | "M207" | "M208" | "M209" | "M210" | "M211" | "M212" | "M213" | "M214" | "M215" | "M216" | "M217" | "M218" | "E300" | "E301" | "E302" | "E303" | "E304" | "W300" | "W301" | "W302" | "W303" | "M120" | "M220" | "M221" | "M222" | "E340" | "E341" | "E342" | "E343" | "E344" | "E345" | "W320" | "W321" | "W322" | "W323" | "M240" | "M241" | "M242" | "E360" | "E361" | "E362" | "E363" | "E364" | "E365" | "E366" | "E367" | "W330" | "W331" | "W332" | "W333" | "W334" | "M250" | "M251" | "E400" | "E401" | "E402" | "E403" | "W350" | "W351" | "W352" | "W353" | "M270" | "M271" | "E420" | "E421" | "E422" | "E423" | "E424" | "W360" | "W361" | "W362" | "W363" | "W364" | "M180" | "M280" | "M281" | "M282" | "E320" | "E321" | "E322" | "E323" | "E324" | "E325" | "E326" | "E327" | "E328" | "E329" | "E330" | "W310" | "W311" | "W312" | "W313" | "W314" | "M130" | "M131" | "M132" | "M230" | "M231" | "M232" | "M233" | "M234" | "M235" | "M236" | "M237" | "M238" | "E380" | "E381" | "E382" | "E383" | "W340" | "W341" | "W342" | "W343" | "M260" | "I100" | "I101" | "I102" | "I103" | "I104" | "I105" | "I200" | "I201" | "I202" | "I203" | "I204" | "I206" | "I207" | "R100" | "R101" | "R200" | "R201" | "R202" | "R203" | "R204" | "R205" | "R206" | "R207" | "S100" | "S200" | "S101" | "S102" | "S103" | "S104" | "S201" | "S202" | "S203" | "S204" | "S205"yesStable code to branch on; E-codes are errors, W-codes are warnings.
warnings[].severity"error" | "warning"yesErrors stop rendering; warnings never do.
warnings[].messagestringyesWhat is wrong, in one sentence.
warnings[].lineintegeryes1-based line in the submitted source. minimum 1.
warnings[].columnintegeryes1-based column in that line. minimum 1.
warnings[].lengthintegeryesNumber of characters the problem covers. minimum 1.
warnings[].hintstring | nullyesA concrete suggestion for fixing it, or null.
warnings[].fixobjectnoThe one certain fix, to apply as it is. Present only when exactly one fix is certain.
warnings[].fix.labelstringyesWhat the fix does, in a few words, for a button.
warnings[].fix.editsFixEdit[]yesThe edits, all against the source the diagnostic was found in.
secretsobjectyes
secrets.countintegeryes
secrets.kindsstring[]yes
diagnosticsobject[]yesWhat the reader or converter left out or could not read, each with a hint.
diagnostics[].codestringyes
diagnostics[].messagestringyes
diagnostics[].hintstring | nullno

AgentImportToBoardBody

FieldTypeRequiredDescription
namestringnoat least 1 character; at most 60 characters.
afterstring | nullnoat least 12 characters; at most 12 characters; pattern ^[0-9A-Za-z]+$.
fromobject | object | object | object | object | object | object | objectyesThe file, picture or text is read in memory; only the diagram made from it is kept, in the new tab.

AgentSaveBoardTabResult

FieldTypeRequiredDescription
diagramobjectyes
diagram.idstringyes
diagram.namestring | nullyes
diagram.versionintegeryes
status"saved" | "held" | "unchanged"yes
approvalobject | nullyes
approval.codestringyes
approval.messagestringyes
tabAgentBoardTabyes
tab.idstringyesat least 12 characters; at most 12 characters; pattern ^[0-9A-Za-z]+$.
tab.namestringyes
tab.kindstringyes
tab.positionnumberyes
tab.versionintegeryesSend it as baseVersion with the next edit, and as sinceVersion to learn what changed after it.
tab.updatedAtintegeryes
tab.updatedBystringyes

AgentSaveBoardTabBody

FieldTypeRequiredDescription
to"new" | "linked"yesnew: a new library diagram. linked: a new version of the library diagram the tab is linked to.
namestringnoat least 1 character; at most 200 characters.
folderstring | nullnoFolder names from the outermost in, joined with a slash, such as "Payments/Checkout", with no slash at either end. Folder names may use letters A to Z, numbers, spaces, - and _. No space at either end of a name and never two together. Up to 5 levels and 40 characters a name. at most 204 characters; pattern ^[A-Za-z0-9_-]+(?: [A-Za-z0-9_-]+)*(?:/[A-Za-z0-9_-]+(?: [A-Za-z0-9_-]+)*){0,4}$.
libraryVersionintegernoFor linked: the library diagram's version the tab last saw. Left out, the tab's own link. minimum 0.

AgentAddBoardTabBody

FieldTypeRequiredDescription
namestringyesat least 1 character; at most 60 characters.
kindstringnoWith no source: start an empty diagram of this kind, such as sequence. Left out, an empty flow. pattern ^[a-z][a-z0-9]{0,23}$.
sourcestringnoDiagram source; the first line is the header, such as flow "Title" (draw_diagram lists every kind). at least 1 character; at most 120000 characters.
afterstring | nullnoPut it after this tab; null for first, left out for last. at least 12 characters; at most 12 characters; pattern ^[0-9A-Za-z]+$.

AgentBoardRevisionList

FieldTypeRequiredDescription
mainVersionintegeryes
protectedbooleanyesTrue when a merge into main needs the approval of a person who manages the board.
revisionsBoardRevision[]yes
revisions[].idstringyesat least 12 characters; at most 12 characters; pattern ^[0-9A-Za-z]+$.
revisions[].tabstringyes
revisions[].namestringyes
revisions[].authorRevisionPersonyes
revisions[].author.kind"person" | "agent" | "key"yes
revisions[].author.labelstringyes
revisions[].authorIdstring | nullyes
revisions[].visibility"private" | "board" | "people"yesprivate: the author only; board: everyone the board is open to; people: the author and the people named.
revisions[].peoplestring[]yesThe account ids it is shared with by name.
revisions[].status"open" | "pending" | "merged" | "discarded"yesopen, pending (a merge waits for approval), merged, or discarded.
revisions[].baseVersionintegeryesThe main version it forked from, or was last updated from.
revisions[].versionintegeryes
revisions[].behindintegeryesMain versions made since baseVersion.
revisions[].createdAtintegeryes
revisions[].updatedAtintegeryes
revisions[].updatedByRevisionPersonyes
revisions[].updatedBy.kind"person" | "agent" | "key"yes
revisions[].updatedBy.labelstringyes
revisions[].readablebooleanyesFalse for a private revision shown by its name only, to the people who manage the board.
revisions[].minebooleanyes
revisions[].requestobject | nullyes
revisions[].request.byRevisionPersonyes
revisions[].request.atintegeryes
revisions[].request.notestring | nullyes
revisions[].reviewobject | nullyes
revisions[].review.byRevisionPersonyes
revisions[].review.atintegeryes
revisions[].review.commentstring | nullyes
revisions[].mergedVersioninteger | nullyes
revisions[].mergedByanyyes
revisions[].mergedBy.kind"person" | "agent" | "key"yes
revisions[].mergedBy.labelstringyes
revisions[].closedAtinteger | nullyes
hiddenintegeryesOpen revisions the caller may not see.
limitintegeryesOpen revisions a tab may have.
revisionsAgentBoardRevision[]no
revisions[].idstringyesat least 12 characters; at most 12 characters; pattern ^[0-9A-Za-z]+$.
revisions[].tabstringyes
revisions[].namestringyes
revisions[].authorRevisionPersonyes
revisions[].author.kind"person" | "agent" | "key"yes
revisions[].author.labelstringyes
revisions[].visibility"private" | "board" | "people"yesprivate: the author only; board: everyone the board is open to; people: the author and the people named.
revisions[].status"open" | "pending" | "merged" | "discarded"yesopen, pending (a merge waits for approval), merged, or discarded.
revisions[].baseVersionintegeryesThe main version it forked from, or was last updated from.
revisions[].versionintegeryes
revisions[].behindintegeryesMain versions made since baseVersion.
revisions[].createdAtintegeryes
revisions[].updatedAtintegeryes
revisions[].updatedByRevisionPersonyes
revisions[].updatedBy.kind"person" | "agent" | "key"yes
revisions[].updatedBy.labelstringyes
revisions[].readablebooleanyesFalse for a private revision shown by its name only, to the people who manage the board.
revisions[].minebooleanyes
revisions[].requestobject | nullyes
revisions[].request.byRevisionPersonyes
revisions[].request.atintegeryes
revisions[].request.notestring | nullyes
revisions[].reviewobject | nullyes
revisions[].review.byRevisionPersonyes
revisions[].review.atintegeryes
revisions[].review.commentstring | nullyes
revisions[].mergedVersioninteger | nullyes
revisions[].mergedByanyyes
revisions[].mergedBy.kind"person" | "agent" | "key"yes
revisions[].mergedBy.labelstringyes
revisions[].closedAtinteger | nullyes
revisions[].sharedintegeryesPeople it is shared with by name.

AgentBoardRevision

FieldTypeRequiredDescription
idstringyesat least 12 characters; at most 12 characters; pattern ^[0-9A-Za-z]+$.
tabstringyes
namestringyes
authorRevisionPersonyes
author.kind"person" | "agent" | "key"yes
author.labelstringyes
visibility"private" | "board" | "people"yesprivate: the author only; board: everyone the board is open to; people: the author and the people named.
status"open" | "pending" | "merged" | "discarded"yesopen, pending (a merge waits for approval), merged, or discarded.
baseVersionintegeryesThe main version it forked from, or was last updated from.
versionintegeryes
behindintegeryesMain versions made since baseVersion.
createdAtintegeryes
updatedAtintegeryes
updatedByRevisionPersonyes
updatedBy.kind"person" | "agent" | "key"yes
updatedBy.labelstringyes
readablebooleanyesFalse for a private revision shown by its name only, to the people who manage the board.
minebooleanyes
requestobject | nullyes
request.byRevisionPersonyes
request.by.kind"person" | "agent" | "key"yes
request.by.labelstringyes
request.atintegeryes
request.notestring | nullyes
reviewobject | nullyes
review.byRevisionPersonyes
review.by.kind"person" | "agent" | "key"yes
review.by.labelstringyes
review.atintegeryes
review.commentstring | nullyes
mergedVersioninteger | nullyes
mergedByanyyes
mergedBy.kind"person" | "agent" | "key"yes
mergedBy.labelstringyes
closedAtinteger | nullyes
sharedintegeryesPeople it is shared with by name.

RevisionPerson

FieldTypeRequiredDescription
kind"person" | "agent" | "key"yes
labelstringyes

BoardRevisionList

FieldTypeRequiredDescription
mainVersionintegeryes
protectedbooleanyesTrue when a merge into main needs the approval of a person who manages the board.
revisionsBoardRevision[]yes
revisions[].idstringyesat least 12 characters; at most 12 characters; pattern ^[0-9A-Za-z]+$.
revisions[].tabstringyes
revisions[].namestringyes
revisions[].authorRevisionPersonyes
revisions[].author.kind"person" | "agent" | "key"yes
revisions[].author.labelstringyes
revisions[].authorIdstring | nullyes
revisions[].visibility"private" | "board" | "people"yesprivate: the author only; board: everyone the board is open to; people: the author and the people named.
revisions[].peoplestring[]yesThe account ids it is shared with by name.
revisions[].status"open" | "pending" | "merged" | "discarded"yesopen, pending (a merge waits for approval), merged, or discarded.
revisions[].baseVersionintegeryesThe main version it forked from, or was last updated from.
revisions[].versionintegeryes
revisions[].behindintegeryesMain versions made since baseVersion.
revisions[].createdAtintegeryes
revisions[].updatedAtintegeryes
revisions[].updatedByRevisionPersonyes
revisions[].updatedBy.kind"person" | "agent" | "key"yes
revisions[].updatedBy.labelstringyes
revisions[].readablebooleanyesFalse for a private revision shown by its name only, to the people who manage the board.
revisions[].minebooleanyes
revisions[].requestobject | nullyes
revisions[].request.byRevisionPersonyes
revisions[].request.atintegeryes
revisions[].request.notestring | nullyes
revisions[].reviewobject | nullyes
revisions[].review.byRevisionPersonyes
revisions[].review.atintegeryes
revisions[].review.commentstring | nullyes
revisions[].mergedVersioninteger | nullyes
revisions[].mergedByanyyes
revisions[].mergedBy.kind"person" | "agent" | "key"yes
revisions[].mergedBy.labelstringyes
revisions[].closedAtinteger | nullyes
hiddenintegeryesOpen revisions the caller may not see.
limitintegeryesOpen revisions a tab may have.

BoardRevision

FieldTypeRequiredDescription
idstringyesat least 12 characters; at most 12 characters; pattern ^[0-9A-Za-z]+$.
tabstringyes
namestringyes
authorRevisionPersonyes
author.kind"person" | "agent" | "key"yes
author.labelstringyes
authorIdstring | nullyes
visibility"private" | "board" | "people"yesprivate: the author only; board: everyone the board is open to; people: the author and the people named.
peoplestring[]yesThe account ids it is shared with by name.
status"open" | "pending" | "merged" | "discarded"yesopen, pending (a merge waits for approval), merged, or discarded.
baseVersionintegeryesThe main version it forked from, or was last updated from.
versionintegeryes
behindintegeryesMain versions made since baseVersion.
createdAtintegeryes
updatedAtintegeryes
updatedByRevisionPersonyes
updatedBy.kind"person" | "agent" | "key"yes
updatedBy.labelstringyes
readablebooleanyesFalse for a private revision shown by its name only, to the people who manage the board.
minebooleanyes
requestobject | nullyes
request.byRevisionPersonyes
request.by.kind"person" | "agent" | "key"yes
request.by.labelstringyes
request.atintegeryes
request.notestring | nullyes
reviewobject | nullyes
review.byRevisionPersonyes
review.by.kind"person" | "agent" | "key"yes
review.by.labelstringyes
review.atintegeryes
review.commentstring | nullyes
mergedVersioninteger | nullyes
mergedByanyyes
mergedBy.kind"person" | "agent" | "key"yes
mergedBy.labelstringyes
closedAtinteger | nullyes

AgentBoardRevisionCreated

FieldTypeRequiredDescription
revisionAgentBoardRevisionyes
revision.idstringyesat least 12 characters; at most 12 characters; pattern ^[0-9A-Za-z]+$.
revision.tabstringyes
revision.namestringyes
revision.authorRevisionPersonyes
revision.author.kind"person" | "agent" | "key"yes
revision.author.labelstringyes
revision.visibility"private" | "board" | "people"yesprivate: the author only; board: everyone the board is open to; people: the author and the people named.
revision.status"open" | "pending" | "merged" | "discarded"yesopen, pending (a merge waits for approval), merged, or discarded.
revision.baseVersionintegeryesThe main version it forked from, or was last updated from.
revision.versionintegeryes
revision.behindintegeryesMain versions made since baseVersion.
revision.createdAtintegeryes
revision.updatedAtintegeryes
revision.updatedByRevisionPersonyes
revision.updatedBy.kind"person" | "agent" | "key"yes
revision.updatedBy.labelstringyes
revision.readablebooleanyesFalse for a private revision shown by its name only, to the people who manage the board.
revision.minebooleanyes
revision.requestobject | nullyes
revision.request.byRevisionPersonyes
revision.request.atintegeryes
revision.request.notestring | nullyes
revision.reviewobject | nullyes
revision.review.byRevisionPersonyes
revision.review.atintegeryes
revision.review.commentstring | nullyes
revision.mergedVersioninteger | nullyes
revision.mergedByanyyes
revision.mergedBy.kind"person" | "agent" | "key"yes
revision.mergedBy.labelstringyes
revision.closedAtinteger | nullyes
revision.sharedintegeryesPeople it is shared with by name.
sourcestringyes
viewUrlstringyesThe board open on this tab with the revision chosen, for the person who connected the agent to watch it live.

AgentCreateBoardRevisionBody

FieldTypeRequiredDescription
namestringnoDefaults to "'s proposal". at least 1 character; at most 60 characters.
fromVersionintegerno
share"private" | "board"nodefault "private".

AgentBoardRevisionCompare

FieldTypeRequiredDescription
mainVersionintegeryes
versionintegeryes
behindintegeryes
samebooleanyes
countsobjectyes
counts.addedintegeryes
counts.removedintegeryes
counts.renamedintegeryes
counts.movedintegeryes
counts.changedintegeryes
changesobject[]yes
changes[].changestringyes
changes[].subjectstringyes
changes[].namestringyes
changes[].lineinteger | nullyes
changes[].detailstringyes
truncatedbooleanyes
summarystringyes
conflictsBoardMergeConflict[]yes
conflicts[].keystringyesThe statement: its id, its label in quotes, or an edge by its ends. A resolution names it.
conflicts[].subjectstringyes
conflicts[].basestring | nullyes
conflicts[].mainstring | nullyes
conflicts[].revisionstring | nullyes
mergeablebooleanyes
revisionanyyes
revision.idstringyesat least 12 characters; at most 12 characters; pattern ^[0-9A-Za-z]+$.
revision.tabstringyes
revision.namestringyes
revision.authorRevisionPersonyes
revision.author.kind"person" | "agent" | "key"yes
revision.author.labelstringyes
revision.visibility"private" | "board" | "people"yesprivate: the author only; board: everyone the board is open to; people: the author and the people named.
revision.status"open" | "pending" | "merged" | "discarded"yesopen, pending (a merge waits for approval), merged, or discarded.
revision.baseVersionintegeryesThe main version it forked from, or was last updated from.
revision.versionintegeryes
revision.behindintegeryesMain versions made since baseVersion.
revision.createdAtintegeryes
revision.updatedAtintegeryes
revision.updatedByRevisionPersonyes
revision.updatedBy.kind"person" | "agent" | "key"yes
revision.updatedBy.labelstringyes
revision.readablebooleanyesFalse for a private revision shown by its name only, to the people who manage the board.
revision.minebooleanyes
revision.requestobject | nullyes
revision.request.byRevisionPersonyes
revision.request.atintegeryes
revision.request.notestring | nullyes
revision.reviewobject | nullyes
revision.review.byRevisionPersonyes
revision.review.atintegeryes
revision.review.commentstring | nullyes
revision.mergedVersioninteger | nullyes
revision.mergedByanyyes
revision.mergedBy.kind"person" | "agent" | "key"yes
revision.mergedBy.labelstringyes
revision.closedAtinteger | nullyes
revision.sharedintegeryesPeople it is shared with by name.

BoardMergeConflict

FieldTypeRequiredDescription
keystringyesThe statement: its id, its label in quotes, or an edge by its ends. A resolution names it.
subjectstringyes
basestring | nullyes
mainstring | nullyes
revisionstring | nullyes

AgentBoardMergeRequest

FieldTypeRequiredDescription
revisionanyyes
revision.idstringyesat least 12 characters; at most 12 characters; pattern ^[0-9A-Za-z]+$.
revision.tabstringyes
revision.namestringyes
revision.authorRevisionPersonyes
revision.author.kind"person" | "agent" | "key"yes
revision.author.labelstringyes
revision.visibility"private" | "board" | "people"yesprivate: the author only; board: everyone the board is open to; people: the author and the people named.
revision.status"open" | "pending" | "merged" | "discarded"yesopen, pending (a merge waits for approval), merged, or discarded.
revision.baseVersionintegeryesThe main version it forked from, or was last updated from.
revision.versionintegeryes
revision.behindintegeryesMain versions made since baseVersion.
revision.createdAtintegeryes
revision.updatedAtintegeryes
revision.updatedByRevisionPersonyes
revision.updatedBy.kind"person" | "agent" | "key"yes
revision.updatedBy.labelstringyes
revision.readablebooleanyesFalse for a private revision shown by its name only, to the people who manage the board.
revision.minebooleanyes
revision.requestobject | nullyes
revision.request.byRevisionPersonyes
revision.request.atintegeryes
revision.request.notestring | nullyes
revision.reviewobject | nullyes
revision.review.byRevisionPersonyes
revision.review.atintegeryes
revision.review.commentstring | nullyes
revision.mergedVersioninteger | nullyes
revision.mergedByanyyes
revision.mergedBy.kind"person" | "agent" | "key"yes
revision.mergedBy.labelstringyes
revision.closedAtinteger | nullyes
revision.sharedintegeryesPeople it is shared with by name.
status"pending"yes
mergeablebooleanyes
conflictsBoardMergeConflict[]yes
conflicts[].keystringyesThe statement: its id, its label in quotes, or an edge by its ends. A resolution names it.
conflicts[].subjectstringyes
conflicts[].basestring | nullyes
conflicts[].mainstring | nullyes
conflicts[].revisionstring | nullyes

BoardMergeRequestBody

FieldTypeRequiredDescription
notestringnoat least 1 character; at most 500 characters.

BoardListenTicket

FieldTypeRequiredDescription
streamUrlstringyesThe WebSocket address of the push stream for this board.
ticketstringyesSent as the second WebSocket subprotocol, after protocol. Reads only this connection's thread on this board. Keep it out of logs and files.
protocolstringyesThe first WebSocket subprotocol to ask for; the stream answers with it.
expiresAtintegeryesWhen the ticket ends, in milliseconds since the epoch; the stream closes then.

BoardWaitResult

FieldTypeRequiredDescription
messagesBoardAgentMessage[]yes
messages[].idstringyes
messages[].atintegeryes
messages[].fromstringyes
messages[].textstringyes
messages[].tabstring | nullyes
messages[].tabNamestring | nullyes
messages[].revisionstring | nullyes
messages[].problemsBoardAgentProblem[]yes
messages[].problems[].codestringyespattern ^[A-Z]\d{3,4}$.
messages[].problems[].severity"error" | "warning"yes
messages[].problems[].lineintegeryesminimum 1; maximum 1000000.
messages[].problems[].columnintegeryesminimum 1; maximum 1000000.
messages[].problems[].messagestringyesat least 1 character; at most 500 characters.
messages[].problems[].hintstring | nullyesat least 1 character; at most 500 characters.
listeningtrueyes
listenSecondsLeftinteger | nullyes

BoardMessageSent

FieldTypeRequiredDescription
messageBoardMessageyes
message.idstringyes
message.connectionstringyes
message.ownerstringyes
message.atintegeryes
message.from"person" | "agent"yes
message.labelstringyes
message.textstringyes
message.tabstring | nullyes
message.revisionstring | nullyes
message.problemsBoardAgentProblem[]yes
message.problems[].codestringyespattern ^[A-Z]\d{3,4}$.
message.problems[].severity"error" | "warning"yes
message.problems[].lineintegeryesminimum 1; maximum 1000000.
message.problems[].columnintegeryesminimum 1; maximum 1000000.
message.problems[].messagestringyesat least 1 character; at most 500 characters.
message.problems[].hintstring | nullyesat least 1 character; at most 500 characters.
message.inReplyTostring | nullyes
message.status"sent" | "delivered" | "answered"yessent: kept for the agent; delivered: the agent read it; answered: the agent replied.
message.deliveredAtinteger | nullyes
message.answeredAtinteger | nullyes
message.usageobject | nullnoFor a reply, what the agent reported it cost; null when it reported nothing.
message.usage.inputTokensintegerno
message.usage.outputTokensintegerno
message.usage.cacheReadTokensintegerno
message.usage.cacheWriteTokensintegerno
message.usage.modelstringno
message.usage.costUsdnumberno
secretsobjectyes
secrets.countintegeryes
secrets.kindsstring[]yes

BoardMessage

FieldTypeRequiredDescription
idstringyes
connectionstringyes
ownerstringyes
atintegeryes
from"person" | "agent"yes
labelstringyes
textstringyes
tabstring | nullyes
revisionstring | nullyes
problemsBoardAgentProblem[]yes
problems[].codestringyespattern ^[A-Z]\d{3,4}$.
problems[].severity"error" | "warning"yes
problems[].lineintegeryesminimum 1; maximum 1000000.
problems[].columnintegeryesminimum 1; maximum 1000000.
problems[].messagestringyesat least 1 character; at most 500 characters.
problems[].hintstring | nullyesat least 1 character; at most 500 characters.
inReplyTostring | nullyes
status"sent" | "delivered" | "answered"yessent: kept for the agent; delivered: the agent read it; answered: the agent replied.
deliveredAtinteger | nullyes
answeredAtinteger | nullyes
usageobject | nullnoFor a reply, what the agent reported it cost; null when it reported nothing.
usage.inputTokensintegerno
usage.outputTokensintegerno
usage.cacheReadTokensintegerno
usage.cacheWriteTokensintegerno
usage.modelstringno
usage.costUsdnumberno

BoardReplyBody

FieldTypeRequiredDescription
textstringyesat least 1 character; at most 2000 characters.
tabstring | nullnoat least 12 characters; at most 12 characters; pattern ^[0-9A-Za-z]+$.
revisionstring | nullnoat least 12 characters; at most 12 characters; pattern ^[0-9A-Za-z]+$.
usageBoardMessageUsagenoWhat the reply cost, only when the agent knows: tokens, model and cost. Shown beside the reply. Leave it out rather than guess.
usage.inputTokensintegernoInput tokens the reply took, not counting cache reads. minimum 0; maximum 1000000000.
usage.outputTokensintegernoOutput tokens the reply took. minimum 0; maximum 1000000000.
usage.cacheReadTokensintegernoInput tokens read from a prompt cache. minimum 0; maximum 1000000000.
usage.cacheWriteTokensintegernoInput tokens written to a prompt cache. minimum 0; maximum 1000000000.
usage.modelstringnoThe model's id as the agent names it, such as claude-opus-5-5. at least 1 character; at most 100 characters; pattern ^[A-Za-z0-9][A-Za-z0-9._:/@[\]-]*$.
usage.costUsdnumbernoWhat the reply cost in US dollars, as the agent knows it. Never an estimate of its own. minimum 0; maximum 10000.

BoardMessageUsage

What the reply cost, only when the agent knows: tokens, model and cost. Shown beside the reply. Leave it out rather than guess.

FieldTypeRequiredDescription
inputTokensintegernoInput tokens the reply took, not counting cache reads. minimum 0; maximum 1000000000.
outputTokensintegernoOutput tokens the reply took. minimum 0; maximum 1000000000.
cacheReadTokensintegernoInput tokens read from a prompt cache. minimum 0; maximum 1000000000.
cacheWriteTokensintegernoInput tokens written to a prompt cache. minimum 0; maximum 1000000000.
modelstringnoThe model's id as the agent names it, such as claude-opus-5-5. at least 1 character; at most 100 characters; pattern ^[A-Za-z0-9][A-Za-z0-9._:/@[\]-]*$.
costUsdnumbernoWhat the reply cost in US dollars, as the agent knows it. Never an estimate of its own. minimum 0; maximum 10000.

DrawDiagramResponse

The result of checking, describing, and drawing a diagram in one call.

FieldTypeRequiredDescription
validbooleanyesTrue when the source has no errors. When false, nothing was drawn: fix the errors and call again.
kindstring | nullyesThe diagram kind, or null when the header could not be read.
errorsDiagnostic[]yesEvery error found in one pass, each with line, column, and a hint. Empty when valid.
errors[].code"E100" | "E101" | "E110" | "E111" | "E120" | "E121" | "E123" | "E124" | "E125" | "E130" | "E131" | "E132" | "E133" | "E134" | "E135" | "E136" | "E137" | "E138" | "E139" | "E140" | "W200" | "W201" | "W202" | "W203" | "W204" | "W205" | "W206" | "W207" | "W208" | "W209" | "W500" | "W600" | "W601" | "W700" | "W701" | "W702" | "W703" | "W704" | "W705" | "W706" | "W707" | "W708" | "W709" | "W710" | "M100" | "M101" | "M102" | "M103" | "M104" | "M110" | "M200" | "M201" | "M202" | "M203" | "M204" | "M205" | "M206" | "M207" | "M208" | "M209" | "M210" | "M211" | "M212" | "M213" | "M214" | "M215" | "M216" | "M217" | "M218" | "E300" | "E301" | "E302" | "E303" | "E304" | "W300" | "W301" | "W302" | "W303" | "M120" | "M220" | "M221" | "M222" | "E340" | "E341" | "E342" | "E343" | "E344" | "E345" | "W320" | "W321" | "W322" | "W323" | "M240" | "M241" | "M242" | "E360" | "E361" | "E362" | "E363" | "E364" | "E365" | "E366" | "E367" | "W330" | "W331" | "W332" | "W333" | "W334" | "M250" | "M251" | "E400" | "E401" | "E402" | "E403" | "W350" | "W351" | "W352" | "W353" | "M270" | "M271" | "E420" | "E421" | "E422" | "E423" | "E424" | "W360" | "W361" | "W362" | "W363" | "W364" | "M180" | "M280" | "M281" | "M282" | "E320" | "E321" | "E322" | "E323" | "E324" | "E325" | "E326" | "E327" | "E328" | "E329" | "E330" | "W310" | "W311" | "W312" | "W313" | "W314" | "M130" | "M131" | "M132" | "M230" | "M231" | "M232" | "M233" | "M234" | "M235" | "M236" | "M237" | "M238" | "E380" | "E381" | "E382" | "E383" | "W340" | "W341" | "W342" | "W343" | "M260" | "I100" | "I101" | "I102" | "I103" | "I104" | "I105" | "I200" | "I201" | "I202" | "I203" | "I204" | "I206" | "I207" | "R100" | "R101" | "R200" | "R201" | "R202" | "R203" | "R204" | "R205" | "R206" | "R207" | "S100" | "S200" | "S101" | "S102" | "S103" | "S104" | "S201" | "S202" | "S203" | "S204" | "S205"yesStable code to branch on; E-codes are errors, W-codes are warnings.
errors[].severity"error" | "warning"yesErrors stop rendering; warnings never do.
errors[].messagestringyesWhat is wrong, in one sentence.
errors[].lineintegeryes1-based line in the submitted source. minimum 1.
errors[].columnintegeryes1-based column in that line. minimum 1.
errors[].lengthintegeryesNumber of characters the problem covers. minimum 1.
errors[].hintstring | nullyesA concrete suggestion for fixing it, or null.
errors[].fixobjectnoThe one certain fix, to apply as it is. Present only when exactly one fix is certain.
errors[].fix.labelstringyesWhat the fix does, in a few words, for a button.
errors[].fix.editsFixEdit[]yesThe edits, all against the source the diagnostic was found in.
warningsDiagnostic[]yesQuality warnings for a valid diagram: too dense, too wide, text cut, unconnected nodes, and suggestions for an icon or a group type. Empty when invalid.
warnings[].code"E100" | "E101" | "E110" | "E111" | "E120" | "E121" | "E123" | "E124" | "E125" | "E130" | "E131" | "E132" | "E133" | "E134" | "E135" | "E136" | "E137" | "E138" | "E139" | "E140" | "W200" | "W201" | "W202" | "W203" | "W204" | "W205" | "W206" | "W207" | "W208" | "W209" | "W500" | "W600" | "W601" | "W700" | "W701" | "W702" | "W703" | "W704" | "W705" | "W706" | "W707" | "W708" | "W709" | "W710" | "M100" | "M101" | "M102" | "M103" | "M104" | "M110" | "M200" | "M201" | "M202" | "M203" | "M204" | "M205" | "M206" | "M207" | "M208" | "M209" | "M210" | "M211" | "M212" | "M213" | "M214" | "M215" | "M216" | "M217" | "M218" | "E300" | "E301" | "E302" | "E303" | "E304" | "W300" | "W301" | "W302" | "W303" | "M120" | "M220" | "M221" | "M222" | "E340" | "E341" | "E342" | "E343" | "E344" | "E345" | "W320" | "W321" | "W322" | "W323" | "M240" | "M241" | "M242" | "E360" | "E361" | "E362" | "E363" | "E364" | "E365" | "E366" | "E367" | "W330" | "W331" | "W332" | "W333" | "W334" | "M250" | "M251" | "E400" | "E401" | "E402" | "E403" | "W350" | "W351" | "W352" | "W353" | "M270" | "M271" | "E420" | "E421" | "E422" | "E423" | "E424" | "W360" | "W361" | "W362" | "W363" | "W364" | "M180" | "M280" | "M281" | "M282" | "E320" | "E321" | "E322" | "E323" | "E324" | "E325" | "E326" | "E327" | "E328" | "E329" | "E330" | "W310" | "W311" | "W312" | "W313" | "W314" | "M130" | "M131" | "M132" | "M230" | "M231" | "M232" | "M233" | "M234" | "M235" | "M236" | "M237" | "M238" | "E380" | "E381" | "E382" | "E383" | "W340" | "W341" | "W342" | "W343" | "M260" | "I100" | "I101" | "I102" | "I103" | "I104" | "I105" | "I200" | "I201" | "I202" | "I203" | "I204" | "I206" | "I207" | "R100" | "R101" | "R200" | "R201" | "R202" | "R203" | "R204" | "R205" | "R206" | "R207" | "S100" | "S200" | "S101" | "S102" | "S103" | "S104" | "S201" | "S202" | "S203" | "S204" | "S205"yesStable code to branch on; E-codes are errors, W-codes are warnings.
warnings[].severity"error" | "warning"yesErrors stop rendering; warnings never do.
warnings[].messagestringyesWhat is wrong, in one sentence.
warnings[].lineintegeryes1-based line in the submitted source. minimum 1.
warnings[].columnintegeryes1-based column in that line. minimum 1.
warnings[].lengthintegeryesNumber of characters the problem covers. minimum 1.
warnings[].hintstring | nullyesA concrete suggestion for fixing it, or null.
warnings[].fixobjectnoThe one certain fix, to apply as it is. Present only when exactly one fix is certain.
warnings[].fix.labelstringyesWhat the fix does, in a few words, for a button.
warnings[].fix.editsFixEdit[]yesThe edits, all against the source the diagnostic was found in.
summarystring | nullyesOne-line description of the diagram, usable as alt text; null when invalid.
outlinestring[]yesThe diagram as plain text in reading order, to check it says what you meant; empty when invalid.
outlineTruncatedbooleanyesTrue when the summary level cut the outline short. Call again with detail "full" to read all of it.
sizeobject | nullyesNatural size of the laid-out diagram; null when invalid.
size.widthintegeryesWidth in px. minimum 1.
size.heightintegeryesHeight in px. minimum 1.
qualityobjectnoHow clean the picture looks (score, grade, measures) and up to three changes that would help; read it instead of looking. Absent when invalid.
quality.scoreintegeryes0 to 100; 100 is a picture with nothing to fix. The same diagram always gets the same score. minimum 0; maximum 100.
quality.grade"clean" | "fair" | "cluttered"yesclean is 85 or more, fair 60 or more, cluttered below.
quality.measuresobjectyesWhat the score is made from: crossings, lineOverBox, labelOverlaps, smallestTextPx (in an 880px column), aspectRatio, emptySpace (0 to 1), longestLine (px), detour (1 is straight), the counts of boxes, lines, labels, series, and slices, and any measure the kind adds.
quality.hintsstring[]yesUp to three changes, the one worth most first, each naming the statement or option to edit.
quality.linestringyesThe grade, the score, and the first hint in one line.
noticesNote[]noInformation notes, such as an icon alias drawn as the real icon; absent when there is none.
notices[].codestringyesA stable code, such as I122 for an icon alias.
notices[].severity"info"yesA note never stops a drawing and is not a warning.
notices[].messagestringyes
notices[].lineintegeryesminimum 1.
notices[].columnintegeryesminimum 1.
notices[].lengthintegeryesminimum 1.
notices[].hintstring | nullyesThe text to write instead.
rendersobject[]yesOne picture per requested color scheme, light first; empty when invalid, when svg is never, and when every picture was left out (see picturesOmitted).
renders[].scheme"light" | "dark"yesThe color scheme this picture is drawn in.
renders[].svgstringyesSelf-contained SVG markup with an accessible title and description.
renders[].sizeSizeyesNatural size of a rendered diagram in px.
renders[].size.widthintegeryesWidth in px. minimum 1.
renders[].size.heightintegeryesHeight in px. minimum 1.
picturesOmittedobjectnoPresent only when pictures were left out because the answer would have been too big for an AI client to read in one piece.
picturesOmitted.schemes("light" | "dark")[]yesThe color schemes whose pictures were left out.
picturesOmitted.charactersintegeryesHow many characters the pictures left out came to.
picturesOmitted.limitintegeryesThe most characters one answer may hold before the pictures are left out.
picturesOmitted.whystringyesWhy they were left out, and what to do.
viewUrlstringnoA link that shows a valid diagram in a browser; give it to the person who wants to look. It holds the drawing itself: the source is in the part after #, never sent to a server, so nothing is saved on Plotwork and it appears in no Diagrams list; anyone with the link can read it. Absent when too long; next says so.
pngUrlstringnoThe viewUrl with &download=png: opening it in a browser saves the diagram as a PNG for Slack, email, or a wiki. The PNG is drawn in the person's browser, not on a server, so it is a link to open, not an image address to embed. Absent when too long.
svgUrlstringnoThe viewUrl with &download=svg: a person opens it to download the SVG. Not a file address for curl; use saveCommand. Absent when too long.
saveCommandstringnoRun in a shell to save the SVG into the repository: the CLI decodes the link locally, fetches nothing, and embeds the source. Set --out to the path; add --scheme dark for dark. Absent when too long.
nextstringyesThe next step in one sentence.

Note

An information note with its place in the source.

FieldTypeRequiredDescription
codestringyesA stable code, such as I122 for an icon alias.
severity"info"yesA note never stops a drawing and is not a warning.
messagestringyes
lineintegeryesminimum 1.
columnintegeryesminimum 1.
lengthintegeryesminimum 1.
hintstring | nullyesThe text to write instead.

Size

Natural size of a rendered diagram in px.

FieldTypeRequiredDescription
widthintegeryesWidth in px. minimum 1.
heightintegeryesHeight in px. minimum 1.

DrawDiagramInput

Diagram source and what to return: the color schemes to draw and how much detail.

FieldTypeRequiredDescription
sourcestringyesDiagram source. The first line is the header: flow "Title", sequence "Title", schema "Title", git "Title", gantt "Title", class "Title", state "Title", timeline "Title", journey "Title", mindmap "Title", treemap "Title", pie "Title", quadrant "Title", layers "Title", c4 "Title", matrix "Title", sankey "Title", xychart "Title", tree "Title", swimlane "Title", requirement "Title", block "Title", packet "Title", kanban "Title", radar "Title", usecase "Title", venn "Title", fishbone "Title", or wardley "Title". at least 1 character; at most 120000 characters.
schemes"light" | "dark" | "both"nolight, dark, or both (the default): the light picture and the dark one a dark page needs. default "both".
theme"plotwork" | "slate" | "ocean" | "forest" | "sunset" | "mono" | "contrast"noColour theme for this drawing, over the header's theme=.
detail"summary" | "full"nosummary (the default), or full: the whole outline, and the source embedded in each SVG. default "summary".
svg"auto" | "always" | "never"noauto (the default): over MCP the SVG text stays out of the answer (picturesOmitted). always returns it. never draws nothing, cheapest. Checks run either way. The HTTP API treats auto as always. default "auto".
embedSourcebooleannoWrite the source into each SVG so read_diagram can give it back. Set it when you save the SVG in a repository or publish it to edit later; anyone with the file or link can then read the source. default false.
settingsobjectnoThe repo's plotwork.config.json, if any. Schema: https://docs.plotwork.dev/schemas/plotwork.config.json (opens in a new tab).

EditDiagramResponse

The edited source, a result for each operation, and the check of the result.

FieldTypeRequiredDescription
sourcestringyesThe edited source. Lines no operation touched are byte for byte as they were, comments included.
changedbooleanyes
resultsobject[]yesOne entry for each operation, in order.
results[].op"rename" | "set" | "add_node" | "remove" | "add_edge" | "remove_edge" | "move" | "replace_text"yes
results[].appliedbooleanyes
results[].linesinteger[]yesLines of the new source this operation wrote, or the lines it removed from.
results[].messagestringyes
results[].hintstring | nullyes
validbooleanyes
kindstring | nullyesA diagram kind: flow, sequence, schema, git, gantt, class, state, timeline, journey, mindmap, treemap, pie, quadrant, layers, c4, matrix, sankey, xychart, tree, swimlane, requirement, block, packet, kanban, radar, usecase, venn, fishbone, or wardley today. Later versions add kinds, so expect others.
errorsDiagnostic[]yes
errors[].code"E100" | "E101" | "E110" | "E111" | "E120" | "E121" | "E123" | "E124" | "E125" | "E130" | "E131" | "E132" | "E133" | "E134" | "E135" | "E136" | "E137" | "E138" | "E139" | "E140" | "W200" | "W201" | "W202" | "W203" | "W204" | "W205" | "W206" | "W207" | "W208" | "W209" | "W500" | "W600" | "W601" | "W700" | "W701" | "W702" | "W703" | "W704" | "W705" | "W706" | "W707" | "W708" | "W709" | "W710" | "M100" | "M101" | "M102" | "M103" | "M104" | "M110" | "M200" | "M201" | "M202" | "M203" | "M204" | "M205" | "M206" | "M207" | "M208" | "M209" | "M210" | "M211" | "M212" | "M213" | "M214" | "M215" | "M216" | "M217" | "M218" | "E300" | "E301" | "E302" | "E303" | "E304" | "W300" | "W301" | "W302" | "W303" | "M120" | "M220" | "M221" | "M222" | "E340" | "E341" | "E342" | "E343" | "E344" | "E345" | "W320" | "W321" | "W322" | "W323" | "M240" | "M241" | "M242" | "E360" | "E361" | "E362" | "E363" | "E364" | "E365" | "E366" | "E367" | "W330" | "W331" | "W332" | "W333" | "W334" | "M250" | "M251" | "E400" | "E401" | "E402" | "E403" | "W350" | "W351" | "W352" | "W353" | "M270" | "M271" | "E420" | "E421" | "E422" | "E423" | "E424" | "W360" | "W361" | "W362" | "W363" | "W364" | "M180" | "M280" | "M281" | "M282" | "E320" | "E321" | "E322" | "E323" | "E324" | "E325" | "E326" | "E327" | "E328" | "E329" | "E330" | "W310" | "W311" | "W312" | "W313" | "W314" | "M130" | "M131" | "M132" | "M230" | "M231" | "M232" | "M233" | "M234" | "M235" | "M236" | "M237" | "M238" | "E380" | "E381" | "E382" | "E383" | "W340" | "W341" | "W342" | "W343" | "M260" | "I100" | "I101" | "I102" | "I103" | "I104" | "I105" | "I200" | "I201" | "I202" | "I203" | "I204" | "I206" | "I207" | "R100" | "R101" | "R200" | "R201" | "R202" | "R203" | "R204" | "R205" | "R206" | "R207" | "S100" | "S200" | "S101" | "S102" | "S103" | "S104" | "S201" | "S202" | "S203" | "S204" | "S205"yesStable code to branch on; E-codes are errors, W-codes are warnings.
errors[].severity"error" | "warning"yesErrors stop rendering; warnings never do.
errors[].messagestringyesWhat is wrong, in one sentence.
errors[].lineintegeryes1-based line in the submitted source. minimum 1.
errors[].columnintegeryes1-based column in that line. minimum 1.
errors[].lengthintegeryesNumber of characters the problem covers. minimum 1.
errors[].hintstring | nullyesA concrete suggestion for fixing it, or null.
errors[].fixobjectnoThe one certain fix, to apply as it is. Present only when exactly one fix is certain.
errors[].fix.labelstringyesWhat the fix does, in a few words, for a button.
errors[].fix.editsFixEdit[]yesThe edits, all against the source the diagnostic was found in.
warningsDiagnostic[]yesQuality warnings; only when the result is drawn.
warnings[].code"E100" | "E101" | "E110" | "E111" | "E120" | "E121" | "E123" | "E124" | "E125" | "E130" | "E131" | "E132" | "E133" | "E134" | "E135" | "E136" | "E137" | "E138" | "E139" | "E140" | "W200" | "W201" | "W202" | "W203" | "W204" | "W205" | "W206" | "W207" | "W208" | "W209" | "W500" | "W600" | "W601" | "W700" | "W701" | "W702" | "W703" | "W704" | "W705" | "W706" | "W707" | "W708" | "W709" | "W710" | "M100" | "M101" | "M102" | "M103" | "M104" | "M110" | "M200" | "M201" | "M202" | "M203" | "M204" | "M205" | "M206" | "M207" | "M208" | "M209" | "M210" | "M211" | "M212" | "M213" | "M214" | "M215" | "M216" | "M217" | "M218" | "E300" | "E301" | "E302" | "E303" | "E304" | "W300" | "W301" | "W302" | "W303" | "M120" | "M220" | "M221" | "M222" | "E340" | "E341" | "E342" | "E343" | "E344" | "E345" | "W320" | "W321" | "W322" | "W323" | "M240" | "M241" | "M242" | "E360" | "E361" | "E362" | "E363" | "E364" | "E365" | "E366" | "E367" | "W330" | "W331" | "W332" | "W333" | "W334" | "M250" | "M251" | "E400" | "E401" | "E402" | "E403" | "W350" | "W351" | "W352" | "W353" | "M270" | "M271" | "E420" | "E421" | "E422" | "E423" | "E424" | "W360" | "W361" | "W362" | "W363" | "W364" | "M180" | "M280" | "M281" | "M282" | "E320" | "E321" | "E322" | "E323" | "E324" | "E325" | "E326" | "E327" | "E328" | "E329" | "E330" | "W310" | "W311" | "W312" | "W313" | "W314" | "M130" | "M131" | "M132" | "M230" | "M231" | "M232" | "M233" | "M234" | "M235" | "M236" | "M237" | "M238" | "E380" | "E381" | "E382" | "E383" | "W340" | "W341" | "W342" | "W343" | "M260" | "I100" | "I101" | "I102" | "I103" | "I104" | "I105" | "I200" | "I201" | "I202" | "I203" | "I204" | "I206" | "I207" | "R100" | "R101" | "R200" | "R201" | "R202" | "R203" | "R204" | "R205" | "R206" | "R207" | "S100" | "S200" | "S101" | "S102" | "S103" | "S104" | "S201" | "S202" | "S203" | "S204" | "S205"yesStable code to branch on; E-codes are errors, W-codes are warnings.
warnings[].severity"error" | "warning"yesErrors stop rendering; warnings never do.
warnings[].messagestringyesWhat is wrong, in one sentence.
warnings[].lineintegeryes1-based line in the submitted source. minimum 1.
warnings[].columnintegeryes1-based column in that line. minimum 1.
warnings[].lengthintegeryesNumber of characters the problem covers. minimum 1.
warnings[].hintstring | nullyesA concrete suggestion for fixing it, or null.
warnings[].fixobjectnoThe one certain fix, to apply as it is. Present only when exactly one fix is certain.
warnings[].fix.labelstringyesWhat the fix does, in a few words, for a button.
warnings[].fix.editsFixEdit[]yesThe edits, all against the source the diagnostic was found in.
summarystring | nullyes
outlinestring[]yes
outlineTruncatedbooleanyes
sizeanyyes
size.widthintegeryesWidth in px. minimum 1.
size.heightintegeryesHeight in px. minimum 1.
rendersobject[]yes
renders[].scheme"light" | "dark"yes
renders[].svgstringyes
renders[].sizeSizeyesNatural size of a rendered diagram in px.
renders[].size.widthintegeryesWidth in px. minimum 1.
renders[].size.heightintegeryesHeight in px. minimum 1.
picturesOmittedobjectnoPresent only when pictures were left out because the answer would have been too big for an AI client to read in one piece.
picturesOmitted.schemes("light" | "dark")[]yesThe color schemes whose pictures were left out.
picturesOmitted.charactersintegeryesHow many characters the pictures left out came to.
picturesOmitted.limitintegeryesThe most characters one answer may hold before the pictures are left out.
picturesOmitted.whystringyesWhy they were left out, and what to do.
viewUrlstringnoA link that shows a valid diagram in a browser; give it to the person who wants to look. It holds the drawing itself: the source is in the part after #, never sent to a server, so nothing is saved on Plotwork and it appears in no Diagrams list; anyone with the link can read it. Absent when too long; next says so.
svgUrlstringnoThe viewUrl with &download=svg: a person opens it to download the SVG. Not a file address for curl; use saveCommand. Absent when too long.
saveCommandstringnoRun in a shell to save the SVG into the repository: the CLI decodes the link locally, fetches nothing, and embeds the source. Set --out to the path; add --scheme dark for dark. Absent when too long.
nextstringyes

EditDiagramInput

Diagram source and the edits to make to it.

FieldTypeRequiredDescription
sourcestringyesDiagram source; the first line is the header, such as flow "Title" (draw_diagram lists every kind). at least 1 character; at most 120000 characters.
operationsobject[]yesApplied in order.
operations[].op"rename" | "set" | "add_node" | "remove" | "add_edge" | "remove_edge" | "move" | "replace_text"yes
operations[].targetstringnoId, label, table.column, or "header". at most 2000 characters.
operations[].tostringnorename: the new name. Edges: the end. at most 2000 characters.
operations[].fromstringnoEdges: the start. at most 2000 characters.
operations[].optionstringnoat most 40 characters; pattern ^[a-z][A-Za-z0-9_-]*$.
operations[].valuestring | nullnoset: null removes the option. at most 2000 characters.
operations[].idstringnoat most 2000 characters.
operations[].labelstringnoadd_edge on sankey: the amount. at most 2000 characters.
operations[].typestringnoadd_node: node type, or statement word (c4 person, tree dir). at most 2000 characters.
operations[].optionsobjectno
operations[].statementstringnoadd_node: the whole line, for a kind with no plain node statement. at most 2000 characters.
operations[].intostring | nullnoA block; null is the top level. at most 2000 characters.
operations[].afterstringnoat most 2000 characters.
operations[].arrow"<-->" | "-->" | "<->" | "..>" | "->" | "--"no
operations[].findstringnoat most 2000 characters.
operations[].replacestringnoat most 2000 characters.
operations[].allbooleanno
svg"auto" | "always" | "never"nonever (the default) draws nothing; auto or always draws like draw_diagram. default "never".
schemes"light" | "dark" | "both"nolight, dark, or both (the default): the light picture and the dark one a dark page needs. default "both".
settingsobjectnoThe repo's plotwork.config.json, if any. Schema: https://docs.plotwork.dev/schemas/plotwork.config.json (opens in a new tab).

ConvertMermaidResponse

The result of converting one Mermaid diagram to Plotwork.

FieldTypeRequiredDescription
okbooleanyesTrue when source is valid Plotwork source. False means nothing was converted and source is empty: read diagnostics.
kindstring | nullyesThe Plotwork kind the diagram became, or null when it could not be converted.
mermaidTypestring | nullyesThe Mermaid diagram type read from the first line, such as flowchart or sequenceDiagram; null when none was found.
sourcestringyesThe Plotwork source, or an empty string when nothing could be converted.
diagnosticsDiagnostic[]yesEverything dropped, changed, or wrong, with a hint that says what to do. Codes start with M. Lines and columns point into the Mermaid you sent. M1xx codes are errors that stop the conversion; M2xx codes are warnings and the conversion went on.
diagnostics[].code"E100" | "E101" | "E110" | "E111" | "E120" | "E121" | "E123" | "E124" | "E125" | "E130" | "E131" | "E132" | "E133" | "E134" | "E135" | "E136" | "E137" | "E138" | "E139" | "E140" | "W200" | "W201" | "W202" | "W203" | "W204" | "W205" | "W206" | "W207" | "W208" | "W209" | "W500" | "W600" | "W601" | "W700" | "W701" | "W702" | "W703" | "W704" | "W705" | "W706" | "W707" | "W708" | "W709" | "W710" | "M100" | "M101" | "M102" | "M103" | "M104" | "M110" | "M200" | "M201" | "M202" | "M203" | "M204" | "M205" | "M206" | "M207" | "M208" | "M209" | "M210" | "M211" | "M212" | "M213" | "M214" | "M215" | "M216" | "M217" | "M218" | "E300" | "E301" | "E302" | "E303" | "E304" | "W300" | "W301" | "W302" | "W303" | "M120" | "M220" | "M221" | "M222" | "E340" | "E341" | "E342" | "E343" | "E344" | "E345" | "W320" | "W321" | "W322" | "W323" | "M240" | "M241" | "M242" | "E360" | "E361" | "E362" | "E363" | "E364" | "E365" | "E366" | "E367" | "W330" | "W331" | "W332" | "W333" | "W334" | "M250" | "M251" | "E400" | "E401" | "E402" | "E403" | "W350" | "W351" | "W352" | "W353" | "M270" | "M271" | "E420" | "E421" | "E422" | "E423" | "E424" | "W360" | "W361" | "W362" | "W363" | "W364" | "M180" | "M280" | "M281" | "M282" | "E320" | "E321" | "E322" | "E323" | "E324" | "E325" | "E326" | "E327" | "E328" | "E329" | "E330" | "W310" | "W311" | "W312" | "W313" | "W314" | "M130" | "M131" | "M132" | "M230" | "M231" | "M232" | "M233" | "M234" | "M235" | "M236" | "M237" | "M238" | "E380" | "E381" | "E382" | "E383" | "W340" | "W341" | "W342" | "W343" | "M260" | "I100" | "I101" | "I102" | "I103" | "I104" | "I105" | "I200" | "I201" | "I202" | "I203" | "I204" | "I206" | "I207" | "R100" | "R101" | "R200" | "R201" | "R202" | "R203" | "R204" | "R205" | "R206" | "R207" | "S100" | "S200" | "S101" | "S102" | "S103" | "S104" | "S201" | "S202" | "S203" | "S204" | "S205"yesStable code to branch on; E-codes are errors, W-codes are warnings.
diagnostics[].severity"error" | "warning"yesErrors stop rendering; warnings never do.
diagnostics[].messagestringyesWhat is wrong, in one sentence.
diagnostics[].lineintegeryes1-based line in the submitted source. minimum 1.
diagnostics[].columnintegeryes1-based column in that line. minimum 1.
diagnostics[].lengthintegeryesNumber of characters the problem covers. minimum 1.
diagnostics[].hintstring | nullyesA concrete suggestion for fixing it, or null.
diagnostics[].fixobjectnoThe one certain fix, to apply as it is. Present only when exactly one fix is certain.
diagnostics[].fix.labelstringyesWhat the fix does, in a few words, for a button.
diagnostics[].fix.editsFixEdit[]yesThe edits, all against the source the diagnostic was found in.
statsobjectyes
stats.nodesintegeryesFlow nodes written.
stats.edgesintegeryesFlow edges written.
stats.groupsintegeryesFlow groups written.
stats.actorsintegeryesSequence participants written.
stats.messagesintegeryesSequence messages written.
stats.tablesintegeryesSchema tables written.
stats.columnsintegeryesSchema columns written.
stats.relationsintegeryesSchema relations written.
stats.droppedintegeryesWarnings about constructs that were dropped: styling, links, activations, and so on.
stats.renamedintegeryesIds that were not valid Plotwork ids and were renamed.
validationobject | nullyesThe Plotwork validator run on source; null when nothing was converted.
validation.validbooleanyesTrue when the converted source has no Plotwork errors. It always is when ok is true.
validation.errorsDiagnostic[]yesPlotwork errors in the converted source. Lines and columns point into source, not into the Mermaid.
validation.errors[].code"E100" | "E101" | "E110" | "E111" | "E120" | "E121" | "E123" | "E124" | "E125" | "E130" | "E131" | "E132" | "E133" | "E134" | "E135" | "E136" | "E137" | "E138" | "E139" | "E140" | "W200" | "W201" | "W202" | "W203" | "W204" | "W205" | "W206" | "W207" | "W208" | "W209" | "W500" | "W600" | "W601" | "W700" | "W701" | "W702" | "W703" | "W704" | "W705" | "W706" | "W707" | "W708" | "W709" | "W710" | "M100" | "M101" | "M102" | "M103" | "M104" | "M110" | "M200" | "M201" | "M202" | "M203" | "M204" | "M205" | "M206" | "M207" | "M208" | "M209" | "M210" | "M211" | "M212" | "M213" | "M214" | "M215" | "M216" | "M217" | "M218" | "E300" | "E301" | "E302" | "E303" | "E304" | "W300" | "W301" | "W302" | "W303" | "M120" | "M220" | "M221" | "M222" | "E340" | "E341" | "E342" | "E343" | "E344" | "E345" | "W320" | "W321" | "W322" | "W323" | "M240" | "M241" | "M242" | "E360" | "E361" | "E362" | "E363" | "E364" | "E365" | "E366" | "E367" | "W330" | "W331" | "W332" | "W333" | "W334" | "M250" | "M251" | "E400" | "E401" | "E402" | "E403" | "W350" | "W351" | "W352" | "W353" | "M270" | "M271" | "E420" | "E421" | "E422" | "E423" | "E424" | "W360" | "W361" | "W362" | "W363" | "W364" | "M180" | "M280" | "M281" | "M282" | "E320" | "E321" | "E322" | "E323" | "E324" | "E325" | "E326" | "E327" | "E328" | "E329" | "E330" | "W310" | "W311" | "W312" | "W313" | "W314" | "M130" | "M131" | "M132" | "M230" | "M231" | "M232" | "M233" | "M234" | "M235" | "M236" | "M237" | "M238" | "E380" | "E381" | "E382" | "E383" | "W340" | "W341" | "W342" | "W343" | "M260" | "I100" | "I101" | "I102" | "I103" | "I104" | "I105" | "I200" | "I201" | "I202" | "I203" | "I204" | "I206" | "I207" | "R100" | "R101" | "R200" | "R201" | "R202" | "R203" | "R204" | "R205" | "R206" | "R207" | "S100" | "S200" | "S101" | "S102" | "S103" | "S104" | "S201" | "S202" | "S203" | "S204" | "S205"yesStable code to branch on; E-codes are errors, W-codes are warnings.
validation.errors[].severity"error" | "warning"yesErrors stop rendering; warnings never do.
validation.errors[].messagestringyesWhat is wrong, in one sentence.
validation.errors[].lineintegeryes1-based line in the submitted source. minimum 1.
validation.errors[].columnintegeryes1-based column in that line. minimum 1.
validation.errors[].lengthintegeryesNumber of characters the problem covers. minimum 1.
validation.errors[].hintstring | nullyesA concrete suggestion for fixing it, or null.
validation.errors[].fixobjectnoThe one certain fix, to apply as it is. Present only when exactly one fix is certain.
validation.warningsDiagnostic[]yesPlotwork quality warnings, including icon and group-type suggestions with the exact icon= to write. Lines and columns point into source, not into the Mermaid.
validation.warnings[].code"E100" | "E101" | "E110" | "E111" | "E120" | "E121" | "E123" | "E124" | "E125" | "E130" | "E131" | "E132" | "E133" | "E134" | "E135" | "E136" | "E137" | "E138" | "E139" | "E140" | "W200" | "W201" | "W202" | "W203" | "W204" | "W205" | "W206" | "W207" | "W208" | "W209" | "W500" | "W600" | "W601" | "W700" | "W701" | "W702" | "W703" | "W704" | "W705" | "W706" | "W707" | "W708" | "W709" | "W710" | "M100" | "M101" | "M102" | "M103" | "M104" | "M110" | "M200" | "M201" | "M202" | "M203" | "M204" | "M205" | "M206" | "M207" | "M208" | "M209" | "M210" | "M211" | "M212" | "M213" | "M214" | "M215" | "M216" | "M217" | "M218" | "E300" | "E301" | "E302" | "E303" | "E304" | "W300" | "W301" | "W302" | "W303" | "M120" | "M220" | "M221" | "M222" | "E340" | "E341" | "E342" | "E343" | "E344" | "E345" | "W320" | "W321" | "W322" | "W323" | "M240" | "M241" | "M242" | "E360" | "E361" | "E362" | "E363" | "E364" | "E365" | "E366" | "E367" | "W330" | "W331" | "W332" | "W333" | "W334" | "M250" | "M251" | "E400" | "E401" | "E402" | "E403" | "W350" | "W351" | "W352" | "W353" | "M270" | "M271" | "E420" | "E421" | "E422" | "E423" | "E424" | "W360" | "W361" | "W362" | "W363" | "W364" | "M180" | "M280" | "M281" | "M282" | "E320" | "E321" | "E322" | "E323" | "E324" | "E325" | "E326" | "E327" | "E328" | "E329" | "E330" | "W310" | "W311" | "W312" | "W313" | "W314" | "M130" | "M131" | "M132" | "M230" | "M231" | "M232" | "M233" | "M234" | "M235" | "M236" | "M237" | "M238" | "E380" | "E381" | "E382" | "E383" | "W340" | "W341" | "W342" | "W343" | "M260" | "I100" | "I101" | "I102" | "I103" | "I104" | "I105" | "I200" | "I201" | "I202" | "I203" | "I204" | "I206" | "I207" | "R100" | "R101" | "R200" | "R201" | "R202" | "R203" | "R204" | "R205" | "R206" | "R207" | "S100" | "S200" | "S101" | "S102" | "S103" | "S104" | "S201" | "S202" | "S203" | "S204" | "S205"yesStable code to branch on; E-codes are errors, W-codes are warnings.
validation.warnings[].severity"error" | "warning"yesErrors stop rendering; warnings never do.
validation.warnings[].messagestringyesWhat is wrong, in one sentence.
validation.warnings[].lineintegeryes1-based line in the submitted source. minimum 1.
validation.warnings[].columnintegeryes1-based column in that line. minimum 1.
validation.warnings[].lengthintegeryesNumber of characters the problem covers. minimum 1.
validation.warnings[].hintstring | nullyesA concrete suggestion for fixing it, or null.
validation.warnings[].fixobjectnoThe one certain fix, to apply as it is. Present only when exactly one fix is certain.
validation.summarystring | nullyesOne-line description of the converted diagram, usable as alt text.
validation.sizeobject | nullyesNatural size of the laid-out diagram.
validation.size.widthintegeryesWidth in px. minimum 1.
validation.size.heightintegeryesHeight in px. minimum 1.
qualityobjectnoHow clean the converted diagram looks and up to three changes that would help (see draw_diagram); absent when it is not valid.
quality.scoreintegeryes0 to 100; 100 is a picture with nothing to fix. The same diagram always gets the same score. minimum 0; maximum 100.
quality.grade"clean" | "fair" | "cluttered"yesclean is 85 or more, fair 60 or more, cluttered below.
quality.measuresobjectyesWhat the score is made from: crossings, lineOverBox, labelOverlaps, smallestTextPx (in an 880px column), aspectRatio, emptySpace (0 to 1), longestLine (px), detour (1 is straight), the counts of boxes, lines, labels, series, and slices, and any measure the kind adds.
quality.hintsstring[]yesUp to three changes, the one worth most first, each naming the statement or option to edit.
quality.linestringyesThe grade, the score, and the first hint in one line.
outlinestring[]yesThe converted diagram as plain text, to check it says what the Mermaid said; empty when nothing was converted.
outlineTruncatedbooleanyesTrue when the summary level cut the outline short. Call again with detail "full" to read all of it.
rendersobject[]yesOne picture per requested color scheme, light first; empty unless render was true and the conversion is valid, when svg is never, and when every picture was left out (see picturesOmitted).
renders[].scheme"light" | "dark"yesThe color scheme this picture is drawn in.
renders[].svgstringyesSelf-contained SVG markup with an accessible title and description.
renders[].sizeSizeyesNatural size of a rendered diagram in px.
renders[].size.widthintegeryesWidth in px. minimum 1.
renders[].size.heightintegeryesHeight in px. minimum 1.
picturesOmittedobjectnoPresent only when pictures were left out because the answer would have been too big for an AI client to read in one piece.
picturesOmitted.schemes("light" | "dark")[]yesThe color schemes whose pictures were left out.
picturesOmitted.charactersintegeryesHow many characters the pictures left out came to.
picturesOmitted.limitintegeryesThe most characters one answer may hold before the pictures are left out.
picturesOmitted.whystringyesWhy they were left out, and what to do.
viewUrlstringnoA link that shows a valid diagram in a browser; give it to the person who wants to look. It holds the drawing itself: the source is in the part after #, never sent to a server, so nothing is saved on Plotwork and it appears in no Diagrams list; anyone with the link can read it. Absent when too long; next says so.
pngUrlstringnoThe viewUrl with &download=png: opening it in a browser saves the diagram as a PNG for Slack, email, or a wiki. The PNG is drawn in the person's browser, not on a server, so it is a link to open, not an image address to embed. Absent when too long.
svgUrlstringnoThe viewUrl with &download=svg: a person opens it to download the SVG. Not a file address for curl; use saveCommand. Absent when too long.
saveCommandstringnoRun in a shell to save the SVG into the repository: the CLI decodes the link locally, fetches nothing, and embeds the source. Set --out to the path; add --scheme dark for dark. Absent when too long.
nextstringyesThe next step in one sentence.

ConvertMermaidInput

Mermaid source and what to return with the converted Plotwork source.

FieldTypeRequiredDescription
sourcestringyesOne Mermaid diagram: a flowchart or graph, sequenceDiagram, erDiagram, gitGraph, gantt, classDiagram, stateDiagram, timeline, journey, mindmap, treemap-beta or treemap, pie, quadrantChart, C4Context or C4Container or C4Component or C4Dynamic or C4Deployment, sankey-beta or sankey, xychart-beta or xychart, treeView-beta or treeView, requirementDiagram, block-beta or block, packet or packet-beta, kanban, radar-beta or radar, usecase-beta or usecase, venn-beta or venn, ishikawa-beta or ishikawa, wardley-beta, architecture-beta, or zenuml. Front matter and %%{init}%% directives are allowed and are dropped. Send the text inside a mermaid fence, without the fence. at least 1 character; at most 120000 characters.
lenientbooleannofalse (the default): a line that cannot be read stops the conversion, so nothing is converted with a line missing. true: such a line is skipped with a warning and the rest is converted. default false.
renderbooleannoAlso draw the converted diagram, in the color schemes schemes names. default false.
schemes"light" | "dark" | "both"nolight, dark, or both (the default): the light picture and the dark one a dark page needs. default "both".
detail"summary" | "full"nosummary (the default), or full: the whole outline, and the source embedded in each SVG. default "summary".
svg"auto" | "always" | "never"noauto (the default): over MCP the SVG text stays out of the answer (picturesOmitted). always returns it. never draws nothing, cheapest. Checks run either way. The HTTP API treats auto as always. default "auto".
embedSourcebooleannoWrite the source into each SVG so read_diagram can give it back. Set it when you save the SVG in a repository or publish it to edit later; anyone with the file or link can then read the source. default false.
settingsobjectnoThe repo's plotwork.config.json, if any. Schema: https://docs.plotwork.dev/schemas/plotwork.config.json (opens in a new tab).

ValidateResponse

Result of checking diagram source.

FieldTypeRequiredDescription
validbooleanyesTrue when there are no errors; warnings do not make a diagram invalid.
kindstring | nullyesThe diagram kind, or null when the header could not be read.
errorsDiagnostic[]yesEvery error found in one pass, so they can be fixed together.
errors[].code"E100" | "E101" | "E110" | "E111" | "E120" | "E121" | "E123" | "E124" | "E125" | "E130" | "E131" | "E132" | "E133" | "E134" | "E135" | "E136" | "E137" | "E138" | "E139" | "E140" | "W200" | "W201" | "W202" | "W203" | "W204" | "W205" | "W206" | "W207" | "W208" | "W209" | "W500" | "W600" | "W601" | "W700" | "W701" | "W702" | "W703" | "W704" | "W705" | "W706" | "W707" | "W708" | "W709" | "W710" | "M100" | "M101" | "M102" | "M103" | "M104" | "M110" | "M200" | "M201" | "M202" | "M203" | "M204" | "M205" | "M206" | "M207" | "M208" | "M209" | "M210" | "M211" | "M212" | "M213" | "M214" | "M215" | "M216" | "M217" | "M218" | "E300" | "E301" | "E302" | "E303" | "E304" | "W300" | "W301" | "W302" | "W303" | "M120" | "M220" | "M221" | "M222" | "E340" | "E341" | "E342" | "E343" | "E344" | "E345" | "W320" | "W321" | "W322" | "W323" | "M240" | "M241" | "M242" | "E360" | "E361" | "E362" | "E363" | "E364" | "E365" | "E366" | "E367" | "W330" | "W331" | "W332" | "W333" | "W334" | "M250" | "M251" | "E400" | "E401" | "E402" | "E403" | "W350" | "W351" | "W352" | "W353" | "M270" | "M271" | "E420" | "E421" | "E422" | "E423" | "E424" | "W360" | "W361" | "W362" | "W363" | "W364" | "M180" | "M280" | "M281" | "M282" | "E320" | "E321" | "E322" | "E323" | "E324" | "E325" | "E326" | "E327" | "E328" | "E329" | "E330" | "W310" | "W311" | "W312" | "W313" | "W314" | "M130" | "M131" | "M132" | "M230" | "M231" | "M232" | "M233" | "M234" | "M235" | "M236" | "M237" | "M238" | "E380" | "E381" | "E382" | "E383" | "W340" | "W341" | "W342" | "W343" | "M260" | "I100" | "I101" | "I102" | "I103" | "I104" | "I105" | "I200" | "I201" | "I202" | "I203" | "I204" | "I206" | "I207" | "R100" | "R101" | "R200" | "R201" | "R202" | "R203" | "R204" | "R205" | "R206" | "R207" | "S100" | "S200" | "S101" | "S102" | "S103" | "S104" | "S201" | "S202" | "S203" | "S204" | "S205"yesStable code to branch on; E-codes are errors, W-codes are warnings.
errors[].severity"error" | "warning"yesErrors stop rendering; warnings never do.
errors[].messagestringyesWhat is wrong, in one sentence.
errors[].lineintegeryes1-based line in the submitted source. minimum 1.
errors[].columnintegeryes1-based column in that line. minimum 1.
errors[].lengthintegeryesNumber of characters the problem covers. minimum 1.
errors[].hintstring | nullyesA concrete suggestion for fixing it, or null.
errors[].fixobjectnoThe one certain fix, to apply as it is. Present only when exactly one fix is certain.
errors[].fix.labelstringyesWhat the fix does, in a few words, for a button.
errors[].fix.editsFixEdit[]yesThe edits, all against the source the diagnostic was found in.
warningsDiagnostic[]yesQuality warnings for a valid diagram, such as too dense or too wide.
warnings[].code"E100" | "E101" | "E110" | "E111" | "E120" | "E121" | "E123" | "E124" | "E125" | "E130" | "E131" | "E132" | "E133" | "E134" | "E135" | "E136" | "E137" | "E138" | "E139" | "E140" | "W200" | "W201" | "W202" | "W203" | "W204" | "W205" | "W206" | "W207" | "W208" | "W209" | "W500" | "W600" | "W601" | "W700" | "W701" | "W702" | "W703" | "W704" | "W705" | "W706" | "W707" | "W708" | "W709" | "W710" | "M100" | "M101" | "M102" | "M103" | "M104" | "M110" | "M200" | "M201" | "M202" | "M203" | "M204" | "M205" | "M206" | "M207" | "M208" | "M209" | "M210" | "M211" | "M212" | "M213" | "M214" | "M215" | "M216" | "M217" | "M218" | "E300" | "E301" | "E302" | "E303" | "E304" | "W300" | "W301" | "W302" | "W303" | "M120" | "M220" | "M221" | "M222" | "E340" | "E341" | "E342" | "E343" | "E344" | "E345" | "W320" | "W321" | "W322" | "W323" | "M240" | "M241" | "M242" | "E360" | "E361" | "E362" | "E363" | "E364" | "E365" | "E366" | "E367" | "W330" | "W331" | "W332" | "W333" | "W334" | "M250" | "M251" | "E400" | "E401" | "E402" | "E403" | "W350" | "W351" | "W352" | "W353" | "M270" | "M271" | "E420" | "E421" | "E422" | "E423" | "E424" | "W360" | "W361" | "W362" | "W363" | "W364" | "M180" | "M280" | "M281" | "M282" | "E320" | "E321" | "E322" | "E323" | "E324" | "E325" | "E326" | "E327" | "E328" | "E329" | "E330" | "W310" | "W311" | "W312" | "W313" | "W314" | "M130" | "M131" | "M132" | "M230" | "M231" | "M232" | "M233" | "M234" | "M235" | "M236" | "M237" | "M238" | "E380" | "E381" | "E382" | "E383" | "W340" | "W341" | "W342" | "W343" | "M260" | "I100" | "I101" | "I102" | "I103" | "I104" | "I105" | "I200" | "I201" | "I202" | "I203" | "I204" | "I206" | "I207" | "R100" | "R101" | "R200" | "R201" | "R202" | "R203" | "R204" | "R205" | "R206" | "R207" | "S100" | "S200" | "S101" | "S102" | "S103" | "S104" | "S201" | "S202" | "S203" | "S204" | "S205"yesStable code to branch on; E-codes are errors, W-codes are warnings.
warnings[].severity"error" | "warning"yesErrors stop rendering; warnings never do.
warnings[].messagestringyesWhat is wrong, in one sentence.
warnings[].lineintegeryes1-based line in the submitted source. minimum 1.
warnings[].columnintegeryes1-based column in that line. minimum 1.
warnings[].lengthintegeryesNumber of characters the problem covers. minimum 1.
warnings[].hintstring | nullyesA concrete suggestion for fixing it, or null.
warnings[].fixobjectnoThe one certain fix, to apply as it is. Present only when exactly one fix is certain.
warnings[].fix.labelstringyesWhat the fix does, in a few words, for a button.
warnings[].fix.editsFixEdit[]yesThe edits, all against the source the diagnostic was found in.
summarystring | nullyesOne-line description of the diagram, or null when invalid.
sizeobject | nullyesNatural rendered size, or null when invalid.
size.widthintegeryesWidth in px. minimum 1.
size.heightintegeryesHeight in px. minimum 1.
qualityobjectnoHow clean the laid-out diagram looks, with up to three changes; absent when invalid.
quality.scoreintegeryes0 to 100; 100 is a picture with nothing to fix. The same diagram always gets the same score. minimum 0; maximum 100.
quality.grade"clean" | "fair" | "cluttered"yesclean is 85 or more, fair 60 or more, cluttered below.
quality.measuresobjectyesWhat the score is made from: crossings, lineOverBox, labelOverlaps, smallestTextPx (in an 880px column), aspectRatio, emptySpace (0 to 1), longestLine (px), detour (1 is straight), the counts of boxes, lines, labels, series, and slices, and any measure the kind adds.
quality.hintsstring[]yesUp to three changes, the one worth most first, each naming the statement or option to edit.
quality.linestringyesThe grade, the score, and the first hint in one line.
noticesNote[]noInformation notes, such as an icon alias resolved to a real icon; absent when there is none.
notices[].codestringyesA stable code, such as I122 for an icon alias.
notices[].severity"info"yesA note never stops a drawing and is not a warning.
notices[].messagestringyes
notices[].lineintegeryesminimum 1.
notices[].columnintegeryesminimum 1.
notices[].lengthintegeryesminimum 1.
notices[].hintstring | nullyesThe text to write instead.

DiagramSourceInput

Request body carrying diagram source.

FieldTypeRequiredDescription
sourcestringyesDiagram source; the first line is the header, such as flow "Title" (draw_diagram lists every kind). at least 1 character; at most 120000 characters.
settingsobjectnoThe repo's plotwork.config.json, if any. Schema: https://docs.plotwork.dev/schemas/plotwork.config.json (opens in a new tab).

RenderResponse

A rendered diagram.

FieldTypeRequiredDescription
svgstringyesSelf-contained SVG markup with an accessible title and description.
scheme"light" | "dark" | "auto"yesThe color scheme used.
sizeSizeyesNatural size of a rendered diagram in px.
size.widthintegeryesWidth in px. minimum 1.
size.heightintegeryesHeight in px. minimum 1.
warningsDiagnostic[]yes
warnings[].code"E100" | "E101" | "E110" | "E111" | "E120" | "E121" | "E123" | "E124" | "E125" | "E130" | "E131" | "E132" | "E133" | "E134" | "E135" | "E136" | "E137" | "E138" | "E139" | "E140" | "W200" | "W201" | "W202" | "W203" | "W204" | "W205" | "W206" | "W207" | "W208" | "W209" | "W500" | "W600" | "W601" | "W700" | "W701" | "W702" | "W703" | "W704" | "W705" | "W706" | "W707" | "W708" | "W709" | "W710" | "M100" | "M101" | "M102" | "M103" | "M104" | "M110" | "M200" | "M201" | "M202" | "M203" | "M204" | "M205" | "M206" | "M207" | "M208" | "M209" | "M210" | "M211" | "M212" | "M213" | "M214" | "M215" | "M216" | "M217" | "M218" | "E300" | "E301" | "E302" | "E303" | "E304" | "W300" | "W301" | "W302" | "W303" | "M120" | "M220" | "M221" | "M222" | "E340" | "E341" | "E342" | "E343" | "E344" | "E345" | "W320" | "W321" | "W322" | "W323" | "M240" | "M241" | "M242" | "E360" | "E361" | "E362" | "E363" | "E364" | "E365" | "E366" | "E367" | "W330" | "W331" | "W332" | "W333" | "W334" | "M250" | "M251" | "E400" | "E401" | "E402" | "E403" | "W350" | "W351" | "W352" | "W353" | "M270" | "M271" | "E420" | "E421" | "E422" | "E423" | "E424" | "W360" | "W361" | "W362" | "W363" | "W364" | "M180" | "M280" | "M281" | "M282" | "E320" | "E321" | "E322" | "E323" | "E324" | "E325" | "E326" | "E327" | "E328" | "E329" | "E330" | "W310" | "W311" | "W312" | "W313" | "W314" | "M130" | "M131" | "M132" | "M230" | "M231" | "M232" | "M233" | "M234" | "M235" | "M236" | "M237" | "M238" | "E380" | "E381" | "E382" | "E383" | "W340" | "W341" | "W342" | "W343" | "M260" | "I100" | "I101" | "I102" | "I103" | "I104" | "I105" | "I200" | "I201" | "I202" | "I203" | "I204" | "I206" | "I207" | "R100" | "R101" | "R200" | "R201" | "R202" | "R203" | "R204" | "R205" | "R206" | "R207" | "S100" | "S200" | "S101" | "S102" | "S103" | "S104" | "S201" | "S202" | "S203" | "S204" | "S205"yesStable code to branch on; E-codes are errors, W-codes are warnings.
warnings[].severity"error" | "warning"yesErrors stop rendering; warnings never do.
warnings[].messagestringyesWhat is wrong, in one sentence.
warnings[].lineintegeryes1-based line in the submitted source. minimum 1.
warnings[].columnintegeryes1-based column in that line. minimum 1.
warnings[].lengthintegeryesNumber of characters the problem covers. minimum 1.
warnings[].hintstring | nullyesA concrete suggestion for fixing it, or null.
warnings[].fixobjectnoThe one certain fix, to apply as it is. Present only when exactly one fix is certain.
warnings[].fix.labelstringyesWhat the fix does, in a few words, for a button.
warnings[].fix.editsFixEdit[]yesThe edits, all against the source the diagnostic was found in.

RenderInput

Diagram source and rendering options.

FieldTypeRequiredDescription
sourcestringyesDiagram source; the first line is the header, such as flow "Title" (draw_diagram lists every kind). at least 1 character; at most 120000 characters.
scheme"light" | "dark" | "auto"noColor scheme to paint with: light, dark, or auto for one picture that follows the reader's light or dark setting. default "light".
theme"plotwork" | "slate" | "ocean" | "forest" | "sunset" | "mono" | "contrast"noColour theme for this drawing, over the header's theme=.
idPrefixstringnoPrefix for element ids; set it when inlining several diagrams into one page. at most 32 characters; pattern ^[A-Za-z][A-Za-z0-9_-]*$.
embedSourcebooleannoWrite the source into the SVG metadata so read_diagram can give it back. Set it true when you save the SVG into a repository; anyone with the file can then read the source. Default false. default false.
settingsobjectnoThe repo's plotwork.config.json, if any. Schema: https://docs.plotwork.dev/schemas/plotwork.config.json (opens in a new tab).

OutlineResponse

A plain-text description of a diagram, usable as alt text.

FieldTypeRequiredDescription
kindstringyesA diagram kind: flow, sequence, schema, git, gantt, class, state, timeline, journey, mindmap, treemap, pie, quadrant, layers, c4, matrix, sankey, xychart, tree, swimlane, requirement, block, packet, kanban, radar, usecase, venn, fishbone, or wardley today. Later versions add kinds, so expect others.
summarystringyesOne-line description.
outlinestring[]yesLines in reading order: participants, steps, tables, and connections.

ReadDiagramResponse

The source of a Plotwork SVG, or why there is none and what to do.

FieldTypeRequiredDescription
status"read" | "no-source" | "damaged" | "not-a-picture" | "refused" | "unreachable"yesread: the source was found. no-source: the picture carries none. damaged: it carries one that cannot be read back. not-a-picture: the text is not an SVG. refused: the link is not one this tool fetches. unreachable: the link could not be fetched.
hasSourcebooleanyesTrue when source is set.
sourcestring | nullyesThe exact source the picture was drawn from, ready to edit and send to draw_diagram; null when there is none.
kindstring | nullyesThe diagram kind of the source, or null.
idstring | nullyesThe id of the stored diagram when the picture was published (data-plotwork-id), or null.
from"text" | "url"yesWhere the picture came from: the text that was sent, or the link that was fetched.
validationobject | nullyesThe check of the source, or null when there is none. It parses the source; draw_diagram also lays it out and returns warnings.
validation.validbooleanyesTrue when the source has no errors.
validation.errorsDiagnostic[]yesEvery error, each with line, column, and a hint; empty when valid.
validation.errors[].code"E100" | "E101" | "E110" | "E111" | "E120" | "E121" | "E123" | "E124" | "E125" | "E130" | "E131" | "E132" | "E133" | "E134" | "E135" | "E136" | "E137" | "E138" | "E139" | "E140" | "W200" | "W201" | "W202" | "W203" | "W204" | "W205" | "W206" | "W207" | "W208" | "W209" | "W500" | "W600" | "W601" | "W700" | "W701" | "W702" | "W703" | "W704" | "W705" | "W706" | "W707" | "W708" | "W709" | "W710" | "M100" | "M101" | "M102" | "M103" | "M104" | "M110" | "M200" | "M201" | "M202" | "M203" | "M204" | "M205" | "M206" | "M207" | "M208" | "M209" | "M210" | "M211" | "M212" | "M213" | "M214" | "M215" | "M216" | "M217" | "M218" | "E300" | "E301" | "E302" | "E303" | "E304" | "W300" | "W301" | "W302" | "W303" | "M120" | "M220" | "M221" | "M222" | "E340" | "E341" | "E342" | "E343" | "E344" | "E345" | "W320" | "W321" | "W322" | "W323" | "M240" | "M241" | "M242" | "E360" | "E361" | "E362" | "E363" | "E364" | "E365" | "E366" | "E367" | "W330" | "W331" | "W332" | "W333" | "W334" | "M250" | "M251" | "E400" | "E401" | "E402" | "E403" | "W350" | "W351" | "W352" | "W353" | "M270" | "M271" | "E420" | "E421" | "E422" | "E423" | "E424" | "W360" | "W361" | "W362" | "W363" | "W364" | "M180" | "M280" | "M281" | "M282" | "E320" | "E321" | "E322" | "E323" | "E324" | "E325" | "E326" | "E327" | "E328" | "E329" | "E330" | "W310" | "W311" | "W312" | "W313" | "W314" | "M130" | "M131" | "M132" | "M230" | "M231" | "M232" | "M233" | "M234" | "M235" | "M236" | "M237" | "M238" | "E380" | "E381" | "E382" | "E383" | "W340" | "W341" | "W342" | "W343" | "M260" | "I100" | "I101" | "I102" | "I103" | "I104" | "I105" | "I200" | "I201" | "I202" | "I203" | "I204" | "I206" | "I207" | "R100" | "R101" | "R200" | "R201" | "R202" | "R203" | "R204" | "R205" | "R206" | "R207" | "S100" | "S200" | "S101" | "S102" | "S103" | "S104" | "S201" | "S202" | "S203" | "S204" | "S205"yesStable code to branch on; E-codes are errors, W-codes are warnings.
validation.errors[].severity"error" | "warning"yesErrors stop rendering; warnings never do.
validation.errors[].messagestringyesWhat is wrong, in one sentence.
validation.errors[].lineintegeryes1-based line in the submitted source. minimum 1.
validation.errors[].columnintegeryes1-based column in that line. minimum 1.
validation.errors[].lengthintegeryesNumber of characters the problem covers. minimum 1.
validation.errors[].hintstring | nullyesA concrete suggestion for fixing it, or null.
validation.errors[].fixobjectnoThe one certain fix, to apply as it is. Present only when exactly one fix is certain.
validation.summarystring | nullyesOne-line description of the diagram, or null when invalid.
pictureobject | nullyesWhat the picture says about itself, or null when the text is not an SVG.
picture.titlestring | nullyesThe diagram title, or null.
picture.summarystring | nullyesThe one-line summary the picture carries, or null.
picture.schemestring | nullyesThe color scheme it was drawn in, or null.
picture.sizeobject | nullyesIts size in px, or null.
picture.size.widthintegeryesWidth in px. minimum 1.
picture.size.heightintegeryesHeight in px. minimum 1.
picture.outlinestring[]yesThe plain-language outline the picture carries, one entry for each line. Empty when the source was read: the source says more.
picture.labelsstring[]yesThe text painted on the picture, each distinct label once, in painted order. Empty when the source was read.
messagestringyesWhat happened, in one sentence.
nextstringyesThe next step in one sentence.

ReadDiagramInput

The text of a Plotwork SVG, or the link of a hosted one.

FieldTypeRequiredDescription
svgstringnoThe text of a Plotwork SVG: the content of an .svg file in the repository. Send this or url, not both. at least 1 character; at most 1000000 characters.
urlstringnoThe link of a hosted Plotwork picture, https://cdn.plotwork.dev/d/ (opens in a new tab)<22 characters>.svg. Only Plotwork's own picture hosts are fetched. Send this or svg, not both. at least 1 character; at most 200 characters.

CompareDiagramsResponse

What changed between two versions of a diagram.

FieldTypeRequiredDescription
samebooleanyes
beforeobjectyes
before.from"source" | "svg" | "url"yes
before.readbooleanyesFalse when no source could be read from it; message says why.
before.kindstring | nullyesA diagram kind: flow, sequence, schema, git, gantt, class, state, timeline, journey, mindmap, treemap, pie, quadrant, layers, c4, matrix, sankey, xychart, tree, swimlane, requirement, block, packet, kanban, radar, usecase, venn, fishbone, or wardley today. Later versions add kinds, so expect others.
before.validbooleanyes
before.messagestring | nullyes
afterobjectyes
after.from"source" | "svg" | "url"yes
after.readbooleanyesFalse when no source could be read from it; message says why.
after.kindstring | nullyesA diagram kind: flow, sequence, schema, git, gantt, class, state, timeline, journey, mindmap, treemap, pie, quadrant, layers, c4, matrix, sankey, xychart, tree, swimlane, requirement, block, packet, kanban, radar, usecase, venn, fishbone, or wardley today. Later versions add kinds, so expect others.
after.validbooleanyes
after.messagestring | nullyes
countsobjectyes
counts.addedintegeryes
counts.removedintegeryes
counts.renamedintegeryes
counts.movedintegeryes
counts.changedintegeryes
changesobject[]yes
changes[].change"added" | "removed" | "renamed" | "moved" | "changed"yes
changes[].subject"header" | "node" | "group" | "edge" | "row" | "series" | "line"yes
changes[].namestringyesThe id, the label in quotes, or for an edge its ends.
changes[].lineinteger | nullyesThe line in after, or in before for a removal.
changes[].detailstringyes
truncatedbooleanyesTrue when more changes were found than are listed; counts covers all of them.
summarystringyesThe changes in plain words, for a pull request review.
markdownstring | nullyes
nextstringyes

CompareDiagramsInput

Two versions of a diagram to compare.

FieldTypeRequiredDescription
beforestringyesThe old diagram: source, the text of a Plotwork SVG that carries its source, or a cdn.plotwork.dev link. at least 1 character; at most 1000000 characters.
afterstringyesThe new diagram, in any of the same three forms. at least 1 character; at most 1000000 characters.
markdownbooleannoAlso return a Markdown block ready to paste as a pull request comment. default false.

SuggestDiagramResponse

The diagram kinds that fit a request, best first, each with a starter source.

FieldTypeRequiredDescription
requeststringyesThe request that was read.
suggestionsobject[]yesUp to 3, best first, one for each kind and style.
suggestions[].kindstringyesA diagram kind: flow, sequence, schema, git, gantt, class, state, timeline, journey, mindmap, treemap, pie, quadrant, layers, c4, matrix, sankey, xychart, tree, swimlane, requirement, block, packet, kanban, radar, usecase, venn, fishbone, or wardley today. Later versions add kinds, so expect others.
suggestions[].stylestring | nullyesThe style the starter uses: compare, score, raci, or risk for a matrix, files or org for a tree; null for the kind's only style.
suggestions[].whystringyesOne sentence: why this kind fits.
suggestions[].confidence"high" | "medium" | "low"yeshigh: the text names this kind of picture or its shape fits it exactly. medium: it leans toward it. low: a fallback worth considering.
suggestions[].starterstringyesA short Plotwork source of this kind that parses without errors: built from the names and numbers in the text where it could find them, otherwise a small example to edit. Replace every placeholder before you draw it.
suggestions[].tailoredbooleanyesTrue when the starter uses names or numbers from the text; false when it is the kind's small example.
suggestions[].statementsstring[]yesThe few statements of this kind to write, as syntax. get_diagram_syntax with this kind has them all.
importFormatstringnoPresent when the data is, or the request names, a file import_source reads (sql, openapi, compose, terraform, and so on): call import_source with this format and the file's text instead of editing a starter.
nextstringyesThe next step in one sentence.

SuggestDiagramInput

A request in plain words and optional data to draw from.

FieldTypeRequiredDescription
requeststringyesWhat the picture is for, in plain words, such as "permission matrix for these endpoints and roles" or "how a refund moves between support and billing". at least 1 character; at most 1000 characters.
datastringnoOptional text to draw from: a pasted table, a list, numbers by period, or notes. Names and numbers in it are used in the starters. at most 20000 characters.

EmbedDiagramResponse

A snippet that shows a Plotwork picture with the viewer.

FieldTypeRequiredDescription
okbooleanyesFalse when the url is not a hosted picture or the svg is not an SVG; message and hint say why.
snippetstring | nullyesThe code to paste into the page or component, or null when ok is false.
installstringyesThe command that installs the viewer.
srcstring | nullyesThe address the snippet loads the picture from.
linkKind"picture" | "stable" | "organisation" | nullyespicture (/d/), stable (/l/), organisation (/o/), or null for a file the page serves.
fingerprintstring | nullyessha256- of the svg text, whether or not the snippet pins it; null without svg.
livebooleanyesTrue when the snippet carries live.
pinnedbooleanyesTrue when the snippet carries fingerprint.
notesstring[]yesEach choice left out and why, and what to know about the link.
messagestringyesWhat happened, in one sentence.
hintstring | nullyesWhat to send instead, when ok is false.

EmbedDiagramInput

A Plotwork picture to show with the viewer, and how.

FieldTypeRequiredDescription
urlstringnoA hosted picture (/d/), stable link (/l/) or organisation embed link (/o/) on cdn.plotwork.dev. Never fetched. at least 1 character; at most 200 characters.
svgstringnoThe text of a Plotwork SVG; needed to pin. at least 1 character; at most 1000000 characters.
pathstringnoWhere the page serves svg from, when there is no url. at least 1 character; at most 500 characters.
format"html" | "react"nohtml for any page, react for React. default "html".
livebooleannoFollow new versions: /l/ and /o/ links only. default false.
pinbooleannoShow only exactly this picture: needs svg. default false.
labelstringnoWhat the diagram shows, for a screen reader. at most 200 characters.

EnquiryAck

FieldTypeRequiredDescription
receivedtrueyesAlways true. The enquiry was received.

EnquiryBody

FieldTypeRequiredDescription
namestringyesThe name of the person asking. at least 1 character; at most 120 characters.
emailstringyesTheir work email address. The reply goes here.
companystringyesThe company. at least 1 character; at most 120 characters.
companySize"1-49" | "50-249" | "250-999" | "1000-4999" | "5000+"yesHow many people the company has.
repos"1-9" | "10-49" | "50-199" | "200-999" | "1000+"yesHow many repositories the team would run diagrams in.
useCasestringyesWhat the team wants to do, in their words. at least 10 characters; at most 2000 characters.
interests("sso-scim" | "audit-siem" | "support-sla" | "limits" | "self-hosting" | "invoicing")[]noWhat the company needs, as the boxes ticked on the form. Left out, nothing was ticked; a box named twice counts once.
contextEnquiryContextnoSent by the portal: where the form was opened. The site sends none.
context.page"contact" | "plan" | "sso" | "log-streaming" | "connectors" | "support" | "audit" | "self-hosting"yesThe place in the portal the form was opened from, such as sso for the Single sign-on panel.
context.orgstringnoThe slug of the organisation the form was opened from. Kept only when the signed-in account is a member. pattern ^[a-z0-9](?:[a-z0-9-]{1,38}[a-z0-9])$.
websitestringnoLeave empty. A field people do not see: an enquiry that fills it is taken for a script and dropped, with the same answer. at most 200 characters.
elapsedMsintegeryesMilliseconds between the form being shown and being sent. An enquiry sent faster than a person can type is dropped, with the same answer. minimum 0.
turnstileTokenstringnoThe token the Cloudflare Turnstile widget on the site gave the visitor. Required from a visitor who is not signed in when the server has a Turnstile secret; never read from a signed-in account. at most 2048 characters.

EnquiryContext

Sent by the portal: where the form was opened. The site sends none.

FieldTypeRequiredDescription
page"contact" | "plan" | "sso" | "log-streaming" | "connectors" | "support" | "audit" | "self-hosting"yesThe place in the portal the form was opened from, such as sso for the Single sign-on panel.
orgstringnoThe slug of the organisation the form was opened from. Kept only when the signed-in account is a member. pattern ^[a-z0-9](?:[a-z0-9-]{1,38}[a-z0-9])$.

GithubOverview

FieldTypeRequiredDescription
configuredbooleanyesWhether the GitHub App is set up on this server.
activebooleanyesWhether the owner's plan includes the App (Pro and Enterprise).
plan"free" | "pro" | "enterprise"yes
canManagebooleanyesWhether the caller may link, unlink, scan and enable: the owner and admins.
appobject | nullyesThe App, when set up: where to install it, and the client ID the portal starts a GitHub sign-in with.
app.slugstringyes
app.clientIdstringyes
app.installUrlstringyes
installationsGithubInstallation[]yes
installations[].idstringyesGitHub's installation id.
installations[].accountobjectyes
installations[].account.loginstringyes
installations[].account.idstringyes
installations[].account.type"User" | "Organization"yes
installations[].repositorySelection"all" | "selected"yesWhether the App reaches every repository of the account or the ones chosen on GitHub.
installations[].suspendedbooleanyes
installations[].linkedAtintegeryesMilliseconds since the epoch.
installations[].linkedByobject | nullyes
installations[].linkedBy.idstringyes
installations[].linkedBy.emailstringyes
installations[].settingsUrlstringyesThe installation's settings page on GitHub, where it is narrowed, suspended or uninstalled.
repositoriesGithubRepository[]yes
repositories[].idstringyesGitHub's repository id.
repositories[].installationIdstringyes
repositories[].fullNamestringyes
repositories[].privatebooleanyes
repositories[].defaultBranchstringyes
repositories[].formatsarray | nullyesThe import formats the last scan found, such as terraform; null before a scan and after a push to the default branch.
repositories[].detectedAtinteger | nullyes
repositories[].status"none" | "pr_open" | "fix_open" | "merged" | "closed" | "adopted" | "reporting" | "failing"yesnone: not enabled. pr_open: the setup pull request is open. fix_open: a pull request that fixes the settings file is open; once it closes, the repository is scanned again. merged: merged, no drift run since. adopted: set up already, so Enable registered CI with no pull request, and no drift run since. reporting or failing: the latest drift run since it was enabled was clean, or drifted or failed. closed: the pull request was closed without merging.
repositories[].pullRequestobject | nullyes
repositories[].pullRequest.numberintegeryes
repositories[].pullRequest.urlstringyes
repositories[].enabledAtinteger | nullyes
repositories[].lastRunobject | nullyesThe repository's latest drift run, whenever it was sent.
repositories[].lastRun.checkedAtintegeryes
repositories[].lastRun.driftedintegeryes
repositories[].lastRun.failedintegeryes
limitsobjectyes
limits.maxRepositoriesPerInstallationintegeryes

GithubInstallation

FieldTypeRequiredDescription
idstringyesGitHub's installation id.
accountobjectyes
account.loginstringyes
account.idstringyes
account.type"User" | "Organization"yes
repositorySelection"all" | "selected"yesWhether the App reaches every repository of the account or the ones chosen on GitHub.
suspendedbooleanyes
linkedAtintegeryesMilliseconds since the epoch.
linkedByobject | nullyes
linkedBy.idstringyes
linkedBy.emailstringyes
settingsUrlstringyesThe installation's settings page on GitHub, where it is narrowed, suspended or uninstalled.

GithubRepository

FieldTypeRequiredDescription
idstringyesGitHub's repository id.
installationIdstringyes
fullNamestringyes
privatebooleanyes
defaultBranchstringyes
formatsarray | nullyesThe import formats the last scan found, such as terraform; null before a scan and after a push to the default branch.
detectedAtinteger | nullyes
status"none" | "pr_open" | "fix_open" | "merged" | "closed" | "adopted" | "reporting" | "failing"yesnone: not enabled. pr_open: the setup pull request is open. fix_open: a pull request that fixes the settings file is open; once it closes, the repository is scanned again. merged: merged, no drift run since. adopted: set up already, so Enable registered CI with no pull request, and no drift run since. reporting or failing: the latest drift run since it was enabled was clean, or drifted or failed. closed: the pull request was closed without merging.
pullRequestobject | nullyes
pullRequest.numberintegeryes
pullRequest.urlstringyes
enabledAtinteger | nullyes
lastRunobject | nullyesThe repository's latest drift run, whenever it was sent.
lastRun.checkedAtintegeryes
lastRun.driftedintegeryes
lastRun.failedintegeryes

GithubAuthorize

FieldTypeRequiredDescription
grantstringyesProof, for ten minutes and for this account only, of the installations the GitHub user can reach. Holds no secret.
installUrlstringyesWhere to install the App, for a GitHub user who can reach no installation of it yet.
expiresAtintegeryes
githubUserobjectyes
githubUser.loginstringyes
githubUser.idstringyes
installationsobject[]yes
installations[].idstringyes
installations[].accountobjectyes
installations[].account.loginstringyes
installations[].account.idstringyes
installations[].account.type"User" | "Organization"yes
installations[].repositorySelection"all" | "selected"yes
installations[].suspendedbooleanyes
installations[].linkedToobject | nullyesThe organisation it is linked to, when the caller is a member of it.
installations[].linkedTo.slugstringyes
installations[].linkedTo.namestringyes
installations[].linkedElsewherebooleanyesTrue when another organisation has it; that organisation is not named.

GithubAuthorizeBody

FieldTypeRequiredDescription
codestringyesThe code GitHub sent the browser back with. at least 1 character; at most 200 characters.
codeVerifierstringnoThe PKCE verifier, when the portal started the sign-in with a challenge. at least 43 characters; at most 128 characters; pattern ^[A-Za-z0-9._~-]+$.
FieldTypeRequiredDescription
installationGithubInstallationyes
installation.idstringyesGitHub's installation id.
installation.accountobjectyes
installation.account.loginstringyes
installation.account.idstringyes
installation.account.type"User" | "Organization"yes
installation.repositorySelection"all" | "selected"yesWhether the App reaches every repository of the account or the ones chosen on GitHub.
installation.suspendedbooleanyes
installation.linkedAtintegeryesMilliseconds since the epoch.
installation.linkedByobject | nullyes
installation.linkedBy.idstringyes
installation.linkedBy.emailstringyes
installation.settingsUrlstringyesThe installation's settings page on GitHub, where it is narrowed, suspended or uninstalled.
syncedintegeryes
nextPageinteger | nullyesThe next page of repositories to read with sync, or null when every one was read.

GithubLinkBody

FieldTypeRequiredDescription
grantstringyesat least 1 character; at most 8192 characters.
installationIdstringyesat most 20 characters; pattern ^[1-9][0-9]{0,19}$.

GithubSync

FieldTypeRequiredDescription
syncedintegeryes
nextPageinteger | nullyes

GithubSyncBody

FieldTypeRequiredDescription
pageintegernominimum 1; maximum 10; default 1.

GithubRepositorySearch

FieldTypeRequiredDescription
itemsGithubPickerRepository[]yesBy name, at most 50 a page.
items[].idstringyesGitHub's repository id.
items[].fullNamestringyes
items[].defaultBranchstringyes
nextCursorstring | nullyesSend as cursor for the next page; null on the last.

GithubPickerRepository

FieldTypeRequiredDescription
idstringyesGitHub's repository id.
fullNamestringyes
defaultBranchstringyes

GithubWorkflows

FieldTypeRequiredDescription
repositoryGithubPickerRepositoryyes
repository.idstringyesGitHub's repository id.
repository.fullNamestringyes
repository.defaultBranchstringyes
workflowsobject[]yesThe workflow files on the default branch, by file name, at most 200. Empty for an empty repository.
workflows[].pathstringyes
workflows[].filestringyes
truncatedbooleanyesTrue when the tree was too large to read whole, so only the top level was read and the list may miss files.
environmentsstring[]yesThe deployment environments by name, at most 100. Empty when there are none or GitHub does not let the App read them.

GithubDetect

FieldTypeRequiredDescription
repositoryGithubRepositoryyes
repository.idstringyesGitHub's repository id.
repository.installationIdstringyes
repository.fullNamestringyes
repository.privatebooleanyes
repository.defaultBranchstringyes
repository.formatsarray | nullyesThe import formats the last scan found, such as terraform; null before a scan and after a push to the default branch.
repository.detectedAtinteger | nullyes
repository.status"none" | "pr_open" | "fix_open" | "merged" | "closed" | "adopted" | "reporting" | "failing"yesnone: not enabled. pr_open: the setup pull request is open. fix_open: a pull request that fixes the settings file is open; once it closes, the repository is scanned again. merged: merged, no drift run since. adopted: set up already, so Enable registered CI with no pull request, and no drift run since. reporting or failing: the latest drift run since it was enabled was clean, or drifted or failed. closed: the pull request was closed without merging.
repository.pullRequestobject | nullyes
repository.pullRequest.numberintegeryes
repository.pullRequest.urlstringyes
repository.enabledAtinteger | nullyes
repository.lastRunobject | nullyesThe repository's latest drift run, whenever it was sent.
repository.lastRun.checkedAtintegeryes
repository.lastRun.driftedintegeryes
repository.lastRun.failedintegeryes
sourcesobject[]yesThe sources a settings file would name, with their paths. Only the format names are stored.
sources[].namestringyes
sources[].formatstringyes
sources[].fromstring[]yes
sources[].outstringyes
truncatedbooleanyesTrue when the tree was too large to read whole, so only part of it was scanned.
planGithubPlanyes
plan.outcome"setup" | "additions" | "complete" | "invalid" | "nothing"yessetup: no settings file yet, so a pull request adds one, the workflow and the diagrams. additions: the repository uses Plotwork, and a pull request adds only what it lacks. complete: it covers everything found, so only CI is registered. invalid: its settings file does not check and is left alone. nothing: nothing to draw.
plan.summarystringyesWhat happens, in one sentence.
plan.addedobject[]yes
plan.added[].namestringyes
plan.added[].formatstringyes
plan.added[].fromstring[]yes
plan.added[].outstringyes
plan.keptstring[]yesThe sources the settings file has, every one left as it is.
plan.workflowobject | nullyesThe workflow written, edited in place (report-drift and id-token: write added), or left as it is.
plan.workflow.action"add" | "edit" | "keep"yes
plan.workflow.filestringyes
plan.suggestionsstring[]yesWhat the workflow still lacks and was not changed, such as an older pin of the Action.
plan.problemsobject[]yesFor invalid: where the settings file does not check, each with a hint.
plan.problems[].codestringyes
plan.problems[].messagestringyes
plan.problems[].lineintegeryes
plan.problems[].columnintegeryes
plan.problems[].hintstring | nullyes
plan.repairobject | nullyesFor invalid: the repair Enable would make.
plan.repair.fixablebooleanyesTrue when every problem has a plain fix, so Enable opens a pull request that fixes the file.
plan.repair.fixesobject[]yes
plan.repair.needsYoustring[]yesWhat the fix leaves as it is for the person: a source that reads no file, a key or value with no plain match.
plan.followUpstring | nullyesFor a fixable invalid: what Enable does once the fix is merged.

GithubPlan

FieldTypeRequiredDescription
outcome"setup" | "additions" | "complete" | "invalid" | "nothing"yessetup: no settings file yet, so a pull request adds one, the workflow and the diagrams. additions: the repository uses Plotwork, and a pull request adds only what it lacks. complete: it covers everything found, so only CI is registered. invalid: its settings file does not check and is left alone. nothing: nothing to draw.
summarystringyesWhat happens, in one sentence.
addedobject[]yes
added[].namestringyes
added[].formatstringyes
added[].fromstring[]yes
added[].outstringyes
keptstring[]yesThe sources the settings file has, every one left as it is.
workflowobject | nullyesThe workflow written, edited in place (report-drift and id-token: write added), or left as it is.
workflow.action"add" | "edit" | "keep"yes
workflow.filestringyes
suggestionsstring[]yesWhat the workflow still lacks and was not changed, such as an older pin of the Action.
problemsobject[]yesFor invalid: where the settings file does not check, each with a hint.
problems[].codestringyes
problems[].messagestringyes
problems[].lineintegeryes
problems[].columnintegeryes
problems[].hintstring | nullyes
repairobject | nullyesFor invalid: the repair Enable would make.
repair.fixablebooleanyesTrue when every problem has a plain fix, so Enable opens a pull request that fixes the file.
repair.fixesobject[]yes
repair.fixes[].lineinteger | nullyes
repair.fixes[].pathstringyes
repair.fixes[].beforestringyes
repair.fixes[].afterstringyes
repair.fixes[].whystringyes
repair.needsYoustring[]yesWhat the fix leaves as it is for the person: a source that reads no file, a key or value with no plain match.
followUpstring | nullyesFor a fixable invalid: what Enable does once the fix is merged.

GithubEnable

FieldTypeRequiredDescription
repositoryGithubRepositoryyes
repository.idstringyesGitHub's repository id.
repository.installationIdstringyes
repository.fullNamestringyes
repository.privatebooleanyes
repository.defaultBranchstringyes
repository.formatsarray | nullyesThe import formats the last scan found, such as terraform; null before a scan and after a push to the default branch.
repository.detectedAtinteger | nullyes
repository.status"none" | "pr_open" | "fix_open" | "merged" | "closed" | "adopted" | "reporting" | "failing"yesnone: not enabled. pr_open: the setup pull request is open. fix_open: a pull request that fixes the settings file is open; once it closes, the repository is scanned again. merged: merged, no drift run since. adopted: set up already, so Enable registered CI with no pull request, and no drift run since. reporting or failing: the latest drift run since it was enabled was clean, or drifted or failed. closed: the pull request was closed without merging.
repository.pullRequestobject | nullyes
repository.pullRequest.numberintegeryes
repository.pullRequest.urlstringyes
repository.enabledAtinteger | nullyes
repository.lastRunobject | nullyesThe repository's latest drift run, whenever it was sent.
repository.lastRun.checkedAtintegeryes
repository.lastRun.driftedintegeryes
repository.lastRun.failedintegeryes
outcome"opened" | "open" | "complete" | "fix_opened"yesopened: a pull request was opened now. open: one was open already. complete: the repository is set up already, so no pull request; only the trusted publisher was registered. fix_opened: its settings file did not check, so a pull request that fixes it was opened, or the open one brought up to date.
pullRequestobject | nullyes
pullRequest.numberintegeryes
pullRequest.urlstringyes
createdbooleanyesTrue when a pull request was opened now.
trustedPublisherobject | nullyesThe trusted publisher for the workflow, or null when the organisation has twenty already.
trustedPublisher.idstringyes
trustedPublisher.namestringyes
trustedPublisher.createdbooleanyes
keylessbooleanyesTrue when the workflow signs in with no key (id-token: write); false while the pinned Action needs PLOTWORK_API_KEY.
sourcesintegeryesHow many diagrams the pull request adds.
planGithubPlanyes
plan.outcome"setup" | "additions" | "complete" | "invalid" | "nothing"yessetup: no settings file yet, so a pull request adds one, the workflow and the diagrams. additions: the repository uses Plotwork, and a pull request adds only what it lacks. complete: it covers everything found, so only CI is registered. invalid: its settings file does not check and is left alone. nothing: nothing to draw.
plan.summarystringyesWhat happens, in one sentence.
plan.addedobject[]yes
plan.added[].namestringyes
plan.added[].formatstringyes
plan.added[].fromstring[]yes
plan.added[].outstringyes
plan.keptstring[]yesThe sources the settings file has, every one left as it is.
plan.workflowobject | nullyesThe workflow written, edited in place (report-drift and id-token: write added), or left as it is.
plan.workflow.action"add" | "edit" | "keep"yes
plan.workflow.filestringyes
plan.suggestionsstring[]yesWhat the workflow still lacks and was not changed, such as an older pin of the Action.
plan.problemsobject[]yesFor invalid: where the settings file does not check, each with a hint.
plan.problems[].codestringyes
plan.problems[].messagestringyes
plan.problems[].lineintegeryes
plan.problems[].columnintegeryes
plan.problems[].hintstring | nullyes
plan.repairobject | nullyesFor invalid: the repair Enable would make.
plan.repair.fixablebooleanyesTrue when every problem has a plain fix, so Enable opens a pull request that fixes the file.
plan.repair.fixesobject[]yes
plan.repair.needsYoustring[]yesWhat the fix leaves as it is for the person: a source that reads no file, a key or value with no plain match.
plan.followUpstring | nullyesFor a fixable invalid: what Enable does once the fix is merged.

GithubTrust

FieldTypeRequiredDescription
trustedPublisherobject | nullyesThe trusted publisher, or null when the organisation has twenty already.
trustedPublisher.idstringyes
trustedPublisher.namestringyes
trustedPublisher.createdbooleanyes
workflowstringyesThe workflow file it trusts: the repository's own Plotwork workflow, else diagrams.yml.

GithubWebhookAck

FieldTypeRequiredDescription
outcome"applied" | "duplicate" | "ignored"yesapplied: rows changed. duplicate: this delivery was applied before. ignored: nothing this App acts on.

PublishAnswer

FieldTypeRequiredDescription

PublishedDiagram

FieldTypeRequiredDescription
idstringyesThe handle for managing the diagram (delete). It is not in the link.
urlstringyesThe public address of the SVG. Anyone with the link can see it; the token in it cannot be guessed.
namestring | nullyesThe label given at publish, or null.
folderstring | nullyesThe folder it is filed in, such as Payments/Checkout, or null for the top level.
scheme"light" | "dark" | "auto"yesThe color scheme it was drawn in: light, dark, or auto.
bytesintegeryesSize of the stored SVG in bytes.
createdAtintegeryesWhen it was first published, in milliseconds since the epoch.
publishedAtintegeryesWhen it was last published, in milliseconds since the epoch. Publishing the same diagram again moves it.
expiresAtinteger | nullyesWhen it will be deleted, in milliseconds since the epoch, or null when the plan keeps diagrams until you delete them.
lockedbooleanyesTrue while the diagram is locked: it cannot be deleted, renamed or moved until you unlock it. A lock does not stop it expiring on a plan that expires diagrams.
lockedAtinteger | nullyesWhen it was locked, in milliseconds since the epoch, or null when it is not locked.
seriesDiagramSeriesyesIts place in a series (the parts of one split import), or null when it is in none.
series.idstringyesThe series id the parts were published with.
series.indexintegeryesIts place in the series, from 1; 0 is the whole import combined into one diagram.
series.totalinteger | nullyesHow many parts the publisher said the series has, or null.
createdbooleanyesTrue when this call stored a new diagram; false when the same diagram was already hosted and its link was kept.
stableLinkStableLinknoPresent only when the publish named an alias: the stable link, now pointing at this diagram.
stableLink.idstringyesThe handle for managing the stable link (delete). It is not in its address.
stableLink.aliasstringyesThe name you gave it. Only you see it.
stableLink.urlstringyesThe public address, on the CDN host. It shows the diagram the stable link points at now (cached for up to 60 seconds) and never changes. Anyone with it can see the picture.
stableLink.diagramIdstring | nullyesThe diagram it shows now, or null when that diagram was deleted or expired; the address then answers 404 until you point the link at a diagram again.
stableLink.createdAtintegeryesWhen it was made, in milliseconds since the epoch.
stableLink.updatedAtintegeryesWhen it was last pointed at a diagram, in milliseconds since the epoch.

DiagramSeries

Its place in a series (the parts of one split import), or null when it is in none.

FieldTypeRequiredDescription
idstringyesThe series id the parts were published with.
indexintegeryesIts place in the series, from 1; 0 is the whole import combined into one diagram.
totalinteger | nullyesHow many parts the publisher said the series has, or null.

Present only when the publish named an alias: the stable link, now pointing at this diagram.

FieldTypeRequiredDescription
idstringyesThe handle for managing the stable link (delete). It is not in its address.
aliasstringyesThe name you gave it. Only you see it.
urlstringyesThe public address, on the CDN host. It shows the diagram the stable link points at now (cached for up to 60 seconds) and never changes. Anyone with it can see the picture.
diagramIdstring | nullyesThe diagram it shows now, or null when that diagram was deleted or expired; the address then answers 404 until you point the link at a diagram again.
createdAtintegeryesWhen it was made, in milliseconds since the epoch.
updatedAtintegeryesWhen it was last pointed at a diagram, in milliseconds since the epoch.

HostedDiagram

FieldTypeRequiredDescription
idstringyesThe handle for managing the diagram (delete). It is not in the link.
urlstringyesThe public address of the SVG. Anyone with the link can see it; the token in it cannot be guessed.
namestring | nullyesThe label given at publish, or null.
folderstring | nullyesThe folder it is filed in, such as Payments/Checkout, or null for the top level.
scheme"light" | "dark" | "auto"yesThe color scheme it was drawn in: light, dark, or auto.
bytesintegeryesSize of the stored SVG in bytes.
createdAtintegeryesWhen it was first published, in milliseconds since the epoch.
publishedAtintegeryesWhen it was last published, in milliseconds since the epoch. Publishing the same diagram again moves it.
expiresAtinteger | nullyesWhen it will be deleted, in milliseconds since the epoch, or null when the plan keeps diagrams until you delete them.
lockedbooleanyesTrue while the diagram is locked: it cannot be deleted, renamed or moved until you unlock it. A lock does not stop it expiring on a plan that expires diagrams.
lockedAtinteger | nullyesWhen it was locked, in milliseconds since the epoch, or null when it is not locked.
seriesDiagramSeriesyesIts place in a series (the parts of one split import), or null when it is in none.
series.idstringyesThe series id the parts were published with.
series.indexintegeryesIts place in the series, from 1; 0 is the whole import combined into one diagram.
series.totalinteger | nullyesHow many parts the publisher said the series has, or null.

RoutedPublish

FieldTypeRequiredDescription
idstringyesThe handle for the diagram in the routes below.
namestring | nullyesThe label given at publish, or null.
folderstring | nullyesThe folder it is filed in, such as Payments/Checkout, or null for the top level.
scheme"light" | "dark" | "auto"yesThe color scheme it was drawn in: light, dark, or auto.
bytesintegeryesSize of the stored SVG in bytes.
createdBystring | nullyesThe person it belongs to: the member who published it, or the person who connected the agent that did. Null when that account has left or an organisation key published it.
publishedVia"person" | "connection" | "key" | nullyesHow it was published: person (signed in, or with a key the person made), connection (an agent connected to the organisation, whose person is createdBy), or key (an organisation key from Keys and CI). Null for a diagram published before this was recorded.
publishedKeyobject | nullyesThe key behind a connection or an organisation key. Null for a person, and once the key no longer exists.
publishedKey.idstringyesThe key's id, as Keys and CI lists it. Never the key itself.
publishedKey.namestring | nullyesThe key's name, or null once the key is revoked.
publishedClientstring | nullyesThe client name the agent gave when it connected, such as Claude Code, for a connection only. at most 100 characters.
createdAtintegeryesWhen it was first published, in milliseconds since the epoch.
publishedAtintegeryesWhen it was last published, in milliseconds since the epoch. Publishing the same diagram again moves it.
expiresAtinteger | nullyesWhen it will be deleted, in milliseconds since the epoch, or null when the owner's plan keeps diagrams until they are deleted.
viewUrlstringyesA page in the portal that shows the diagram to a signed-in member. It is not a link anyone can open: an organisation's diagrams have no public address.
lockedbooleanyesTrue while the owner has the diagram locked: nobody can delete, rename or move it, its publisher and the owner included, until the owner unlocks it. A lock does not stop it expiring on a plan that expires diagrams.
lockedAtinteger | nullyesWhen the owner locked it, in milliseconds since the epoch, or null when it is not locked.
restrictedtruenoPresent, and true, when the owner has restricted this diagram's folder and the caller is allowed in it, so the portal can show it as locked. Absent otherwise. A diagram in a folder the caller may not use is not listed at all.
keepInsidetruenoPresent, and true, when the folder rule over this diagram keeps its diagrams inside: the svg route refuses ?download=1 and the copy route refuses a copy (403 orgs.folder_restricted). Absent otherwise.
shareOrganisationDiagramShareyesIts public link while the organisation shares it, or null. Only a diagram someone chose to share has one.
share.urlstringyesThe public address, {CDN_URL}/l/<token>.svg. Anyone with it can see the picture, without its source. It keeps showing the latest version when the diagram is edited, and never changes.
share.sharedAtintegeryesWhen the diagram was first shared, in milliseconds since the epoch.
keptbooleanyes"Keep": true when an owner or admin keeps it from the library retention. The plan's own retention still applies.
deletesAtinteger | nullyesWhen the retention deletes it, in milliseconds since the epoch: the nearer of the plan's expiry and "Delete library diagrams not updated for". Null when nothing will, and always null under a legal hold.
classificationClassificationyesA diagram's classification label: public, internal (the default, and what a diagram published before labels reads as) or confidential. Confidential is never shared publicly; under "Share only diagrams labelled Public" only public is.
pendingbooleanyesTrue while it is held for approval ("Publishing needs approval"): only its publisher and the approvers see it.
changePendingbooleanyesTrue while a new version of it waits for approval. The library shows this version until then.
seriesDiagramSeriesyesIts place in a series (the parts of one split import), or null when it is in none.
series.idstringyesThe series id the parts were published with.
series.indexintegeryesIts place in the series, from 1; 0 is the whole import combined into one diagram.
series.totalinteger | nullyesHow many parts the publisher said the series has, or null.
createdbooleanyesTrue when this call stored a new diagram; false when the same diagram was already in the library and was kept.
sourceEmbeddedbooleanyesTrue when the stored picture carries the diagram source: the call sent embedSource true, or left it out while the organisation's keepEditable is on.
approvalApprovalHoldnoPresent when the organisation's "Publishing needs approval" or "Public sharing needs approval" held this. It is data, not an error: the diagram is stored, and only its publisher and the approvers can see it until an approver approves.
approval.state"pending"yes
approval.requestIdstringyesThe request, as the Approvals queue lists it.
approval.kind"publish" | "change" | "share"yespublish (a new diagram), change (a new version of one the library shows) or share (a public link).
approval.expiresAtintegeryesWhen the daily sweep ends the request if nobody decides it, in milliseconds since the epoch: thirty days after it was made.
approval.messagestringyesOne sentence to tell the person: held for approval by the organisation, and what happens next.
approval.codestringyesThe warning code a tool answer carries for it: W601.
privatetrueyesThe diagram is in an organisation's private library and has no public link.
organizationPublishOrganizationyesThe organisation whose private library holds the diagram.
organization.idstringyes
organization.slugstringyes
organization.namestringyes
routedBy"organisation-default" | "organisation-required"noPresent when the organisation's Publishing setting chose its library for a publish that named no organisation: organisation-default (its members publish there unless they ask for a personal link) or organisation-required (they always do).

OrganisationDiagramShare

Its public link while the organisation shares it, or null. Only a diagram someone chose to share has one.

FieldTypeRequiredDescription
urlstringyesThe public address, {CDN_URL}/l/<token>.svg. Anyone with it can see the picture, without its source. It keeps showing the latest version when the diagram is edited, and never changes.
sharedAtintegeryesWhen the diagram was first shared, in milliseconds since the epoch.

Classification

A diagram's classification label: public, internal (the default, and what a diagram published before labels reads as) or confidential. Confidential is never shared publicly; under "Share only diagrams labelled Public" only public is.

FieldTypeRequiredDescription

ApprovalHold

Present when the organisation's "Publishing needs approval" or "Public sharing needs approval" held this. It is data, not an error: the diagram is stored, and only its publisher and the approvers can see it until an approver approves.

FieldTypeRequiredDescription
state"pending"yes
requestIdstringyesThe request, as the Approvals queue lists it.
kind"publish" | "change" | "share"yespublish (a new diagram), change (a new version of one the library shows) or share (a public link).
expiresAtintegeryesWhen the daily sweep ends the request if nobody decides it, in milliseconds since the epoch: thirty days after it was made.
messagestringyesOne sentence to tell the person: held for approval by the organisation, and what happens next.
codestringyesThe warning code a tool answer carries for it: W601.

PublishOrganization

The organisation whose private library holds the diagram.

FieldTypeRequiredDescription
idstringyes
slugstringyes
namestringyes

PublishedOrganisationDiagram

FieldTypeRequiredDescription
idstringyesThe handle for the diagram in the routes below.
namestring | nullyesThe label given at publish, or null.
folderstring | nullyesThe folder it is filed in, such as Payments/Checkout, or null for the top level.
scheme"light" | "dark" | "auto"yesThe color scheme it was drawn in: light, dark, or auto.
bytesintegeryesSize of the stored SVG in bytes.
createdBystring | nullyesThe person it belongs to: the member who published it, or the person who connected the agent that did. Null when that account has left or an organisation key published it.
publishedVia"person" | "connection" | "key" | nullyesHow it was published: person (signed in, or with a key the person made), connection (an agent connected to the organisation, whose person is createdBy), or key (an organisation key from Keys and CI). Null for a diagram published before this was recorded.
publishedKeyobject | nullyesThe key behind a connection or an organisation key. Null for a person, and once the key no longer exists.
publishedKey.idstringyesThe key's id, as Keys and CI lists it. Never the key itself.
publishedKey.namestring | nullyesThe key's name, or null once the key is revoked.
publishedClientstring | nullyesThe client name the agent gave when it connected, such as Claude Code, for a connection only. at most 100 characters.
createdAtintegeryesWhen it was first published, in milliseconds since the epoch.
publishedAtintegeryesWhen it was last published, in milliseconds since the epoch. Publishing the same diagram again moves it.
expiresAtinteger | nullyesWhen it will be deleted, in milliseconds since the epoch, or null when the owner's plan keeps diagrams until they are deleted.
viewUrlstringyesA page in the portal that shows the diagram to a signed-in member. It is not a link anyone can open: an organisation's diagrams have no public address.
lockedbooleanyesTrue while the owner has the diagram locked: nobody can delete, rename or move it, its publisher and the owner included, until the owner unlocks it. A lock does not stop it expiring on a plan that expires diagrams.
lockedAtinteger | nullyesWhen the owner locked it, in milliseconds since the epoch, or null when it is not locked.
restrictedtruenoPresent, and true, when the owner has restricted this diagram's folder and the caller is allowed in it, so the portal can show it as locked. Absent otherwise. A diagram in a folder the caller may not use is not listed at all.
keepInsidetruenoPresent, and true, when the folder rule over this diagram keeps its diagrams inside: the svg route refuses ?download=1 and the copy route refuses a copy (403 orgs.folder_restricted). Absent otherwise.
shareOrganisationDiagramShareyesIts public link while the organisation shares it, or null. Only a diagram someone chose to share has one.
share.urlstringyesThe public address, {CDN_URL}/l/<token>.svg. Anyone with it can see the picture, without its source. It keeps showing the latest version when the diagram is edited, and never changes.
share.sharedAtintegeryesWhen the diagram was first shared, in milliseconds since the epoch.
keptbooleanyes"Keep": true when an owner or admin keeps it from the library retention. The plan's own retention still applies.
deletesAtinteger | nullyesWhen the retention deletes it, in milliseconds since the epoch: the nearer of the plan's expiry and "Delete library diagrams not updated for". Null when nothing will, and always null under a legal hold.
classificationClassificationyesA diagram's classification label: public, internal (the default, and what a diagram published before labels reads as) or confidential. Confidential is never shared publicly; under "Share only diagrams labelled Public" only public is.
pendingbooleanyesTrue while it is held for approval ("Publishing needs approval"): only its publisher and the approvers see it.
changePendingbooleanyesTrue while a new version of it waits for approval. The library shows this version until then.
seriesDiagramSeriesyesIts place in a series (the parts of one split import), or null when it is in none.
series.idstringyesThe series id the parts were published with.
series.indexintegeryesIts place in the series, from 1; 0 is the whole import combined into one diagram.
series.totalinteger | nullyesHow many parts the publisher said the series has, or null.
createdbooleanyesTrue when this call stored a new diagram; false when the same diagram was already in the library and was kept.
sourceEmbeddedbooleanyesTrue when the stored picture carries the diagram source: the call sent embedSource true, or left it out while the organisation's keepEditable is on.
approvalApprovalHoldnoPresent when the organisation's "Publishing needs approval" or "Public sharing needs approval" held this. It is data, not an error: the diagram is stored, and only its publisher and the approvers can see it until an approver approves.
approval.state"pending"yes
approval.requestIdstringyesThe request, as the Approvals queue lists it.
approval.kind"publish" | "change" | "share"yespublish (a new diagram), change (a new version of one the library shows) or share (a public link).
approval.expiresAtintegeryesWhen the daily sweep ends the request if nobody decides it, in milliseconds since the epoch: thirty days after it was made.
approval.messagestringyesOne sentence to tell the person: held for approval by the organisation, and what happens next.
approval.codestringyesThe warning code a tool answer carries for it: W601.

OrganisationDiagram

FieldTypeRequiredDescription
idstringyesThe handle for the diagram in the routes below.
namestring | nullyesThe label given at publish, or null.
folderstring | nullyesThe folder it is filed in, such as Payments/Checkout, or null for the top level.
scheme"light" | "dark" | "auto"yesThe color scheme it was drawn in: light, dark, or auto.
bytesintegeryesSize of the stored SVG in bytes.
createdBystring | nullyesThe person it belongs to: the member who published it, or the person who connected the agent that did. Null when that account has left or an organisation key published it.
publishedVia"person" | "connection" | "key" | nullyesHow it was published: person (signed in, or with a key the person made), connection (an agent connected to the organisation, whose person is createdBy), or key (an organisation key from Keys and CI). Null for a diagram published before this was recorded.
publishedKeyobject | nullyesThe key behind a connection or an organisation key. Null for a person, and once the key no longer exists.
publishedKey.idstringyesThe key's id, as Keys and CI lists it. Never the key itself.
publishedKey.namestring | nullyesThe key's name, or null once the key is revoked.
publishedClientstring | nullyesThe client name the agent gave when it connected, such as Claude Code, for a connection only. at most 100 characters.
createdAtintegeryesWhen it was first published, in milliseconds since the epoch.
publishedAtintegeryesWhen it was last published, in milliseconds since the epoch. Publishing the same diagram again moves it.
expiresAtinteger | nullyesWhen it will be deleted, in milliseconds since the epoch, or null when the owner's plan keeps diagrams until they are deleted.
viewUrlstringyesA page in the portal that shows the diagram to a signed-in member. It is not a link anyone can open: an organisation's diagrams have no public address.
lockedbooleanyesTrue while the owner has the diagram locked: nobody can delete, rename or move it, its publisher and the owner included, until the owner unlocks it. A lock does not stop it expiring on a plan that expires diagrams.
lockedAtinteger | nullyesWhen the owner locked it, in milliseconds since the epoch, or null when it is not locked.
restrictedtruenoPresent, and true, when the owner has restricted this diagram's folder and the caller is allowed in it, so the portal can show it as locked. Absent otherwise. A diagram in a folder the caller may not use is not listed at all.
keepInsidetruenoPresent, and true, when the folder rule over this diagram keeps its diagrams inside: the svg route refuses ?download=1 and the copy route refuses a copy (403 orgs.folder_restricted). Absent otherwise.
shareOrganisationDiagramShareyesIts public link while the organisation shares it, or null. Only a diagram someone chose to share has one.
share.urlstringyesThe public address, {CDN_URL}/l/<token>.svg. Anyone with it can see the picture, without its source. It keeps showing the latest version when the diagram is edited, and never changes.
share.sharedAtintegeryesWhen the diagram was first shared, in milliseconds since the epoch.
keptbooleanyes"Keep": true when an owner or admin keeps it from the library retention. The plan's own retention still applies.
deletesAtinteger | nullyesWhen the retention deletes it, in milliseconds since the epoch: the nearer of the plan's expiry and "Delete library diagrams not updated for". Null when nothing will, and always null under a legal hold.
classificationClassificationyesA diagram's classification label: public, internal (the default, and what a diagram published before labels reads as) or confidential. Confidential is never shared publicly; under "Share only diagrams labelled Public" only public is.
pendingbooleanyesTrue while it is held for approval ("Publishing needs approval"): only its publisher and the approvers see it.
changePendingbooleanyesTrue while a new version of it waits for approval. The library shows this version until then.
seriesDiagramSeriesyesIts place in a series (the parts of one split import), or null when it is in none.
series.idstringyesThe series id the parts were published with.
series.indexintegeryesIts place in the series, from 1; 0 is the whole import combined into one diagram.
series.totalinteger | nullyesHow many parts the publisher said the series has, or null.

PublishDiagramBody

FieldTypeRequiredDescription
sourcestringyesDiagram source; the first line is the header, such as flow "Title" (draw_diagram lists every kind). at least 1 character; at most 120000 characters.
settingsobjectnoThe repo's plotwork.config.json, if any. Schema: https://docs.plotwork.dev/schemas/plotwork.config.json (opens in a new tab).
scheme"light" | "dark" | "auto"noThe color scheme to draw it in: light, dark, or auto (one picture that follows the viewer's light or dark setting). Light when left out.
theme"light" | "dark" | "auto"noThe old name of scheme, still taken from callers that send it: light, dark, or auto. Send scheme instead; refused when both are sent and differ.
embedSourcebooleannoWhether the stored SVG carries the diagram source in its metadata, so the picture can be edited later: read_diagram gives the source back from the link. The source is part of the picture, which anyone who has the link can read (for a diagram in an organisation, every member who can open it). Left out, a personal diagram carries the source, and a diagram that lands in an organisation follows its keepEditable setting (on unless the owner turned it off). Send false to leave the source out, such as for a public link whose labels name internal systems. The same diagram published with and without it is two pictures with two links.
namestringnoA label for the diagram in your list and in the Markdown snippet. Optional. at least 1 character; at most 80 characters; pattern ^[^\p{Cc}]+$/u.
folderstring | nullnoThe folder to file the diagram in. Left out, a new diagram goes to the top level and a diagram that is already hosted stays where it is. A path files a new diagram there, or moves the one that is already hosted and keeps its link. null puts it at the top level. at most 204 characters; pattern ^[A-Za-z0-9_-]+(?: [A-Za-z0-9_-]+)*(?:/[A-Za-z0-9_-]+(?: [A-Za-z0-9_-]+)*){0,4}$.
aliasstringnoPoint a stable link with this name at the diagram, so one address always shows the latest version. The first publish with a name makes the stable link (the answer's stableLink.url) and every later publish with the same name moves it to the new diagram; the address never changes. How many stable links an account keeps depends on its plan. An alias asks for a personal link, so an organisation that requires its library refuses it (orgs.publish_required). Optional. at least 1 character; at most 60 characters; pattern ^[a-z0-9]+(?:-[a-z0-9]+)*$.
organizationstringnoAn organisation's slug or id: the diagram goes to that organisation's private library, and the answer has private true and a viewUrl in place of a public link. The account must be a member who may publish there. Left out, the diagram goes to your own library, unless an organisation you belong to publishes its members' diagrams to its library. at least 1 character; at most 64 characters.
personalbooleannoTrue asks for a public link in your own library even though an organisation you belong to publishes its members' diagrams to its library by default. An organisation that requires its library refuses it (403 orgs.publish_required). Not with organization.
classificationanyno
seriesSeriesInputnoPublish the diagram as one part of a series: the parts of one big import, such as an overview and one diagram per group, each published with the same id and its place, the overview first. The portal shows a series as tabs of one diagram and can open it on one board. A part published at a place another diagram of the series holds takes the place. Left out, a diagram's series is left as it is. Optional.
series.idstringyesThe series id, the same for every part: letters, digits, - and _, up to 64 characters. It names nothing outside your library or the organisation's. at least 1 character; at most 64 characters; pattern ^[A-Za-z0-9_-]+$.
series.indexintegeryesThe part's place in the series, from 1 (the overview); 0 is the whole import combined into one diagram, at most one a series. minimum 0; maximum 1000.
series.totalintegernoHow many parts the series has. Optional. minimum 1; maximum 1000.

SeriesInput

Publish the diagram as one part of a series: the parts of one big import, such as an overview and one diagram per group, each published with the same id and its place, the overview first. The portal shows a series as tabs of one diagram and can open it on one board. A part published at a place another diagram of the series holds takes the place. Left out, a diagram's series is left as it is. Optional.

FieldTypeRequiredDescription
idstringyesThe series id, the same for every part: letters, digits, - and _, up to 64 characters. It names nothing outside your library or the organisation's. at least 1 character; at most 64 characters; pattern ^[A-Za-z0-9_-]+$.
indexintegeryesThe part's place in the series, from 1 (the overview); 0 is the whole import combined into one diagram, at most one a series. minimum 0; maximum 1000.
totalintegernoHow many parts the series has. Optional. minimum 1; maximum 1000.

HostedDiagramList

FieldTypeRequiredDescription
itemsHostedDiagram[]yesAt most 200, newest published first.
items[].idstringyesThe handle for managing the diagram (delete). It is not in the link.
items[].urlstringyesThe public address of the SVG. Anyone with the link can see it; the token in it cannot be guessed.
items[].namestring | nullyesThe label given at publish, or null.
items[].folderstring | nullyesThe folder it is filed in, such as Payments/Checkout, or null for the top level.
items[].scheme"light" | "dark" | "auto"yesThe color scheme it was drawn in: light, dark, or auto.
items[].bytesintegeryesSize of the stored SVG in bytes.
items[].createdAtintegeryesWhen it was first published, in milliseconds since the epoch.
items[].publishedAtintegeryesWhen it was last published, in milliseconds since the epoch. Publishing the same diagram again moves it.
items[].expiresAtinteger | nullyesWhen it will be deleted, in milliseconds since the epoch, or null when the plan keeps diagrams until you delete them.
items[].lockedbooleanyesTrue while the diagram is locked: it cannot be deleted, renamed or moved until you unlock it. A lock does not stop it expiring on a plan that expires diagrams.
items[].lockedAtinteger | nullyesWhen it was locked, in milliseconds since the epoch, or null when it is not locked.
items[].seriesDiagramSeriesyesIts place in a series (the parts of one split import), or null when it is in none.
items[].series.idstringyesThe series id the parts were published with.
items[].series.indexintegeryesIts place in the series, from 1; 0 is the whole import combined into one diagram.
items[].series.totalinteger | nullyesHow many parts the publisher said the series has, or null.
stableLinksStableLink[]yesEvery stable link the account keeps, by alias, including any whose diagram is gone.
stableLinks[].idstringyesThe handle for managing the stable link (delete). It is not in its address.
stableLinks[].aliasstringyesThe name you gave it. Only you see it.
stableLinks[].urlstringyesThe public address, on the CDN host. It shows the diagram the stable link points at now (cached for up to 60 seconds) and never changes. Anyone with it can see the picture.
stableLinks[].diagramIdstring | nullyesThe diagram it shows now, or null when that diagram was deleted or expired; the address then answers 404 until you point the link at a diagram again.
stableLinks[].createdAtintegeryesWhen it was made, in milliseconds since the epoch.
stableLinks[].updatedAtintegeryesWhen it was last pointed at a diagram, in milliseconds since the epoch.
usageHostingUsageyes
usage.plan"free" | "pro"yesThe plan the account is on, which decides the limits.
usage.countintegeryesHosted diagrams the account holds. This is the total, even when the list is shorter. minimum 0.
usage.bytesintegeryesTotal size of the hosted diagrams in bytes. minimum 0.
usage.stableLinksintegeryesStable links the account keeps. minimum 0.
usage.limitsHostingPlanLimitsyes
usage.limits.dailyCallsintegeryes
usage.limits.hostedDiagramsintegeryes
usage.limits.hostedBytesintegeryes
usage.limits.retentionDaysinteger | nullyesDays a diagram is kept after it was last published, or null to keep it until you delete it.
usage.limits.maxDiagramBytesintegeryes
usage.limits.stableLinksintegeryesStable links the account may keep at once.

HostingUsage

FieldTypeRequiredDescription
plan"free" | "pro"yesThe plan the account is on, which decides the limits.
countintegeryesHosted diagrams the account holds. This is the total, even when the list is shorter. minimum 0.
bytesintegeryesTotal size of the hosted diagrams in bytes. minimum 0.
stableLinksintegeryesStable links the account keeps. minimum 0.
limitsHostingPlanLimitsyes
limits.dailyCallsintegeryes
limits.hostedDiagramsintegeryes
limits.hostedBytesintegeryes
limits.retentionDaysinteger | nullyesDays a diagram is kept after it was last published, or null to keep it until you delete it.
limits.maxDiagramBytesintegeryes
limits.stableLinksintegeryesStable links the account may keep at once.

HostingPlanLimits

FieldTypeRequiredDescription
dailyCallsintegeryes
hostedDiagramsintegeryes
hostedBytesintegeryes
retentionDaysinteger | nullyesDays a diagram is kept after it was last published, or null to keep it until you delete it.
maxDiagramBytesintegeryes
stableLinksintegeryesStable links the account may keep at once.

HostedDiagramSeries

FieldTypeRequiredDescription
itemsHostedDiagram[]yesBy place in the series, then newest first should two share a place.
items[].idstringyesThe handle for managing the diagram (delete). It is not in the link.
items[].urlstringyesThe public address of the SVG. Anyone with the link can see it; the token in it cannot be guessed.
items[].namestring | nullyesThe label given at publish, or null.
items[].folderstring | nullyesThe folder it is filed in, such as Payments/Checkout, or null for the top level.
items[].scheme"light" | "dark" | "auto"yesThe color scheme it was drawn in: light, dark, or auto.
items[].bytesintegeryesSize of the stored SVG in bytes.
items[].createdAtintegeryesWhen it was first published, in milliseconds since the epoch.
items[].publishedAtintegeryesWhen it was last published, in milliseconds since the epoch. Publishing the same diagram again moves it.
items[].expiresAtinteger | nullyesWhen it will be deleted, in milliseconds since the epoch, or null when the plan keeps diagrams until you delete them.
items[].lockedbooleanyesTrue while the diagram is locked: it cannot be deleted, renamed or moved until you unlock it. A lock does not stop it expiring on a plan that expires diagrams.
items[].lockedAtinteger | nullyesWhen it was locked, in milliseconds since the epoch, or null when it is not locked.
items[].seriesDiagramSeriesyesIts place in a series (the parts of one split import), or null when it is in none.
items[].series.idstringyesThe series id the parts were published with.
items[].series.indexintegeryesIts place in the series, from 1; 0 is the whole import combined into one diagram.
items[].series.totalinteger | nullyesHow many parts the publisher said the series has, or null.

CombinedHostedSeries

FieldTypeRequiredDescription
diagramPublishedDiagramyes
diagram.idstringyesThe handle for managing the diagram (delete). It is not in the link.
diagram.urlstringyesThe public address of the SVG. Anyone with the link can see it; the token in it cannot be guessed.
diagram.namestring | nullyesThe label given at publish, or null.
diagram.folderstring | nullyesThe folder it is filed in, such as Payments/Checkout, or null for the top level.
diagram.scheme"light" | "dark" | "auto"yesThe color scheme it was drawn in: light, dark, or auto.
diagram.bytesintegeryesSize of the stored SVG in bytes.
diagram.createdAtintegeryesWhen it was first published, in milliseconds since the epoch.
diagram.publishedAtintegeryesWhen it was last published, in milliseconds since the epoch. Publishing the same diagram again moves it.
diagram.expiresAtinteger | nullyesWhen it will be deleted, in milliseconds since the epoch, or null when the plan keeps diagrams until you delete them.
diagram.lockedbooleanyesTrue while the diagram is locked: it cannot be deleted, renamed or moved until you unlock it. A lock does not stop it expiring on a plan that expires diagrams.
diagram.lockedAtinteger | nullyesWhen it was locked, in milliseconds since the epoch, or null when it is not locked.
diagram.seriesDiagramSeriesyesIts place in a series (the parts of one split import), or null when it is in none.
diagram.series.idstringyesThe series id the parts were published with.
diagram.series.indexintegeryesIts place in the series, from 1; 0 is the whole import combined into one diagram.
diagram.series.totalinteger | nullyesHow many parts the publisher said the series has, or null.
diagram.createdbooleanyesTrue when this call stored a new diagram; false when the same diagram was already hosted and its link was kept.
diagram.stableLinkStableLinknoPresent only when the publish named an alias: the stable link, now pointing at this diagram.
diagram.stableLink.idstringyesThe handle for managing the stable link (delete). It is not in its address.
diagram.stableLink.aliasstringyesThe name you gave it. Only you see it.
diagram.stableLink.urlstringyesThe public address, on the CDN host. It shows the diagram the stable link points at now (cached for up to 60 seconds) and never changes. Anyone with it can see the picture.
diagram.stableLink.diagramIdstring | nullyesThe diagram it shows now, or null when that diagram was deleted or expired; the address then answers 404 until you point the link at a diagram again.
diagram.stableLink.createdAtintegeryesWhen it was made, in milliseconds since the epoch.
diagram.stableLink.updatedAtintegeryesWhen it was last pointed at a diagram, in milliseconds since the epoch.
mergedinteger[]yesThe places of the parts merged, in order.
skippedobject[]yesThe parts left out on purpose.
skipped[].indexintegeryes
skipped[].namestringyes
skipped[].reason"overview" | "combined"yesoverview: a split's overview, whose boxes stand for parts. combined: an earlier combined whole, which this one takes the place of.
linksobjectyesThe arrows between parts.
links.restoredintegeryesArrows a part drew to a dashed box of another part, now ending on the box itself.
links.keptintegeryesArrows that still end on a dashed box naming another part, because that part is not in the series.
notestringyesOne sentence for the person: what was merged and how the arrows between parts were drawn.

MoveDiagramBody

FieldTypeRequiredDescription
folderstring | nullyesThe folder to file the diagram in, or null for the top level. at most 204 characters; pattern ^[A-Za-z0-9_-]+(?: [A-Za-z0-9_-]+)*(?:/[A-Za-z0-9_-]+(?: [A-Za-z0-9_-]+)*){0,4}$.

CreatedDiagram

FieldTypeRequiredDescription

CreateDiagramBody

FieldTypeRequiredDescription
sourcestringyesDiagram source; the first line is the header, such as flow "Title" (draw_diagram lists every kind). at least 1 character; at most 120000 characters.
scheme"light" | "dark" | "auto"noThe color scheme to draw it in: light, dark, or auto. Light when left out.
namestringnoA label for the diagram in your list and in the Markdown snippet. Optional. at least 1 character; at most 80 characters; pattern ^[^\p{Cc}]+$/u.
folderstring | nullnoThe folder to file the diagram in. Left out, a new diagram goes to the top level and a diagram that is already hosted stays where it is. A path files a new diagram there, or moves the one that is already hosted and keeps its link. null puts it at the top level. at most 204 characters; pattern ^[A-Za-z0-9_-]+(?: [A-Za-z0-9_-]+)*(?:/[A-Za-z0-9_-]+(?: [A-Za-z0-9_-]+)*){0,4}$.

EditedDiagram

FieldTypeRequiredDescription
idstringyesThe handle for managing the diagram (delete). It is not in the link.
urlstringyesThe public address of the SVG. Anyone with the link can see it; the token in it cannot be guessed.
namestring | nullyesThe label given at publish, or null.
folderstring | nullyesThe folder it is filed in, such as Payments/Checkout, or null for the top level.
scheme"light" | "dark" | "auto"yesThe color scheme it was drawn in: light, dark, or auto.
bytesintegeryesSize of the stored SVG in bytes.
createdAtintegeryesWhen it was first published, in milliseconds since the epoch.
publishedAtintegeryesWhen it was last published, in milliseconds since the epoch. Publishing the same diagram again moves it.
expiresAtinteger | nullyesWhen it will be deleted, in milliseconds since the epoch, or null when the plan keeps diagrams until you delete them.
lockedbooleanyesTrue while the diagram is locked: it cannot be deleted, renamed or moved until you unlock it. A lock does not stop it expiring on a plan that expires diagrams.
lockedAtinteger | nullyesWhen it was locked, in milliseconds since the epoch, or null when it is not locked.
seriesDiagramSeriesyesIts place in a series (the parts of one split import), or null when it is in none.
series.idstringyesThe series id the parts were published with.
series.indexintegeryesIts place in the series, from 1; 0 is the whole import combined into one diagram.
series.totalinteger | nullyesHow many parts the publisher said the series has, or null.
warningsDiagnostic[]yesQuality warnings from drawing the source, as draw_diagram gives them. Empty for a restore.
warnings[].code"E100" | "E101" | "E110" | "E111" | "E120" | "E121" | "E123" | "E124" | "E125" | "E130" | "E131" | "E132" | "E133" | "E134" | "E135" | "E136" | "E137" | "E138" | "E139" | "E140" | "W200" | "W201" | "W202" | "W203" | "W204" | "W205" | "W206" | "W207" | "W208" | "W209" | "W500" | "W600" | "W601" | "W700" | "W701" | "W702" | "W703" | "W704" | "W705" | "W706" | "W707" | "W708" | "W709" | "W710" | "M100" | "M101" | "M102" | "M103" | "M104" | "M110" | "M200" | "M201" | "M202" | "M203" | "M204" | "M205" | "M206" | "M207" | "M208" | "M209" | "M210" | "M211" | "M212" | "M213" | "M214" | "M215" | "M216" | "M217" | "M218" | "E300" | "E301" | "E302" | "E303" | "E304" | "W300" | "W301" | "W302" | "W303" | "M120" | "M220" | "M221" | "M222" | "E340" | "E341" | "E342" | "E343" | "E344" | "E345" | "W320" | "W321" | "W322" | "W323" | "M240" | "M241" | "M242" | "E360" | "E361" | "E362" | "E363" | "E364" | "E365" | "E366" | "E367" | "W330" | "W331" | "W332" | "W333" | "W334" | "M250" | "M251" | "E400" | "E401" | "E402" | "E403" | "W350" | "W351" | "W352" | "W353" | "M270" | "M271" | "E420" | "E421" | "E422" | "E423" | "E424" | "W360" | "W361" | "W362" | "W363" | "W364" | "M180" | "M280" | "M281" | "M282" | "E320" | "E321" | "E322" | "E323" | "E324" | "E325" | "E326" | "E327" | "E328" | "E329" | "E330" | "W310" | "W311" | "W312" | "W313" | "W314" | "M130" | "M131" | "M132" | "M230" | "M231" | "M232" | "M233" | "M234" | "M235" | "M236" | "M237" | "M238" | "E380" | "E381" | "E382" | "E383" | "W340" | "W341" | "W342" | "W343" | "M260" | "I100" | "I101" | "I102" | "I103" | "I104" | "I105" | "I200" | "I201" | "I202" | "I203" | "I204" | "I206" | "I207" | "R100" | "R101" | "R200" | "R201" | "R202" | "R203" | "R204" | "R205" | "R206" | "R207" | "S100" | "S200" | "S101" | "S102" | "S103" | "S104" | "S201" | "S202" | "S203" | "S204" | "S205"yesStable code to branch on; E-codes are errors, W-codes are warnings.
warnings[].severity"error" | "warning"yesErrors stop rendering; warnings never do.
warnings[].messagestringyesWhat is wrong, in one sentence.
warnings[].lineintegeryes1-based line in the submitted source. minimum 1.
warnings[].columnintegeryes1-based column in that line. minimum 1.
warnings[].lengthintegeryesNumber of characters the problem covers. minimum 1.
warnings[].hintstring | nullyesA concrete suggestion for fixing it, or null.
warnings[].fixobjectnoThe one certain fix, to apply as it is. Present only when exactly one fix is certain.
warnings[].fix.labelstringyesWhat the fix does, in a few words, for a button.
warnings[].fix.editsFixEdit[]yesThe edits, all against the source the diagnostic was found in.
changedbooleanyesFalse when the source draws the picture the diagram already has: nothing was stored and no version was kept.

SaveDiagramSourceBody

FieldTypeRequiredDescription
sourcestringyesDiagram source; the first line is the header, such as flow "Title" (draw_diagram lists every kind). at least 1 character; at most 120000 characters.
scheme"light" | "dark" | "auto"noThe color scheme to draw it in: light, dark, or auto. Left out, the scheme the diagram has.
baseVersionintegeryesThe diagram's publishedAt (milliseconds since the epoch) when the editor loaded it. If the diagram was saved since, the answer is 409 diagram.version_conflict with details.currentVersion. minimum 0.

DiagramVersionList

FieldTypeRequiredDescription
itemsDiagramVersion[]yesNewest first. A diagram keeps at most ten.
items[].idstringyesThe handle for restoring it.
items[].savedAtintegeryesWhen it stopped being the current picture, in milliseconds since the epoch.
items[].bytesintegeryesSize of the stored SVG in bytes. Versions do not count toward the plan.
items[].scheme"light" | "dark" | "auto"yes

DiagramVersion

FieldTypeRequiredDescription
idstringyesThe handle for restoring it.
savedAtintegeryesWhen it stopped being the current picture, in milliseconds since the epoch.
bytesintegeryesSize of the stored SVG in bytes. Versions do not count toward the plan.
scheme"light" | "dark" | "auto"yes

RestoreDiagramVersionBody

FieldTypeRequiredDescription
baseVersionintegeryesThe diagram's publishedAt (milliseconds since the epoch) when the editor loaded it. If the diagram was saved since, the answer is 409 diagram.version_conflict with details.currentVersion. minimum 0.

SetStableLinkBody

FieldTypeRequiredDescription
aliasstringyesThe name of a stable link: lower-case letters and digits in words joined by single hyphens, up to 60 characters. Only you see it; the public address carries a random token instead. at least 1 character; at most 60 characters; pattern ^[a-z0-9]+(?:-[a-z0-9]+)*$.
diagramIdstringyesOne of your hosted diagrams, by its id.

OEmbedPhoto

FieldTypeRequiredDescription
version"1.0"yes
type"photo"yes
provider_namestringyes
provider_urlstringyes
titlestringyesAlways "Diagram": the diagram's own name is shown only to its owner.
urlstringyesThe picture. For a stable link, the stable link itself, so the embed keeps showing the latest version.
widthintegeryes
heightintegeryes
cache_ageintegeryesSeconds the answer may be kept: 60 for a stable link, 3600 for a picture.

Me

FieldTypeRequiredDescription
idstringyes
namestring | nullyes
emailstringnoThe account's address: for a key always, for an app only with the email scope.
organisationobject | nullyesThe organisation the key or the grant is for, or null.
organisation.idstringyes
organisation.slugstringyes
organisation.namestringyes

LibraryPage

FieldTypeRequiredDescription
itemsobject[]yes
items[].idstringyes
items[].namestring | nullyes
items[].folderstring | nullyes
items[].scheme"light" | "dark" | "auto"yesThe color scheme it was drawn in: light, dark, or auto.
items[].bytesintegeryes
items[].updatedAtintegeryesWhen it was last published, in milliseconds since the epoch.
items[].classification"public" | "internal" | "confidential" | nullyesIts label in an organisation's library, or null for a person's own diagram.
nextCursorstring | nullyes

MapIconsResponse

An icon, or candidates, for each name sent, and the names that found no icon.

FieldTypeRequiredDescription
provider"aws" | "gcp" | "azure" | "alibaba" | "oci" | "ibm" | "cloudflare" | "digitalocean" | "vercel" | nullyesThe provider hint that was used, or null.
resultsobject[]yesOne entry per name that matched something, in the order sent.
results[].namestringyesThe name exactly as it was sent.
results[].resolvedbooleanyesTrue when icon holds the one icon to use. False when the name could mean more than one: choose from candidates, or ask the user.
results[].iconstring | nullyesThe icon to write as icon=, such as aws:lambda; null when resolved is false.
results[].confidence"exact" | "strong" | "ambiguous"yesexact: the name is the icon or product name. strong: the name clearly points at this icon and no other provider competes. ambiguous: several icons fit, or the match is by idea only.
results[].alternativesstring[]yesUp to 3 other icons that also fit a resolved name, best first. Empty when none.
results[].candidatesstring[]yesWhen resolved is false, the icons that fit, best first (up to 4). Empty when resolved.
gapsobject[]yesNames that matched nothing, in the order sent.
gaps[].namestringyesThe name that matched no icon.
gaps[].fallbackstringyesA neutral icon to use instead, or leave icon= out so the node type draws its own.
gaps[].reasonstringyesWhy there is no match, and what to try.
resolvedCountintegeryesHow many names have one icon to use.
ambiguousCountintegeryesHow many names need a choice from candidates.
gapCountintegeryesHow many names matched nothing.

MapIconsInput

Names to find icons for, and an optional provider to look in first.

FieldTypeRequiredDescription
namesstring[]yesServices, products, or ideas to find icons for, written as the user wrote them ("S3", "Postgres", "load balancer"). Up to 40 names of up to 80 characters.
provider"aws" | "gcp" | "azure" | "alibaba" | "oci" | "ibm" | "cloudflare" | "digitalocean" | "vercel"noThe cloud the architecture runs on. A name is looked up there first, so "queue" finds aws:sqs for aws. Omit it when the names are not tied to one provider.

IconSearchResponse

Matching bundled icon names.

FieldTypeRequiredDescription
querystringyesThe query that was searched.
itemsstring[]yesMatching icon references as set:name, best match first.

ImportSourceResponse

The result of turning a file of another format into Plotwork source.

FieldTypeRequiredDescription
okbooleanyesTrue when source is valid Plotwork source. False means nothing was imported and source is empty: read diagnostics.
kindstring | nullyesThe kind of diagram the file became, or null when nothing was imported.
formatstringyesThe format the text was read as.
sourcestringyesThe Plotwork source, or an empty string when nothing could be imported.
diagnosticsDiagnostic[]yesEverything left out, changed, or wrong, with a hint. Codes start with I and point into the text you sent: I1xx errors stopped the import, I2xx warnings did not.
diagnostics[].code"E100" | "E101" | "E110" | "E111" | "E120" | "E121" | "E123" | "E124" | "E125" | "E130" | "E131" | "E132" | "E133" | "E134" | "E135" | "E136" | "E137" | "E138" | "E139" | "E140" | "W200" | "W201" | "W202" | "W203" | "W204" | "W205" | "W206" | "W207" | "W208" | "W209" | "W500" | "W600" | "W601" | "W700" | "W701" | "W702" | "W703" | "W704" | "W705" | "W706" | "W707" | "W708" | "W709" | "W710" | "M100" | "M101" | "M102" | "M103" | "M104" | "M110" | "M200" | "M201" | "M202" | "M203" | "M204" | "M205" | "M206" | "M207" | "M208" | "M209" | "M210" | "M211" | "M212" | "M213" | "M214" | "M215" | "M216" | "M217" | "M218" | "E300" | "E301" | "E302" | "E303" | "E304" | "W300" | "W301" | "W302" | "W303" | "M120" | "M220" | "M221" | "M222" | "E340" | "E341" | "E342" | "E343" | "E344" | "E345" | "W320" | "W321" | "W322" | "W323" | "M240" | "M241" | "M242" | "E360" | "E361" | "E362" | "E363" | "E364" | "E365" | "E366" | "E367" | "W330" | "W331" | "W332" | "W333" | "W334" | "M250" | "M251" | "E400" | "E401" | "E402" | "E403" | "W350" | "W351" | "W352" | "W353" | "M270" | "M271" | "E420" | "E421" | "E422" | "E423" | "E424" | "W360" | "W361" | "W362" | "W363" | "W364" | "M180" | "M280" | "M281" | "M282" | "E320" | "E321" | "E322" | "E323" | "E324" | "E325" | "E326" | "E327" | "E328" | "E329" | "E330" | "W310" | "W311" | "W312" | "W313" | "W314" | "M130" | "M131" | "M132" | "M230" | "M231" | "M232" | "M233" | "M234" | "M235" | "M236" | "M237" | "M238" | "E380" | "E381" | "E382" | "E383" | "W340" | "W341" | "W342" | "W343" | "M260" | "I100" | "I101" | "I102" | "I103" | "I104" | "I105" | "I200" | "I201" | "I202" | "I203" | "I204" | "I206" | "I207" | "R100" | "R101" | "R200" | "R201" | "R202" | "R203" | "R204" | "R205" | "R206" | "R207" | "S100" | "S200" | "S101" | "S102" | "S103" | "S104" | "S201" | "S202" | "S203" | "S204" | "S205"yesStable code to branch on; E-codes are errors, W-codes are warnings.
diagnostics[].severity"error" | "warning"yesErrors stop rendering; warnings never do.
diagnostics[].messagestringyesWhat is wrong, in one sentence.
diagnostics[].lineintegeryes1-based line in the submitted source. minimum 1.
diagnostics[].columnintegeryes1-based column in that line. minimum 1.
diagnostics[].lengthintegeryesNumber of characters the problem covers. minimum 1.
diagnostics[].hintstring | nullyesA concrete suggestion for fixing it, or null.
diagnostics[].fixobjectnoThe one certain fix, to apply as it is. Present only when exactly one fix is certain.
diagnostics[].fix.labelstringyesWhat the fix does, in a few words, for a button.
diagnostics[].fix.editsFixEdit[]yesThe edits, all against the source the diagnostic was found in.
statsobjectyes
stats.itemsintegeryesBoxes, tables, rows, slices, places, entries, or commits written.
stats.linksintegeryesArrows, relations, messages, flows, or merges written.
stats.groupsintegeryesFrames, sections, or folders written.
stats.droppedintegeryesThings in the file left out by a cap or because the picture has no place for them; each is in diagnostics.
coverageobject | nullyesHow much of the file the picture shows; null when nothing was imported. When complete is false, the picture is not the whole file: say so.
coverage.nounstringyesWhat was counted, such as resources, services, tables, or endpoints.
coverage.totalintegeryesEverything of that kind in the file.
coverage.drawnintegeryesDrawn as a box, frame, table, row, or entry of its own.
coverage.summarisedintegeryesNot drawn on their own but counted on the box they belong to, such as "3 role assignments".
coverage.omittedintegeryesNot in the picture at all; the diagnostics say which and why.
coverage.completebooleanyesTrue when nothing was omitted.
coverage.linestringyesThe coverage in one sentence, such as "Drawn 12 of 85 resources; 60 are counted on the boxes they belong to and 13 are left out.".
validationobject | nullyesThe Plotwork validator run on source; null when nothing was imported.
validation.validbooleanyesTrue when the source has no Plotwork errors. It always is when ok is true.
validation.errorsDiagnostic[]yesPlotwork errors. Lines and columns point into source.
validation.errors[].code"E100" | "E101" | "E110" | "E111" | "E120" | "E121" | "E123" | "E124" | "E125" | "E130" | "E131" | "E132" | "E133" | "E134" | "E135" | "E136" | "E137" | "E138" | "E139" | "E140" | "W200" | "W201" | "W202" | "W203" | "W204" | "W205" | "W206" | "W207" | "W208" | "W209" | "W500" | "W600" | "W601" | "W700" | "W701" | "W702" | "W703" | "W704" | "W705" | "W706" | "W707" | "W708" | "W709" | "W710" | "M100" | "M101" | "M102" | "M103" | "M104" | "M110" | "M200" | "M201" | "M202" | "M203" | "M204" | "M205" | "M206" | "M207" | "M208" | "M209" | "M210" | "M211" | "M212" | "M213" | "M214" | "M215" | "M216" | "M217" | "M218" | "E300" | "E301" | "E302" | "E303" | "E304" | "W300" | "W301" | "W302" | "W303" | "M120" | "M220" | "M221" | "M222" | "E340" | "E341" | "E342" | "E343" | "E344" | "E345" | "W320" | "W321" | "W322" | "W323" | "M240" | "M241" | "M242" | "E360" | "E361" | "E362" | "E363" | "E364" | "E365" | "E366" | "E367" | "W330" | "W331" | "W332" | "W333" | "W334" | "M250" | "M251" | "E400" | "E401" | "E402" | "E403" | "W350" | "W351" | "W352" | "W353" | "M270" | "M271" | "E420" | "E421" | "E422" | "E423" | "E424" | "W360" | "W361" | "W362" | "W363" | "W364" | "M180" | "M280" | "M281" | "M282" | "E320" | "E321" | "E322" | "E323" | "E324" | "E325" | "E326" | "E327" | "E328" | "E329" | "E330" | "W310" | "W311" | "W312" | "W313" | "W314" | "M130" | "M131" | "M132" | "M230" | "M231" | "M232" | "M233" | "M234" | "M235" | "M236" | "M237" | "M238" | "E380" | "E381" | "E382" | "E383" | "W340" | "W341" | "W342" | "W343" | "M260" | "I100" | "I101" | "I102" | "I103" | "I104" | "I105" | "I200" | "I201" | "I202" | "I203" | "I204" | "I206" | "I207" | "R100" | "R101" | "R200" | "R201" | "R202" | "R203" | "R204" | "R205" | "R206" | "R207" | "S100" | "S200" | "S101" | "S102" | "S103" | "S104" | "S201" | "S202" | "S203" | "S204" | "S205"yesStable code to branch on; E-codes are errors, W-codes are warnings.
validation.errors[].severity"error" | "warning"yesErrors stop rendering; warnings never do.
validation.errors[].messagestringyesWhat is wrong, in one sentence.
validation.errors[].lineintegeryes1-based line in the submitted source. minimum 1.
validation.errors[].columnintegeryes1-based column in that line. minimum 1.
validation.errors[].lengthintegeryesNumber of characters the problem covers. minimum 1.
validation.errors[].hintstring | nullyesA concrete suggestion for fixing it, or null.
validation.errors[].fixobjectnoThe one certain fix, to apply as it is. Present only when exactly one fix is certain.
validation.warningsDiagnostic[]yesPlotwork quality warnings, with the exact fix in each hint. Lines and columns point into source.
validation.warnings[].code"E100" | "E101" | "E110" | "E111" | "E120" | "E121" | "E123" | "E124" | "E125" | "E130" | "E131" | "E132" | "E133" | "E134" | "E135" | "E136" | "E137" | "E138" | "E139" | "E140" | "W200" | "W201" | "W202" | "W203" | "W204" | "W205" | "W206" | "W207" | "W208" | "W209" | "W500" | "W600" | "W601" | "W700" | "W701" | "W702" | "W703" | "W704" | "W705" | "W706" | "W707" | "W708" | "W709" | "W710" | "M100" | "M101" | "M102" | "M103" | "M104" | "M110" | "M200" | "M201" | "M202" | "M203" | "M204" | "M205" | "M206" | "M207" | "M208" | "M209" | "M210" | "M211" | "M212" | "M213" | "M214" | "M215" | "M216" | "M217" | "M218" | "E300" | "E301" | "E302" | "E303" | "E304" | "W300" | "W301" | "W302" | "W303" | "M120" | "M220" | "M221" | "M222" | "E340" | "E341" | "E342" | "E343" | "E344" | "E345" | "W320" | "W321" | "W322" | "W323" | "M240" | "M241" | "M242" | "E360" | "E361" | "E362" | "E363" | "E364" | "E365" | "E366" | "E367" | "W330" | "W331" | "W332" | "W333" | "W334" | "M250" | "M251" | "E400" | "E401" | "E402" | "E403" | "W350" | "W351" | "W352" | "W353" | "M270" | "M271" | "E420" | "E421" | "E422" | "E423" | "E424" | "W360" | "W361" | "W362" | "W363" | "W364" | "M180" | "M280" | "M281" | "M282" | "E320" | "E321" | "E322" | "E323" | "E324" | "E325" | "E326" | "E327" | "E328" | "E329" | "E330" | "W310" | "W311" | "W312" | "W313" | "W314" | "M130" | "M131" | "M132" | "M230" | "M231" | "M232" | "M233" | "M234" | "M235" | "M236" | "M237" | "M238" | "E380" | "E381" | "E382" | "E383" | "W340" | "W341" | "W342" | "W343" | "M260" | "I100" | "I101" | "I102" | "I103" | "I104" | "I105" | "I200" | "I201" | "I202" | "I203" | "I204" | "I206" | "I207" | "R100" | "R101" | "R200" | "R201" | "R202" | "R203" | "R204" | "R205" | "R206" | "R207" | "S100" | "S200" | "S101" | "S102" | "S103" | "S104" | "S201" | "S202" | "S203" | "S204" | "S205"yesStable code to branch on; E-codes are errors, W-codes are warnings.
validation.warnings[].severity"error" | "warning"yesErrors stop rendering; warnings never do.
validation.warnings[].messagestringyesWhat is wrong, in one sentence.
validation.warnings[].lineintegeryes1-based line in the submitted source. minimum 1.
validation.warnings[].columnintegeryes1-based column in that line. minimum 1.
validation.warnings[].lengthintegeryesNumber of characters the problem covers. minimum 1.
validation.warnings[].hintstring | nullyesA concrete suggestion for fixing it, or null.
validation.warnings[].fixobjectnoThe one certain fix, to apply as it is. Present only when exactly one fix is certain.
validation.summarystring | nullyesOne-line description of the diagram, usable as alt text.
validation.sizeobject | nullyesNatural size of the laid-out diagram.
validation.size.widthintegeryesWidth in px. minimum 1.
validation.size.heightintegeryesHeight in px. minimum 1.
partsobject[]yesWhen the file is too big for one readable picture, the diagrams it was split into, in order, at most 24 a page; source is the first diagram of all. Show or draw each of them. Empty when the import is one diagram.
parts[].indexintegeryesIts place among all the parts, from 1. minimum 1.
parts[].titlestringyesWhat this diagram shows, such as one resource group or one tag of an API.
parts[].kindstringyesThe kind of diagram.
parts[].sourcestringyesThe Plotwork source of this diagram; draw it with draw_diagram.
parts[].itemsintegeryesThe boxes, rows, or entries it draws.
parts[].validbooleanyesTrue when the source has no Plotwork errors.
parts[].warningsDiagnostic[]yesPlotwork quality warnings of this diagram. Lines and columns point into its source.
parts[].warnings[].code"E100" | "E101" | "E110" | "E111" | "E120" | "E121" | "E123" | "E124" | "E125" | "E130" | "E131" | "E132" | "E133" | "E134" | "E135" | "E136" | "E137" | "E138" | "E139" | "E140" | "W200" | "W201" | "W202" | "W203" | "W204" | "W205" | "W206" | "W207" | "W208" | "W209" | "W500" | "W600" | "W601" | "W700" | "W701" | "W702" | "W703" | "W704" | "W705" | "W706" | "W707" | "W708" | "W709" | "W710" | "M100" | "M101" | "M102" | "M103" | "M104" | "M110" | "M200" | "M201" | "M202" | "M203" | "M204" | "M205" | "M206" | "M207" | "M208" | "M209" | "M210" | "M211" | "M212" | "M213" | "M214" | "M215" | "M216" | "M217" | "M218" | "E300" | "E301" | "E302" | "E303" | "E304" | "W300" | "W301" | "W302" | "W303" | "M120" | "M220" | "M221" | "M222" | "E340" | "E341" | "E342" | "E343" | "E344" | "E345" | "W320" | "W321" | "W322" | "W323" | "M240" | "M241" | "M242" | "E360" | "E361" | "E362" | "E363" | "E364" | "E365" | "E366" | "E367" | "W330" | "W331" | "W332" | "W333" | "W334" | "M250" | "M251" | "E400" | "E401" | "E402" | "E403" | "W350" | "W351" | "W352" | "W353" | "M270" | "M271" | "E420" | "E421" | "E422" | "E423" | "E424" | "W360" | "W361" | "W362" | "W363" | "W364" | "M180" | "M280" | "M281" | "M282" | "E320" | "E321" | "E322" | "E323" | "E324" | "E325" | "E326" | "E327" | "E328" | "E329" | "E330" | "W310" | "W311" | "W312" | "W313" | "W314" | "M130" | "M131" | "M132" | "M230" | "M231" | "M232" | "M233" | "M234" | "M235" | "M236" | "M237" | "M238" | "E380" | "E381" | "E382" | "E383" | "W340" | "W341" | "W342" | "W343" | "M260" | "I100" | "I101" | "I102" | "I103" | "I104" | "I105" | "I200" | "I201" | "I202" | "I203" | "I204" | "I206" | "I207" | "R100" | "R101" | "R200" | "R201" | "R202" | "R203" | "R204" | "R205" | "R206" | "R207" | "S100" | "S200" | "S101" | "S102" | "S103" | "S104" | "S201" | "S202" | "S203" | "S204" | "S205"yesStable code to branch on; E-codes are errors, W-codes are warnings.
parts[].warnings[].severity"error" | "warning"yesErrors stop rendering; warnings never do.
parts[].warnings[].messagestringyesWhat is wrong, in one sentence.
parts[].warnings[].lineintegeryes1-based line in the submitted source. minimum 1.
parts[].warnings[].columnintegeryes1-based column in that line. minimum 1.
parts[].warnings[].lengthintegeryesNumber of characters the problem covers. minimum 1.
parts[].warnings[].hintstring | nullyesA concrete suggestion for fixing it, or null.
parts[].warnings[].fixobjectnoThe one certain fix, to apply as it is. Present only when exactly one fix is certain.
partsTotalintegeryesHow many diagrams the import was split into in all; 0 when it is one diagram.
partsPageintegeryesThe page of parts this answer holds, from 1.
partsPagesintegeryesHow many pages of parts there are; call again with partsPage for the next one.
seriesobject | nullyesFor a split import, publish_diagram's series for every part, with the part's index. Null for one diagram.
series.idstringyes
series.totalintegeryes
combinedobject | nullyesA split import as one diagram, every arrow kept; publish at series index 0.
combined.titlestringyes
combined.sourcestringyes
outlinestring[]yesThe diagram as plain text, to check it says what the file says; empty when nothing was imported.
outlineTruncatedbooleanyesTrue when the outline was cut short at its summary length.
viewUrlstringnoA link that shows a valid diagram in a browser; give it to the person who wants to look. It holds the drawing itself: the source is in the part after #, never sent to a server, so nothing is saved on Plotwork and it appears in no Diagrams list; anyone with the link can read it. Absent when too long; next says so.
pngUrlstringnoThe viewUrl with &download=png: opening it in a browser saves the diagram as a PNG for Slack, email, or a wiki. The PNG is drawn in the person's browser, not on a server, so it is a link to open, not an image address to embed. Absent when too long.
svgUrlstringnoThe viewUrl with &download=svg: a person opens it to download the SVG. Not a file address for curl; use saveCommand. Absent when too long.
saveCommandstringnoRun in a shell to save the SVG into the repository: the CLI decodes the link locally, fetches nothing, and embeds the source. Set --out to the path; add --scheme dark for dark. Absent when too long.
nextstringyesThe next step in one sentence.

ImportSourceInput

A file of another format to turn into Plotwork source.

FieldTypeRequiredDescription
format"sql" | "prisma" | "drizzle" | "openapi" | "graphql" | "protobuf" | "terraform" | "terraform-plan" | "bicep" | "arm" | "pulumi" | "cloudformation" | "cdk" | "serverless" | "compose" | "dockerfile" | "kubernetes" | "helm" | "kustomize" | "nginx" | "backstage" | "structurizr" | "asyncapi" | "github-actions" | "gitlab-ci" | "azure-pipelines" | "dbt" | "workspaces" | "drawio" | "csv" | "json" | "tree" | "git-log"yesWhat the text is; get_diagram_syntax with topic import-formats describes each.
textstringnoThe file content, as text. Send text or files, not both.
filesobject[]noThe files of a folder, for a format that spans files; the others read the first.
files[].pathstringyesThe file path, such as infra/network.tf; diagnostics name it. at least 1 character; at most 300 characters.
files[].textstringyesThe file content, as text.
titlestringnoThe diagram title; taken from the file when left out. at most 200 characters.
partsPageintegernoPage of parts, 24 a page. minimum 1; maximum 100000.
large"parts" | "whole" | "both"noToo big for one picture: parts, whole, or both.
optionsobjectnodefault {}.
options.view"endpoints" | "map" | "sequence" | "git" | "timeline" | "context" | "container" | "component"noThe picture of a format drawn several ways.
options.operationIdstringnoopenapi sequence: the operation. at most 200 characters.
options.chart"auto" | "xychart" | "pie" | "sankey" | "treemap" | "matrix"nocsv, json: the chart; auto picks.
options.tablesstring[]noTables to draw, by name or prefix*.
options.pathsstring[]noopenapi: path prefixes to read.
options.tagsstring[]noopenapi: tags to read.
options.varFilesstring[]noVariables files to apply.
options.groupBy"module" | "network" | "file" | "owner"noHow things are framed; module is the default.
options.rootstringnoThe root, stack, template, or draw.io page of several to draw. at most 300 characters.
options.icons"auto" | "off"nooff: no icons, as settings with icons off.

RunTaskAck

FieldTypeRequiredDescription
outcome"verified" | "accepted"yesverified: the address check HCP Terraform makes when the run task is created. accepted: a run, which is drawn and reported back after this answer.

SyncMarkdownResponse

The result of turning a document's diagram fences into pictures.

FieldTypeRequiredDescription
mode"sync" | "check"yesThe mode that ran.
markdownstringyesThe document to write back: every diagram fence wrapped in its collapsed source section, with the picture block and text description under it, and everything else unchanged. In check mode this is the document that was sent.
changedbooleanyesTrue when the document or a file differs from what was sent. In check mode this says the pictures are stale or a fence would convert.
filesobject[]yesThe SVG files to write for each picture that was refreshed (one, or light and dark with schemes light-and-dark), with paths relative to the repository root. Empty in check mode. A picture that was already current has no files.
files[].pathstringyesWhere to write the file, relative to the repository root.
files[].contentstringnoThe file contents; absent when files is none.
files[].encoding"utf8"yesHow content is encoded. Always utf8: the files are SVG text.
files[].bytesintegernoOnly when files is none: the size of the file in bytes.
files[].sha256stringnoOnly when files is none: the SHA-256 of the content, in hex, to check a file fetched later.
files[].viewUrlstringnoOnly when files is none: a link that shows this diagram in a browser.
reportobject[]yesOne entry per fence handled, in document order.
report[].idstring | nullyesThe picture id, which names the SVG files; null for a fence that has none (a mermaid fence that was not converted).
report[].source"diagram" | "mermaid"yesdiagram for a fence that was already Plotwork, mermaid for one that came from Mermaid.
report[].kindstring | nullyesThe diagram kind, or null when it could not be read.
report[].lineintegeryesThe 1-based line of the opening fence in the document that was sent. minimum 1.
report[].status"synced" | "converted" | "unchanged" | "skipped" | "failed"yessynced: the picture was written or refreshed. converted: a mermaid fence became a diagram fence and was drawn. unchanged: the picture was already current. skipped: a cap stopped it, see message. failed: it has errors, the fence is left as it was.
report[].diagnosticsDiagnostic[]yesErrors and warnings, with line numbers counted in the document that was sent. For a converted fence they point at the Mermaid lines.
report[].diagnostics[].code"E100" | "E101" | "E110" | "E111" | "E120" | "E121" | "E123" | "E124" | "E125" | "E130" | "E131" | "E132" | "E133" | "E134" | "E135" | "E136" | "E137" | "E138" | "E139" | "E140" | "W200" | "W201" | "W202" | "W203" | "W204" | "W205" | "W206" | "W207" | "W208" | "W209" | "W500" | "W600" | "W601" | "W700" | "W701" | "W702" | "W703" | "W704" | "W705" | "W706" | "W707" | "W708" | "W709" | "W710" | "M100" | "M101" | "M102" | "M103" | "M104" | "M110" | "M200" | "M201" | "M202" | "M203" | "M204" | "M205" | "M206" | "M207" | "M208" | "M209" | "M210" | "M211" | "M212" | "M213" | "M214" | "M215" | "M216" | "M217" | "M218" | "E300" | "E301" | "E302" | "E303" | "E304" | "W300" | "W301" | "W302" | "W303" | "M120" | "M220" | "M221" | "M222" | "E340" | "E341" | "E342" | "E343" | "E344" | "E345" | "W320" | "W321" | "W322" | "W323" | "M240" | "M241" | "M242" | "E360" | "E361" | "E362" | "E363" | "E364" | "E365" | "E366" | "E367" | "W330" | "W331" | "W332" | "W333" | "W334" | "M250" | "M251" | "E400" | "E401" | "E402" | "E403" | "W350" | "W351" | "W352" | "W353" | "M270" | "M271" | "E420" | "E421" | "E422" | "E423" | "E424" | "W360" | "W361" | "W362" | "W363" | "W364" | "M180" | "M280" | "M281" | "M282" | "E320" | "E321" | "E322" | "E323" | "E324" | "E325" | "E326" | "E327" | "E328" | "E329" | "E330" | "W310" | "W311" | "W312" | "W313" | "W314" | "M130" | "M131" | "M132" | "M230" | "M231" | "M232" | "M233" | "M234" | "M235" | "M236" | "M237" | "M238" | "E380" | "E381" | "E382" | "E383" | "W340" | "W341" | "W342" | "W343" | "M260" | "I100" | "I101" | "I102" | "I103" | "I104" | "I105" | "I200" | "I201" | "I202" | "I203" | "I204" | "I206" | "I207" | "R100" | "R101" | "R200" | "R201" | "R202" | "R203" | "R204" | "R205" | "R206" | "R207" | "S100" | "S200" | "S101" | "S102" | "S103" | "S104" | "S201" | "S202" | "S203" | "S204" | "S205"yesStable code to branch on; E-codes are errors, W-codes are warnings.
report[].diagnostics[].severity"error" | "warning"yesErrors stop rendering; warnings never do.
report[].diagnostics[].messagestringyesWhat is wrong, in one sentence.
report[].diagnostics[].lineintegeryes1-based line in the submitted source. minimum 1.
report[].diagnostics[].columnintegeryes1-based column in that line. minimum 1.
report[].diagnostics[].lengthintegeryesNumber of characters the problem covers. minimum 1.
report[].diagnostics[].hintstring | nullyesA concrete suggestion for fixing it, or null.
report[].diagnostics[].fixobjectnoThe one certain fix, to apply as it is. Present only when exactly one fix is certain.
report[].messagestring | nullyesA plain sentence when something needs saying, such as why a fence was skipped; otherwise null.
summaryobjectyes
summary.diagramsintegeryesFences handled: synced, converted, unchanged, skipped, and failed together.
summary.syncedintegeryes
summary.convertedintegeryes
summary.unchangedintegeryes
summary.skippedintegeryes
summary.failedintegeryes
summary.mermaidIgnoredintegeryesMermaid fences left alone because convertMermaid was false.
summary.filesintegeryesFiles to write.
summary.outputBytesintegeryesBytes in the returned document and files together.
capsobjectyes
caps.hitbooleanyesTrue when a cap stopped some of the work. Nothing is cut silently: see messages.
caps.messagesstring[]yesOne plain sentence per cap that was hit, saying what was skipped and what to do.
caps.maxDiagramsintegeryesMost fences handled in one call.
caps.maxOutputBytesintegeryesMost bytes in the returned document and files together.
pagesobjectnoPresent when page or pageSize was sent: which pictures files holds, and the next page.
pages.pageintegeryes
pages.pageSizeintegeryes
pages.pagesintegeryesPages in all.
pages.picturesintegeryesPictures in all, each one file or a light and a dark one.
pages.nextPageinteger | nullyesThe page to ask for next, or null on the last one.
nextstringyesThe next step in one sentence.

SyncMarkdownInput

A Markdown document and how to turn its diagram fences into pictures.

FieldTypeRequiredDescription
markdownstringyesThe whole Markdown document, exactly as it is on disk, with its line endings. Up to 10000000 characters. at least 1 character; at most 10000000 characters.
documentPathstringyesWhere the document lives, relative to the repository root, with forward slashes, for example docs/guide.md. Picture links and file paths are worked out from it. at least 1 character; at most 300 characters.
assetsDirstringnoThe directory for the SVG files, relative to the repository root. The default is assets/diagrams next to the document. at least 1 character; at most 300 characters.
prefixstringnoText put in front of every picture file name, for documents that share one assets directory. By default a titled diagram is named from its title and an untitled one from the document name. at least 1 character; at most 32 characters.
convertMermaidbooleannoWhen true, every mermaid fence that can be converted is replaced by a diagram fence first, then drawn. Fences that cannot be converted are left exactly as they were and reported. default false.
mode"sync" | "check"nosync (the default) returns the rewritten document and the files to write. check changes nothing: it only reports whether a picture is stale or a fence would convert. default "sync".
files"inline" | "none"noinline (the default) returns each SVG file with its content. none returns each with path, bytes, sha256, and viewUrl instead, so the answer stays small. default "inline".
pageintegernoWhich page of files to return, from 1; pictures are paged in document order, a light and a dark file together. minimum 1.
pageSizeintegernoPictures per page, at most 30. Setting page or pageSize turns paging on. minimum 1; maximum 30.
settingsobjectnoThe repo's plotwork.config.json, if any. Schema: https://docs.plotwork.dev/schemas/plotwork.config.json (opens in a new tab).

PlanDocumentResponse

The sections of a document a picture would help, each with a kind, a reason, and a starter.

FieldTypeRequiredDescription
summarystringyesOne sentence: how many sections were read and how many would gain a picture.
format"markdown" | "html" | "text"yesHow the document was read: Markdown headings, HTML h1 to h6, or plain text with heading-like lines.
sectionsReadintegeryesSections read, up to the cap.
suggestionsobject[]yesIn document order. Sections that read well as text, or already have a diagram, are not listed.
suggestions[].headingstringyesThe heading of the section, as written.
suggestions[].lineintegeryesThe 1-based line of the heading in the document that was sent. minimum 1.
suggestions[].kindstringyesA diagram kind: flow, sequence, schema, git, gantt, class, state, timeline, journey, mindmap, treemap, pie, quadrant, layers, c4, matrix, sankey, xychart, tree, swimlane, requirement, block, packet, kanban, radar, usecase, venn, fishbone, or wardley today. Later versions add kinds, so expect others.
suggestions[].stylestring | nullyesThe style the starter uses: compare, score, raci, or risk for a matrix, files or org for a tree; null for the kind's only style.
suggestions[].whystringyesOne sentence: what in the section points to this kind.
suggestions[].confidence"high" | "medium" | "low"yeshigh: the text names this kind of picture or its shape fits it exactly. medium: it leans toward it. low: a fallback worth considering.
suggestions[].starterstringyesA short Plotwork source of this kind that parses without errors: built from the names and numbers in the text where it could find them, otherwise a small example to edit. Replace every placeholder before you draw it.
suggestions[].tailoredbooleanyesTrue when the starter uses names or numbers from the text; false when it is the kind's small example.
capsobjectyes
caps.hitbooleanyesTrue when a cap left something out; messages says what.
caps.messagesstring[]yes
caps.maxSectionsintegeryes
caps.maxSuggestionsintegeryes
nextstringyesThe next step in one sentence.

PlanDocumentInput

A document to read for the sections a picture would help.

FieldTypeRequiredDescription
documentstringyesThe whole document: Markdown, plain text pasted from Confluence, Notion, or Google Docs, or HTML. Up to 10000000 characters. at least 1 character; at most 10000000 characters.
maxSuggestionsintegernoMost sections to suggest a picture for, up to 12. The strongest are kept, in document order. The default is 8. minimum 1; maximum 12; default 8.

AuthorizationServerMetadata

FieldTypeRequiredDescription
issuerstringyes
authorization_endpointstringyes
token_endpointstringyes
revocation_endpointstringyes
response_types_supportedstring[]yes
grant_types_supportedstring[]yes
code_challenge_methods_supportedstring[]yes
token_endpoint_auth_methods_supportedstring[]yes
revocation_endpoint_auth_methods_supportedstring[]yes
scopes_supportedstring[]yes
authorization_response_iss_parameter_supportedbooleanyes
service_documentationstringyes

TokenAnswer

FieldTypeRequiredDescription
access_tokenstringyespwa_... Send it as Authorization: Bearer. Works for an hour.
token_type"Bearer"yes
expires_inintegeryes
refresh_tokenstringyespwr_... Works once, for 30 days; a refresh answers a new one.
scopestringyes

OAuthError

FieldTypeRequiredDescription
error"invalid_request" | "invalid_client" | "invalid_grant" | "unauthorized_client" | "unsupported_grant_type" | "invalid_scope"yes
error_descriptionstringyes

TokenForm

FieldTypeRequiredDescription
grant_typestringyesauthorization_code or refresh_token.
codestringno
redirect_uristringno
code_verifierstringno
refresh_tokenstringno
scopestringno
client_idstringnoRequired unless sent with HTTP Basic.
client_secretstringnoA confidential app sends its secret here or with HTTP Basic.

RevokeForm

FieldTypeRequiredDescription
tokenstringnoThe access or refresh token to revoke. Required.
token_type_hintstringnoaccess_token or refresh_token. Optional; the token is found either way.
client_idstringno
client_secretstringno

OrganisationList

FieldTypeRequiredDescription
itemsOrganisation[]yesBy name, at most 100.
items[].idstringyes
items[].slugstringyes
items[].namestringyes
items[].role"owner" | "admin" | "member" | "reader"yesWhat the caller is in this organisation.
items[].createdAtintegeryesMilliseconds since the epoch.
items[].memberCountintegeryesPeople who have joined, the owner included. The same number as usage.members. minimum 0.
items[].plan"free" | "pro" | "enterprise"yesThe organisation's plan: enterprise under a contract, otherwise its owner's.
items[].contractEndsOnstring | nullyesThe last day of the Enterprise contract, YYYY-MM-DD, or null when there is none or it has no end date written. The terms of a contract are not shown to members.
items[].usageOrganisationUsageyes
items[].usage.diagramsintegeryesminimum 0.
items[].usage.bytesintegeryesminimum 0.
items[].usage.membersintegeryesPeople who have joined, the owner included. minimum 0.
items[].usage.invitesintegeryesInvitations that can still be accepted. They count toward the member limit. minimum 0.
items[].limitsOrganisationLimitsyes
items[].limits.dailyCallsintegeryes
items[].limits.hostedDiagramsintegeryesDiagrams the organisation may hold.
items[].limits.hostedBytesintegeryesTotal bytes of diagrams the organisation may hold.
items[].limits.retentionDaysinteger | nullyesDays a diagram is kept after it was last published, or null to keep it until it is deleted.
items[].limits.maxDiagramBytesintegeryes
items[].limits.stableLinksintegeryesStable links the owner may keep for their own diagrams. An organisation's diagrams have none.
items[].limits.organisationsintegeryesOrganisations an account on this plan may own.
items[].limits.orgMembersintegeryesPeople one organisation may have, the owner included and pending invitations counted.
items[].limits.orgIconsintegeryesCustom icons one organisation may keep; zero on a plan without custom icons. minimum 0.
items[].limits.driftHistoryDaysintegeryesDays the drift dashboard keeps a run and a status after it was reported; zero on a plan without the dashboard. minimum 0.
items[].limits.auditRetentionDaysintegeryesDays the organisation's audit log keeps an event; zero on a plan that records none. minimum 0.
items[].limits.boardsintegeryesLive whiteboards the organisation may keep; zero on a plan without them. minimum 0.
items[].limits.boardTabsintegeryesTabs one whiteboard may have. minimum 0.
items[].limits.boardParticipantsintegeryesPeople on one whiteboard at once. minimum 0.
items[].limits.boardHistoryDaysintegeryesDays a whiteboard keeps the history of its changes. minimum 0.
items[].limits.boardSessionMinutesintegeryesMinutes one live connection to a whiteboard lasts before it asks whether the person is still there. minimum 0.
items[].limits.boardIdleMinutesintegeryesMinutes with no input before a whiteboard pauses its live connection. minimum 0.
items[].limits.boardDailyAwakeMinutesintegeryesMinutes the organisation's whiteboards may be live in one UTC day. minimum 0.
items[].limits.boardRevisionsintegeryesOpen revisions one tab of a whiteboard may have. minimum 0.
items[].avatarOrgAvataryesThe organisation's uploaded avatar, or null when it has none and a mark made from its id stands in.
items[].avatar.versionstringyesChanges with every upload. Put it in the address (?v=) so a new picture is a new address.
items[].avatar.contentType"image/svg+xml" | "image/png" | "image/gif" | "image/webp"yes
items[].avatar.animatedbooleanyesTrue when it moves, so a page can hold it still for a person who asked for less motion.
items[].keepEditablebooleanyesThe owner's setting "Keep diagrams editable": true when a publish to the organisation that does not send embedSource writes the diagram source into the picture, so members can edit it in the portal later. Every member can open such a picture and read its source.
items[].publishingOrganisationPublishingyes
items[].publishing.policy"personal" | "organisation-default" | "organisation-required"yesWhat the owner or an admin chose: personal (members publish where they choose), organisation-default (a member's publish that names no organisation goes to this library), or organisation-required (nothing a member publishes reaches a public link).
items[].publishing.effective"personal" | "organisation-default" | "organisation-required"yesWhat is enforced now: the choice, except organisation-required on a plan that no longer includes it, which acts as organisation-default.
items[].publishing.hideViewLinksbooleanyesWhether hosted answers leave view links out for members and the organisation's keys. Honoured only while effective is organisation-required.
items[].publishing.requiredAvailablebooleanyesWhether the organisation's plan includes organisation-required (Pro and Enterprise).
items[].sharingOrganisationSharingyes
items[].sharing.publicSharingbooleanyes"Allow public sharing of individual diagrams": while true, the owner and admins may share any diagram, and a member a diagram they published, at a public link. Off by default. Turning it off ends every link.
items[].sharing.sharedCountintegeryesHow many of the organisation's diagrams have a public link now. Counted against the plan's stableLinks. minimum 0.
items[].sharing.autoPublishbooleanyes"Agents publish every diagram they draw": while true, every valid drawing made through one of the organisation's agent connections or keys is stored in its private library with its source. Off by default.
items[].sharing.embedLinksbooleanyes"Allow diagrams on chosen websites" (Enterprise): while true, a diagram may have embed links that show it only on the websites they name. Off by default. Turning it off ends every embed link.
items[].sharing.embedLinkCountintegeryesHow many embed links the organisation has now. minimum 0.
items[].governanceOrganisationGovernanceyes
items[].governance.availablebooleanyesWhether the organisation's plan includes the policies (Enterprise). A choice saved before is kept, and is not applied without it.
items[].governance.retentionOrganisationRetentionyes
items[].governance.legalHoldobject | nullyesThe legal hold, or null when it is off. While it is on nothing of the organisation is deleted: no sweep, no member, and not the organisation itself.
items[].governance.patternsOnlybooleanyes"Agents start from approved patterns": find_pattern, called through the organisation's connections and keys, answers with its own patterns only.
items[].governance.styleRulesStrictbooleanyes"Style rules are errors": a publish to the library that breaks a saved style rule is refused with the findings.
items[].classificationOrganisationClassificationSummaryyes
items[].classification.defaultClassificationyesA diagram's classification label: public, internal (the default, and what a diagram published before labels reads as) or confidential. Confidential is never shared publicly; under "Share only diagrams labelled Public" only public is.
items[].classification.sharePublicOnlybooleanyes"Share only diagrams labelled Public": while true, only a diagram labelled public may have a public link. The owner's setting.
items[].approvalOrganisationApprovalSummaryyes
items[].approval.publish"off" | "folders" | "all"yes"Publishing needs approval": off, folders (the chosen folders and every folder inside them) or all.
items[].approval.sharebooleanyes"Public sharing needs approval".
items[].approval.approverbooleanyesTrue when the caller decides requests: the owner, an admin, or a member chosen as an approver.
items[].approval.pendinginteger | nullyesHow many requests wait for a decision, for an approver; null for anyone else. minimum 0.
items[].agentsOrganisationAgentsyes
items[].agents.approvedOnlybooleanyes"Only approved agents can connect": while true, an agent connects to the organisation only when it is on the approved list.
items[].agents.approvedstring[]yesThe approved agents by label, such as "Claude Code". Empty while approvedOnly is false. What identifies each is on GET /orgs/{org}/policies/agents, for the owner and admins.
items[].agents.orgOnlybooleanyes"Agents connect to this organisation", as applied: a member on a verified domain connects agents to the organisation, not to their own account. False on a plan without single sign-on.
items[].logAccessbooleanyesWhether the caller may read the audit log and the call history: the owner and admins, or a role or person the owner let in (PUT /orgs/{org}/log-access).
items[].boardsEnabledbooleanyesWhether live whiteboards are on for the organisation: its plan has them and Plotwork turned them on. The Boards section shows only then.

Organisation

FieldTypeRequiredDescription
idstringyes
slugstringyes
namestringyes
role"owner" | "admin" | "member" | "reader"yesWhat the caller is in this organisation.
createdAtintegeryesMilliseconds since the epoch.
memberCountintegeryesPeople who have joined, the owner included. The same number as usage.members. minimum 0.
plan"free" | "pro" | "enterprise"yesThe organisation's plan: enterprise under a contract, otherwise its owner's.
contractEndsOnstring | nullyesThe last day of the Enterprise contract, YYYY-MM-DD, or null when there is none or it has no end date written. The terms of a contract are not shown to members.
usageOrganisationUsageyes
usage.diagramsintegeryesminimum 0.
usage.bytesintegeryesminimum 0.
usage.membersintegeryesPeople who have joined, the owner included. minimum 0.
usage.invitesintegeryesInvitations that can still be accepted. They count toward the member limit. minimum 0.
limitsOrganisationLimitsyes
limits.dailyCallsintegeryes
limits.hostedDiagramsintegeryesDiagrams the organisation may hold.
limits.hostedBytesintegeryesTotal bytes of diagrams the organisation may hold.
limits.retentionDaysinteger | nullyesDays a diagram is kept after it was last published, or null to keep it until it is deleted.
limits.maxDiagramBytesintegeryes
limits.stableLinksintegeryesStable links the owner may keep for their own diagrams. An organisation's diagrams have none.
limits.organisationsintegeryesOrganisations an account on this plan may own.
limits.orgMembersintegeryesPeople one organisation may have, the owner included and pending invitations counted.
limits.orgIconsintegeryesCustom icons one organisation may keep; zero on a plan without custom icons. minimum 0.
limits.driftHistoryDaysintegeryesDays the drift dashboard keeps a run and a status after it was reported; zero on a plan without the dashboard. minimum 0.
limits.auditRetentionDaysintegeryesDays the organisation's audit log keeps an event; zero on a plan that records none. minimum 0.
limits.boardsintegeryesLive whiteboards the organisation may keep; zero on a plan without them. minimum 0.
limits.boardTabsintegeryesTabs one whiteboard may have. minimum 0.
limits.boardParticipantsintegeryesPeople on one whiteboard at once. minimum 0.
limits.boardHistoryDaysintegeryesDays a whiteboard keeps the history of its changes. minimum 0.
limits.boardSessionMinutesintegeryesMinutes one live connection to a whiteboard lasts before it asks whether the person is still there. minimum 0.
limits.boardIdleMinutesintegeryesMinutes with no input before a whiteboard pauses its live connection. minimum 0.
limits.boardDailyAwakeMinutesintegeryesMinutes the organisation's whiteboards may be live in one UTC day. minimum 0.
limits.boardRevisionsintegeryesOpen revisions one tab of a whiteboard may have. minimum 0.
avatarOrgAvataryesThe organisation's uploaded avatar, or null when it has none and a mark made from its id stands in.
avatar.versionstringyesChanges with every upload. Put it in the address (?v=) so a new picture is a new address.
avatar.contentType"image/svg+xml" | "image/png" | "image/gif" | "image/webp"yes
avatar.animatedbooleanyesTrue when it moves, so a page can hold it still for a person who asked for less motion.
keepEditablebooleanyesThe owner's setting "Keep diagrams editable": true when a publish to the organisation that does not send embedSource writes the diagram source into the picture, so members can edit it in the portal later. Every member can open such a picture and read its source.
publishingOrganisationPublishingyes
publishing.policy"personal" | "organisation-default" | "organisation-required"yesWhat the owner or an admin chose: personal (members publish where they choose), organisation-default (a member's publish that names no organisation goes to this library), or organisation-required (nothing a member publishes reaches a public link).
publishing.effective"personal" | "organisation-default" | "organisation-required"yesWhat is enforced now: the choice, except organisation-required on a plan that no longer includes it, which acts as organisation-default.
publishing.hideViewLinksbooleanyesWhether hosted answers leave view links out for members and the organisation's keys. Honoured only while effective is organisation-required.
publishing.requiredAvailablebooleanyesWhether the organisation's plan includes organisation-required (Pro and Enterprise).
sharingOrganisationSharingyes
sharing.publicSharingbooleanyes"Allow public sharing of individual diagrams": while true, the owner and admins may share any diagram, and a member a diagram they published, at a public link. Off by default. Turning it off ends every link.
sharing.sharedCountintegeryesHow many of the organisation's diagrams have a public link now. Counted against the plan's stableLinks. minimum 0.
sharing.autoPublishbooleanyes"Agents publish every diagram they draw": while true, every valid drawing made through one of the organisation's agent connections or keys is stored in its private library with its source. Off by default.
sharing.embedLinksbooleanyes"Allow diagrams on chosen websites" (Enterprise): while true, a diagram may have embed links that show it only on the websites they name. Off by default. Turning it off ends every embed link.
sharing.embedLinkCountintegeryesHow many embed links the organisation has now. minimum 0.
governanceOrganisationGovernanceyes
governance.availablebooleanyesWhether the organisation's plan includes the policies (Enterprise). A choice saved before is kept, and is not applied without it.
governance.retentionOrganisationRetentionyes
governance.retention.libraryDays90yes"Delete library diagrams not updated for": 90, 180, 365 or 730 days, or null for never (the default).
governance.retention.auditDays365yes"Keep the audit log for": 365, 730 or 2555 days (one, two or seven years), or null for the plan's days (the default). It only lengthens.
governance.retention.planLibraryDaysinteger | nullyesHow long the plan keeps a diagram after its last publish, or null for until it is deleted. The plan's limit wins when it is shorter.
governance.retention.planAuditDaysintegeryesHow many days the plan keeps an audit event.
governance.retention.effectiveLibraryDaysinteger | nullyesWhat is applied: the shorter of planLibraryDays and libraryDays. Null when diagrams are kept until they are deleted.
governance.retention.effectiveAuditDaysintegeryesWhat is applied: the longer of planAuditDays and auditDays, auditDays counted up to auditMaxDays.
governance.retention.auditMaxDaysintegeryesThe longest auditDays this server takes: 730 unless its database is on D1's paid tier, then 2555. Every organisation shares one database.
governance.legalHoldobject | nullyesThe legal hold, or null when it is off. While it is on nothing of the organisation is deleted: no sweep, no member, and not the organisation itself.
governance.legalHold.sinceintegeryesWhen the owner turned it on, in milliseconds since the epoch.
governance.legalHold.reasonstring | nullyesThe reason the owner typed. Shown to the owner and admins; null for anyone else.
governance.patternsOnlybooleanyes"Agents start from approved patterns": find_pattern, called through the organisation's connections and keys, answers with its own patterns only.
governance.styleRulesStrictbooleanyes"Style rules are errors": a publish to the library that breaks a saved style rule is refused with the findings.
classificationOrganisationClassificationSummaryyes
classification.defaultClassificationyesA diagram's classification label: public, internal (the default, and what a diagram published before labels reads as) or confidential. Confidential is never shared publicly; under "Share only diagrams labelled Public" only public is.
classification.sharePublicOnlybooleanyes"Share only diagrams labelled Public": while true, only a diagram labelled public may have a public link. The owner's setting.
approvalOrganisationApprovalSummaryyes
approval.publish"off" | "folders" | "all"yes"Publishing needs approval": off, folders (the chosen folders and every folder inside them) or all.
approval.sharebooleanyes"Public sharing needs approval".
approval.approverbooleanyesTrue when the caller decides requests: the owner, an admin, or a member chosen as an approver.
approval.pendinginteger | nullyesHow many requests wait for a decision, for an approver; null for anyone else. minimum 0.
agentsOrganisationAgentsyes
agents.approvedOnlybooleanyes"Only approved agents can connect": while true, an agent connects to the organisation only when it is on the approved list.
agents.approvedstring[]yesThe approved agents by label, such as "Claude Code". Empty while approvedOnly is false. What identifies each is on GET /orgs/{org}/policies/agents, for the owner and admins.
agents.orgOnlybooleanyes"Agents connect to this organisation", as applied: a member on a verified domain connects agents to the organisation, not to their own account. False on a plan without single sign-on.
logAccessbooleanyesWhether the caller may read the audit log and the call history: the owner and admins, or a role or person the owner let in (PUT /orgs/{org}/log-access).
boardsEnabledbooleanyesWhether live whiteboards are on for the organisation: its plan has them and Plotwork turned them on. The Boards section shows only then.

OrganisationUsage

FieldTypeRequiredDescription
diagramsintegeryesminimum 0.
bytesintegeryesminimum 0.
membersintegeryesPeople who have joined, the owner included. minimum 0.
invitesintegeryesInvitations that can still be accepted. They count toward the member limit. minimum 0.

OrganisationLimits

FieldTypeRequiredDescription
dailyCallsintegeryes
hostedDiagramsintegeryesDiagrams the organisation may hold.
hostedBytesintegeryesTotal bytes of diagrams the organisation may hold.
retentionDaysinteger | nullyesDays a diagram is kept after it was last published, or null to keep it until it is deleted.
maxDiagramBytesintegeryes
stableLinksintegeryesStable links the owner may keep for their own diagrams. An organisation's diagrams have none.
organisationsintegeryesOrganisations an account on this plan may own.
orgMembersintegeryesPeople one organisation may have, the owner included and pending invitations counted.
orgIconsintegeryesCustom icons one organisation may keep; zero on a plan without custom icons. minimum 0.
driftHistoryDaysintegeryesDays the drift dashboard keeps a run and a status after it was reported; zero on a plan without the dashboard. minimum 0.
auditRetentionDaysintegeryesDays the organisation's audit log keeps an event; zero on a plan that records none. minimum 0.
boardsintegeryesLive whiteboards the organisation may keep; zero on a plan without them. minimum 0.
boardTabsintegeryesTabs one whiteboard may have. minimum 0.
boardParticipantsintegeryesPeople on one whiteboard at once. minimum 0.
boardHistoryDaysintegeryesDays a whiteboard keeps the history of its changes. minimum 0.
boardSessionMinutesintegeryesMinutes one live connection to a whiteboard lasts before it asks whether the person is still there. minimum 0.
boardIdleMinutesintegeryesMinutes with no input before a whiteboard pauses its live connection. minimum 0.
boardDailyAwakeMinutesintegeryesMinutes the organisation's whiteboards may be live in one UTC day. minimum 0.
boardRevisionsintegeryesOpen revisions one tab of a whiteboard may have. minimum 0.

OrgAvatar

The organisation's uploaded avatar, or null when it has none and a mark made from its id stands in.

FieldTypeRequiredDescription
versionstringyesChanges with every upload. Put it in the address (?v=) so a new picture is a new address.
contentType"image/svg+xml" | "image/png" | "image/gif" | "image/webp"yes
animatedbooleanyesTrue when it moves, so a page can hold it still for a person who asked for less motion.

OrganisationPublishing

FieldTypeRequiredDescription
policy"personal" | "organisation-default" | "organisation-required"yesWhat the owner or an admin chose: personal (members publish where they choose), organisation-default (a member's publish that names no organisation goes to this library), or organisation-required (nothing a member publishes reaches a public link).
effective"personal" | "organisation-default" | "organisation-required"yesWhat is enforced now: the choice, except organisation-required on a plan that no longer includes it, which acts as organisation-default.
hideViewLinksbooleanyesWhether hosted answers leave view links out for members and the organisation's keys. Honoured only while effective is organisation-required.
requiredAvailablebooleanyesWhether the organisation's plan includes organisation-required (Pro and Enterprise).

OrganisationSharing

FieldTypeRequiredDescription
publicSharingbooleanyes"Allow public sharing of individual diagrams": while true, the owner and admins may share any diagram, and a member a diagram they published, at a public link. Off by default. Turning it off ends every link.
sharedCountintegeryesHow many of the organisation's diagrams have a public link now. Counted against the plan's stableLinks. minimum 0.
autoPublishbooleanyes"Agents publish every diagram they draw": while true, every valid drawing made through one of the organisation's agent connections or keys is stored in its private library with its source. Off by default.
embedLinksbooleanyes"Allow diagrams on chosen websites" (Enterprise): while true, a diagram may have embed links that show it only on the websites they name. Off by default. Turning it off ends every embed link.
embedLinkCountintegeryesHow many embed links the organisation has now. minimum 0.

OrganisationGovernance

FieldTypeRequiredDescription
availablebooleanyesWhether the organisation's plan includes the policies (Enterprise). A choice saved before is kept, and is not applied without it.
retentionOrganisationRetentionyes
retention.libraryDays90yes"Delete library diagrams not updated for": 90, 180, 365 or 730 days, or null for never (the default).
retention.auditDays365yes"Keep the audit log for": 365, 730 or 2555 days (one, two or seven years), or null for the plan's days (the default). It only lengthens.
retention.planLibraryDaysinteger | nullyesHow long the plan keeps a diagram after its last publish, or null for until it is deleted. The plan's limit wins when it is shorter.
retention.planAuditDaysintegeryesHow many days the plan keeps an audit event.
retention.effectiveLibraryDaysinteger | nullyesWhat is applied: the shorter of planLibraryDays and libraryDays. Null when diagrams are kept until they are deleted.
retention.effectiveAuditDaysintegeryesWhat is applied: the longer of planAuditDays and auditDays, auditDays counted up to auditMaxDays.
retention.auditMaxDaysintegeryesThe longest auditDays this server takes: 730 unless its database is on D1's paid tier, then 2555. Every organisation shares one database.
legalHoldobject | nullyesThe legal hold, or null when it is off. While it is on nothing of the organisation is deleted: no sweep, no member, and not the organisation itself.
legalHold.sinceintegeryesWhen the owner turned it on, in milliseconds since the epoch.
legalHold.reasonstring | nullyesThe reason the owner typed. Shown to the owner and admins; null for anyone else.
patternsOnlybooleanyes"Agents start from approved patterns": find_pattern, called through the organisation's connections and keys, answers with its own patterns only.
styleRulesStrictbooleanyes"Style rules are errors": a publish to the library that breaks a saved style rule is refused with the findings.

OrganisationRetention

FieldTypeRequiredDescription
libraryDays90yes"Delete library diagrams not updated for": 90, 180, 365 or 730 days, or null for never (the default).
auditDays365yes"Keep the audit log for": 365, 730 or 2555 days (one, two or seven years), or null for the plan's days (the default). It only lengthens.
planLibraryDaysinteger | nullyesHow long the plan keeps a diagram after its last publish, or null for until it is deleted. The plan's limit wins when it is shorter.
planAuditDaysintegeryesHow many days the plan keeps an audit event.
effectiveLibraryDaysinteger | nullyesWhat is applied: the shorter of planLibraryDays and libraryDays. Null when diagrams are kept until they are deleted.
effectiveAuditDaysintegeryesWhat is applied: the longer of planAuditDays and auditDays, auditDays counted up to auditMaxDays.
auditMaxDaysintegeryesThe longest auditDays this server takes: 730 unless its database is on D1's paid tier, then 2555. Every organisation shares one database.

OrganisationClassificationSummary

FieldTypeRequiredDescription
defaultClassificationyesA diagram's classification label: public, internal (the default, and what a diagram published before labels reads as) or confidential. Confidential is never shared publicly; under "Share only diagrams labelled Public" only public is.
sharePublicOnlybooleanyes"Share only diagrams labelled Public": while true, only a diagram labelled public may have a public link. The owner's setting.

OrganisationApprovalSummary

FieldTypeRequiredDescription
publish"off" | "folders" | "all"yes"Publishing needs approval": off, folders (the chosen folders and every folder inside them) or all.
sharebooleanyes"Public sharing needs approval".
approverbooleanyesTrue when the caller decides requests: the owner, an admin, or a member chosen as an approver.
pendinginteger | nullyesHow many requests wait for a decision, for an approver; null for anyone else. minimum 0.

OrganisationAgents

FieldTypeRequiredDescription
approvedOnlybooleanyes"Only approved agents can connect": while true, an agent connects to the organisation only when it is on the approved list.
approvedstring[]yesThe approved agents by label, such as "Claude Code". Empty while approvedOnly is false. What identifies each is on GET /orgs/{org}/policies/agents, for the owner and admins.
orgOnlybooleanyes"Agents connect to this organisation", as applied: a member on a verified domain connects agents to the organisation, not to their own account. False on a plan without single sign-on.

CreateOrganisationBody

FieldTypeRequiredDescription
namestringyesWhat people read. 1 to 60 characters. It can be changed; the slug cannot. at least 1 character; pattern ^[^\p{Cc}]+$/u.
slugstringnoThe handle. Left out, it is made from the name, with a short suffix when that is taken. at least 3 characters; at most 40 characters; pattern ^[a-z0-9][a-z0-9-]*[a-z0-9]$.

RenameOrganisationBody

FieldTypeRequiredDescription
namestringyesWhat people read. 1 to 60 characters. It can be changed; the slug cannot. at least 1 character; pattern ^[^\p{Cc}]+$/u.

OrganisationMemberList

FieldTypeRequiredDescription
itemsOrganisationMember[]yes
items[].userIdstringyes
items[].emailstringyesShown to every member: a team knows who is in it.
items[].namestring | nullyesThe name the person chose to be shown by, or null for none.
items[].role"owner" | "admin" | "member" | "reader"yes
items[].joinedAtintegeryesMilliseconds since the epoch.

OrganisationMember

FieldTypeRequiredDescription
userIdstringyes
emailstringyesShown to every member: a team knows who is in it.
namestring | nullyesThe name the person chose to be shown by, or null for none.
role"owner" | "admin" | "member" | "reader"yes
joinedAtintegeryesMilliseconds since the epoch.

ChangeMemberRoleBody

FieldTypeRequiredDescription
role"admin" | "member" | "reader"yesadmin, member or reader. An admin can invite and remove members and readers, rename the organisation and manage its keys; a member can publish and change their own diagrams; a reader can view and download and change nothing. Only the owner offers admin or changes a role.

OrganisationInviteList

FieldTypeRequiredDescription
itemsOrganisationInvite[]yes
items[].idstringyes
items[].emailstringyes
items[].role"admin" | "member" | "reader"yes
items[].createdAtintegeryesMilliseconds since the epoch.
items[].expiresAtintegeryesMilliseconds since the epoch. Seven days after it was made.

OrganisationInvite

FieldTypeRequiredDescription
idstringyes
emailstringyes
role"admin" | "member" | "reader"yes
createdAtintegeryesMilliseconds since the epoch.
expiresAtintegeryesMilliseconds since the epoch. Seven days after it was made.

CreateInviteBody

FieldTypeRequiredDescription
emailstringyesThe address to invite. The person must sign in with this address to accept. at least 3 characters; at most 254 characters.
role"admin" | "member" | "reader"yesadmin, member or reader. An admin can invite and remove members and readers, rename the organisation and manage its keys; a member can publish and change their own diagrams; a reader can view and download and change nothing. Only the owner offers admin or changes a role.

AcceptInviteBody

FieldTypeRequiredDescription
tokenstringyesThe token in the invitation link. at least 1 character; at most 200 characters.

OrganisationDiagramSeries

FieldTypeRequiredDescription
itemsOrganisationDiagram[]yesBy place in the series, then newest first should two share a place.
items[].idstringyesThe handle for the diagram in the routes below.
items[].namestring | nullyesThe label given at publish, or null.
items[].folderstring | nullyesThe folder it is filed in, such as Payments/Checkout, or null for the top level.
items[].scheme"light" | "dark" | "auto"yesThe color scheme it was drawn in: light, dark, or auto.
items[].bytesintegeryesSize of the stored SVG in bytes.
items[].createdBystring | nullyesThe person it belongs to: the member who published it, or the person who connected the agent that did. Null when that account has left or an organisation key published it.
items[].publishedVia"person" | "connection" | "key" | nullyesHow it was published: person (signed in, or with a key the person made), connection (an agent connected to the organisation, whose person is createdBy), or key (an organisation key from Keys and CI). Null for a diagram published before this was recorded.
items[].publishedKeyobject | nullyesThe key behind a connection or an organisation key. Null for a person, and once the key no longer exists.
items[].publishedKey.idstringyesThe key's id, as Keys and CI lists it. Never the key itself.
items[].publishedKey.namestring | nullyesThe key's name, or null once the key is revoked.
items[].publishedClientstring | nullyesThe client name the agent gave when it connected, such as Claude Code, for a connection only. at most 100 characters.
items[].createdAtintegeryesWhen it was first published, in milliseconds since the epoch.
items[].publishedAtintegeryesWhen it was last published, in milliseconds since the epoch. Publishing the same diagram again moves it.
items[].expiresAtinteger | nullyesWhen it will be deleted, in milliseconds since the epoch, or null when the owner's plan keeps diagrams until they are deleted.
items[].viewUrlstringyesA page in the portal that shows the diagram to a signed-in member. It is not a link anyone can open: an organisation's diagrams have no public address.
items[].lockedbooleanyesTrue while the owner has the diagram locked: nobody can delete, rename or move it, its publisher and the owner included, until the owner unlocks it. A lock does not stop it expiring on a plan that expires diagrams.
items[].lockedAtinteger | nullyesWhen the owner locked it, in milliseconds since the epoch, or null when it is not locked.
items[].restrictedtruenoPresent, and true, when the owner has restricted this diagram's folder and the caller is allowed in it, so the portal can show it as locked. Absent otherwise. A diagram in a folder the caller may not use is not listed at all.
items[].keepInsidetruenoPresent, and true, when the folder rule over this diagram keeps its diagrams inside: the svg route refuses ?download=1 and the copy route refuses a copy (403 orgs.folder_restricted). Absent otherwise.
items[].shareOrganisationDiagramShareyesIts public link while the organisation shares it, or null. Only a diagram someone chose to share has one.
items[].share.urlstringyesThe public address, {CDN_URL}/l/<token>.svg. Anyone with it can see the picture, without its source. It keeps showing the latest version when the diagram is edited, and never changes.
items[].share.sharedAtintegeryesWhen the diagram was first shared, in milliseconds since the epoch.
items[].keptbooleanyes"Keep": true when an owner or admin keeps it from the library retention. The plan's own retention still applies.
items[].deletesAtinteger | nullyesWhen the retention deletes it, in milliseconds since the epoch: the nearer of the plan's expiry and "Delete library diagrams not updated for". Null when nothing will, and always null under a legal hold.
items[].classificationClassificationyesA diagram's classification label: public, internal (the default, and what a diagram published before labels reads as) or confidential. Confidential is never shared publicly; under "Share only diagrams labelled Public" only public is.
items[].pendingbooleanyesTrue while it is held for approval ("Publishing needs approval"): only its publisher and the approvers see it.
items[].changePendingbooleanyesTrue while a new version of it waits for approval. The library shows this version until then.
items[].seriesDiagramSeriesyesIts place in a series (the parts of one split import), or null when it is in none.
items[].series.idstringyesThe series id the parts were published with.
items[].series.indexintegeryesIts place in the series, from 1; 0 is the whole import combined into one diagram.
items[].series.totalinteger | nullyesHow many parts the publisher said the series has, or null.

OrganisationDiagramList

FieldTypeRequiredDescription
itemsOrganisationDiagram[]yesAt most 200, newest published first.
items[].idstringyesThe handle for the diagram in the routes below.
items[].namestring | nullyesThe label given at publish, or null.
items[].folderstring | nullyesThe folder it is filed in, such as Payments/Checkout, or null for the top level.
items[].scheme"light" | "dark" | "auto"yesThe color scheme it was drawn in: light, dark, or auto.
items[].bytesintegeryesSize of the stored SVG in bytes.
items[].createdBystring | nullyesThe person it belongs to: the member who published it, or the person who connected the agent that did. Null when that account has left or an organisation key published it.
items[].publishedVia"person" | "connection" | "key" | nullyesHow it was published: person (signed in, or with a key the person made), connection (an agent connected to the organisation, whose person is createdBy), or key (an organisation key from Keys and CI). Null for a diagram published before this was recorded.
items[].publishedKeyobject | nullyesThe key behind a connection or an organisation key. Null for a person, and once the key no longer exists.
items[].publishedKey.idstringyesThe key's id, as Keys and CI lists it. Never the key itself.
items[].publishedKey.namestring | nullyesThe key's name, or null once the key is revoked.
items[].publishedClientstring | nullyesThe client name the agent gave when it connected, such as Claude Code, for a connection only. at most 100 characters.
items[].createdAtintegeryesWhen it was first published, in milliseconds since the epoch.
items[].publishedAtintegeryesWhen it was last published, in milliseconds since the epoch. Publishing the same diagram again moves it.
items[].expiresAtinteger | nullyesWhen it will be deleted, in milliseconds since the epoch, or null when the owner's plan keeps diagrams until they are deleted.
items[].viewUrlstringyesA page in the portal that shows the diagram to a signed-in member. It is not a link anyone can open: an organisation's diagrams have no public address.
items[].lockedbooleanyesTrue while the owner has the diagram locked: nobody can delete, rename or move it, its publisher and the owner included, until the owner unlocks it. A lock does not stop it expiring on a plan that expires diagrams.
items[].lockedAtinteger | nullyesWhen the owner locked it, in milliseconds since the epoch, or null when it is not locked.
items[].restrictedtruenoPresent, and true, when the owner has restricted this diagram's folder and the caller is allowed in it, so the portal can show it as locked. Absent otherwise. A diagram in a folder the caller may not use is not listed at all.
items[].keepInsidetruenoPresent, and true, when the folder rule over this diagram keeps its diagrams inside: the svg route refuses ?download=1 and the copy route refuses a copy (403 orgs.folder_restricted). Absent otherwise.
items[].shareOrganisationDiagramShareyesIts public link while the organisation shares it, or null. Only a diagram someone chose to share has one.
items[].share.urlstringyesThe public address, {CDN_URL}/l/<token>.svg. Anyone with it can see the picture, without its source. It keeps showing the latest version when the diagram is edited, and never changes.
items[].share.sharedAtintegeryesWhen the diagram was first shared, in milliseconds since the epoch.
items[].keptbooleanyes"Keep": true when an owner or admin keeps it from the library retention. The plan's own retention still applies.
items[].deletesAtinteger | nullyesWhen the retention deletes it, in milliseconds since the epoch: the nearer of the plan's expiry and "Delete library diagrams not updated for". Null when nothing will, and always null under a legal hold.
items[].classificationClassificationyesA diagram's classification label: public, internal (the default, and what a diagram published before labels reads as) or confidential. Confidential is never shared publicly; under "Share only diagrams labelled Public" only public is.
items[].pendingbooleanyesTrue while it is held for approval ("Publishing needs approval"): only its publisher and the approvers see it.
items[].changePendingbooleanyesTrue while a new version of it waits for approval. The library shows this version until then.
items[].seriesDiagramSeriesyesIts place in a series (the parts of one split import), or null when it is in none.
items[].series.idstringyesThe series id the parts were published with.
items[].series.indexintegeryesIts place in the series, from 1; 0 is the whole import combined into one diagram.
items[].series.totalinteger | nullyesHow many parts the publisher said the series has, or null.
usageOrganisationHostingUsageyes
usage.plan"free" | "pro" | "enterprise"yes
usage.countintegeryesDiagrams the organisation holds. This is the total, even when the list is shorter. minimum 0.
usage.bytesintegeryesminimum 0.
usage.limitsOrganisationLimitsyes
usage.limits.dailyCallsintegeryes
usage.limits.hostedDiagramsintegeryesDiagrams the organisation may hold.
usage.limits.hostedBytesintegeryesTotal bytes of diagrams the organisation may hold.
usage.limits.retentionDaysinteger | nullyesDays a diagram is kept after it was last published, or null to keep it until it is deleted.
usage.limits.maxDiagramBytesintegeryes
usage.limits.stableLinksintegeryesStable links the owner may keep for their own diagrams. An organisation's diagrams have none.
usage.limits.organisationsintegeryesOrganisations an account on this plan may own.
usage.limits.orgMembersintegeryesPeople one organisation may have, the owner included and pending invitations counted.
usage.limits.orgIconsintegeryesCustom icons one organisation may keep; zero on a plan without custom icons. minimum 0.
usage.limits.driftHistoryDaysintegeryesDays the drift dashboard keeps a run and a status after it was reported; zero on a plan without the dashboard. minimum 0.
usage.limits.auditRetentionDaysintegeryesDays the organisation's audit log keeps an event; zero on a plan that records none. minimum 0.
usage.limits.boardsintegeryesLive whiteboards the organisation may keep; zero on a plan without them. minimum 0.
usage.limits.boardTabsintegeryesTabs one whiteboard may have. minimum 0.
usage.limits.boardParticipantsintegeryesPeople on one whiteboard at once. minimum 0.
usage.limits.boardHistoryDaysintegeryesDays a whiteboard keeps the history of its changes. minimum 0.
usage.limits.boardSessionMinutesintegeryesMinutes one live connection to a whiteboard lasts before it asks whether the person is still there. minimum 0.
usage.limits.boardIdleMinutesintegeryesMinutes with no input before a whiteboard pauses its live connection. minimum 0.
usage.limits.boardDailyAwakeMinutesintegeryesMinutes the organisation's whiteboards may be live in one UTC day. minimum 0.
usage.limits.boardRevisionsintegeryesOpen revisions one tab of a whiteboard may have. minimum 0.

OrganisationHostingUsage

FieldTypeRequiredDescription
plan"free" | "pro" | "enterprise"yes
countintegeryesDiagrams the organisation holds. This is the total, even when the list is shorter. minimum 0.
bytesintegeryesminimum 0.
limitsOrganisationLimitsyes
limits.dailyCallsintegeryes
limits.hostedDiagramsintegeryesDiagrams the organisation may hold.
limits.hostedBytesintegeryesTotal bytes of diagrams the organisation may hold.
limits.retentionDaysinteger | nullyesDays a diagram is kept after it was last published, or null to keep it until it is deleted.
limits.maxDiagramBytesintegeryes
limits.stableLinksintegeryesStable links the owner may keep for their own diagrams. An organisation's diagrams have none.
limits.organisationsintegeryesOrganisations an account on this plan may own.
limits.orgMembersintegeryesPeople one organisation may have, the owner included and pending invitations counted.
limits.orgIconsintegeryesCustom icons one organisation may keep; zero on a plan without custom icons. minimum 0.
limits.driftHistoryDaysintegeryesDays the drift dashboard keeps a run and a status after it was reported; zero on a plan without the dashboard. minimum 0.
limits.auditRetentionDaysintegeryesDays the organisation's audit log keeps an event; zero on a plan that records none. minimum 0.
limits.boardsintegeryesLive whiteboards the organisation may keep; zero on a plan without them. minimum 0.
limits.boardTabsintegeryesTabs one whiteboard may have. minimum 0.
limits.boardParticipantsintegeryesPeople on one whiteboard at once. minimum 0.
limits.boardHistoryDaysintegeryesDays a whiteboard keeps the history of its changes. minimum 0.
limits.boardSessionMinutesintegeryesMinutes one live connection to a whiteboard lasts before it asks whether the person is still there. minimum 0.
limits.boardIdleMinutesintegeryesMinutes with no input before a whiteboard pauses its live connection. minimum 0.
limits.boardDailyAwakeMinutesintegeryesMinutes the organisation's whiteboards may be live in one UTC day. minimum 0.
limits.boardRevisionsintegeryesOpen revisions one tab of a whiteboard may have. minimum 0.

PublishOrganisationDiagramBody

FieldTypeRequiredDescription
sourcestringyesDiagram source; the first line is the header, such as flow "Title" (draw_diagram lists every kind). at least 1 character; at most 120000 characters.
settingsobjectnoThe repo's plotwork.config.json, if any. Schema: https://docs.plotwork.dev/schemas/plotwork.config.json (opens in a new tab).
scheme"light" | "dark" | "auto"noThe color scheme to draw it in: light, dark, or auto (one picture that follows the viewer's light or dark setting). Light when left out.
theme"light" | "dark" | "auto"noThe old name of scheme, still taken from callers that send it: light, dark, or auto. Send scheme instead; refused when both are sent and differ.
embedSourcebooleannoWrite the diagram source into the stored SVG, in its metadata, so the diagram can be edited later; every member who can open it can then read the source. The same diagram published with and without it is two pictures. Left out, the organisation's keepEditable setting decides (on unless the owner turned it off); false always leaves the source out.
namestringnoA label for the diagram in your list and in the Markdown snippet. Optional. at least 1 character; at most 80 characters; pattern ^[^\p{Cc}]+$/u.
folderstring | nullnoThe folder to file the diagram in. Left out, a new diagram goes to the top level and a diagram that is already hosted stays where it is. A path files a new diagram there, or moves the one that is already hosted and keeps its link. null puts it at the top level. at most 204 characters; pattern ^[A-Za-z0-9_-]+(?: [A-Za-z0-9_-]+)*(?:/[A-Za-z0-9_-]+(?: [A-Za-z0-9_-]+)*){0,4}$.
classificationanyno
seriesSeriesInputnoPublish the diagram as one part of a series: the parts of one big import, such as an overview and one diagram per group, each published with the same id and its place, the overview first. The portal shows a series as tabs of one diagram and can open it on one board. A part published at a place another diagram of the series holds takes the place. Left out, a diagram's series is left as it is. Optional.
series.idstringyesThe series id, the same for every part: letters, digits, - and _, up to 64 characters. It names nothing outside your library or the organisation's. at least 1 character; at most 64 characters; pattern ^[A-Za-z0-9_-]+$.
series.indexintegeryesThe part's place in the series, from 1 (the overview); 0 is the whole import combined into one diagram, at most one a series. minimum 0; maximum 1000.
series.totalintegernoHow many parts the series has. Optional. minimum 1; maximum 1000.

UpdateOrganisationDiagramBody

FieldTypeRequiredDescription
folderstring | nullnoThe folder to file the diagram in, or null for the top level. at most 204 characters; pattern ^[A-Za-z0-9_-]+(?: [A-Za-z0-9_-]+)*(?:/[A-Za-z0-9_-]+(?: [A-Za-z0-9_-]+)*){0,4}$.
namestring | nullnoA new label, or null to clear it. at least 1 character; at most 80 characters; pattern ^[^\p{Cc}]+$/u.

CopyOrganisationDiagramBody

FieldTypeRequiredDescription
folderstring | nullyesThe folder to file the copy in, or null for the top level. at most 204 characters; pattern ^[A-Za-z0-9_-]+(?: [A-Za-z0-9_-]+)*(?:/[A-Za-z0-9_-]+(?: [A-Za-z0-9_-]+)*){0,4}$.

CombinedOrganisationSeries

FieldTypeRequiredDescription
diagramPublishedOrganisationDiagramyes
diagram.idstringyesThe handle for the diagram in the routes below.
diagram.namestring | nullyesThe label given at publish, or null.
diagram.folderstring | nullyesThe folder it is filed in, such as Payments/Checkout, or null for the top level.
diagram.scheme"light" | "dark" | "auto"yesThe color scheme it was drawn in: light, dark, or auto.
diagram.bytesintegeryesSize of the stored SVG in bytes.
diagram.createdBystring | nullyesThe person it belongs to: the member who published it, or the person who connected the agent that did. Null when that account has left or an organisation key published it.
diagram.publishedVia"person" | "connection" | "key" | nullyesHow it was published: person (signed in, or with a key the person made), connection (an agent connected to the organisation, whose person is createdBy), or key (an organisation key from Keys and CI). Null for a diagram published before this was recorded.
diagram.publishedKeyobject | nullyesThe key behind a connection or an organisation key. Null for a person, and once the key no longer exists.
diagram.publishedKey.idstringyesThe key's id, as Keys and CI lists it. Never the key itself.
diagram.publishedKey.namestring | nullyesThe key's name, or null once the key is revoked.
diagram.publishedClientstring | nullyesThe client name the agent gave when it connected, such as Claude Code, for a connection only. at most 100 characters.
diagram.createdAtintegeryesWhen it was first published, in milliseconds since the epoch.
diagram.publishedAtintegeryesWhen it was last published, in milliseconds since the epoch. Publishing the same diagram again moves it.
diagram.expiresAtinteger | nullyesWhen it will be deleted, in milliseconds since the epoch, or null when the owner's plan keeps diagrams until they are deleted.
diagram.viewUrlstringyesA page in the portal that shows the diagram to a signed-in member. It is not a link anyone can open: an organisation's diagrams have no public address.
diagram.lockedbooleanyesTrue while the owner has the diagram locked: nobody can delete, rename or move it, its publisher and the owner included, until the owner unlocks it. A lock does not stop it expiring on a plan that expires diagrams.
diagram.lockedAtinteger | nullyesWhen the owner locked it, in milliseconds since the epoch, or null when it is not locked.
diagram.restrictedtruenoPresent, and true, when the owner has restricted this diagram's folder and the caller is allowed in it, so the portal can show it as locked. Absent otherwise. A diagram in a folder the caller may not use is not listed at all.
diagram.keepInsidetruenoPresent, and true, when the folder rule over this diagram keeps its diagrams inside: the svg route refuses ?download=1 and the copy route refuses a copy (403 orgs.folder_restricted). Absent otherwise.
diagram.shareOrganisationDiagramShareyesIts public link while the organisation shares it, or null. Only a diagram someone chose to share has one.
diagram.share.urlstringyesThe public address, {CDN_URL}/l/<token>.svg. Anyone with it can see the picture, without its source. It keeps showing the latest version when the diagram is edited, and never changes.
diagram.share.sharedAtintegeryesWhen the diagram was first shared, in milliseconds since the epoch.
diagram.keptbooleanyes"Keep": true when an owner or admin keeps it from the library retention. The plan's own retention still applies.
diagram.deletesAtinteger | nullyesWhen the retention deletes it, in milliseconds since the epoch: the nearer of the plan's expiry and "Delete library diagrams not updated for". Null when nothing will, and always null under a legal hold.
diagram.classificationClassificationyesA diagram's classification label: public, internal (the default, and what a diagram published before labels reads as) or confidential. Confidential is never shared publicly; under "Share only diagrams labelled Public" only public is.
diagram.pendingbooleanyesTrue while it is held for approval ("Publishing needs approval"): only its publisher and the approvers see it.
diagram.changePendingbooleanyesTrue while a new version of it waits for approval. The library shows this version until then.
diagram.seriesDiagramSeriesyesIts place in a series (the parts of one split import), or null when it is in none.
diagram.series.idstringyesThe series id the parts were published with.
diagram.series.indexintegeryesIts place in the series, from 1; 0 is the whole import combined into one diagram.
diagram.series.totalinteger | nullyesHow many parts the publisher said the series has, or null.
diagram.createdbooleanyesTrue when this call stored a new diagram; false when the same diagram was already in the library and was kept.
diagram.sourceEmbeddedbooleanyesTrue when the stored picture carries the diagram source: the call sent embedSource true, or left it out while the organisation's keepEditable is on.
diagram.approvalApprovalHoldnoPresent when the organisation's "Publishing needs approval" or "Public sharing needs approval" held this. It is data, not an error: the diagram is stored, and only its publisher and the approvers can see it until an approver approves.
diagram.approval.state"pending"yes
diagram.approval.requestIdstringyesThe request, as the Approvals queue lists it.
diagram.approval.kind"publish" | "change" | "share"yespublish (a new diagram), change (a new version of one the library shows) or share (a public link).
diagram.approval.expiresAtintegeryesWhen the daily sweep ends the request if nobody decides it, in milliseconds since the epoch: thirty days after it was made.
diagram.approval.messagestringyesOne sentence to tell the person: held for approval by the organisation, and what happens next.
diagram.approval.codestringyesThe warning code a tool answer carries for it: W601.
mergedinteger[]yesThe places of the parts merged, in order.
skippedobject[]yesThe parts left out on purpose.
skipped[].indexintegeryes
skipped[].namestringyes
skipped[].reason"overview" | "combined"yesoverview: a split's overview, whose boxes stand for parts. combined: an earlier combined whole, which this one takes the place of.
linksobjectyesThe arrows between parts.
links.restoredintegeryesArrows a part drew to a dashed box of another part, now ending on the box itself.
links.keptintegeryesArrows that still end on a dashed box naming another part, because that part is not in the series.
notestringyesOne sentence for the person: what was merged and how the arrows between parts were drawn.

EditedOrganisationDiagram

FieldTypeRequiredDescription
idstringyesThe handle for the diagram in the routes below.
namestring | nullyesThe label given at publish, or null.
folderstring | nullyesThe folder it is filed in, such as Payments/Checkout, or null for the top level.
scheme"light" | "dark" | "auto"yesThe color scheme it was drawn in: light, dark, or auto.
bytesintegeryesSize of the stored SVG in bytes.
createdBystring | nullyesThe person it belongs to: the member who published it, or the person who connected the agent that did. Null when that account has left or an organisation key published it.
publishedVia"person" | "connection" | "key" | nullyesHow it was published: person (signed in, or with a key the person made), connection (an agent connected to the organisation, whose person is createdBy), or key (an organisation key from Keys and CI). Null for a diagram published before this was recorded.
publishedKeyobject | nullyesThe key behind a connection or an organisation key. Null for a person, and once the key no longer exists.
publishedKey.idstringyesThe key's id, as Keys and CI lists it. Never the key itself.
publishedKey.namestring | nullyesThe key's name, or null once the key is revoked.
publishedClientstring | nullyesThe client name the agent gave when it connected, such as Claude Code, for a connection only. at most 100 characters.
createdAtintegeryesWhen it was first published, in milliseconds since the epoch.
publishedAtintegeryesWhen it was last published, in milliseconds since the epoch. Publishing the same diagram again moves it.
expiresAtinteger | nullyesWhen it will be deleted, in milliseconds since the epoch, or null when the owner's plan keeps diagrams until they are deleted.
viewUrlstringyesA page in the portal that shows the diagram to a signed-in member. It is not a link anyone can open: an organisation's diagrams have no public address.
lockedbooleanyesTrue while the owner has the diagram locked: nobody can delete, rename or move it, its publisher and the owner included, until the owner unlocks it. A lock does not stop it expiring on a plan that expires diagrams.
lockedAtinteger | nullyesWhen the owner locked it, in milliseconds since the epoch, or null when it is not locked.
restrictedtruenoPresent, and true, when the owner has restricted this diagram's folder and the caller is allowed in it, so the portal can show it as locked. Absent otherwise. A diagram in a folder the caller may not use is not listed at all.
keepInsidetruenoPresent, and true, when the folder rule over this diagram keeps its diagrams inside: the svg route refuses ?download=1 and the copy route refuses a copy (403 orgs.folder_restricted). Absent otherwise.
shareOrganisationDiagramShareyesIts public link while the organisation shares it, or null. Only a diagram someone chose to share has one.
share.urlstringyesThe public address, {CDN_URL}/l/<token>.svg. Anyone with it can see the picture, without its source. It keeps showing the latest version when the diagram is edited, and never changes.
share.sharedAtintegeryesWhen the diagram was first shared, in milliseconds since the epoch.
keptbooleanyes"Keep": true when an owner or admin keeps it from the library retention. The plan's own retention still applies.
deletesAtinteger | nullyesWhen the retention deletes it, in milliseconds since the epoch: the nearer of the plan's expiry and "Delete library diagrams not updated for". Null when nothing will, and always null under a legal hold.
classificationClassificationyesA diagram's classification label: public, internal (the default, and what a diagram published before labels reads as) or confidential. Confidential is never shared publicly; under "Share only diagrams labelled Public" only public is.
pendingbooleanyesTrue while it is held for approval ("Publishing needs approval"): only its publisher and the approvers see it.
changePendingbooleanyesTrue while a new version of it waits for approval. The library shows this version until then.
seriesDiagramSeriesyesIts place in a series (the parts of one split import), or null when it is in none.
series.idstringyesThe series id the parts were published with.
series.indexintegeryesIts place in the series, from 1; 0 is the whole import combined into one diagram.
series.totalinteger | nullyesHow many parts the publisher said the series has, or null.
warningsDiagnostic[]yesQuality warnings from drawing the source, as draw_diagram gives them. Empty for a restore.
warnings[].code"E100" | "E101" | "E110" | "E111" | "E120" | "E121" | "E123" | "E124" | "E125" | "E130" | "E131" | "E132" | "E133" | "E134" | "E135" | "E136" | "E137" | "E138" | "E139" | "E140" | "W200" | "W201" | "W202" | "W203" | "W204" | "W205" | "W206" | "W207" | "W208" | "W209" | "W500" | "W600" | "W601" | "W700" | "W701" | "W702" | "W703" | "W704" | "W705" | "W706" | "W707" | "W708" | "W709" | "W710" | "M100" | "M101" | "M102" | "M103" | "M104" | "M110" | "M200" | "M201" | "M202" | "M203" | "M204" | "M205" | "M206" | "M207" | "M208" | "M209" | "M210" | "M211" | "M212" | "M213" | "M214" | "M215" | "M216" | "M217" | "M218" | "E300" | "E301" | "E302" | "E303" | "E304" | "W300" | "W301" | "W302" | "W303" | "M120" | "M220" | "M221" | "M222" | "E340" | "E341" | "E342" | "E343" | "E344" | "E345" | "W320" | "W321" | "W322" | "W323" | "M240" | "M241" | "M242" | "E360" | "E361" | "E362" | "E363" | "E364" | "E365" | "E366" | "E367" | "W330" | "W331" | "W332" | "W333" | "W334" | "M250" | "M251" | "E400" | "E401" | "E402" | "E403" | "W350" | "W351" | "W352" | "W353" | "M270" | "M271" | "E420" | "E421" | "E422" | "E423" | "E424" | "W360" | "W361" | "W362" | "W363" | "W364" | "M180" | "M280" | "M281" | "M282" | "E320" | "E321" | "E322" | "E323" | "E324" | "E325" | "E326" | "E327" | "E328" | "E329" | "E330" | "W310" | "W311" | "W312" | "W313" | "W314" | "M130" | "M131" | "M132" | "M230" | "M231" | "M232" | "M233" | "M234" | "M235" | "M236" | "M237" | "M238" | "E380" | "E381" | "E382" | "E383" | "W340" | "W341" | "W342" | "W343" | "M260" | "I100" | "I101" | "I102" | "I103" | "I104" | "I105" | "I200" | "I201" | "I202" | "I203" | "I204" | "I206" | "I207" | "R100" | "R101" | "R200" | "R201" | "R202" | "R203" | "R204" | "R205" | "R206" | "R207" | "S100" | "S200" | "S101" | "S102" | "S103" | "S104" | "S201" | "S202" | "S203" | "S204" | "S205"yesStable code to branch on; E-codes are errors, W-codes are warnings.
warnings[].severity"error" | "warning"yesErrors stop rendering; warnings never do.
warnings[].messagestringyesWhat is wrong, in one sentence.
warnings[].lineintegeryes1-based line in the submitted source. minimum 1.
warnings[].columnintegeryes1-based column in that line. minimum 1.
warnings[].lengthintegeryesNumber of characters the problem covers. minimum 1.
warnings[].hintstring | nullyesA concrete suggestion for fixing it, or null.
warnings[].fixobjectnoThe one certain fix, to apply as it is. Present only when exactly one fix is certain.
warnings[].fix.labelstringyesWhat the fix does, in a few words, for a button.
warnings[].fix.editsFixEdit[]yesThe edits, all against the source the diagnostic was found in.
changedbooleanyesFalse when the source draws the picture the diagram already has: nothing was stored and no version was kept.

KeepEditable

FieldTypeRequiredDescription
keepEditablebooleanyesTrue to write the diagram source into every picture published to the organisation that does not say otherwise, so members can edit it in the portal later. A publish that sends embedSource false still leaves it out.

SecretScanning

FieldTypeRequiredDescription
mode"warn" | "block"yeswarn: a publish to the library goes ahead and every draw warns (W700 to W710). block: a publish, an auto-publish, an editor save or a public share with any finding is refused with 422 orgs.publish_blocked.
privateIpsbooleanyesAlso count private IPv4 addresses (10/8, 172.16/12, 192.168/16) as findings (W709). Off by default; counts only while mode is block.
hostPatternsstring[]yesInternal hostname patterns that count as findings (W710), such as *.corp.example: DNS names in lower case, with * only as the first label. Empty by default; count only while mode is block.

CallCaps

FieldTypeRequiredDescription
memberinteger | nullyesThe most calls a day one member makes through every agent they connected to the organisation, or null for off. minimum 1; maximum 100000000.
connectioninteger | nullyesThe most calls a day one agent connection makes, or null for off. minimum 1; maximum 100000000.
keyinteger | nullyesThe most calls a day one organisation key from Keys and CI makes, or null for off. minimum 1; maximum 100000000.
overridesCallCapOverride[]yesUp to 200, one a member or key.
overrides[].kind"member" | "key"yesmember: a member, every agent they connected to the organisation together. key: one organisation key or one agent connection.
overrides[].idstringyesThe member's account id, or the key's id. at least 1 character; at most 64 characters.
overrides[].dailyCallsintegeryesThe calls a day, at most the organisation allowance. minimum 1; maximum 100000000.
availablebooleanyesFalse on a plan without the limits (anything but Enterprise): they are not applied, and only turning them off is allowed.
planstringyes
allowanceintegeryesThe most calls a day an account in the organisation may make. Every limit is held to it.
choicesCallCapChoice[]yesThe members who can connect agents and the live keys, for an override.
choices[].kind"member" | "key"yes
choices[].idstringyes
choices[].labelstringyesThe member's address, the key's name, or the name the agent gave itself.
choices[].via"connection" | "key"noFor a key: an agent connection, or a key from Keys and CI.
choices[].memberstring | nullnoFor an agent connection: the address of the member who connected it.

CallCapOverride

FieldTypeRequiredDescription
kind"member" | "key"yesmember: a member, every agent they connected to the organisation together. key: one organisation key or one agent connection.
idstringyesThe member's account id, or the key's id. at least 1 character; at most 64 characters.
dailyCallsintegeryesThe calls a day, at most the organisation allowance. minimum 1; maximum 100000000.

CallCapChoice

FieldTypeRequiredDescription
kind"member" | "key"yes
idstringyes
labelstringyesThe member's address, the key's name, or the name the agent gave itself.
via"connection" | "key"noFor a key: an agent connection, or a key from Keys and CI.
memberstring | nullnoFor an agent connection: the address of the member who connected it.

CallCapsInput

FieldTypeRequiredDescription
memberinteger | nullyesThe most calls a day one member makes through every agent they connected to the organisation, or null for off. minimum 1; maximum 100000000.
connectioninteger | nullyesThe most calls a day one agent connection makes, or null for off. minimum 1; maximum 100000000.
keyinteger | nullyesThe most calls a day one organisation key from Keys and CI makes, or null for off. minimum 1; maximum 100000000.
overridesCallCapOverride[]yesUp to 200, one a member or key.
overrides[].kind"member" | "key"yesmember: a member, every agent they connected to the organisation together. key: one organisation key or one agent connection.
overrides[].idstringyesThe member's account id, or the key's id. at least 1 character; at most 64 characters.
overrides[].dailyCallsintegeryesThe calls a day, at most the organisation allowance. minimum 1; maximum 100000000.

CapsToday

FieldTypeRequiredDescription
availablebooleanyes
daystringyesThe UTC day, YYYY-MM-DD. The counts start again at 00:00 UTC.
scope"organisation" | "own"yesorganisation for a caller who may read the call history; own for anyone else, who sees their own.
itemsCapUse[]yes
items[].scope"member" | "connection" | "key"yes
items[].idstringyesThe member's account id, or the key's id.
items[].labelstringyes
items[].memberstring | nullyesFor a connection: the address of the member who connected it.
items[].usedintegeryesCalls today, UTC.
items[].limitinteger | nullyesThe limit, or null when none holds it.
alertsCapUse[]yesThe ones at or past 80 percent of their limit, the fullest first.
alerts[].scope"member" | "connection" | "key"yes
alerts[].idstringyesThe member's account id, or the key's id.
alerts[].labelstringyes
alerts[].memberstring | nullyesFor a connection: the address of the member who connected it.
alerts[].usedintegeryesCalls today, UTC.
alerts[].limitinteger | nullyesThe limit, or null when none holds it.

CapUse

FieldTypeRequiredDescription
scope"member" | "connection" | "key"yes
idstringyesThe member's account id, or the key's id.
labelstringyes
memberstring | nullyesFor a connection: the address of the member who connected it.
usedintegeryesCalls today, UTC.
limitinteger | nullyesThe limit, or null when none holds it.

SetOrganisationPublishingBody

FieldTypeRequiredDescription
policy"personal" | "organisation-default" | "organisation-required"yes
hideViewLinksbooleannoLeave view links out of hosted answers for members and keys. Only with organisation-required. default false.

MemberPublicDiagramList

FieldTypeRequiredDescription
itemsMemberPublicDiagram[]yesAt most 200, newest published first.
items[].idstringyesThe personal diagram's id.
items[].namestring | nullyes
items[].urlstringyesIts public link, which anyone who has it can open.
items[].createdAtintegeryes
items[].publishedAtintegeryes
items[].bytesintegeryes
items[].lockedbooleanyesWhether the member locked it. Moving and unpublishing override the member's lock.
items[].stableLinksintegeryesHow many of the member's stable links show it now. minimum 0.
items[].memberobjectyes
items[].member.userIdstringyes
items[].member.emailstringyes
totalintegeryesHow many there are, which may be more than the list holds. minimum 0.

MemberPublicDiagram

FieldTypeRequiredDescription
idstringyesThe personal diagram's id.
namestring | nullyes
urlstringyesIts public link, which anyone who has it can open.
createdAtintegeryes
publishedAtintegeryes
bytesintegeryes
lockedbooleanyesWhether the member locked it. Moving and unpublishing override the member's lock.
stableLinksintegeryesHow many of the member's stable links show it now. minimum 0.
memberobjectyes
member.userIdstringyes
member.emailstringyes

MovedMemberDiagram

FieldTypeRequiredDescription
diagramOrganisationDiagramyes
diagram.idstringyesThe handle for the diagram in the routes below.
diagram.namestring | nullyesThe label given at publish, or null.
diagram.folderstring | nullyesThe folder it is filed in, such as Payments/Checkout, or null for the top level.
diagram.scheme"light" | "dark" | "auto"yesThe color scheme it was drawn in: light, dark, or auto.
diagram.bytesintegeryesSize of the stored SVG in bytes.
diagram.createdBystring | nullyesThe person it belongs to: the member who published it, or the person who connected the agent that did. Null when that account has left or an organisation key published it.
diagram.publishedVia"person" | "connection" | "key" | nullyesHow it was published: person (signed in, or with a key the person made), connection (an agent connected to the organisation, whose person is createdBy), or key (an organisation key from Keys and CI). Null for a diagram published before this was recorded.
diagram.publishedKeyobject | nullyesThe key behind a connection or an organisation key. Null for a person, and once the key no longer exists.
diagram.publishedKey.idstringyesThe key's id, as Keys and CI lists it. Never the key itself.
diagram.publishedKey.namestring | nullyesThe key's name, or null once the key is revoked.
diagram.publishedClientstring | nullyesThe client name the agent gave when it connected, such as Claude Code, for a connection only. at most 100 characters.
diagram.createdAtintegeryesWhen it was first published, in milliseconds since the epoch.
diagram.publishedAtintegeryesWhen it was last published, in milliseconds since the epoch. Publishing the same diagram again moves it.
diagram.expiresAtinteger | nullyesWhen it will be deleted, in milliseconds since the epoch, or null when the owner's plan keeps diagrams until they are deleted.
diagram.viewUrlstringyesA page in the portal that shows the diagram to a signed-in member. It is not a link anyone can open: an organisation's diagrams have no public address.
diagram.lockedbooleanyesTrue while the owner has the diagram locked: nobody can delete, rename or move it, its publisher and the owner included, until the owner unlocks it. A lock does not stop it expiring on a plan that expires diagrams.
diagram.lockedAtinteger | nullyesWhen the owner locked it, in milliseconds since the epoch, or null when it is not locked.
diagram.restrictedtruenoPresent, and true, when the owner has restricted this diagram's folder and the caller is allowed in it, so the portal can show it as locked. Absent otherwise. A diagram in a folder the caller may not use is not listed at all.
diagram.keepInsidetruenoPresent, and true, when the folder rule over this diagram keeps its diagrams inside: the svg route refuses ?download=1 and the copy route refuses a copy (403 orgs.folder_restricted). Absent otherwise.
diagram.shareOrganisationDiagramShareyesIts public link while the organisation shares it, or null. Only a diagram someone chose to share has one.
diagram.share.urlstringyesThe public address, {CDN_URL}/l/<token>.svg. Anyone with it can see the picture, without its source. It keeps showing the latest version when the diagram is edited, and never changes.
diagram.share.sharedAtintegeryesWhen the diagram was first shared, in milliseconds since the epoch.
diagram.keptbooleanyes"Keep": true when an owner or admin keeps it from the library retention. The plan's own retention still applies.
diagram.deletesAtinteger | nullyesWhen the retention deletes it, in milliseconds since the epoch: the nearer of the plan's expiry and "Delete library diagrams not updated for". Null when nothing will, and always null under a legal hold.
diagram.classificationClassificationyesA diagram's classification label: public, internal (the default, and what a diagram published before labels reads as) or confidential. Confidential is never shared publicly; under "Share only diagrams labelled Public" only public is.
diagram.pendingbooleanyesTrue while it is held for approval ("Publishing needs approval"): only its publisher and the approvers see it.
diagram.changePendingbooleanyesTrue while a new version of it waits for approval. The library shows this version until then.
diagram.seriesDiagramSeriesyesIts place in a series (the parts of one split import), or null when it is in none.
diagram.series.idstringyesThe series id the parts were published with.
diagram.series.indexintegeryesIts place in the series, from 1; 0 is the whole import combined into one diagram.
diagram.series.totalinteger | nullyesHow many parts the publisher said the series has, or null.
mergedbooleanyesTrue when the library already held exactly this picture, so only the public copy went.

UserPublishing

FieldTypeRequiredDescription
defaultOrganizationanyyes
defaultOrganization.idstringyes
defaultOrganization.slugstringyes
defaultOrganization.namestringyes
organizationsPublishingClaim[]yesThe organisations whose Publishing setting claims the person's publishes, by name.
organizations[].idstringyes
organizations[].slugstringyes
organizations[].namestringyes
organizations[].policy"organisation-default" | "organisation-required"yesWhat it enforces: its library by default, or its library always.
organizations[].via"member" | "domain"yesmember when the person belongs to it; domain when it verified the domain of their address and they have not joined.
organizations[].canPublishbooleanyesWhether the person may publish to its library: a member who is not a reader.
targetPublishTargetyespersonal, the organisation it goes to and why, choose (several claim it and none is the default), or refused.

PublishingClaim

FieldTypeRequiredDescription
idstringyes
slugstringyes
namestringyes
policy"organisation-default" | "organisation-required"yesWhat it enforces: its library by default, or its library always.
via"member" | "domain"yesmember when the person belongs to it; domain when it verified the domain of their address and they have not joined.
canPublishbooleanyesWhether the person may publish to its library: a member who is not a reader.

PublishTarget

personal, the organisation it goes to and why, choose (several claim it and none is the default), or refused.

FieldTypeRequiredDescription

SetUserPublishingBody

FieldTypeRequiredDescription
defaultOrganizationstring | nullyesAn organisation's slug or id, or null for none. The person must be a member who may publish there. at least 1 character; at most 64 characters.

OrganisationLegend

FieldTypeRequiredDescription
legend"members" | "on" | "off" | "required"yesThe legend of flow diagrams drawn for the organisation on the hosted service: members (each member's own choice, the default), on or off (a repository's plotwork.config.json and a diagram's header still win), or required (drawn whatever a repository or a header says).

SetOrganisationLegendBody

FieldTypeRequiredDescription
legend"members" | "on" | "off" | "required"yes

UserLegend

FieldTypeRequiredDescription
legend"on" | "off"yesThe legend of flow diagrams you draw on the hosted service, on (the default) or off, when no organisation decides it. A repository's plotwork.config.json and a diagram's header still win.

SetUserLegendBody

FieldTypeRequiredDescription
legend"on" | "off"yes

OrganisationStyle

The style of flow diagrams drawn for the organisation on the hosted service. Each part it chooses is written over a repository's plotwork.config.json; a diagram's header wins over its values, but never over what it allows.

FieldTypeRequiredDescription
spacing"members" | "compact" | "normal" | "roomy"yesHow far apart the boxes sit: compact, normal, or roomy, or members (each member's own choice, the default).
edges"members" | "orthogonal" | "spline" | "straight"yesHow the lines are drawn: orthogonal (straight runs, rounded corners), spline (curves), or straight (slanted), or members (each member's own choice, the default).
tabs"plate" | "heading"yesHow a group's name is drawn in its corner: plate, a raised tab outlined in the frame's colour (the default), or heading, flat on the frame. The organisation's choice; members have none.
allowedobjectyesThe values each part may take, every value by default. A diagram that asks for another (by its header, a repository's plotwork.config.json, a member's own choice or an agent) is drawn with an allowed one, with warning S205; a list of one requires it.
allowed.spacing("compact" | "normal" | "roomy")[]yes
allowed.edges("orthogonal" | "spline" | "straight")[]yes

SetOrganisationStyleBody

FieldTypeRequiredDescription
spacing"members" | "compact" | "normal" | "roomy"no
edges"members" | "orthogonal" | "spline" | "straight"no
tabs"plate" | "heading"no
allowedobjectno
allowed.spacing("compact" | "normal" | "roomy")[]no
allowed.edges("orthogonal" | "spline" | "straight")[]no

UserStyle

The style of flow diagrams you draw on the hosted service when no organisation decides it. A repository's plotwork.config.json and a diagram's header still win.

FieldTypeRequiredDescription
spacing"compact" | "normal" | "roomy"yesHow far apart the boxes sit: compact, normal, or roomy. normal by default.
edges"orthogonal" | "spline" | "straight"yesHow the lines are drawn: orthogonal (straight runs, rounded corners), spline (curves), or straight (slanted). orthogonal by default.

SetUserStyleBody

FieldTypeRequiredDescription
spacing"compact" | "normal" | "roomy"no
edges"orthogonal" | "spline" | "straight"no

OrganisationImportLarge

FieldTypeRequiredDescription
large"parts" | "whole" | "both"yesWhat an import too big for one readable picture draws for the organisation's members, keys and agents when the call does not say: parts (an overview and one diagram per group), whole (one diagram with every arrow), or both (the default). A member's own choice wins.

SetOrganisationImportLargeBody

FieldTypeRequiredDescription
large"parts" | "whole" | "both"yes

UserImportLarge

FieldTypeRequiredDescription
large"org" | "parts" | "whole" | "both"yesWhat your imports too big for one readable picture draw on the hosted service when the call does not say: org (the organisation's choice, the default; both for a person in none), parts, whole, or both.

SetUserImportLargeBody

FieldTypeRequiredDescription
large"org" | "parts" | "whole" | "both"yes

SharedOrganisationDiagram

FieldTypeRequiredDescription
diagramIdstringyes
urlstringyesThe public address. Paste it as an image, or give it to GET /oembed.
sharedAtintegeryesWhen the diagram was first shared, in milliseconds since the epoch.
updatedAtintegeryesWhen the public copy was last written, in milliseconds since the epoch.
sharedBystring | nullyesThe account that first shared it, or null once that account is deleted.
createdbooleanyesTrue when this call made the link; false when the diagram was already shared and kept its address.

HeldOrganisationShare

FieldTypeRequiredDescription
diagramIdstringyes
approvalApprovalHoldyesPresent when the organisation's "Publishing needs approval" or "Public sharing needs approval" held this. It is data, not an error: the diagram is stored, and only its publisher and the approvers can see it until an approver approves.
approval.state"pending"yes
approval.requestIdstringyesThe request, as the Approvals queue lists it.
approval.kind"publish" | "change" | "share"yespublish (a new diagram), change (a new version of one the library shows) or share (a public link).
approval.expiresAtintegeryesWhen the daily sweep ends the request if nobody decides it, in milliseconds since the epoch: thirty days after it was made.
approval.messagestringyesOne sentence to tell the person: held for approval by the organisation, and what happens next.
approval.codestringyesThe warning code a tool answer carries for it: W601.

OrganisationPublicSharingChanged

FieldTypeRequiredDescription
publicSharingbooleanyes"Allow public sharing of individual diagrams": while true, the owner and admins may share any diagram, and a member a diagram they published, at a public link. Off by default. Turning it off ends every link.
sharedCountintegeryesHow many of the organisation's diagrams have a public link now. Counted against the plan's stableLinks. minimum 0.
autoPublishbooleanyes"Agents publish every diagram they draw": while true, every valid drawing made through one of the organisation's agent connections or keys is stored in its private library with its source. Off by default.
embedLinksbooleanyes"Allow diagrams on chosen websites" (Enterprise): while true, a diagram may have embed links that show it only on the websites they name. Off by default. Turning it off ends every embed link.
embedLinkCountintegeryesHow many embed links the organisation has now. minimum 0.
linksEndedintegeryesHow many public links this call ended: every one when sharing was turned off, none otherwise. minimum 0.

SetOrganisationPublicSharingBody

FieldTypeRequiredDescription
publicSharingbooleanyesTrue to allow public links to single diagrams; false to end every one.

SetOrganisationAutoPublishBody

FieldTypeRequiredDescription
autoPublishbooleanyesTrue to keep every valid drawing the organisation's agents make in its private library.

EmbedLinkViews

FieldTypeRequiredDescription
availablebooleanyesFalse when views are not set up on this server or could not be read now.
daysintegeryes
linksobject[]yes
links[].linkIdstringyes
links[].diagramIdstringyes
links[].labelstring | nullyes
links[].shownintegeryes
links[].refusedintegeryes
links[].sitesobject[]yes
links[].sites[].sitestringyesThe host of the page that asked, or empty for requests that named no page.
links[].sites[].shownintegeryes
links[].sites[].refusedintegeryesPlaceholders: a site not on the list, no site named, or an ended link.
links[].sites[].lastDaystringyesThe last UTC day it asked, YYYY-MM-DD.
links[].daysobject[]yes
links[].days[].daystringyes
links[].days[].shownintegeryes
links[].days[].refusedintegeryes

EmbedLinksOfDiagram

FieldTypeRequiredDescription
includedbooleanyesThe organisation's plan includes allowed sites (Enterprise).
enabledbooleanyesThe owner turned on "Allow diagrams on chosen websites".
eligiblebooleanyesThe diagram may have a link: it is not labelled Confidential and not waiting for approval.
mayManagebooleanyesThe caller may make, change and end its links. False means links is empty.
linksEmbedLink[]yes
links[].idstringyes
links[].diagramIdstringyes
links[].urlstring | nullyesThe address, {EMBED_URL}/o/<token>.svg. A page on one of sites that shows it as an image gets the picture, without its source; anything else gets a placeholder. Null when the server cannot show it again: rotate the link for a new one.
links[].labelstring | nullyesAn optional name for the page it is for.
links[].sitesstring[]yesThe websites a page must be on, lower case.
links[].proxiedSitesstring[]yesSites in sites whose images reach Plotwork through a proxy that names no page (GitHub), so the link shows them the placeholder.
links[].expiresAtinteger | nullyesWhen it stops, in milliseconds since the epoch, or null for never.
links[].expiredbooleanyes
links[].createdBystring | nullyes
links[].createdAtintegeryes
links[].updatedAtintegeryes
links[].rotatedAtinteger | nullyes
maxintegeryesThe most links one diagram may have.
FieldTypeRequiredDescription
idstringyes
diagramIdstringyes
urlstring | nullyesThe address, {EMBED_URL}/o/<token>.svg. A page on one of sites that shows it as an image gets the picture, without its source; anything else gets a placeholder. Null when the server cannot show it again: rotate the link for a new one.
labelstring | nullyesAn optional name for the page it is for.
sitesstring[]yesThe websites a page must be on, lower case.
proxiedSitesstring[]yesSites in sites whose images reach Plotwork through a proxy that names no page (GitHub), so the link shows them the placeholder.
expiresAtinteger | nullyesWhen it stops, in milliseconds since the epoch, or null for never.
expiredbooleanyes
createdBystring | nullyes
createdAtintegeryes
updatedAtintegeryes
rotatedAtinteger | nullyes

CreateEmbedLinkBody

FieldTypeRequiredDescription
sitesstring[]yes
expiresAtinteger | nullnoWhen it stops, in milliseconds since the epoch, within three years. Left out or null: never.
labelstring | nullnoAn optional name for the page it is for. at most 80 characters.

UpdateEmbedLinkBody

FieldTypeRequiredDescription
sitesstring[]no
expiresAtinteger | nullno
labelstring | nullnoat most 80 characters.

OrganisationEmbedLinksChanged

FieldTypeRequiredDescription
embedLinksbooleanyes
linksEndedintegeryesHow many embed links this call ended: every one when the setting was turned off, none otherwise. minimum 0.

SetOrganisationEmbedLinksBody

FieldTypeRequiredDescription
embedLinksbooleanyesTrue to allow diagrams on chosen websites; false to end every embed link.

OrganisationClassification

FieldTypeRequiredDescription
defaultClassificationyesA diagram's classification label: public, internal (the default, and what a diagram published before labels reads as) or confidential. Confidential is never shared publicly; under "Share only diagrams labelled Public" only public is.
sharePublicOnlybooleanyes"Share only diagrams labelled Public": while true, only a diagram labelled public may have a public link. The owner's setting.
foldersobject[]yesThe folders with a default label of their own. A new diagram filed in one, or in a folder inside it, gets it; the deepest wins.
folders[].folderstringyesat least 1 character; at most 300 characters.
folders[].classificationClassificationyesA diagram's classification label: public, internal (the default, and what a diagram published before labels reads as) or confidential. Confidential is never shared publicly; under "Share only diagrams labelled Public" only public is.

OrganisationClassificationChanged

FieldTypeRequiredDescription
defaultClassificationyesA diagram's classification label: public, internal (the default, and what a diagram published before labels reads as) or confidential. Confidential is never shared publicly; under "Share only diagrams labelled Public" only public is.
sharePublicOnlybooleanyes"Share only diagrams labelled Public": while true, only a diagram labelled public may have a public link. The owner's setting.
foldersobject[]yesThe folders with a default label of their own. A new diagram filed in one, or in a folder inside it, gets it; the deepest wins.
folders[].folderstringyesat least 1 character; at most 300 characters.
folders[].classificationClassificationyesA diagram's classification label: public, internal (the default, and what a diagram published before labels reads as) or confidential. Confidential is never shared publicly; under "Share only diagrams labelled Public" only public is.
linksEndedintegeryesHow many public links ended because "Share only diagrams labelled Public" was turned on and their diagram is not labelled public. minimum 0.

SetOrganisationClassificationBody

FieldTypeRequiredDescription
defaultClassificationyesA diagram's classification label: public, internal (the default, and what a diagram published before labels reads as) or confidential. Confidential is never shared publicly; under "Share only diagrams labelled Public" only public is.
sharePublicOnlybooleannoOnly the owner may change it; left out, it stays as it is.
foldersobject[]yesAt most 50 folders, each a folder path.
folders[].folderstringyesFolder names from the outermost in, joined with a slash, such as "Payments/Checkout", with no slash at either end. Folder names may use letters A to Z, numbers, spaces, - and _. No space at either end of a name and never two together. Up to 5 levels and 40 characters a name. at most 204 characters; pattern ^[A-Za-z0-9_-]+(?: [A-Za-z0-9_-]+)*(?:/[A-Za-z0-9_-]+(?: [A-Za-z0-9_-]+)*){0,4}$.
folders[].classificationstringyesat least 1 character; at most 20 characters.

ClassifiedOrganisationDiagram

FieldTypeRequiredDescription
diagramIdstringyes
classificationClassificationyesA diagram's classification label: public, internal (the default, and what a diagram published before labels reads as) or confidential. Confidential is never shared publicly; under "Share only diagrams labelled Public" only public is.
previousClassificationyesA diagram's classification label: public, internal (the default, and what a diagram published before labels reads as) or confidential. Confidential is never shared publicly; under "Share only diagrams labelled Public" only public is.
shareEndedbooleanyesTrue when the new label ended the diagram's public link: Confidential, or anything but public under "Share only diagrams labelled Public".

ClassifyOrganisationDiagramBody

FieldTypeRequiredDescription
classificationClassificationyesA diagram's classification label: public, internal (the default, and what a diagram published before labels reads as) or confidential. Confidential is never shared publicly; under "Share only diagrams labelled Public" only public is.

OrganisationApproval

FieldTypeRequiredDescription
publish"off" | "folders" | "all"yes
foldersstring[]yesThe folders "Publishing needs approval" covers when it is folders.
sharebooleanyes
holdKeysbooleanyes"Hold organisation keys for approval too": while false, a publish or a new version made with an organisation key from Keys and CI goes in directly. An agent connection is held as its person is. The owner's setting.
approversarray | nullyesThe members chosen to approve besides the owner and the admins. Null for a caller who may not manage them.

SetOrganisationApprovalBody

FieldTypeRequiredDescription
publish"off" | "folders" | "all"yes
foldersstring[]yes
sharebooleanyes
holdKeysbooleannoOnly the owner may change it; left out, it stays as it is.
approversstring[]yesAccount ids of members with the member role, at most 50.

ApprovalRequestList

FieldTypeRequiredDescription
itemsApprovalRequest[]yes
items[].idstringyes
items[].kind"publish" | "change" | "share"yes
items[].status"pending" | "approved" | "rejected" | "expired"yes
items[].diagramobject | nullyesThe diagram as the library has it now, or null once it is gone (a rejected new diagram).
items[].diagram.idstringyes
items[].diagram.namestring | nullyes
items[].diagram.folderstring | nullyes
items[].diagram.classificationClassificationyesA diagram's classification label: public, internal (the default, and what a diagram published before labels reads as) or confidential. Confidential is never shared publicly; under "Share only diagrams labelled Public" only public is.
items[].diagram.scheme"light" | "dark" | "auto"yes
items[].requestedByobject | nullyesWho asked, or null for an organisation key and once the account is gone.
items[].requestedBy.userIdstringyes
items[].requestedBy.emailstringyes
items[].requestedAtintegeryes
items[].expiresAtintegeryes
items[].secretFindingsintegeryesHow many things that look like a secret the scan found when the request was made, under the organisation's scanning options. minimum 0.
items[].reviewedByobject | nullyes
items[].reviewedBy.userIdstringyes
items[].reviewedBy.emailstringyes
items[].reviewedAtinteger | nullyes
items[].commentstring | nullyesThe approver's comment, when they gave one.
totalintegeryesHow many requests wait, even when the list is shorter. minimum 0.

ApprovalRequest

FieldTypeRequiredDescription
idstringyes
kind"publish" | "change" | "share"yes
status"pending" | "approved" | "rejected" | "expired"yes
diagramobject | nullyesThe diagram as the library has it now, or null once it is gone (a rejected new diagram).
diagram.idstringyes
diagram.namestring | nullyes
diagram.folderstring | nullyes
diagram.classificationClassificationyesA diagram's classification label: public, internal (the default, and what a diagram published before labels reads as) or confidential. Confidential is never shared publicly; under "Share only diagrams labelled Public" only public is.
diagram.scheme"light" | "dark" | "auto"yes
requestedByobject | nullyesWho asked, or null for an organisation key and once the account is gone.
requestedBy.userIdstringyes
requestedBy.emailstringyes
requestedAtintegeryes
expiresAtintegeryes
secretFindingsintegeryesHow many things that look like a secret the scan found when the request was made, under the organisation's scanning options. minimum 0.
reviewedByobject | nullyes
reviewedBy.userIdstringyes
reviewedBy.emailstringyes
reviewedAtinteger | nullyes
commentstring | nullyesThe approver's comment, when they gave one.

ApprovalRequestDetail

FieldTypeRequiredDescription
itemApprovalRequestyes
item.idstringyes
item.kind"publish" | "change" | "share"yes
item.status"pending" | "approved" | "rejected" | "expired"yes
item.diagramobject | nullyesThe diagram as the library has it now, or null once it is gone (a rejected new diagram).
item.diagram.idstringyes
item.diagram.namestring | nullyes
item.diagram.folderstring | nullyes
item.diagram.classificationClassificationyesA diagram's classification label: public, internal (the default, and what a diagram published before labels reads as) or confidential. Confidential is never shared publicly; under "Share only diagrams labelled Public" only public is.
item.diagram.scheme"light" | "dark" | "auto"yes
item.requestedByobject | nullyesWho asked, or null for an organisation key and once the account is gone.
item.requestedBy.userIdstringyes
item.requestedBy.emailstringyes
item.requestedAtintegeryes
item.expiresAtintegeryes
item.secretFindingsintegeryesHow many things that look like a secret the scan found when the request was made, under the organisation's scanning options. minimum 0.
item.reviewedByobject | nullyes
item.reviewedBy.userIdstringyes
item.reviewedBy.emailstringyes
item.reviewedAtinteger | nullyes
item.commentstring | nullyesThe approver's comment, when they gave one.
diffobject | nullyesFor a new version: what changed against the one the library shows, by meaning (compare_diagrams). Null for a publish and a share.
diff.samebooleanyes
diff.comparedbooleanyesFalse when a side carries no source, so nothing could be compared.
diff.countsobjectyes
diff.counts.addedintegeryes
diff.counts.removedintegeryes
diff.counts.renamedintegeryes
diff.counts.movedintegeryes
diff.counts.changedintegeryes
diff.changesobject[]yes
diff.changes[].changestringyes
diff.changes[].subjectstringyes
diff.changes[].namestringyes
diff.changes[].lineinteger | nullyes
diff.changes[].detailstringyes
diff.truncatedbooleanyes
diff.summarystringyes

DecideApprovalBody

FieldTypeRequiredDescription
commentstring | nullnoAn optional comment for the publisher, at most 500 characters. It is emailed to them and kept in the organisation's audit log. at least 1 character; at most 500 characters.

SetOrganisationRetentionBody

FieldTypeRequiredDescription
libraryDays90yes"Delete library diagrams not updated for": 90, 180, 365 or 730 days, or null for never (the default).
auditDays365yes"Keep the audit log for": 365, 730 or 2555 days (one, two or seven years), or null for the plan's days (the default). It only lengthens.

SetLegalHoldBody

FieldTypeRequiredDescription
onbooleanyesTrue puts the organisation on legal hold; false takes it off.
reasonstringyesWhy, in the owner's words: a matter, a request, a ticket. Written to the audit log, both to turn it on and to turn it off. at least 3 characters; at most 500 characters.

SetGovernanceSwitchBody

FieldTypeRequiredDescription
onbooleanyes

DiagramKept

FieldTypeRequiredDescription
idstringyes
keptbooleanyes

SetDiagramKeptBody

FieldTypeRequiredDescription
keptbooleanyesTrue keeps the diagram from the library retention; false lets it go when it is due.

OrganisationPatternList

FieldTypeRequiredDescription
itemsOrganisationPatternSummary[]yesBy title.
items[].idstringyesWhat the tools take: org:<name>.
items[].namestringyesThe name after org:.
items[].titlestringyes
items[].summarystringyes
items[].whenToUsestringyes
items[].kindstringyesThe kind of diagram, such as flow.
items[].tagsstring[]yes
items[].flavours("neutral" | "aws" | "azure" | "gcp")[]yes
items[].slotCountintegeryesminimum 0.
items[].createdAtintegeryes
items[].updatedAtintegeryes
items[].updatedBystring | nullyesThe account that last saved it, or null once that account is gone.
items[].picturesobject | nullyesIts pictures, drawn when it was saved: its first flavour with every slot at its default, in the organisation's brand and icons. Null for a pattern saved before pictures were kept, or whose drawing failed; the next save draws them.
items[].pictures.lightstringyesThe path of its light picture on this API, with the save time in it.
items[].pictures.darkstringyesThe path of its dark picture on this API.
limitintegeryesThe most patterns the organisation keeps.
availablebooleanyesWhether the organisation's plan includes its own patterns (Enterprise). Without it they are kept and not offered to agents.
canEditbooleanyesWhether the caller may save, change and remove them: the owner and admins, signed in.

OrganisationPatternSummary

FieldTypeRequiredDescription
idstringyesWhat the tools take: org:<name>.
namestringyesThe name after org:.
titlestringyes
summarystringyes
whenToUsestringyes
kindstringyesThe kind of diagram, such as flow.
tagsstring[]yes
flavours("neutral" | "aws" | "azure" | "gcp")[]yes
slotCountintegeryesminimum 0.
createdAtintegeryes
updatedAtintegeryes
updatedBystring | nullyesThe account that last saved it, or null once that account is gone.
picturesobject | nullyesIts pictures, drawn when it was saved: its first flavour with every slot at its default, in the organisation's brand and icons. Null for a pattern saved before pictures were kept, or whose drawing failed; the next save draws them.
pictures.lightstringyesThe path of its light picture on this API, with the save time in it.
pictures.darkstringyesThe path of its dark picture on this API.

OrganisationPattern

FieldTypeRequiredDescription
idstringyesWhat the tools take: org:<name>.
namestringyesThe name after org:.
titlestringyes
summarystringyes
whenToUsestringyes
kindstringyesThe kind of diagram, such as flow.
tagsstring[]yes
flavours("neutral" | "aws" | "azure" | "gcp")[]yes
slotCountintegeryesminimum 0.
createdAtintegeryes
updatedAtintegeryes
updatedBystring | nullyesThe account that last saved it, or null once that account is gone.
picturesobject | nullyesIts pictures, drawn when it was saved: its first flavour with every slot at its default, in the organisation's brand and icons. Null for a pattern saved before pictures were kept, or whose drawing failed; the next save draws them.
pictures.lightstringyesThe path of its light picture on this API, with the save time in it.
pictures.darkstringyesThe path of its dark picture on this API.
templatesobjectyesThe Plotwork source of each flavour (neutral, aws, azure, gcp), at least one, with {{slot}} markers inside quoted labels.
templates.neutralstringnoat most 10000 characters.
templates.awsstringnoat most 10000 characters.
templates.azurestringnoat most 10000 characters.
templates.gcpstringnoat most 10000 characters.
slotsobject[]yes
slots[].idstringyesLowercase words joined with hyphens; written {{id}} inside a quoted label of the source. at least 1 character; at most 40 characters.
slots[].defaultstringyesThe text the slot has when nothing replaces it. No quotes or line breaks. Up to 60 characters, or 600 for the description slot, which is the alt text. at most 600 characters.
slots[].meaningstringyesOne line on what belongs in the slot, so an agent fills it with the right thing. at most 200 characters.
notesobjectyes
notes.keepstringyesWhat to leave exactly as it is.
notes.renamestringyesWhat to rename or replace, and how.
notes.splitstringyesWhen the diagram has grown too big, and where to cut it.

CreateOrganisationPatternBody

FieldTypeRequiredDescription
namestringyesThe name after org:: lowercase letters, digits and single hyphens, such as payments-service. Never changes. at least 1 character; at most 50 characters.
$schemastringnoThe schema line of a pattern file (https://docs.plotwork.dev/schemas/plotwork.pattern.json (opens in a new tab)). Ignored, so a pattern file is a valid body as it is. at most 200 characters.
titlestringyesat most 80 characters.
summarystringyesOne sentence: what the diagram shows. at most 300 characters.
whenToUsestringnoTwo or three sentences: when to start from it, and when not to. at most 600 characters.
tagsstring[]noWords a search should match, such as payments.
templatesobjectyesThe Plotwork source of each flavour (neutral, aws, azure, gcp), at least one, with {{slot}} markers inside quoted labels.
templates.neutralstringnoat most 10000 characters.
templates.awsstringnoat most 10000 characters.
templates.azurestringnoat most 10000 characters.
templates.gcpstringnoat most 10000 characters.
slotsobject[]no
slots[].idstringyesLowercase words joined with hyphens; written {{id}} inside a quoted label of the source. at least 1 character; at most 40 characters.
slots[].defaultstringyesThe text the slot has when nothing replaces it. No quotes or line breaks. Up to 60 characters, or 600 for the description slot, which is the alt text. at most 600 characters.
slots[].meaningstringyesOne line on what belongs in the slot, so an agent fills it with the right thing. at most 200 characters.
notesobjectnoWhat to keep, what to rename, and when to split. Left out, each has a plain default.
notes.keepstringnoat most 400 characters.
notes.renamestringnoat most 400 characters.
notes.splitstringnoat most 400 characters.

UpdateOrganisationPatternBody

FieldTypeRequiredDescription
$schemastringnoThe schema line of a pattern file (https://docs.plotwork.dev/schemas/plotwork.pattern.json (opens in a new tab)). Ignored, so a pattern file is a valid body as it is. at most 200 characters.
titlestringyesat most 80 characters.
summarystringyesOne sentence: what the diagram shows. at most 300 characters.
whenToUsestringnoTwo or three sentences: when to start from it, and when not to. at most 600 characters.
tagsstring[]noWords a search should match, such as payments.
templatesobjectyesThe Plotwork source of each flavour (neutral, aws, azure, gcp), at least one, with {{slot}} markers inside quoted labels.
templates.neutralstringnoat most 10000 characters.
templates.awsstringnoat most 10000 characters.
templates.azurestringnoat most 10000 characters.
templates.gcpstringnoat most 10000 characters.
slotsobject[]no
slots[].idstringyesLowercase words joined with hyphens; written {{id}} inside a quoted label of the source. at least 1 character; at most 40 characters.
slots[].defaultstringyesThe text the slot has when nothing replaces it. No quotes or line breaks. Up to 60 characters, or 600 for the description slot, which is the alt text. at most 600 characters.
slots[].meaningstringyesOne line on what belongs in the slot, so an agent fills it with the right thing. at most 200 characters.
notesobjectnoWhat to keep, what to rename, and when to split. Left out, each has a plain default.
notes.keepstringnoat most 400 characters.
notes.renamestringnoat most 400 characters.
notes.splitstringnoat most 400 characters.

FolderRuleList

FieldTypeRequiredDescription
itemsFolderRule[]yesBy folder, at most 50.
items[].folderstringyesThe restricted folder, in the form diagrams carry in their folder.
items[].roles("admin" | "member" | "reader" | "key")[]yesThe roles let in, apart from the owner, who is always allowed: admin, member, reader, and key for the organisation's own API keys.
items[].usersFolderRuleUser[]yesThe people let in by name, whatever their role.
items[].users[].userIdstringyesThe member's account id.
items[].users[].emailstringyesThe member's address, as the member list shows it.
items[].keepInsidebooleanyesWhether the rule keeps its diagrams inside: no file download (?download=1, a folder ZIP) and no copy, for anyone, the owner included. The pictures still show to the people let in.
items[].createdAtintegeryesMilliseconds since the epoch. When the rule as it now stands was set; replacing a rule sets it again.

FolderRule

FieldTypeRequiredDescription
folderstringyesThe restricted folder, in the form diagrams carry in their folder.
roles("admin" | "member" | "reader" | "key")[]yesThe roles let in, apart from the owner, who is always allowed: admin, member, reader, and key for the organisation's own API keys.
usersFolderRuleUser[]yesThe people let in by name, whatever their role.
users[].userIdstringyesThe member's account id.
users[].emailstringyesThe member's address, as the member list shows it.
keepInsidebooleanyesWhether the rule keeps its diagrams inside: no file download (?download=1, a folder ZIP) and no copy, for anyone, the owner included. The pictures still show to the people let in.
createdAtintegeryesMilliseconds since the epoch. When the rule as it now stands was set; replacing a rule sets it again.

FolderRuleUser

FieldTypeRequiredDescription
userIdstringyesThe member's account id.
emailstringyesThe member's address, as the member list shows it.

SetFolderRuleBody

FieldTypeRequiredDescription
folderstringyesThe folder the rule restricts, with every folder inside it: names from the outermost in, joined with a slash, with no slash at either end, each of the letters A to Z, numbers, single spaces, - and _. at most 204 characters; pattern ^[A-Za-z0-9_-]+(?: [A-Za-z0-9_-]+)*(?:/[A-Za-z0-9_-]+(?: [A-Za-z0-9_-]+)*){0,4}$.
rolesstring[]yesAny of admin, member, reader, key. owner is not a choice. An empty list, with no people, lets in the owner alone.
usersstring[]yesAccount ids of current members, at most 100. A person who leaves is taken out of every rule.
keepInsidebooleannoKeep the diagrams inside: refuse file downloads and copies of every diagram under the rule. Left out, off.

FolderRecordList

FieldTypeRequiredDescription
itemsFolderRecord[]yesBy path, at most 500. The folders diagrams are filed in are read from the diagrams and are not listed here unless someone made them.
items[].pathstringyesThe folder, in the form diagrams carry in their folder.
items[].createdAtintegeryesMilliseconds since the epoch, when it was made.

FolderRecord

FieldTypeRequiredDescription
pathstringyesThe folder, in the form diagrams carry in their folder.
createdAtintegeryesMilliseconds since the epoch, when it was made.

CreateFolderBody

FieldTypeRequiredDescription
pathstringyesFolder names from the outermost in, joined with a slash, such as "Payments/Checkout", with no slash at either end. Folder names may use letters A to Z, numbers, spaces, - and _. No space at either end of a name and never two together. Up to 5 levels and 40 characters a name. at most 204 characters; pattern ^[A-Za-z0-9_-]+(?: [A-Za-z0-9_-]+)*(?:/[A-Za-z0-9_-]+(?: [A-Za-z0-9_-]+)*){0,4}$.

MoveFolderBody

FieldTypeRequiredDescription
fromstringyesThe folder that moves, with every folder inside it. at most 204 characters; pattern ^[A-Za-z0-9_-]+(?: [A-Za-z0-9_-]+)*(?:/[A-Za-z0-9_-]+(?: [A-Za-z0-9_-]+)*){0,4}$.
tostringyesWhere it goes: its new path, which may rename it, move it, or both. at most 204 characters; pattern ^[A-Za-z0-9_-]+(?: [A-Za-z0-9_-]+)*(?:/[A-Za-z0-9_-]+(?: [A-Za-z0-9_-]+)*){0,4}$.

OrgApiKeyList

FieldTypeRequiredDescription
itemsOrgApiKeySummary[]yes
items[].idstringyes
items[].namestringyes
items[].prefixstringyes
items[].last4stringyes
items[].createdAtintegeryesMilliseconds since the epoch.
items[].lastUsedAtinteger | nullyesMilliseconds since the epoch, or null if never used.
items[].revealablebooleanyesTrue when the full key can be shown again with the reveal route. False for a key made before that was possible, or on a server that cannot seal keys.
items[].scopes("diagrams" | "audit:read" | "drift:write" | "boards" | "design:write")[]yesdiagrams: read the library, publish, change its diagrams, report drift runs and read the style rules, which every key made before scopes holds. audit:read: read and export the audit log, and nothing else unless diagrams is also given. drift:write: report drift runs and read the style rules, and nothing else, for CI that publishes nothing. boards: read and change the live whiteboards open to the whole organisation, through /v1/boards, and on the hosted MCP server beside diagrams; off unless given.
items[].expiresAtinteger | nullyesWhen the key stops working under the organisation's key policy ("Keys expire after"), in milliseconds since the epoch, or null for never.

OrgApiKeySummary

FieldTypeRequiredDescription
idstringyes
namestringyes
prefixstringyes
last4stringyes
createdAtintegeryesMilliseconds since the epoch.
lastUsedAtinteger | nullyesMilliseconds since the epoch, or null if never used.
revealablebooleanyesTrue when the full key can be shown again with the reveal route. False for a key made before that was possible, or on a server that cannot seal keys.
scopes("diagrams" | "audit:read" | "drift:write" | "boards" | "design:write")[]yesdiagrams: read the library, publish, change its diagrams, report drift runs and read the style rules, which every key made before scopes holds. audit:read: read and export the audit log, and nothing else unless diagrams is also given. drift:write: report drift runs and read the style rules, and nothing else, for CI that publishes nothing. boards: read and change the live whiteboards open to the whole organisation, through /v1/boards, and on the hosted MCP server beside diagrams; off unless given.
expiresAtinteger | nullyesWhen the key stops working under the organisation's key policy ("Keys expire after"), in milliseconds since the epoch, or null for never.

CreatedOrgApiKey

FieldTypeRequiredDescription
idstringyes
namestringyes
prefixstringyes
last4stringyes
createdAtintegeryesMilliseconds since the epoch.
lastUsedAtinteger | nullyesMilliseconds since the epoch, or null if never used.
revealablebooleanyesTrue when the full key can be shown again with the reveal route. False for a key made before that was possible, or on a server that cannot seal keys.
keystringyesThe full key. When revealable is false this is the only time it is shown, so store it now.
scopes("diagrams" | "audit:read" | "drift:write" | "boards" | "design:write")[]yesdiagrams: read the library, publish, change its diagrams, report drift runs and read the style rules, which every key made before scopes holds. audit:read: read and export the audit log, and nothing else unless diagrams is also given. drift:write: report drift runs and read the style rules, and nothing else, for CI that publishes nothing. boards: read and change the live whiteboards open to the whole organisation, through /v1/boards, and on the hosted MCP server beside diagrams; off unless given.
expiresAtinteger | nullyesWhen the key stops working under the organisation's key policy ("Keys expire after"), in milliseconds since the epoch, or null for never.

CreateOrgApiKeyBody

FieldTypeRequiredDescription
namestringyesat least 1 character; at most 60 characters; pattern \S.
scopes("diagrams" | "audit:read" | "drift:write" | "boards" | "design:write")[]noWhat the key may do. Left out, ["diagrams"]. A key for a SIEM takes ["audit:read"] alone.

TrustedPublisherList

FieldTypeRequiredDescription
activebooleanyesWhether the owner's plan includes trusted publishers. Entries saved before stay, and sign nothing in, while it does not.
plan"free" | "pro" | "enterprise"yes
audiencestring | nullyesThe audience a GitHub workflow asks GitHub for: this API's origin. Null on a server that cannot exchange GitHub's tokens.
issuerstringyesThe issuer of GitHub's tokens.
azureDevopsobjectyesWhat an Azure Pipelines token is: its issuer, which ends in the Azure DevOps organisation's id, and the audience Azure DevOps always names.
azureDevops.issuerPrefixstringyes
azureDevops.audiencestringyes
gitlabobjectyesWhat a GitLab job's token is: GitLab.com's issuer, the instance an entry names when no host is typed. A GitLab job asks for audience in its id_tokens.
gitlab.defaultIssuerstringyes
limitintegeryesThe most trusted publishers an organisation may have.
itemsTrustedPublisher[]yesBy name, then id.
items[].idstringyes
items[].namestringyes
items[].provider"github" | "azure-devops" | "gitlab"yesgithub for a GitHub Actions workflow, azure-devops for an Azure Pipelines pipeline, gitlab for a GitLab project's CI/CD pipelines.
items[].repositorystring | nullyesA GitHub entry's repository, owner/name. Null for the other providers.
items[].repositoryIdstring | nullyesGitHub's id of the repository, which a run's token must carry. Null until known: a private repository's is pinned by its first run.
items[].repositoryOwnerIdstring | nullyesGitHub's id of the repository's owner, which a run's token must carry. Null until known.
items[].workflowstring | nullyesA GitHub entry's workflow file in .github/workflows the run must start from. Null for the other providers.
items[].environmentstring | nullyesThe deployment environment the job must run in, or null for any.
items[].refstring | nullyesThe ref pattern the run must match, such as refs/heads/main, or null for any ref.
items[].azureDevopsTrustedPublisherAzureDevopsPipelineyesAn Azure Pipelines entry's pipeline. Null for the other providers.
items[].azureDevops.organizationstringyesThe Azure DevOps organisation, by name.
items[].azureDevops.projectstringyesThe project, by name.
items[].azureDevops.pipelineIdstringyesThe pipeline's definition id, definitionId in its address.
items[].azureDevops.organizationIdstring | nullyesAzure DevOps's id of the organisation, which a run's token must carry. Null until the first run pins it.
items[].azureDevops.projectIdstring | nullyesAzure DevOps's id of the project, which a run's token must carry. Null until the first run pins it.
items[].gitlabTrustedPublisherGitlabProjectyesA GitLab entry's project. Null for the other providers.
items[].gitlab.hoststringyesThe GitLab instance, exactly as its tokens name their issuer.
items[].gitlab.projectPathstringyesThe project's full path.
items[].gitlab.projectIdstring | nullyesGitLab's id of the project, which a job's token must carry. Null until the first job pins it.
items[].gitlab.namespaceIdstring | nullyesGitLab's id of the project's group, which a job's token must carry. Null until the first job pins it.
items[].gitlab.protectedOnlybooleanyesWhether only a job for a protected branch or tag signs in.
items[].permissions("diagrams" | "drift:write")[]yesdiagrams: publish to the organisation's library (and read it and the style rules). drift:write: report drift runs to the Drift tab and read the style rules.
items[].createdAtintegeryesMilliseconds since the epoch.
items[].createdByobject | nullyesWho added it, or null when that account is gone.
items[].createdBy.idstringyes
items[].createdBy.emailstringyes
items[].updatedAtintegeryesMilliseconds since the epoch.
items[].lastUsedAtinteger | nullyesWhen a run last signed in with it, in milliseconds since the epoch, or null for never.
items[].refusedAtinteger | nullyesWhen a run that named it was last refused, in milliseconds since the epoch, or null for never. At or after lastUsedAt, the entry is invalid: its runs do not sign in now.
items[].groupstringyesThe group it is listed under, as GET /orgs/{org}/trusted-publishers/groups names it.
nextCursorstring | nullyesSend as cursor for the next page; null on the last.

TrustedPublisher

FieldTypeRequiredDescription
idstringyes
namestringyes
provider"github" | "azure-devops" | "gitlab"yesgithub for a GitHub Actions workflow, azure-devops for an Azure Pipelines pipeline, gitlab for a GitLab project's CI/CD pipelines.
repositorystring | nullyesA GitHub entry's repository, owner/name. Null for the other providers.
repositoryIdstring | nullyesGitHub's id of the repository, which a run's token must carry. Null until known: a private repository's is pinned by its first run.
repositoryOwnerIdstring | nullyesGitHub's id of the repository's owner, which a run's token must carry. Null until known.
workflowstring | nullyesA GitHub entry's workflow file in .github/workflows the run must start from. Null for the other providers.
environmentstring | nullyesThe deployment environment the job must run in, or null for any.
refstring | nullyesThe ref pattern the run must match, such as refs/heads/main, or null for any ref.
azureDevopsTrustedPublisherAzureDevopsPipelineyesAn Azure Pipelines entry's pipeline. Null for the other providers.
azureDevops.organizationstringyesThe Azure DevOps organisation, by name.
azureDevops.projectstringyesThe project, by name.
azureDevops.pipelineIdstringyesThe pipeline's definition id, definitionId in its address.
azureDevops.organizationIdstring | nullyesAzure DevOps's id of the organisation, which a run's token must carry. Null until the first run pins it.
azureDevops.projectIdstring | nullyesAzure DevOps's id of the project, which a run's token must carry. Null until the first run pins it.
gitlabTrustedPublisherGitlabProjectyesA GitLab entry's project. Null for the other providers.
gitlab.hoststringyesThe GitLab instance, exactly as its tokens name their issuer.
gitlab.projectPathstringyesThe project's full path.
gitlab.projectIdstring | nullyesGitLab's id of the project, which a job's token must carry. Null until the first job pins it.
gitlab.namespaceIdstring | nullyesGitLab's id of the project's group, which a job's token must carry. Null until the first job pins it.
gitlab.protectedOnlybooleanyesWhether only a job for a protected branch or tag signs in.
permissions("diagrams" | "drift:write")[]yesdiagrams: publish to the organisation's library (and read it and the style rules). drift:write: report drift runs to the Drift tab and read the style rules.
createdAtintegeryesMilliseconds since the epoch.
createdByobject | nullyesWho added it, or null when that account is gone.
createdBy.idstringyes
createdBy.emailstringyes
updatedAtintegeryesMilliseconds since the epoch.
lastUsedAtinteger | nullyesWhen a run last signed in with it, in milliseconds since the epoch, or null for never.
refusedAtinteger | nullyesWhen a run that named it was last refused, in milliseconds since the epoch, or null for never. At or after lastUsedAt, the entry is invalid: its runs do not sign in now.
groupstringyesThe group it is listed under, as GET /orgs/{org}/trusted-publishers/groups names it.

TrustedPublisherAzureDevopsPipeline

An Azure Pipelines entry's pipeline. Null for the other providers.

FieldTypeRequiredDescription
organizationstringyesThe Azure DevOps organisation, by name.
projectstringyesThe project, by name.
pipelineIdstringyesThe pipeline's definition id, definitionId in its address.
organizationIdstring | nullyesAzure DevOps's id of the organisation, which a run's token must carry. Null until the first run pins it.
projectIdstring | nullyesAzure DevOps's id of the project, which a run's token must carry. Null until the first run pins it.

TrustedPublisherGitlabProject

A GitLab entry's project. Null for the other providers.

FieldTypeRequiredDescription
hoststringyesThe GitLab instance, exactly as its tokens name their issuer.
projectPathstringyesThe project's full path.
projectIdstring | nullyesGitLab's id of the project, which a job's token must carry. Null until the first job pins it.
namespaceIdstring | nullyesGitLab's id of the project's group, which a job's token must carry. Null until the first job pins it.
protectedOnlybooleanyesWhether only a job for a protected branch or tag signs in.

TrustedPublisherGroups

FieldTypeRequiredDescription
activebooleanyesWhether the owner's plan includes trusted publishers. Entries saved before stay, and sign nothing in, while it does not.
plan"free" | "pro" | "enterprise"yes
audiencestring | nullyesThe audience a GitHub workflow asks GitHub for: this API's origin. Null on a server that cannot exchange GitHub's tokens.
issuerstringyesThe issuer of GitHub's tokens.
azureDevopsobjectyesWhat an Azure Pipelines token is: its issuer, which ends in the Azure DevOps organisation's id, and the audience Azure DevOps always names.
azureDevops.issuerPrefixstringyes
azureDevops.audiencestringyes
gitlabobjectyesWhat a GitLab job's token is: GitLab.com's issuer, the instance an entry names when no host is typed. A GitLab job asks for audience in its id_tokens.
gitlab.defaultIssuerstringyes
limitintegeryesThe most trusted publishers an organisation may have.
heldinteger | nullyesHow many trusted publishers the organisation has, whatever the filters. On the first page only, null after it.
totalsobject | nullyesThe entries that match the filters, in all and by CI provider. On the first page only, null after it.
totals.allintegeryes
totals.githubintegeryes
totals.azure-devopsintegeryes
totals.gitlabintegeryes
groupsTrustedPublisherGroup[]yesBy provider, then owner in lower case.
groups[].idstringyesThe provider and the owner in lower case, to send as group.
groups[].provider"github" | "azure-devops" | "gitlab"yes
groups[].ownerstringyesA GitHub repository's owner, an Azure DevOps organisation and project, or a GitLab project's group path (after its host when it is not GitLab.com), as typed.
groups[].countintegeryesIts entries that match the filters.
groups[].neverintegeryesOf them, the ones no run signed in with yet.
groups[].invalidintegeryesOf them, the ones whose last exchange was refused.
nextCursorstring | nullyesSend as cursor for the next page of groups; null on the last.

TrustedPublisherGroup

FieldTypeRequiredDescription
idstringyesThe provider and the owner in lower case, to send as group.
provider"github" | "azure-devops" | "gitlab"yes
ownerstringyesA GitHub repository's owner, an Azure DevOps organisation and project, or a GitLab project's group path (after its host when it is not GitLab.com), as typed.
countintegeryesIts entries that match the filters.
neverintegeryesOf them, the ones no run signed in with yet.
invalidintegeryesOf them, the ones whose last exchange was refused.

TrustedPublisherBody

FieldTypeRequiredDescription

TrustedPublisherGithubBody

FieldTypeRequiredDescription
namestringnoA name to recognise it by in the usage, the call history and the audit log. Left out or blank, the repository name and the workflow, or the project and the pipeline id. at most 60 characters.
provider"github"noThe CI provider: github, the default.
repositorystringyesThe repository, owner/name. at most 140 characters.
workflowstringyesThe workflow file in .github/workflows, with no folder. at most 100 characters.
environmentstring | nullnoThe deployment environment the job must run in. Left out, null or blank, any job of the workflow. at most 255 characters.
refstring | nullnoA branch (main) or a ref pattern (refs/tags/v*, * for any characters) the run must be for. Left out, null or blank, any ref. at most 255 characters.
permissions("diagrams" | "drift:write")[]noWhat its runs may do. Left out, both.

TrustedPublisherAzureDevopsBody

FieldTypeRequiredDescription
namestringnoA name to recognise it by in the usage, the call history and the audit log. Left out or blank, the repository name and the workflow, or the project and the pipeline id. at most 60 characters.
provider"azure-devops"yesThe CI provider: azure-devops for an Azure Pipelines pipeline.
azureOrganizationstringyesThe Azure DevOps organisation, by name: acme in https://dev.azure.com/acme. at most 50 characters.
azureProjectstringyesThe project, by name. at most 64 characters.
pipelineIdstringyesThe pipeline's definition id: the number after definitionId= in the address of its runs. A rename keeps it. at most 10 characters.
refstring | nullnoA branch (main) or a ref pattern (refs/tags/v*, * for any characters) the run must be for. Left out, null or blank, any ref. at most 255 characters.
permissions("diagrams" | "drift:write")[]noWhat its runs may do. Left out, both.

TrustedPublisherGitlabBody

FieldTypeRequiredDescription
namestringnoA name to recognise it by in the usage, the call history and the audit log. Left out or blank, the repository name and the workflow, or the project and the pipeline id. at most 60 characters.
provider"gitlab"yesThe CI provider: gitlab for a GitLab project's CI/CD pipelines.
gitlabHoststring | nullnoThe GitLab instance: left out, null or blank for GitLab.com, or a self-managed instance as a host name or https:// address with no port or path. A self-managed instance must answer its OpenID Connect discovery document from the internet. at most 261 characters.
projectPathstringyesThe project's full path, group/subgroup/project. at most 255 characters.
environmentstring | nullnoThe environment the job must name in environment:. Left out, null or blank, any job of the project's pipelines. at most 255 characters.
refstring | nullnoA branch (main) or a ref pattern (refs/tags/v*, * for any characters) the run must be for. Left out, null or blank, any ref. at most 255 characters.
protectedOnlybooleannoWhen true, only a job for a protected branch or tag signs in. Left out, false.
permissions("diagrams" | "drift:write")[]noWhat its runs may do. Left out, both.

OrgAzureDevopsConnector

FieldTypeRequiredDescription
configuredbooleanyesWhether this server has the Microsoft Entra app the connector signs in with. When false, the trusted publisher form keeps its typed fields.
availablebooleanyesWhether the plan has trusted publishers, which the connector serves: Pro and Enterprise.
planstringyes
connectionobject | nullyesThe sign-in, or null when nobody has connected Azure DevOps. The token is never answered.
connection.accountLabelstring | nullyesThe Microsoft account's address or display name, whose access the lists use.
connection.connectedByobject | nullyesThe Plotwork account that connected it, or null when that account is gone.
connection.connectedBy.idstringyes
connection.connectedBy.emailstringyes
connection.connectedBy.namestring | nullyes
connection.connectedAtintegeryes

OrgAzureDevopsConnect

FieldTypeRequiredDescription
urlstringyesMicrosoft's sign-in page. The browser goes there next.

OrgAzureDevopsOrganizations

FieldTypeRequiredDescription
itemsobject[]yesThe Azure DevOps organisations the connected account is a member of, by name.
items[].idstringyes
items[].namestringyes
truncatedbooleanyes

OrgAzureDevopsProjects

FieldTypeRequiredDescription
itemsobject[]yesThe organisation's projects, by name.
items[].idstringyes
items[].namestringyes
truncatedbooleanyes

OrgAzureDevopsPipelines

FieldTypeRequiredDescription
itemsobject[]yesThe project's pipelines, by folder then name.
items[].idstringyesThe pipeline's definition id, the definitionId of its address.
items[].namestringyes
items[].folderstringyesThe folder it is in, \ for the top.
truncatedbooleanyesTrue when there were more than 1,000.

OrgAzureDevopsPipeline

FieldTypeRequiredDescription
idstringyesThe pipeline's definition id, the definitionId of its address.
namestringyes
folderstringyesThe folder it is in, \ for the top.
repositoryobject | nullyesThe repository the pipeline builds, by name, and its kind (such as TfsGit or GitHub).
repository.namestringyes
repository.typestringyes
defaultBranchstring | nullyesThe repository's default branch for the pipeline, such as refs/heads/main.

RunTask

FieldTypeRequiredDescription
activebooleanyesWhether the owner's plan includes the run task (Pro and Enterprise). While it does not, each run is reported as passed with a sentence, and nothing is drawn.
plan"free" | "pro" | "enterprise"yes
enabledbooleanyesWhether the run task is on.
endpointstring | nullyesThe endpoint URL to give HCP Terraform, by the organisation id. Null on a server with no API_URL.
keyLast4string | nullyesThe HMAC key's last four characters, or null while the run task is off.
failOnErrorbooleanyesTrue when a run Plotwork cannot draw or keep is reported as failed. False (the default) reports it as passed, with a sentence.
enabledAtinteger | nullyesWhen it was turned on, in milliseconds since the epoch.
enabledByobject | nullyesWho turned it on, or null when that account is gone.
enabledBy.idstringyes
enabledBy.emailstringyes
lastRunAtinteger | nullyesWhen HCP Terraform last called it for a run, in milliseconds since the epoch, or null for never.
lastStatus"passed" | "failed" | nullyesThe status sent back to the last run.

RunTaskWithKey

FieldTypeRequiredDescription
activebooleanyesWhether the owner's plan includes the run task (Pro and Enterprise). While it does not, each run is reported as passed with a sentence, and nothing is drawn.
plan"free" | "pro" | "enterprise"yes
enabledbooleanyesWhether the run task is on.
endpointstring | nullyesThe endpoint URL to give HCP Terraform, by the organisation id. Null on a server with no API_URL.
keyLast4string | nullyesThe HMAC key's last four characters, or null while the run task is off.
failOnErrorbooleanyesTrue when a run Plotwork cannot draw or keep is reported as failed. False (the default) reports it as passed, with a sentence.
enabledAtinteger | nullyesWhen it was turned on, in milliseconds since the epoch.
enabledByobject | nullyesWho turned it on, or null when that account is gone.
enabledBy.idstringyes
enabledBy.emailstringyes
lastRunAtinteger | nullyesWhen HCP Terraform last called it for a run, in milliseconds since the epoch, or null for never.
lastStatus"passed" | "failed" | nullyesThe status sent back to the last run.
hmacKeystringyesThe HMAC key to give HCP Terraform. Shown by this answer only; keep it out of logs and files. 64 hex characters.

RunTaskOptions

FieldTypeRequiredDescription
failOnErrorbooleanyesReport a run Plotwork cannot draw or keep as failed. With an advisory run task the run still goes on.

OrgEvidence

FieldTypeRequiredDescription
activebooleanyesTrue when the plan includes compliance evidence (Enterprise). When false the lists are empty.
plan"free" | "pro" | "enterprise"yes
retentionDaysintegeryesminimum 0.
legalHoldbooleanyes
githubLinkedbooleanyes
settingsEvidenceSettingsyes
settings.frameworks("pci-dss" | "soc2" | "iso27001" | "nist-800-53")[]yes
settings.staleDaysintegeryes
settings.defaultsbooleanyesTrue when nothing was saved and these are the defaults: every framework, 14 days.
frameworksEvidenceFrameworkSummary[]yes
frameworks[].id"pci-dss" | "soc2" | "iso27001" | "nist-800-53"yes
frameworks[].namestringyes
frameworks[].versionstringyes
frameworks[].markstringyes
frameworks[].sourcestringyes
frameworks[].chosenbooleanyes
frameworks[].controlsEvidenceControlSummary[]yes
frameworks[].controls[].idstringyes
frameworks[].controls[].refstringyes
frameworks[].controls[].titlestringyes
frameworks[].controls[].evidencestringyes
frameworks[].controls[].textstringyes
frameworks[].controls[].paraphrasedbooleanyes
frameworks[].controls[].howstringyes
frameworks[].controls[].limitstringyes
frameworks[].controls[].totalintegeryesDiagrams mapped to it, hand-drawn ones included. minimum 0.
frameworks[].controls[].currentintegeryesOf those, the ones that are current. minimum 0.
repositoriesEvidenceRepository[]yes
repositories[].repositorystringyes
repositories[].status"current" | "drifted" | "stale" | "unknown"yescurrent, drifted, stale or unknown, by the checks on the default branch (docs/architecture/compliance-evidence.md, section 2).
repositories[].repositoryIdstring | nullyesThe GitHub App's id of the repository, when an installation reaches it.
repositories[].privateboolean | nullyes
repositories[].archivedbooleanyes
repositories[].setup"none" | "pr_open" | "merged" | "closed" | nullyes
repositories[].diagramsintegeryesminimum 0.
repositories[].currentintegeryesminimum 0.
repositories[].driftedintegeryesminimum 0.
repositories[].staleintegeryesminimum 0.
repositories[].unknownintegeryesminimum 0.
repositories[].unverifiedintegeryesminimum 0.
repositories[].lastCheckedAtinteger | nullyes
repositories[].runUrlstring | nullyes
repositories[].controlsstring[]yes
repositories[].badgebooleanyesTrue when its README badge is on.
repositories[].scannedAtinteger | nullyes
diagramsEvidenceDiagram[]yes
diagrams[].repositorystringyes
diagrams[].namestringyes
diagrams[].outstringyesThe diagram's path in the repository.
diagrams[].formatstring | nullyesThe importer it is drawn with, as the run reported or as its name says, or null.
diagrams[].status"current" | "drifted" | "stale" | "unknown"yescurrent, drifted, stale or unknown, by the checks on the default branch (docs/architecture/compliance-evidence.md, section 2).
diagrams[].lastKnown"current" | "drifted" | nullyesFor a stale diagram, what its latest conclusive check found.
diagrams[].lastCheckFailedbooleanyesTrue when the latest check could not make the diagram; the status is the one before it.
diagrams[].driftedSinceinteger | nullyesFor a drifted diagram, when its drift began.
diagrams[].addedintegeryesminimum 0.
diagrams[].removedintegeryesminimum 0.
diagrams[].changedintegeryesminimum 0.
diagrams[].lastCheckedAtinteger | nullyes
diagrams[].lastShastring | nullyes
diagrams[].runUrlstring | nullyes
diagrams[].pullRequestUrlstring | nullyes
diagrams[].controlsstring[]yesThe controls it serves as evidence for, suggested or set.
diagrams[].suggestedstring[]yesThe controls its format suggests.
findingsEvidenceFinding[]yes
findings[].idstringyes
findings[].repositorystringyes
findings[].pathstringyes
findings[].lineintegeryes
findings[].mermaidTypestring | nullyes
findings[].kindstring | nullyes
findings[].nodesintegeryesminimum 0.
findings[].matchedintegeryesminimum 0.
findings[].sourceobject | nullyesThe detected source that shares the most names with it.
findings[].source.namestringyes
findings[].source.formatstringyes
findings[].mentionsMissingstring[]yesHints: names it draws that no source declares. Hints, not verification.
findings[].codeMissingstring[]yesHints: names the matching source declares that it does not draw.
findings[].pullRequestNumberinteger | nullyes
findings[].supersededbooleanyesTrue once the source its pull request added has a check.
findings[].controlsstring[]yes
findings[].suggestedstring[]yes
findings[].scannedAtintegeryes
trendobject | nullyesThe 90-day trend, from the stored checks. Null on a plan without compliance evidence.
trend.daysstring[]yesThe last 90 UTC dates, oldest first.
trend.overall(number | null)[]yesThe share of diagrams drawn from code that were current at the end of each day, 0 to 1, or null before any.
trend.frameworksobjectyesThe same share over the diagrams mapped to each framework's controls.
trend.frameworks.pci-dss(number | null)[]no
trend.frameworks.soc2(number | null)[]no
trend.frameworks.iso27001(number | null)[]no
trend.frameworks.nist-800-53(number | null)[]no
truncatedbooleanyes

EvidenceSettings

FieldTypeRequiredDescription
frameworks("pci-dss" | "soc2" | "iso27001" | "nist-800-53")[]yes
staleDaysintegeryes
defaultsbooleanyesTrue when nothing was saved and these are the defaults: every framework, 14 days.

EvidenceFrameworkSummary

FieldTypeRequiredDescription
id"pci-dss" | "soc2" | "iso27001" | "nist-800-53"yes
namestringyes
versionstringyes
markstringyes
sourcestringyes
chosenbooleanyes
controlsEvidenceControlSummary[]yes
controls[].idstringyes
controls[].refstringyes
controls[].titlestringyes
controls[].evidencestringyes
controls[].textstringyes
controls[].paraphrasedbooleanyes
controls[].howstringyes
controls[].limitstringyes
controls[].totalintegeryesDiagrams mapped to it, hand-drawn ones included. minimum 0.
controls[].currentintegeryesOf those, the ones that are current. minimum 0.

EvidenceControlSummary

FieldTypeRequiredDescription
idstringyes
refstringyes
titlestringyes
evidencestringyes
textstringyes
paraphrasedbooleanyes
howstringyes
limitstringyes
totalintegeryesDiagrams mapped to it, hand-drawn ones included. minimum 0.
currentintegeryesOf those, the ones that are current. minimum 0.

EvidenceRepository

FieldTypeRequiredDescription
repositorystringyes
status"current" | "drifted" | "stale" | "unknown"yescurrent, drifted, stale or unknown, by the checks on the default branch (docs/architecture/compliance-evidence.md, section 2).
repositoryIdstring | nullyesThe GitHub App's id of the repository, when an installation reaches it.
privateboolean | nullyes
archivedbooleanyes
setup"none" | "pr_open" | "merged" | "closed" | nullyes
diagramsintegeryesminimum 0.
currentintegeryesminimum 0.
driftedintegeryesminimum 0.
staleintegeryesminimum 0.
unknownintegeryesminimum 0.
unverifiedintegeryesminimum 0.
lastCheckedAtinteger | nullyes
runUrlstring | nullyes
controlsstring[]yes
badgebooleanyesTrue when its README badge is on.
scannedAtinteger | nullyes

EvidenceDiagram

FieldTypeRequiredDescription
repositorystringyes
namestringyes
outstringyesThe diagram's path in the repository.
formatstring | nullyesThe importer it is drawn with, as the run reported or as its name says, or null.
status"current" | "drifted" | "stale" | "unknown"yescurrent, drifted, stale or unknown, by the checks on the default branch (docs/architecture/compliance-evidence.md, section 2).
lastKnown"current" | "drifted" | nullyesFor a stale diagram, what its latest conclusive check found.
lastCheckFailedbooleanyesTrue when the latest check could not make the diagram; the status is the one before it.
driftedSinceinteger | nullyesFor a drifted diagram, when its drift began.
addedintegeryesminimum 0.
removedintegeryesminimum 0.
changedintegeryesminimum 0.
lastCheckedAtinteger | nullyes
lastShastring | nullyes
runUrlstring | nullyes
pullRequestUrlstring | nullyes
controlsstring[]yesThe controls it serves as evidence for, suggested or set.
suggestedstring[]yesThe controls its format suggests.

EvidenceFinding

FieldTypeRequiredDescription
idstringyes
repositorystringyes
pathstringyes
lineintegeryes
mermaidTypestring | nullyes
kindstring | nullyes
nodesintegeryesminimum 0.
matchedintegeryesminimum 0.
sourceobject | nullyesThe detected source that shares the most names with it.
source.namestringyes
source.formatstringyes
mentionsMissingstring[]yesHints: names it draws that no source declares. Hints, not verification.
codeMissingstring[]yesHints: names the matching source declares that it does not draw.
pullRequestNumberinteger | nullyes
supersededbooleanyesTrue once the source its pull request added has a check.
controlsstring[]yes
suggestedstring[]yes
scannedAtintegeryes

EvidenceSettingsBody

FieldTypeRequiredDescription
frameworks("pci-dss" | "soc2" | "iso27001" | "nist-800-53")[]yesThe frameworks the page shows, each once.
staleDaysintegeryesDays without a conclusive check on the default branch after which a diagram is stale, 1 to 90. minimum 1; maximum 90.

EvidenceControlBody

FieldTypeRequiredDescription
repositorystringyesThe repository, as owner/name. at most 140 characters; pattern ^[A-Za-z0-9][A-Za-z0-9-]{0,38}\/[A-Za-z0-9._-]{1,100}$.
diagramstringyesThe diagram: a source name, or mermaid:<finding id> for a hand-drawn one. at least 1 character; at most 160 characters; pattern ^[^\p{Cc}]+$/u.
control"pci-dss:1.2.3" | "pci-dss:1.2.4" | "soc2:CC2.1" | "soc2:CC8.1" | "iso27001:A.5.9" | "iso27001:A.8.9" | "nist-800-53:CM-8" | "nist-800-53:PL-2"yesA control: <framework>:<control>, such as pci-dss:1.2.4.
mode"add" | "remove" | nullyesadd maps the diagram to the control, remove takes a suggested one off, and null returns it to its suggestion.

EvidenceDiagramDetail

FieldTypeRequiredDescription
diagramEvidenceDiagramyes
diagram.repositorystringyes
diagram.namestringyes
diagram.outstringyesThe diagram's path in the repository.
diagram.formatstring | nullyesThe importer it is drawn with, as the run reported or as its name says, or null.
diagram.status"current" | "drifted" | "stale" | "unknown"yescurrent, drifted, stale or unknown, by the checks on the default branch (docs/architecture/compliance-evidence.md, section 2).
diagram.lastKnown"current" | "drifted" | nullyesFor a stale diagram, what its latest conclusive check found.
diagram.lastCheckFailedbooleanyesTrue when the latest check could not make the diagram; the status is the one before it.
diagram.driftedSinceinteger | nullyesFor a drifted diagram, when its drift began.
diagram.addedintegeryesminimum 0.
diagram.removedintegeryesminimum 0.
diagram.changedintegeryesminimum 0.
diagram.lastCheckedAtinteger | nullyes
diagram.lastShastring | nullyes
diagram.runUrlstring | nullyes
diagram.pullRequestUrlstring | nullyes
diagram.controlsstring[]yesThe controls it serves as evidence for, suggested or set.
diagram.suggestedstring[]yesThe controls its format suggests.
checksEvidenceCheck[]yes
checks[].status"in-step" | "drifted" | "written" | "failed"yes
checks[].checksintegeryes
checks[].firstAtintegeryes
checks[].lastAtintegeryes
checks[].firstShastring | nullyes
checks[].lastShastring | nullyes
checks[].runUrlstring | nullyes
checks[].pullRequestUrlstring | nullyes
checks[].addedintegeryesminimum 0.
checks[].removedintegeryesminimum 0.
checks[].changedintegeryesminimum 0.
truncatedbooleanyes
episodesEvidenceEpisode[]yes
episodes[].startedAtintegeryes
episodes[].resolvedAtinteger | nullyes
episodes[].checksintegeryesminimum 0.
episodes[].addedintegeryesminimum 0.
episodes[].removedintegeryesminimum 0.
episodes[].changedintegeryesminimum 0.
episodes[].pullRequestUrlstring | nullyes
episodes[].resolvedShastring | nullyes
episodes[].resolvedRunUrlstring | nullyes

EvidenceCheck

FieldTypeRequiredDescription
status"in-step" | "drifted" | "written" | "failed"yes
checksintegeryes
firstAtintegeryes
lastAtintegeryes
firstShastring | nullyes
lastShastring | nullyes
runUrlstring | nullyes
pullRequestUrlstring | nullyes
addedintegeryesminimum 0.
removedintegeryesminimum 0.
changedintegeryesminimum 0.

EvidenceEpisode

FieldTypeRequiredDescription
startedAtintegeryes
resolvedAtinteger | nullyes
checksintegeryesminimum 0.
addedintegeryesminimum 0.
removedintegeryesminimum 0.
changedintegeryesminimum 0.
pullRequestUrlstring | nullyes
resolvedShastring | nullyes
resolvedRunUrlstring | nullyes

EvidenceBadge

FieldTypeRequiredDescription
repositorystringyes
urlstringyesThe badge, an SVG. The address is the secret: it names no repository.
markdownstringyes

EvidenceBadgeBody

FieldTypeRequiredDescription
repositorystringyesThe repository, as owner/name. at most 140 characters; pattern ^[A-Za-z0-9][A-Za-z0-9-]{0,38}\/[A-Za-z0-9._-]{1,100}$.

EvidenceScan

FieldTypeRequiredDescription
repositorystringyes
documentsintegeryesminimum 0.
truncatedbooleanyes
archivedbooleanyes
findingsEvidenceFinding[]yes
findings[].idstringyes
findings[].repositorystringyes
findings[].pathstringyes
findings[].lineintegeryes
findings[].mermaidTypestring | nullyes
findings[].kindstring | nullyes
findings[].nodesintegeryesminimum 0.
findings[].matchedintegeryesminimum 0.
findings[].sourceobject | nullyesThe detected source that shares the most names with it.
findings[].source.namestringyes
findings[].source.formatstringyes
findings[].mentionsMissingstring[]yesHints: names it draws that no source declares. Hints, not verification.
findings[].codeMissingstring[]yesHints: names the matching source declares that it does not draw.
findings[].pullRequestNumberinteger | nullyes
findings[].supersededbooleanyesTrue once the source its pull request added has a check.
findings[].controlsstring[]yes
findings[].suggestedstring[]yes
findings[].scannedAtintegeryes

EvidenceVerify

FieldTypeRequiredDescription
outcome"opened" | "present"yesopened: a pull request; present: the settings already draw the source.
sourceobjectyes
source.namestringyes
source.formatstringyes
pullRequestobject | nullyes
pullRequest.numberintegeryes
pullRequest.urlstringyes

EvidenceShareCreated

FieldTypeRequiredDescription
idstringyes
framework"pci-dss" | "soc2" | "iso27001" | "nist-800-53" | "all"yes
fromstringyes
tostringyes
paper"a4" | "letter"yes
labelstring | nullyes
protection"none" | "password" | "emails"yes
emailsstring[]yes
createdBystring | nullyes
createdAtintegeryes
expiresAtintegeryes
revokedAtinteger | nullyes
viewsintegeryesminimum 0.
lastViewedAtinteger | nullyes
state"live" | "expired" | "revoked"yes
urlstringyesThe link. Its address is the secret: only its hash is stored, so it is in this answer and nowhere else.

EvidenceShare

FieldTypeRequiredDescription
idstringyes
framework"pci-dss" | "soc2" | "iso27001" | "nist-800-53" | "all"yes
fromstringyes
tostringyes
paper"a4" | "letter"yes
labelstring | nullyes
protection"none" | "password" | "emails"yes
emailsstring[]yes
createdBystring | nullyes
createdAtintegeryes
expiresAtintegeryes
revokedAtinteger | nullyes
viewsintegeryesminimum 0.
lastViewedAtinteger | nullyes
state"live" | "expired" | "revoked"yes

EvidenceShareBody

FieldTypeRequiredDescription
framework"pci-dss" | "soc2" | "iso27001" | "nist-800-53" | "all"yesOne framework, or all.
fromstringyesThe first day, YYYY-MM-DD, UTC.
tostringyesThe last day, YYYY-MM-DD, UTC.
paper"a4" | "letter"noThe report's paper. default "a4".
labelstring | nullnoA name for the link in the list, such as "FY26 SOC 2 audit". Shown to the viewer. at least 1 character; at most 80 characters; default null.
days7 | 30 | 90yesDays until the link stops working: 7, 30 or 90.
passwordstring | nullnoA password the viewer types, at least 10 characters. Only a salted hash is kept. at least 10 characters; at most 200 characters; default null.
emailsarray | nullnoThe addresses that may open it, signed in to Plotwork with an emailed code. Not with a password. default null.

EvidenceShareList

FieldTypeRequiredDescription
sharesEvidenceShare[]yes
shares[].idstringyes
shares[].framework"pci-dss" | "soc2" | "iso27001" | "nist-800-53" | "all"yes
shares[].fromstringyes
shares[].tostringyes
shares[].paper"a4" | "letter"yes
shares[].labelstring | nullyes
shares[].protection"none" | "password" | "emails"yes
shares[].emailsstring[]yes
shares[].createdBystring | nullyes
shares[].createdAtintegeryes
shares[].expiresAtintegeryes
shares[].revokedAtinteger | nullyes
shares[].viewsintegeryesminimum 0.
shares[].lastViewedAtinteger | nullyes
shares[].state"live" | "expired" | "revoked"yes

OrgConnectionList

FieldTypeRequiredDescription
itemsOrgConnection[]yes
items[].idstringyes
items[].clientIdstringyesThe OAuth client id the agent registered with.
items[].clientNamestringyesThe name the agent gave itself when it registered. It is a claim, not a fact.
items[].connectedAtintegeryesMilliseconds since the epoch.
items[].lastUsedAtinteger | nullyesMilliseconds since the epoch, or null if the agent has not made a call.
items[].connectedByobjectyesThe member who approved the connection.
items[].connectedBy.userIdstringyes
items[].connectedBy.emailstringyes

OrgConnection

FieldTypeRequiredDescription
idstringyes
clientIdstringyesThe OAuth client id the agent registered with.
clientNamestringyesThe name the agent gave itself when it registered. It is a claim, not a fact.
connectedAtintegeryesMilliseconds since the epoch.
lastUsedAtinteger | nullyesMilliseconds since the epoch, or null if the agent has not made a call.
connectedByobjectyesThe member who approved the connection.
connectedBy.userIdstringyes
connectedBy.emailstringyes

NewOrgAppBody

FieldTypeRequiredDescription
namestringyesat least 3 characters; at most 60 characters.
homepagestring | nullnoAn https address, shown as a claim. at most 2048 characters.
clientType"confidential" | "public"yes
redirectUrisstring[]yesOne to ten addresses a code may be sent to, matched exactly: https, or http on localhost, 127.0.0.1 or [::1] with any port.
membersOnlybooleanno

OrgAppChangeBody

FieldTypeRequiredDescription
namestringnoat least 3 characters; at most 60 characters.
homepagestring | nullnoat most 2048 characters.
redirectUrisstring[]noOne to ten addresses a code may be sent to, matched exactly: https, or http on localhost, 127.0.0.1 or [::1] with any port.
membersOnlybooleanno

OrgAppConnectionList

FieldTypeRequiredDescription
itemsOrgAppConnection[]yes
items[].idstringyes
items[].appobjectyes
items[].app.idstringyesThe app's id, which is its OAuth client_id.
items[].app.namestringyes
items[].app.homepagestring | nullyes
items[].scopesAppScope[]yes
items[].connectedAtintegeryes
items[].lastUsedAtinteger | nullyes
items[].connectedByobjectyes
items[].connectedBy.userIdstringyes
items[].connectedBy.emailstringyes

OrgAppConnection

FieldTypeRequiredDescription
idstringyes
appobjectyes
app.idstringyesThe app's id, which is its OAuth client_id.
app.namestringyes
app.homepagestring | nullyes
scopesAppScope[]yes
connectedAtintegeryes
lastUsedAtinteger | nullyes
connectedByobjectyes
connectedBy.userIdstringyes
connectedBy.emailstringyes

AllowedAgentsPolicy

FieldTypeRequiredDescription
enabledbooleanyes"Only approved agents can connect". False means any agent a member approves may connect.
agentsAllowedAgent[]yes
presetsobject[]yes
presets[].idstringyes
presets[].labelstringyes
presets[].entriesobject[]yes
presets[].entries[].namestringyes
presets[].entries[].redirectstringyes
presets[].confirmedbooleanyesFalse when the name and redirect are what the agent is known to send but were not seen in Plotwork's own tests; it may not match.
recentobject[]yesThe agents that connected to the organisation in the last 90 days, one each, newest first.
recent[].entryAllowedAgentyes
recent[].connectionsintegeryesHow many of its connections to the organisation are live.
recent[].lastConnectedAtintegeryes

AllowedAgent

FieldTypeRequiredDescription

AllowedAgentsPolicyResult

FieldTypeRequiredDescription
enabledbooleanyes
agentsAllowedAgent[]yes
connectionsEndedintegeryesThe connections from agents the list no longer approves, which the change ended (or with dryRun, would end).
dryRunbooleanyes

AllowedAgentsPolicyBody

FieldTypeRequiredDescription
enabledbooleanyes
agents(object | object)[]yes
dryRunbooleannoAnswer how many connections the change would end, and change nothing.

AllowedAppsPolicy

FieldTypeRequiredDescription
enabledbooleanyes"Only approved apps can connect". False means any app a member approves may connect.
appsPolicyApp[]yesThe approved apps, by client id, in the order stored.
apps[].idstringyesThe app's client id.
apps[].namestring | nullyesThe name the app registered, a claim; null when no app has the id any more.
apps[].homepagestring | nullyes
apps[].ownbooleanyesTrue for the organisation's own registered app, which is always allowed.
ownPolicyApp[]yesThe organisation's own registered apps, always allowed while the policy is on.
own[].idstringyesThe app's client id.
own[].namestring | nullyesThe name the app registered, a claim; null when no app has the id any more.
own[].homepagestring | nullyes
own[].ownbooleanyesTrue for the organisation's own registered app, which is always allowed.
recentobject[]yesOther apps connected to the organisation in the last 90 days, live or ended, one each, newest first.
recent[].appPolicyAppyes
recent[].app.idstringyesThe app's client id.
recent[].app.namestring | nullyesThe name the app registered, a claim; null when no app has the id any more.
recent[].app.homepagestring | nullyes
recent[].app.ownbooleanyesTrue for the organisation's own registered app, which is always allowed.
recent[].connectionsintegeryesHow many of its connections to the organisation are live.
recent[].lastConnectedAtintegeryes

PolicyApp

FieldTypeRequiredDescription
idstringyesThe app's client id.
namestring | nullyesThe name the app registered, a claim; null when no app has the id any more.
homepagestring | nullyes
ownbooleanyesTrue for the organisation's own registered app, which is always allowed.

AllowedAppsPolicyResult

FieldTypeRequiredDescription
enabledbooleanyes
appsPolicyApp[]yes
apps[].idstringyesThe app's client id.
apps[].namestring | nullyesThe name the app registered, a claim; null when no app has the id any more.
apps[].homepagestring | nullyes
apps[].ownbooleanyesTrue for the organisation's own registered app, which is always allowed.
connectionsEndedintegeryesThe app connections the list no longer allows, which the change ended (or with dryRun, would end).
dryRunbooleanyes

AllowedAppsPolicyBody

FieldTypeRequiredDescription
enabledbooleanyes
appsstring[]yesThe client ids of the apps to approve. Each must name a registered app.
dryRunbooleannoAnswer how many connections the change would end, and change nothing.

KeyPolicy

FieldTypeRequiredDescription
expiryDays30 | 90 | 180 | nullyes"Keys expire after": 30, 90 or 180 days from when a key is made, or null for never.
browserOnlybooleanyes"Agents sign in through the browser only": members and readers on a verified domain make no personal API key, and only the owner and admins make the organisation's keys, for CI.
networksstring[]yes"Keys only from these networks": CIDR ranges, IPv4 or IPv6, in their canonical spelling. Empty is any network.

KeyPolicyResult

FieldTypeRequiredDescription
expiryDays30 | 90 | 180 | nullyes"Keys expire after": 30, 90 or 180 days from when a key is made, or null for never.
browserOnlybooleanyes"Agents sign in through the browser only": members and readers on a verified domain make no personal API key, and only the owner and admins make the organisation's keys, for CI.
networksstring[]yes"Keys only from these networks": CIDR ranges, IPv4 or IPv6, in their canonical spelling. Empty is any network.
keysChangedintegeryesThe live keys whose expiry date the change set, brought forward or cleared (or with dryRun, would).
personalKeysobjectyesWhen the change turns browserOnly on: the members and readers on a verified domain who hold personal API keys, and how many keys. Otherwise zero.
personalKeys.membersintegeryes
personalKeys.keysintegeryes
personalKeysRevokedintegeryesThe personal keys the change revoked, with revokePersonalKeys.
dryRunbooleanyes

KeyPolicyBody

FieldTypeRequiredDescription
expiryDays30 | 90 | 180 | nullyes"Keys expire after": 30, 90 or 180 days from when a key is made, or null for never.
browserOnlybooleanyes
networksstring[]yesCIDR ranges (203.0.113.0/24, 2001:db8::/32) or single addresses. Each is checked and stored in its canonical spelling.
dryRunbooleannoAnswer how many keys would be given a new expiry date, and change nothing.
revokePersonalKeysbooleannoWhen this change turns browserOnly on: also revoke the personal API keys of the members and readers it holds, and email each of them. Off unless sent.

OrgBrand

FieldTypeRequiredDescription
brandBrandColorsyesThe saved brand, or null when none is saved.
brand.primarystringyesLowercase #rrggbb.
brand.secondarystringyesLowercase #rrggbb.
brand.accentstringyesLowercase #rrggbb.
chosen("primary" | "secondary" | "accent")[]yesThe colors the person chose. The others are made from the primary.
activebooleanyesTrue when a brand is saved and the owner's plan includes brand themes, so the hosted service paints with it.
canEditbooleanyesTrue when the caller's role may save, remove and preview a brand: the owner and admins.
plan"free" | "pro" | "enterprise"yesThe organisation's plan, which is its owner's.

BrandColors

The saved brand, or null when none is saved.

FieldTypeRequiredDescription
primarystringyesLowercase #rrggbb.
secondarystringyesLowercase #rrggbb.
accentstringyesLowercase #rrggbb.

SavedBrand

FieldTypeRequiredDescription
brandanyyes
brand.primarystringyesLowercase #rrggbb.
brand.secondarystringyesLowercase #rrggbb.
brand.accentstringyesLowercase #rrggbb.
chosen("primary" | "secondary" | "accent")[]yes
checkBrandCheckyes
check.issuesBrandIssue[]yes
check.issues[].role"primary" | "secondary" | "accent"yes
check.issues[].severity"error" | "warning" | "note"yesAn error stops a save. A warning and a note are advice.
check.issues[].code"not-a-color" | "missing-primary" | "reads-as-status" | "too-similar" | "adjusted"yes
check.issues[].messagestringyes
check.swatchesobject | nullyesThe color each scheme draws for each role, made darker or lighter where it would not keep 3:1 against the surface.
check.swatches.lightobjectyes
check.swatches.darkobjectyes

BrandCheck

FieldTypeRequiredDescription
issuesBrandIssue[]yes
issues[].role"primary" | "secondary" | "accent"yes
issues[].severity"error" | "warning" | "note"yesAn error stops a save. A warning and a note are advice.
issues[].code"not-a-color" | "missing-primary" | "reads-as-status" | "too-similar" | "adjusted"yes
issues[].messagestringyes
swatchesobject | nullyesThe color each scheme draws for each role, made darker or lighter where it would not keep 3:1 against the surface.
swatches.lightobjectyes
swatches.light.primaryobjectyes
swatches.light.secondaryobjectyes
swatches.light.accentobjectyes
swatches.darkobjectyes
swatches.dark.primaryobjectyes
swatches.dark.secondaryobjectyes
swatches.dark.accentobjectyes

BrandIssue

FieldTypeRequiredDescription
role"primary" | "secondary" | "accent"yes
severity"error" | "warning" | "note"yesAn error stops a save. A warning and a note are advice.
code"not-a-color" | "missing-primary" | "reads-as-status" | "too-similar" | "adjusted"yes
messagestringyes

BrandBody

FieldTypeRequiredDescription
primarystring | nullnoThe main brand color, as #rrggbb or #rgb in any case. Takes the place of the blue tone. A brand needs one. at most 32 characters.
secondarystring | nullnoTakes the place of the violet tone. Left out or null, it is made from the primary by turning its hue, and follows the primary. at most 32 characters.
accentstring | nullnoTakes the place of the aqua tone. Left out or null, it is made from the primary by turning its hue, and follows the primary. at most 32 characters.

BrandPreview

FieldTypeRequiredDescription
checkBrandCheckyes
check.issuesBrandIssue[]yes
check.issues[].role"primary" | "secondary" | "accent"yes
check.issues[].severity"error" | "warning" | "note"yesAn error stops a save. A warning and a note are advice.
check.issues[].code"not-a-color" | "missing-primary" | "reads-as-status" | "too-similar" | "adjusted"yes
check.issues[].messagestringyes
check.swatchesobject | nullyesThe color each scheme draws for each role, made darker or lighter where it would not keep 3:1 against the surface.
check.swatches.lightobjectyes
check.swatches.darkobjectyes
picturesBrandPreviewPicture[]yes
pictures[].idstringyes
pictures[].titlestringyes
pictures[].lightstringyesThe sample as an SVG in the light scheme.
pictures[].darkstringyesThe sample as an SVG in the dark scheme.

BrandPreviewPicture

FieldTypeRequiredDescription
idstringyes
titlestringyes
lightstringyesThe sample as an SVG in the light scheme.
darkstringyesThe sample as an SVG in the dark scheme.

AccountBrand

FieldTypeRequiredDescription
chosenobject | nullyesThe organisation whose brand and custom icons the account's own calls use, or null.
chosen.idstringyes
chosen.slugstringyes
chosen.namestringyes
availableobject[]yesThe organisations the account belongs to that have a saved brand or custom icons, by name.
available[].idstringyes
available[].slugstringyes
available[].namestringyes
available[].activebooleanyesTrue when the organisation has a saved brand and the owner's plan includes brand themes.
available[].iconsActivebooleanyesTrue when the organisation has custom icons and the owner's plan includes them.

ChooseBrandBody

FieldTypeRequiredDescription
organizationstring | nullyesAn organisation's id or slug, or null for no brand. The account must be a member and the organisation must have a saved brand. at least 1 character; at most 64 characters.

OrgStyleRules

FieldTypeRequiredDescription
rulesStyleRules | nullyesThe saved rules as the engine read them (the format of docs/architecture/repository-settings.md), or null when none are saved.
textstring | nullyesThe saved rules as the person wrote them, or null.
activebooleanyesTrue when rules are saved and the owner's plan includes saved style rules, so CI that reads them applies them.
canEditbooleanyesTrue when the caller's role may save and remove the rules.
plan"free" | "pro" | "enterprise"yesThe organisation's plan, which is its owner's.
updatedAtinteger | nullyesWhen the rules were last saved, in milliseconds since the epoch, or null.

StyleRules

A team's style rules for its Plotwork diagrams, with the version of the format.

FieldTypeRequiredDescription
$schemastringnoat most 500 characters.
version1yes
level"error" | "warning"noerror fails a check; warning is reported and passes. Defaults to the file's level, which defaults to error.
requireTitlebooleannoEvery diagram has a title in its header.
requireDescriptionbooleannoEvery diagram has desc= in its header, the text screen readers announce.
maxNodesintegernoThe most nodes one diagram may hold. minimum 1; maximum 10000.
forbidKinds("flow" | "sequence" | "schema" | "git" | "gantt" | "class" | "state" | "timeline" | "journey" | "mindmap" | "treemap" | "pie" | "quadrant" | "layers" | "c4" | "matrix" | "sankey" | "xychart" | "tree" | "swimlane" | "requirement" | "block" | "packet" | "kanban" | "radar" | "usecase" | "venn" | "fishbone" | "wardley")[]noKinds of diagram the team does not use.
idsobjectnoA pattern every node id must match.
ids.patternstringyesA JavaScript regular expression, without slashes, such as ^[a-z][a-z0-9_]*$. No nested repeats and no back references. at least 1 character; at most 200 characters.
ids.kinds("flow" | "sequence" | "schema" | "git" | "gantt" | "class" | "state" | "timeline" | "journey" | "mindmap" | "treemap" | "pie" | "quadrant" | "layers" | "c4" | "matrix" | "sankey" | "xychart" | "tree" | "swimlane" | "requirement" | "block" | "packet" | "kanban" | "radar" | "usecase" | "venn" | "fishbone" | "wardley")[]noOnly diagrams of these kinds; every kind when left out.
ids.hintstringnoWhat to tell the author who breaks the rule. at least 1 character; at most 300 characters.
ids.level"error" | "warning"noerror fails a check; warning is reported and passes. Defaults to the file's level, which defaults to error.
labelsobjectnoA pattern every node label must match.
labels.patternstringyesA JavaScript regular expression, without slashes, such as ^[a-z][a-z0-9_]*$. No nested repeats and no back references. at least 1 character; at most 200 characters.
labels.kinds("flow" | "sequence" | "schema" | "git" | "gantt" | "class" | "state" | "timeline" | "journey" | "mindmap" | "treemap" | "pie" | "quadrant" | "layers" | "c4" | "matrix" | "sankey" | "xychart" | "tree" | "swimlane" | "requirement" | "block" | "packet" | "kanban" | "radar" | "usecase" | "venn" | "fishbone" | "wardley")[]noOnly diagrams of these kinds; every kind when left out.
labels.hintstringnoWhat to tell the author who breaks the rule. at least 1 character; at most 300 characters.
labels.level"error" | "warning"noerror fails a check; warning is reported and passes. Defaults to the file's level, which defaults to error.
iconsobject[]noIcons required by label.
icons[].labelstringyesMatched against each node label with case ignored, such as postgres|mysql. at least 1 character; at most 200 characters.
icons[].usestring[]yes
icons[].kinds("flow" | "sequence" | "schema" | "git" | "gantt" | "class" | "state" | "timeline" | "journey" | "mindmap" | "treemap" | "pie" | "quadrant" | "layers" | "c4" | "matrix" | "sankey" | "xychart" | "tree" | "swimlane" | "requirement" | "block" | "packet" | "kanban" | "radar" | "usecase" | "venn" | "fishbone" | "wardley")[]noOnly diagrams of these kinds; every kind when left out.
icons[].hintstringnoWhat to tell the author who breaks the rule. at least 1 character; at most 300 characters.
icons[].level"error" | "warning"noerror fails a check; warning is reported and passes. Defaults to the file's level, which defaults to error.
tonesobject[]noTones allowed or forbidden, by node type.
tones[].typesstring[]noOnly nodes of these types, as the kind names them (database, service, person, table, container); every node when left out.
tones[].allow("neutral" | "blue" | "violet" | "aqua" | "orange" | "green" | "amber" | "red")[]no
tones[].forbid("neutral" | "blue" | "violet" | "aqua" | "orange" | "green" | "amber" | "red")[]no
tones[].kinds("flow" | "sequence" | "schema" | "git" | "gantt" | "class" | "state" | "timeline" | "journey" | "mindmap" | "treemap" | "pie" | "quadrant" | "layers" | "c4" | "matrix" | "sankey" | "xychart" | "tree" | "swimlane" | "requirement" | "block" | "packet" | "kanban" | "radar" | "usecase" | "venn" | "fishbone" | "wardley")[]noOnly diagrams of these kinds; every kind when left out.
tones[].hintstringnoWhat to tell the author who breaks the rule. at least 1 character; at most 300 characters.
tones[].level"error" | "warning"noerror fails a check; warning is reported and passes. Defaults to the file's level, which defaults to error.

StyleRulesBody

FieldTypeRequiredDescription
textstringyesThe rules file as JSON text, at most 32768 characters. The style rules guide lists its fields. at least 1 character; at most 32768 characters.

OrgIcons

FieldTypeRequiredDescription
iconsOrgIcon[]yes
icons[].namestringyes
icons[].refstringyesWhat a diagram writes to use it.
icons[].aliasesstring[]yes
icons[].mediaType"image/svg+xml" | "image/png"yes
icons[].imagestringyesThe checked picture as a data: address, for a preview.
icons[].widthnumberyes
icons[].heightnumberyes
icons[].bytesintegeryes
icons[].updatedAtintegeryesMilliseconds since the epoch.
activebooleanyesTrue when the owner's plan includes custom icons, so the hosted service draws them.
canEditbooleanyesTrue when the caller's role may upload, replace and delete icons.
plan"free" | "pro" | "enterprise"yes
limitintegeryesHow many icons the plan lets the organisation keep.

OrgIcon

FieldTypeRequiredDescription
namestringyes
refstringyesWhat a diagram writes to use it.
aliasesstring[]yes
mediaType"image/svg+xml" | "image/png"yes
imagestringyesThe checked picture as a data: address, for a preview.
widthnumberyes
heightnumberyes
bytesintegeryes
updatedAtintegeryesMilliseconds since the epoch.

SavedIcon

FieldTypeRequiredDescription
iconOrgIconyes
icon.namestringyes
icon.refstringyesWhat a diagram writes to use it.
icon.aliasesstring[]yes
icon.mediaType"image/svg+xml" | "image/png"yes
icon.imagestringyesThe checked picture as a data: address, for a preview.
icon.widthnumberyes
icon.heightnumberyes
icon.bytesintegeryes
icon.updatedAtintegeryesMilliseconds since the epoch.
removedstring[]yesWhat the check left out of the file because it draws nothing, such as editor metadata.

IconBody

One file (svg or png), or neither to change only the aliases of an icon that exists.

FieldTypeRequiredDescription
svgstringnoThe SVG file's text, at most 32 KB. It is rewritten from an allowlist before it is stored. at most 49152 characters.
pngstringnoThe PNG file's bytes in base64, at most 32 KB and 1024 pixels on a side. at most 49152 characters.
aliasesstring[]noOther names search and automatic matching find the icon by, at most 10. Left out, the icon has none.

IconPreview

FieldTypeRequiredDescription
refstringyesWhat a diagram writes to use the icon.
sourcestringyesThe diagram source the preview draws, which uses the icon on one box.
lightstringyesThe preview drawn on light, as SVG text.
darkstringyesThe preview drawn on dark, as SVG text.

SavedAvatar

FieldTypeRequiredDescription
avatarOrgAvataryesThe organisation's uploaded avatar, or null when it has none and a mark made from its id stands in.
avatar.versionstringyesChanges with every upload. Put it in the address (?v=) so a new picture is a new address.
avatar.contentType"image/svg+xml" | "image/png" | "image/gif" | "image/webp"yes
avatar.animatedbooleanyesTrue when it moves, so a page can hold it still for a person who asked for less motion.
removedstring[]yesWhat the check left out of the file because it draws nothing, such as editor metadata, EXIF or XMP.

AvatarBody

One file: svg, or image.

FieldTypeRequiredDescription
svgstringnoThe SVG file's text, at most 256 KB, still or animated with SMIL. It is rewritten from an allowlist before it is stored. at most 368640 characters.
imagestringnoA PNG (APNG included), GIF or WebP file's bytes in base64, still or animated: at most 256 KB, 512 pixels on a side, and 200 frames. The format is read from the bytes. at most 368640 characters.

DriftRunReceipt

FieldTypeRequiredDescription
organizationobjectyesThe organisation the run was stored for. With _ in the path, this says which one the key belongs to.
organization.idstringyes
organization.slugstringyes
repositorystringyesThe repository, as sent.
sourcesintegeryesSources stored. minimum 0.
driftedintegeryesSources that drifted. minimum 0.
dashboardUrlstringyesThe organisation's drift dashboard in the portal, for a signed-in member.

DriftRunBody

FieldTypeRequiredDescription
repositorystringyesThe repository the run checked, as owner/name. at most 140 characters; pattern ^[A-Za-z0-9][A-Za-z0-9-]{0,38}\/[A-Za-z0-9._-]{1,100}$.
refstring | nullyesThe git ref the run checked, or null. at least 1 character; at most 255 characters; pattern ^[^\p{Cc}]+$/u.
shastring | nullyesThe commit the run checked, or null. pattern ^[0-9a-fA-F]{7,64}$.
eventstring | nullyesThe event that started the run, or null. at least 1 character; at most 64 characters; pattern ^[a-z][a-z0-9_]*$.
runUrlstring | nullyesThe run on GitHub. An https address of at most 500 characters, or null. at most 500 characters.
pullRequestUrlstring | nullyesThe pull request the run opened or checked. An https address of at most 500 characters, or null. at most 500 characters.
defaultBranchstring | nullnoThe repository's default branch, as the run's event names it. Compliance evidence keeps only the checks of runs on it; left out, the GitHub App's, else main or master. at least 1 character; at most 255 characters; pattern ^[^\p{Cc}]+$/u.
sourcesDriftSourceBody[]yesEvery source the run checked, at most 250. A source of the repository that a run leaves out is removed from the dashboard.
sources[].namestringyesThe source's name as the repository's settings write it, 1 to 120 characters. Unique within a run. at least 1 character; at most 120 characters; pattern ^[^\p{Cc}]+$/u.
sources[].outstringyesThe diagram's path in the repository, 1 to 300 characters. at least 1 character; at most 300 characters; pattern ^[^\p{Cc}]+$/u.
sources[].status"in-step" | "drifted" | "written" | "failed"yesWhat the check found: the diagram matches its files (in-step), differs (drifted), was written by the run (written), or could not be made (failed).
sources[].addedintegeryesItems in the files that the diagram does not have. minimum 0; maximum 1000000.
sources[].removedintegeryesItems in the diagram that the files no longer have. minimum 0; maximum 1000000.
sources[].changedintegeryesItems both have that differ. minimum 0; maximum 1000000.
sources[].errorsintegeryesErrors the run met making this diagram. minimum 0; maximum 1000000.
sources[].ownersstring[]yesThe owners CODEOWNERS gives the diagram's path, as it writes them: at most 20, each @user, @org/team or an email address.
sources[].formatstring | nullnoThe importer the source reads, such as terraform or openapi. Compliance evidence suggests the controls a diagram serves as evidence for by it; left out, by the source name. pattern ^[a-z][a-z0-9-]{0,39}$.

DriftSourceBody

FieldTypeRequiredDescription
namestringyesThe source's name as the repository's settings write it, 1 to 120 characters. Unique within a run. at least 1 character; at most 120 characters; pattern ^[^\p{Cc}]+$/u.
outstringyesThe diagram's path in the repository, 1 to 300 characters. at least 1 character; at most 300 characters; pattern ^[^\p{Cc}]+$/u.
status"in-step" | "drifted" | "written" | "failed"yesWhat the check found: the diagram matches its files (in-step), differs (drifted), was written by the run (written), or could not be made (failed).
addedintegeryesItems in the files that the diagram does not have. minimum 0; maximum 1000000.
removedintegeryesItems in the diagram that the files no longer have. minimum 0; maximum 1000000.
changedintegeryesItems both have that differ. minimum 0; maximum 1000000.
errorsintegeryesErrors the run met making this diagram. minimum 0; maximum 1000000.
ownersstring[]yesThe owners CODEOWNERS gives the diagram's path, as it writes them: at most 20, each @user, @org/team or an email address.
formatstring | nullnoThe importer the source reads, such as terraform or openapi. Compliance evidence suggests the controls a diagram serves as evidence for by it; left out, by the source name. pattern ^[a-z][a-z0-9-]{0,39}$.

OrgDrift

FieldTypeRequiredDescription
activebooleanyesTrue when the owner's plan includes the drift dashboard. When false the lists are empty and run reports are refused.
plan"free" | "pro" | "enterprise"yesThe organisation's plan, which is its owner's.
retentionDaysintegeryesDays a run and a status are kept after they were reported, from the owner's plan. Zero on a plan without the dashboard. minimum 0.
repositoriesDriftRepository[]yesEvery repository with a stored status, by name.
repositories[].repositorystringyes
repositories[].sourcesintegeryesminimum 0.
repositories[].inStepintegeryesminimum 0.
repositories[].driftedintegeryesminimum 0.
repositories[].writtenintegeryesminimum 0.
repositories[].failedintegeryesminimum 0.
repositories[].refstring | nullyes
repositories[].shastring | nullyes
repositories[].runUrlstring | nullyesThe run on GitHub, or null.
repositories[].pullRequestUrlstring | nullyesThe pull request, or null.
repositories[].checkedAtintegeryesWhen the run was reported, in milliseconds since the epoch.
sourcesDriftSource[]yesThe latest status of every source: failed first, then drifted, written and in step, each by repository and name.
sources[].repositorystringyes
sources[].namestringyes
sources[].outstringyes
sources[].status"in-step" | "drifted" | "written" | "failed"yes
sources[].addedintegeryesminimum 0.
sources[].removedintegeryesminimum 0.
sources[].changedintegeryesminimum 0.
sources[].errorsintegeryesminimum 0.
sources[].ownersstring[]yesThe owners CODEOWNERS gave the path, as written there.
sources[].refstring | nullyes
sources[].shastring | nullyes
sources[].runUrlstring | nullyesThe run on GitHub, or null.
sources[].pullRequestUrlstring | nullyesThe pull request, or null.
sources[].checkedAtintegeryesWhen the run was reported, in milliseconds since the epoch.
truncatedbooleanyesTrue when there were more sources than one answer carries.
runsDriftRun[]yesThe latest runs, newest first.
runs[].idstringyes
runs[].repositorystringyes
runs[].eventstring | nullyes
runs[].sourcesintegeryesminimum 0.
runs[].driftedintegeryesminimum 0.
runs[].failedintegeryesminimum 0.
runs[].errorsintegeryesminimum 0.
runs[].refstring | nullyes
runs[].shastring | nullyes
runs[].runUrlstring | nullyesThe run on GitHub, or null.
runs[].pullRequestUrlstring | nullyesThe pull request, or null.
runs[].checkedAtintegeryesWhen the run was reported, in milliseconds since the epoch.

DriftRepository

FieldTypeRequiredDescription
repositorystringyes
sourcesintegeryesminimum 0.
inStepintegeryesminimum 0.
driftedintegeryesminimum 0.
writtenintegeryesminimum 0.
failedintegeryesminimum 0.
refstring | nullyes
shastring | nullyes
runUrlstring | nullyesThe run on GitHub, or null.
pullRequestUrlstring | nullyesThe pull request, or null.
checkedAtintegeryesWhen the run was reported, in milliseconds since the epoch.

DriftSource

FieldTypeRequiredDescription
repositorystringyes
namestringyes
outstringyes
status"in-step" | "drifted" | "written" | "failed"yes
addedintegeryesminimum 0.
removedintegeryesminimum 0.
changedintegeryesminimum 0.
errorsintegeryesminimum 0.
ownersstring[]yesThe owners CODEOWNERS gave the path, as written there.
refstring | nullyes
shastring | nullyes
runUrlstring | nullyesThe run on GitHub, or null.
pullRequestUrlstring | nullyesThe pull request, or null.
checkedAtintegeryesWhen the run was reported, in milliseconds since the epoch.

DriftRun

FieldTypeRequiredDescription
idstringyes
repositorystringyes
eventstring | nullyes
sourcesintegeryesminimum 0.
driftedintegeryesminimum 0.
failedintegeryesminimum 0.
errorsintegeryesminimum 0.
refstring | nullyes
shastring | nullyes
runUrlstring | nullyesThe run on GitHub, or null.
pullRequestUrlstring | nullyesThe pull request, or null.
checkedAtintegeryesWhen the run was reported, in milliseconds since the epoch.

OrgAuditPage

FieldTypeRequiredDescription
itemsOrgAuditEvent[]yes
items[].version1yesThe version of this shape. A change that is not only an addition gets a new number.
items[].idstringyes
items[].orgIdstringyes
items[].atstringyesWhen it happened: an ISO 8601 time in UTC with milliseconds.
items[].action"orgs.org.create" | "orgs.org.rename" | "orgs.member.add" | "orgs.member.remove" | "orgs.member.leave" | "orgs.member.role" | "orgs.owner.transfer" | "orgs.invite.create" | "orgs.invite.revoke" | "orgs.invite.accept" | "orgs.key.create" | "orgs.key.reveal" | "orgs.key.revoke" | "orgs.key.expired" | "orgs.key.network_refused" | "orgs.connection.create" | "orgs.connection.revoke" | "orgs.app.create" | "orgs.app.update" | "orgs.app.delete" | "orgs.app.rotate" | "orgs.app.connect" | "orgs.app.disconnect" | "orgs.trusted_publisher.create" | "orgs.trusted_publisher.update" | "orgs.trusted_publisher.delete" | "orgs.trusted_publisher.exchange" | "orgs.trusted_publisher.refused" | "orgs.github.link" | "orgs.github.unlink" | "orgs.github.uninstalled" | "orgs.github.suspended" | "orgs.github.unsuspended" | "orgs.github.enable" | "orgs.run_task.enable" | "orgs.run_task.rotate" | "orgs.run_task.reveal" | "orgs.run_task.update" | "orgs.run_task.disable" | "orgs.run_task.run" | "orgs.diagram.publish" | "orgs.diagram.update" | "orgs.diagram.edit" | "orgs.diagram.restore" | "orgs.diagram.lock" | "orgs.diagram.unlock" | "orgs.diagram.publish_blocked" | "orgs.diagram.share" | "orgs.diagram.unshare" | "orgs.diagram.embed_link_create" | "orgs.diagram.embed_link_update" | "orgs.diagram.embed_link_rotate" | "orgs.diagram.embed_link_delete" | "orgs.diagram.classify" | "orgs.diagram.approval_request" | "orgs.diagram.approve" | "orgs.diagram.reject" | "orgs.diagram.approval_expire" | "orgs.settings.classification" | "orgs.settings.approval" | "orgs.diagram.delete" | "orgs.folder_rule.set" | "orgs.folder_rule.clear" | "orgs.folder.create" | "orgs.folder.delete" | "orgs.folder.move" | "orgs.brand.set" | "orgs.brand.clear" | "orgs.icon.set" | "orgs.icon.delete" | "orgs.avatar.set" | "orgs.avatar.clear" | "orgs.style_rules.set" | "orgs.style_rules.clear" | "orgs.settings.editable" | "orgs.settings.secret_scanning" | "orgs.settings.publishing" | "orgs.settings.public_sharing" | "orgs.settings.embed_links" | "orgs.settings.auto_publish" | "orgs.settings.legend" | "orgs.settings.style" | "orgs.settings.imports" | "orgs.settings.board_guests" | "orgs.board.guest_open" | "orgs.settings.agents" | "orgs.settings.allowed_agents" | "orgs.settings.allowed_apps" | "orgs.settings.key_policy" | "orgs.settings.caps" | "orgs.cap.reached" | "orgs.settings.log_access" | "orgs.settings.retention" | "orgs.legal_hold.on" | "orgs.legal_hold.off" | "orgs.retention.sweep" | "orgs.diagram.keep" | "orgs.pattern.create" | "orgs.pattern.update" | "orgs.pattern.delete" | "orgs.settings.patterns_only" | "orgs.settings.style_rules_strict" | "orgs.publishing.move" | "orgs.publishing.unpublish" | "orgs.drift.report" | "orgs.drift.settings" | "orgs.evidence.settings" | "orgs.evidence.control" | "orgs.evidence.export" | "orgs.evidence.share" | "orgs.evidence.share_view" | "orgs.evidence.badge" | "orgs.evidence.scan" | "orgs.evidence.verify" | "orgs.integration.create" | "orgs.integration.update" | "orgs.integration.delete" | "orgs.storage.connect" | "orgs.storage.update" | "orgs.storage.disconnect" | "orgs.storage.sync" | "orgs.storage.failing" | "orgs.storage.gave_up" | "orgs.documents.place" | "orgs.documents.unplace" | "orgs.documents.refresh" | "orgs.contract.set" | "orgs.contract.end" | "orgs.audit.export" | "orgs.calls.export" | "orgs.security.two_factor" | "orgs.security.reminder" | "orgs.connector.set" | "orgs.connector.remove" | "orgs.connector.rotate" | "orgs.connector.test" | "orgs.connector.default" | "orgs.connector.azure_devops_connect" | "orgs.connector.azure_devops_disconnect" | "orgs.sso.signin" | "orgs.sso.config" | "orgs.sso.domain_add" | "orgs.sso.domain_verify" | "orgs.sso.domain_remove" | "orgs.sso.signin_failed" | "orgs.sso.jit" | "orgs.sso.break_glass" | "orgs.sso.key_rotate" | "orgs.scim.token" | "orgs.scim.user_create" | "orgs.scim.user_update" | "orgs.scim.user_deactivate" | "orgs.scim.user_delete" | "orgs.scim.group" | "orgs.scim.role" | "orgs.board.create" | "orgs.board.update" | "orgs.board.delete" | "orgs.board.edit" | "orgs.board.restore" | "orgs.board.share" | "orgs.board.access" | "orgs.board.join_link" | "orgs.board.access_request" | "orgs.board.tab_save" | "orgs.board.tab_import" | "orgs.board.export" | "orgs.board.revision.create" | "orgs.board.revision.share" | "orgs.board.revision.switch_request" | "orgs.board.revision.merge" | "orgs.board.revision.discard" | "orgs.board.agent_message" | "orgs.board.agent_reply" | "orgs.board.agent_listen" | "orgs.settings.board_agent_messages"yesWhat happened. Never reused for another meaning.
items[].actorobjectyes
items[].actor.kind"user" | "key" | "ci" | "operator"yes
items[].actor.idstring | nullyesThe account id (user), the key id (key, ci), or null (operator).
items[].actor.namestring | nullyesThe address or key name when it was recorded, "Plotwork support" for the operator, null once a deleted account is forgotten.
items[].targetobjectyes
items[].target.type"org" | "member" | "invite" | "key" | "diagram" | "folder" | "brand" | "icon" | "avatar" | "style_rules" | "settings" | "drift" | "contract" | "sso" | nullyes
items[].target.idstring | nullyes
items[].target.namestring | nullyesA member's address, an invited address, a key's, a diagram's or an icon's name, or a folder.
items[].metadataobjectyesA few facts about the event, such as role or keepEditable. Never a diagram source, a key, a token or a color.
items[].ipstring | nullyesThe network the request came from: the IPv4 /24 or the IPv6 /48, never the full address.
items[].userAgentstring | nullyesThe first 200 characters of the user agent.
items[].requestIdstring | nullyesThe request id, which Plotwork support can look up in the API's logs.
nextCursorstring | nullyesSend as cursor for the next, older page; null on the last.
retentionDaysintegeryesHow many days the organisation's plan keeps an event.
canExportbooleanyesWhether the caller may export the log: the plan exports it, and the caller is the owner, an admin or a key with audit:read.

OrgAuditEvent

FieldTypeRequiredDescription
version1yesThe version of this shape. A change that is not only an addition gets a new number.
idstringyes
orgIdstringyes
atstringyesWhen it happened: an ISO 8601 time in UTC with milliseconds.
action"orgs.org.create" | "orgs.org.rename" | "orgs.member.add" | "orgs.member.remove" | "orgs.member.leave" | "orgs.member.role" | "orgs.owner.transfer" | "orgs.invite.create" | "orgs.invite.revoke" | "orgs.invite.accept" | "orgs.key.create" | "orgs.key.reveal" | "orgs.key.revoke" | "orgs.key.expired" | "orgs.key.network_refused" | "orgs.connection.create" | "orgs.connection.revoke" | "orgs.app.create" | "orgs.app.update" | "orgs.app.delete" | "orgs.app.rotate" | "orgs.app.connect" | "orgs.app.disconnect" | "orgs.trusted_publisher.create" | "orgs.trusted_publisher.update" | "orgs.trusted_publisher.delete" | "orgs.trusted_publisher.exchange" | "orgs.trusted_publisher.refused" | "orgs.github.link" | "orgs.github.unlink" | "orgs.github.uninstalled" | "orgs.github.suspended" | "orgs.github.unsuspended" | "orgs.github.enable" | "orgs.run_task.enable" | "orgs.run_task.rotate" | "orgs.run_task.reveal" | "orgs.run_task.update" | "orgs.run_task.disable" | "orgs.run_task.run" | "orgs.diagram.publish" | "orgs.diagram.update" | "orgs.diagram.edit" | "orgs.diagram.restore" | "orgs.diagram.lock" | "orgs.diagram.unlock" | "orgs.diagram.publish_blocked" | "orgs.diagram.share" | "orgs.diagram.unshare" | "orgs.diagram.embed_link_create" | "orgs.diagram.embed_link_update" | "orgs.diagram.embed_link_rotate" | "orgs.diagram.embed_link_delete" | "orgs.diagram.classify" | "orgs.diagram.approval_request" | "orgs.diagram.approve" | "orgs.diagram.reject" | "orgs.diagram.approval_expire" | "orgs.settings.classification" | "orgs.settings.approval" | "orgs.diagram.delete" | "orgs.folder_rule.set" | "orgs.folder_rule.clear" | "orgs.folder.create" | "orgs.folder.delete" | "orgs.folder.move" | "orgs.brand.set" | "orgs.brand.clear" | "orgs.icon.set" | "orgs.icon.delete" | "orgs.avatar.set" | "orgs.avatar.clear" | "orgs.style_rules.set" | "orgs.style_rules.clear" | "orgs.settings.editable" | "orgs.settings.secret_scanning" | "orgs.settings.publishing" | "orgs.settings.public_sharing" | "orgs.settings.embed_links" | "orgs.settings.auto_publish" | "orgs.settings.legend" | "orgs.settings.style" | "orgs.settings.imports" | "orgs.settings.board_guests" | "orgs.board.guest_open" | "orgs.settings.agents" | "orgs.settings.allowed_agents" | "orgs.settings.allowed_apps" | "orgs.settings.key_policy" | "orgs.settings.caps" | "orgs.cap.reached" | "orgs.settings.log_access" | "orgs.settings.retention" | "orgs.legal_hold.on" | "orgs.legal_hold.off" | "orgs.retention.sweep" | "orgs.diagram.keep" | "orgs.pattern.create" | "orgs.pattern.update" | "orgs.pattern.delete" | "orgs.settings.patterns_only" | "orgs.settings.style_rules_strict" | "orgs.publishing.move" | "orgs.publishing.unpublish" | "orgs.drift.report" | "orgs.drift.settings" | "orgs.evidence.settings" | "orgs.evidence.control" | "orgs.evidence.export" | "orgs.evidence.share" | "orgs.evidence.share_view" | "orgs.evidence.badge" | "orgs.evidence.scan" | "orgs.evidence.verify" | "orgs.integration.create" | "orgs.integration.update" | "orgs.integration.delete" | "orgs.storage.connect" | "orgs.storage.update" | "orgs.storage.disconnect" | "orgs.storage.sync" | "orgs.storage.failing" | "orgs.storage.gave_up" | "orgs.documents.place" | "orgs.documents.unplace" | "orgs.documents.refresh" | "orgs.contract.set" | "orgs.contract.end" | "orgs.audit.export" | "orgs.calls.export" | "orgs.security.two_factor" | "orgs.security.reminder" | "orgs.connector.set" | "orgs.connector.remove" | "orgs.connector.rotate" | "orgs.connector.test" | "orgs.connector.default" | "orgs.connector.azure_devops_connect" | "orgs.connector.azure_devops_disconnect" | "orgs.sso.signin" | "orgs.sso.config" | "orgs.sso.domain_add" | "orgs.sso.domain_verify" | "orgs.sso.domain_remove" | "orgs.sso.signin_failed" | "orgs.sso.jit" | "orgs.sso.break_glass" | "orgs.sso.key_rotate" | "orgs.scim.token" | "orgs.scim.user_create" | "orgs.scim.user_update" | "orgs.scim.user_deactivate" | "orgs.scim.user_delete" | "orgs.scim.group" | "orgs.scim.role" | "orgs.board.create" | "orgs.board.update" | "orgs.board.delete" | "orgs.board.edit" | "orgs.board.restore" | "orgs.board.share" | "orgs.board.access" | "orgs.board.join_link" | "orgs.board.access_request" | "orgs.board.tab_save" | "orgs.board.tab_import" | "orgs.board.export" | "orgs.board.revision.create" | "orgs.board.revision.share" | "orgs.board.revision.switch_request" | "orgs.board.revision.merge" | "orgs.board.revision.discard" | "orgs.board.agent_message" | "orgs.board.agent_reply" | "orgs.board.agent_listen" | "orgs.settings.board_agent_messages"yesWhat happened. Never reused for another meaning.
actorobjectyes
actor.kind"user" | "key" | "ci" | "operator"yes
actor.idstring | nullyesThe account id (user), the key id (key, ci), or null (operator).
actor.namestring | nullyesThe address or key name when it was recorded, "Plotwork support" for the operator, null once a deleted account is forgotten.
targetobjectyes
target.type"org" | "member" | "invite" | "key" | "diagram" | "folder" | "brand" | "icon" | "avatar" | "style_rules" | "settings" | "drift" | "contract" | "sso" | nullyes
target.idstring | nullyes
target.namestring | nullyesA member's address, an invited address, a key's, a diagram's or an icon's name, or a folder.
metadataobjectyesA few facts about the event, such as role or keepEditable. Never a diagram source, a key, a token or a color.
ipstring | nullyesThe network the request came from: the IPv4 /24 or the IPv6 /48, never the full address.
userAgentstring | nullyesThe first 200 characters of the user agent.
requestIdstring | nullyesThe request id, which Plotwork support can look up in the API's logs.

OrgUsage

FieldTypeRequiredDescription
availablebooleanyesFalse when the call history is not set up on this server, or could not be read; the figures are then zero.
retentionDaysintegeryes
todayintegeryesCalls today, UTC.
monthintegeryesCalls this calendar month, UTC.
daysobject[]yesThe last 31 UTC days, oldest first.
days[].daystringyes
days[].connectionintegeryes
days[].keyintegeryes
groupsobject[]yesThis month's calls by what they did.
groups[].group"draw" | "import" | "publish" | "library" | "check" | "icons" | "docs" | "help"yes
groups[].callsintegeryes
viaobjectyesThis month's calls by how they came.
via.connectionintegeryes
via.keyintegeryes
canReadCallsbooleanyesWhether the caller may read every member's calls.
canExportbooleanyes
breakdownobject | nullyesCalls of the last 90 days by member and by agent or key, for a caller who may read the history; null for anyone else.
breakdown.membersobject[]yes
breakdown.members[].userIdstringyes
breakdown.members[].emailstring | nullyes
breakdown.members[].callsintegeryes
breakdown.members[].lastAtnumberyes
breakdown.agentsobject[]yes
breakdown.agents[].keyIdstringyes
breakdown.agents[].via"connection" | "key"yes
breakdown.agents[].namestring | nullyes
breakdown.agents[].memberobject | nullyes
breakdown.agents[].callsintegeryes
breakdown.agents[].lastAtnumberyes

OrgCallPage

FieldTypeRequiredDescription
availablebooleanyesFalse when the call history is not set up on this server, or could not be read.
itemsOrgCall[]yes
items[].atstringyesWhen the call ended: an ISO 8601 time in UTC with milliseconds.
items[].surface"mcp" | "api"yesmcp for the hosted MCP server, api for the REST API.
items[].via"connection" | "key"yesconnection for an agent a member connected with a browser sign-in, key for a key from Keys and CI.
items[].memberobject | nullyesThe member who connected the agent; null for a key from Keys and CI.
items[].member.userIdstringyes
items[].member.emailstring | nullyes
items[].keyobjectyesThe key behind the call, with its name; the name is null once the key is gone.
items[].key.idstringyes
items[].key.namestring | nullyes
items[].agentstring | nullyesThe name the agent gave itself, for a connection; null for a key.
items[].toolstringyesThe MCP tool, or the /v1 route as METHOD path.
items[].group"draw" | "import" | "publish" | "library" | "check" | "icons" | "docs" | "help"yes
items[].outcome"ok" | "invalid" | "refused" | "error"yesok, invalid (the input was refused: a source with errors, arguments that do not fit), refused (a limit, a plan or a rule said no) or error.
items[].durationMsintegeryes
items[].requestIdstring | nullyesThe request id or Cloudflare ray id, for support.
nextCursorstring | nullyesSend as cursor for the next, older page; null when this is the last.
scope"organisation" | "own"yesorganisation: every member's calls. own: the calls of the agents the caller connected, for someone the owner has not let read the history.
retentionDaysintegeryesDays the history keeps a call.
canExportbooleanyesWhether the caller may download the history as CSV (the owner and admins).

OrgCall

FieldTypeRequiredDescription
atstringyesWhen the call ended: an ISO 8601 time in UTC with milliseconds.
surface"mcp" | "api"yesmcp for the hosted MCP server, api for the REST API.
via"connection" | "key"yesconnection for an agent a member connected with a browser sign-in, key for a key from Keys and CI.
memberobject | nullyesThe member who connected the agent; null for a key from Keys and CI.
member.userIdstringyes
member.emailstring | nullyes
keyobjectyesThe key behind the call, with its name; the name is null once the key is gone.
key.idstringyes
key.namestring | nullyes
agentstring | nullyesThe name the agent gave itself, for a connection; null for a key.
toolstringyesThe MCP tool, or the /v1 route as METHOD path.
group"draw" | "import" | "publish" | "library" | "check" | "icons" | "docs" | "help"yes
outcome"ok" | "invalid" | "refused" | "error"yesok, invalid (the input was refused: a source with errors, arguments that do not fit), refused (a limit, a plan or a rule said no) or error.
durationMsintegeryes
requestIdstring | nullyesThe request id or Cloudflare ray id, for support.

LogAccess

FieldTypeRequiredDescription
roles("member" | "reader")[]yes
membersobject[]yes
members[].userIdstringyes
members[].emailstringyes
members[].role"owner" | "admin" | "member" | "reader"yes

LogAccessInput

FieldTypeRequiredDescription
roles("member" | "reader")[]yesRoles let in besides the owner and admins.
membersstring[]yesMembers let in by name, by account id, at most 100.

SsoSettings

FieldTypeRequiredDescription
availablebooleanyesWhether the organisation's plan has single sign-on (Enterprise).
plan"free" | "pro" | "enterprise"yes
redirectUristringyesThe redirect URI to register at the identity provider.
samlSamlServiceProvideryes
saml.entityIdstringyesOur entity id for this organisation: the audience to set at the provider.
saml.acsUrlstringyesOur assertion consumer service for this organisation: the single sign-on URL to set at the provider.
saml.metadataUrlstringyesOur service provider metadata, for a provider that imports it.
samlAvailablebooleanyesWhether this server can check SAML responses.
federationSsoFederationyesPlotwork's issuer for this organisation, or null when this server cannot sign assertions.
federation.issuerstringyesPlotwork's issuer for this organisation: the federated credential's Issuer.
federation.subjectstringyesThe federated credential's Subject identifier: the organisation's id.
federation.audience"api://AzureADTokenExchange"yesThe federated credential's Audience.
federation.jwksUristringyesWhere the public keys are published, for a provider that fetches them.
connectionSsoConnectionyes
connection.protocol"oidc" | "saml"yesOpenID Connect or SAML 2.0. One connection, one protocol.
connection.issuerstringyesThe OpenID Connect issuer, or the SAML provider's entity id.
connection.clientIdstring | nullyesOpenID Connect only.
connection.credential"client_secret" | "federated" | "private_key_jwt" | nullyesWhat the connection proves itself with at the token endpoint: a client secret, a Microsoft Entra ID federated credential, or a private key JWT. OpenID Connect only.
connection.secretSetbooleanyesTrue when an OpenID Connect client secret is stored. It is never returned. False for the other credentials and for SAML.
connection.tokenAuthMethod"client_secret_basic" | "client_secret_post" | "private_key_jwt" | nullyes
connection.signingKeySsoSigningKeyyesThe connection's signing key, for federated and private_key_jwt; null otherwise.
connection.signingKey.kidstringyes
connection.signingKey.createdAtintegeryesWhen the key was made: the last rotation, or when the credential was chosen. Milliseconds since the epoch.
connection.signingKey.publicJwkSsoPublicJwkyes
connection.signingKey.publicKeyPemstringyesThe same public key as a PEM PUBLIC KEY, for a provider that takes a pasted key.
connection.signingKey.previousKidstring | nullyesThe key a rotation replaced, while it is still published (a day), or null.
connection.signingKey.previousExpiresAtinteger | nullyesWhen the previous key leaves the JWKS, or null.
connection.warnings"private_key_jwt_not_listed"[]yesWhat the save noticed but did not refuse: private_key_jwt_not_listed when the provider's discovery document does not list private_key_jwt. Empty when read.
connection.samlSamlConnectionyesSAML only.
connection.saml.entityIdstringyesThe provider's entity id, which every Issuer must equal.
connection.saml.ssoUrlstringyesThe provider's sign-in service on the redirect binding.
connection.saml.certificatesobject[]yes
connection.saml.emailAttributestring | nullyesThe attribute that carries the address, or null when the name identifier does.
connection.saml.metadataUrlstring | nullyesWhere the metadata was fetched from, or null when it was pasted.
connection.enabledbooleanyes
connection.requireSsobooleanyes
connection.jitbooleanyes
connection.jitRole"member" | "reader"yes
connection.updatedAtintegeryes
domainsSsoDomain[]yes
domains[].idstringyes
domains[].domainstringyes
domains[].verifiedbooleanyes
domains[].verifiedAtinteger | nullyes
domains[].checkedAtinteger | nullyes
domains[].createdAtintegeryes
domains[].recordobjectyes
domains[].record.namestringyes
domains[].record.type"TXT"yes
domains[].record.valuestringyes
agentsOrgOnlybooleanyes"Agents connect to this organisation": members on a verified domain connect agents only to the organisation.

SamlServiceProvider

FieldTypeRequiredDescription
entityIdstringyesOur entity id for this organisation: the audience to set at the provider.
acsUrlstringyesOur assertion consumer service for this organisation: the single sign-on URL to set at the provider.
metadataUrlstringyesOur service provider metadata, for a provider that imports it.

SsoFederation

Plotwork's issuer for this organisation, or null when this server cannot sign assertions.

FieldTypeRequiredDescription
issuerstringyesPlotwork's issuer for this organisation: the federated credential's Issuer.
subjectstringyesThe federated credential's Subject identifier: the organisation's id.
audience"api://AzureADTokenExchange"yesThe federated credential's Audience.
jwksUristringyesWhere the public keys are published, for a provider that fetches them.

SsoConnection

FieldTypeRequiredDescription
protocol"oidc" | "saml"yesOpenID Connect or SAML 2.0. One connection, one protocol.
issuerstringyesThe OpenID Connect issuer, or the SAML provider's entity id.
clientIdstring | nullyesOpenID Connect only.
credential"client_secret" | "federated" | "private_key_jwt" | nullyesWhat the connection proves itself with at the token endpoint: a client secret, a Microsoft Entra ID federated credential, or a private key JWT. OpenID Connect only.
secretSetbooleanyesTrue when an OpenID Connect client secret is stored. It is never returned. False for the other credentials and for SAML.
tokenAuthMethod"client_secret_basic" | "client_secret_post" | "private_key_jwt" | nullyes
signingKeySsoSigningKeyyesThe connection's signing key, for federated and private_key_jwt; null otherwise.
signingKey.kidstringyes
signingKey.createdAtintegeryesWhen the key was made: the last rotation, or when the credential was chosen. Milliseconds since the epoch.
signingKey.publicJwkSsoPublicJwkyes
signingKey.publicJwk.kty"RSA"yes
signingKey.publicJwk.nstringyesThe modulus, base64url.
signingKey.publicJwk.estringyesThe public exponent, base64url.
signingKey.publicJwk.kidstringyesThe key id: the key's RFC 7638 thumbprint.
signingKey.publicJwk.alg"RS256"yes
signingKey.publicJwk.use"sig"yes
signingKey.publicKeyPemstringyesThe same public key as a PEM PUBLIC KEY, for a provider that takes a pasted key.
signingKey.previousKidstring | nullyesThe key a rotation replaced, while it is still published (a day), or null.
signingKey.previousExpiresAtinteger | nullyesWhen the previous key leaves the JWKS, or null.
warnings"private_key_jwt_not_listed"[]yesWhat the save noticed but did not refuse: private_key_jwt_not_listed when the provider's discovery document does not list private_key_jwt. Empty when read.
samlSamlConnectionyesSAML only.
saml.entityIdstringyesThe provider's entity id, which every Issuer must equal.
saml.ssoUrlstringyesThe provider's sign-in service on the redirect binding.
saml.certificatesobject[]yes
saml.certificates[].fingerprintstringyesSHA-256 of the certificate, as providers show it.
saml.certificates[].notAfterintegeryesWhen the certificate expires, in milliseconds since the epoch. Shown, not enforced.
saml.emailAttributestring | nullyesThe attribute that carries the address, or null when the name identifier does.
saml.metadataUrlstring | nullyesWhere the metadata was fetched from, or null when it was pasted.
enabledbooleanyes
requireSsobooleanyes
jitbooleanyes
jitRole"member" | "reader"yes
updatedAtintegeryes

SsoSigningKey

The connection's signing key, for federated and private_key_jwt; null otherwise.

FieldTypeRequiredDescription
kidstringyes
createdAtintegeryesWhen the key was made: the last rotation, or when the credential was chosen. Milliseconds since the epoch.
publicJwkSsoPublicJwkyes
publicJwk.kty"RSA"yes
publicJwk.nstringyesThe modulus, base64url.
publicJwk.estringyesThe public exponent, base64url.
publicJwk.kidstringyesThe key id: the key's RFC 7638 thumbprint.
publicJwk.alg"RS256"yes
publicJwk.use"sig"yes
publicKeyPemstringyesThe same public key as a PEM PUBLIC KEY, for a provider that takes a pasted key.
previousKidstring | nullyesThe key a rotation replaced, while it is still published (a day), or null.
previousExpiresAtinteger | nullyesWhen the previous key leaves the JWKS, or null.

SamlConnection

SAML only.

FieldTypeRequiredDescription
entityIdstringyesThe provider's entity id, which every Issuer must equal.
ssoUrlstringyesThe provider's sign-in service on the redirect binding.
certificatesobject[]yes
certificates[].fingerprintstringyesSHA-256 of the certificate, as providers show it.
certificates[].notAfterintegeryesWhen the certificate expires, in milliseconds since the epoch. Shown, not enforced.
emailAttributestring | nullyesThe attribute that carries the address, or null when the name identifier does.
metadataUrlstring | nullyesWhere the metadata was fetched from, or null when it was pasted.

SsoDomain

FieldTypeRequiredDescription
idstringyes
domainstringyes
verifiedbooleanyes
verifiedAtinteger | nullyes
checkedAtinteger | nullyes
createdAtintegeryes
recordobjectyes
record.namestringyes
record.type"TXT"yes
record.valuestringyes

SsoConnectionBody

FieldTypeRequiredDescription
issuerstringyesThe issuer URL of your own tenant. at least 9 characters; at most 300 characters.
clientIdstringyesat least 1 character; at most 255 characters.
clientSecretstringnoFor client_secret: required the first time, and when switching from another credential. Left out later, the stored one is kept. Never returned. Ignored by the other credentials. at least 1 character; at most 1000 characters.
credential"client_secret" | "federated" | "private_key_jwt"noWhat the connection proves itself with. Left out, the stored credential is kept (a client secret for a new connection). federated and private_key_jwt make a signing key when the connection has none.

AgentPolicy

FieldTypeRequiredDescription
orgOnlybooleanyesWhen true, a member whose address is on one of the organisation's verified domains can connect an agent only to the organisation, not to their own account.

SsoSwitchesBody

FieldTypeRequiredDescription
enabledbooleanno
requireSsobooleanno
jitbooleanno
jitRole"member" | "reader"no

SamlConnectionBody

FieldTypeRequiredDescription
metadataUrlstringnoThe address of the provider's metadata, fetched over HTTPS. Give this or metadataXml, or neither to keep the stored metadata. at least 9 characters; at most 500 characters.
metadataXmlstringnoThe provider's metadata XML, pasted. at least 1 character; at most 262144 characters.
emailAttributestring | nullnoThe attribute that carries the address. Null reads the name identifier; left out keeps the stored choice. at least 1 character; at most 200 characters.

SsoDomainBody

FieldTypeRequiredDescription
domainstringyesat least 3 characters; at most 253 characters.

SsoDomainVerify

FieldTypeRequiredDescription
domainSsoDomainyes
domain.idstringyes
domain.domainstringyes
domain.verifiedbooleanyes
domain.verifiedAtinteger | nullyes
domain.checkedAtinteger | nullyes
domain.createdAtintegeryes
domain.recordobjectyes
domain.record.namestringyes
domain.record.type"TXT"yes
domain.record.valuestringyes
checkedbooleanyesFalse when the resolver did not answer, so nothing was learned. Try again.

ScimSettings

FieldTypeRequiredDescription
availablebooleanyesWhether the organisation's plan includes SCIM (Enterprise).
baseUrlstringyesThe SCIM base URL to give the identity provider.
tokenScimTokenViewyes
token.prefixstringyesThe first characters of the token, to tell it apart.
token.createdAtintegeryes
token.lastUsedAtinteger | nullyesWhen the provider last used it, to the minute. Null until it has.
usersintegeryesHow many people the provider manages here, active or not.
groupsScimGroupView[]yes
groups[].idstringyes
groups[].displayNamestringyes
groups[].role"admin" | "member" | "reader" | nullyesThe role the group gives its members, or null when it gives none.
groups[].membersintegeryes

ScimTokenView

FieldTypeRequiredDescription
prefixstringyesThe first characters of the token, to tell it apart.
createdAtintegeryes
lastUsedAtinteger | nullyesWhen the provider last used it, to the minute. Null until it has.

ScimGroupView

FieldTypeRequiredDescription
idstringyes
displayNamestringyes
role"admin" | "member" | "reader" | nullyesThe role the group gives its members, or null when it gives none.
membersintegeryes

ScimTokenIssued

FieldTypeRequiredDescription
tokenstringyesThe bearer token for the identity provider. Shown once; only its hash is kept.
viewScimTokenViewyes
view.prefixstringyesThe first characters of the token, to tell it apart.
view.createdAtintegeryes
view.lastUsedAtinteger | nullyesWhen the provider last used it, to the minute. Null until it has.

ScimGroupRoleBody

FieldTypeRequiredDescription
role"admin" | "member" | "reader" | nullyes

SupportSettings

FieldTypeRequiredDescription
availablebooleanyesTrue when the organisation's plan includes priority support (Enterprise).
planstringyesThe organisation's plan.
contactobject | nullyesThe named contact, or null when none is named yet. A request still reaches Plotwork support.
contact.namestringyes
contact.emailstringyes
firstResponseHoursinteger | nullyesThe first response target, in business hours, or null when the contract names none.
hoursstring | nullyesWhen support is staffed, as the contract says it, or null.
uptimeSlabooleanyesTrue when the plan includes an uptime SLA.
contractobject | nullyesThe dates of the contract: for the owner and the admins only, and null for everyone else or a contract set without dates.
contract.startsOnstringyesThe first day of the contract, YYYY-MM-DD (UTC).
contract.endsOnstringyesThe last day of the contract, YYYY-MM-DD (UTC).
contract.autoRenewbooleanyesWhether the contract renews by itself at the end.
contract.noticeDaysintegeryesThe notice either side gives before the end, in days.

SupportAck

FieldTypeRequiredDescription
receivedtrueyes
contactNamestring | nullyesThe name of the contact who will answer, or null when none is named.
firstResponseHoursinteger | nullyesThe first response target, in business hours, or null.

SupportRequestBody

FieldTypeRequiredDescription
subjectstringyesOne line on what it is about. 1 to 160 characters. at least 1 character; at most 160 characters.
messagestringyesWhat happened, what was expected, and anything that helps reproduce it. 1 to 5000 characters; line breaks are kept. at least 1 character; at most 5000 characters.
severity"question" | "broken" | "urgent"yesquestion for a question, broken when something does not work, urgent when production is affected. The contact reads the urgent ones first.

BoardList

FieldTypeRequiredDescription
itemsBoardListItem[]yes
items[].idstringyesat least 22 characters; at most 22 characters; pattern ^[0-9A-Za-z]+$.
items[].namestringyes
items[].classification"public" | "internal" | "confidential"yes
items[].access"org" | "restricted"yes
items[].role"view" | "edit" | "manage"yesview: look; edit: change the tabs; manage: also change who may open the board.
items[].tabCountintegeryesminimum 0.
items[].createdAtintegeryes
items[].updatedAtintegeryes
items[].createdBystring | nullyesThe email address of the member who made it, or null when they left.
items[].livebooleanyesTrue when someone opened its live connection in the last two minutes.
items[].keptbooleanyes
limitintegeryesBoards the organisation may keep. minimum 0.
countintegeryesBoards the organisation keeps now, including those the caller may not open. minimum 0.

BoardListItem

FieldTypeRequiredDescription
idstringyesat least 22 characters; at most 22 characters; pattern ^[0-9A-Za-z]+$.
namestringyes
classification"public" | "internal" | "confidential"yes
access"org" | "restricted"yes
role"view" | "edit" | "manage"yesview: look; edit: change the tabs; manage: also change who may open the board.
tabCountintegeryesminimum 0.
createdAtintegeryes
updatedAtintegeryes
createdBystring | nullyesThe email address of the member who made it, or null when they left.
livebooleanyesTrue when someone opened its live connection in the last two minutes.
keptbooleanyes

Board

FieldTypeRequiredDescription
idstringyesat least 22 characters; at most 22 characters; pattern ^[0-9A-Za-z]+$.
namestringyes
classification"public" | "internal" | "confidential"yes
access"org" | "restricted"yes
role"view" | "edit" | "manage"yesview: look; edit: change the tabs; manage: also change who may open the board.
tabCountintegeryesminimum 0.
createdAtintegeryes
updatedAtintegeryes
createdBystring | nullyesThe email address of the member who made it, or null when they left.
livebooleanyesTrue when someone opened its live connection in the last two minutes.
keptbooleanyes
livebooleanno
orgRole"view" | "edit"yesWhat every member gets when access is org.
headBoardHeadyes
head.idstringyesat least 22 characters; at most 22 characters; pattern ^[0-9A-Za-z]+$.
head.orgIdstringyes
head.versionintegeryes
head.tabsBoardTab[]yes
head.tabs[].idstringyesat least 12 characters; at most 12 characters; pattern ^[0-9A-Za-z]+$.
head.tabs[].namestringyes
head.tabs[].kindstringyesThe kind the source declares, such as flow.
head.tabs[].positionnumberyes
head.tabs[].versionintegeryes
head.tabs[].updatedAtintegeryes
head.tabs[].updatedBystringyesWho changed it last: an email address, an agent and its member, or a key name.
head.tabs[].libraryobject | nullyes
limitsBoardLiveLimitsyes
limits.sessionMinutesintegeryes
limits.idleMinutesintegeryes
limits.hiddenGraceSecondsintegeryes
limits.participantsintegeryes
limits.tabsintegeryes
liveAvailablebooleanyesFalse when today's live minutes are spent: the board opens read-only and reloads its tabs by hand.
urlstringyesThe board's address in the portal.
shortUrlstringyesThe short address, for chat and a QR code.

BoardHead

FieldTypeRequiredDescription
idstringyesat least 22 characters; at most 22 characters; pattern ^[0-9A-Za-z]+$.
orgIdstringyes
versionintegeryes
tabsBoardTab[]yes
tabs[].idstringyesat least 12 characters; at most 12 characters; pattern ^[0-9A-Za-z]+$.
tabs[].namestringyes
tabs[].kindstringyesThe kind the source declares, such as flow.
tabs[].positionnumberyes
tabs[].versionintegeryes
tabs[].updatedAtintegeryes
tabs[].updatedBystringyesWho changed it last: an email address, an agent and its member, or a key name.
tabs[].libraryobject | nullyes
tabs[].library.diagramIdstringyes
tabs[].library.versionintegeryes
tabs[].library.savedbooleanyesTrue while the tab holds what was saved or imported.

BoardTab

FieldTypeRequiredDescription
idstringyesat least 12 characters; at most 12 characters; pattern ^[0-9A-Za-z]+$.
namestringyes
kindstringyesThe kind the source declares, such as flow.
positionnumberyes
versionintegeryes
updatedAtintegeryes
updatedBystringyesWho changed it last: an email address, an agent and its member, or a key name.
libraryobject | nullyes
library.diagramIdstringyes
library.versionintegeryes
library.savedbooleanyesTrue while the tab holds what was saved or imported.

BoardLiveLimits

FieldTypeRequiredDescription
sessionMinutesintegeryes
idleMinutesintegeryes
hiddenGraceSecondsintegeryes
participantsintegeryes
tabsintegeryes

CreateBoardBody

FieldTypeRequiredDescription
namestringyesat least 1 character; at most 120 characters.
classification"public" | "internal" | "confidential"no

UpdateBoardBody

FieldTypeRequiredDescription
namestringnoat least 1 character; at most 120 characters.
classification"public" | "internal" | "confidential"no
keptbooleanno

BoardTabRead

FieldTypeRequiredDescription
tabBoardTabyes
tab.idstringyesat least 12 characters; at most 12 characters; pattern ^[0-9A-Za-z]+$.
tab.namestringyes
tab.kindstringyesThe kind the source declares, such as flow.
tab.positionnumberyes
tab.versionintegeryes
tab.updatedAtintegeryes
tab.updatedBystringyesWho changed it last: an email address, an agent and its member, or a key name.
tab.libraryobject | nullyes
tab.library.diagramIdstringyes
tab.library.versionintegeryes
tab.library.savedbooleanyesTrue while the tab holds what was saved or imported.
sourcestringyes
changesSinceBoardHistoryEntry[]yes
changesSince[].versionintegeryes
changesSince[].typestringyes
changesSince[].actorBoardActoryes
changesSince[].actor.kind"person" | "agent" | "key"yes
changesSince[].actor.labelstringyes
changesSince[].countsobjectyes
changesSince[].counts.addedintegeryes
changesSince[].counts.removedintegeryes
changesSince[].counts.renamedintegeryes
changesSince[].counts.movedintegeryes
changesSince[].counts.changedintegeryes
changesSince[].atintegeryes
changesSince[].restorablebooleanyes

BoardWriteResult

FieldTypeRequiredDescription
changedbooleanyesFalse when the write changed nothing; nothing was stored.
versionintegeryes
tabanyyes
tab.idstringyesat least 12 characters; at most 12 characters; pattern ^[0-9A-Za-z]+$.
tab.namestringyes
tab.kindstringyesThe kind the source declares, such as flow.
tab.positionnumberyes
tab.versionintegeryes
tab.updatedAtintegeryes
tab.updatedBystringyesWho changed it last: an email address, an agent and its member, or a key name.
tab.libraryobject | nullyes
tab.library.diagramIdstringyes
tab.library.versionintegeryes
tab.library.savedbooleanyesTrue while the tab holds what was saved or imported.
headBoardHeadyes
head.idstringyesat least 22 characters; at most 22 characters; pattern ^[0-9A-Za-z]+$.
head.orgIdstringyes
head.versionintegeryes
head.tabsBoardTab[]yes
head.tabs[].idstringyesat least 12 characters; at most 12 characters; pattern ^[0-9A-Za-z]+$.
head.tabs[].namestringyes
head.tabs[].kindstringyesThe kind the source declares, such as flow.
head.tabs[].positionnumberyes
head.tabs[].versionintegeryes
head.tabs[].updatedAtintegeryes
head.tabs[].updatedBystringyesWho changed it last: an email address, an agent and its member, or a key name.
head.tabs[].libraryobject | nullyes
resultsobject[]yes
results[].opstringyes
results[].appliedbooleanyes
results[].linesinteger[]yes
results[].messagestringyes
results[].hintstring | nullyes
changesobject[]yes
changes[].changestringyes
changes[].subjectstringyes
changes[].namestringyes
changes[].lineinteger | nullyes
changes[].detailstringyes
warningsDiagnostic[]yes
warnings[].code"E100" | "E101" | "E110" | "E111" | "E120" | "E121" | "E123" | "E124" | "E125" | "E130" | "E131" | "E132" | "E133" | "E134" | "E135" | "E136" | "E137" | "E138" | "E139" | "E140" | "W200" | "W201" | "W202" | "W203" | "W204" | "W205" | "W206" | "W207" | "W208" | "W209" | "W500" | "W600" | "W601" | "W700" | "W701" | "W702" | "W703" | "W704" | "W705" | "W706" | "W707" | "W708" | "W709" | "W710" | "M100" | "M101" | "M102" | "M103" | "M104" | "M110" | "M200" | "M201" | "M202" | "M203" | "M204" | "M205" | "M206" | "M207" | "M208" | "M209" | "M210" | "M211" | "M212" | "M213" | "M214" | "M215" | "M216" | "M217" | "M218" | "E300" | "E301" | "E302" | "E303" | "E304" | "W300" | "W301" | "W302" | "W303" | "M120" | "M220" | "M221" | "M222" | "E340" | "E341" | "E342" | "E343" | "E344" | "E345" | "W320" | "W321" | "W322" | "W323" | "M240" | "M241" | "M242" | "E360" | "E361" | "E362" | "E363" | "E364" | "E365" | "E366" | "E367" | "W330" | "W331" | "W332" | "W333" | "W334" | "M250" | "M251" | "E400" | "E401" | "E402" | "E403" | "W350" | "W351" | "W352" | "W353" | "M270" | "M271" | "E420" | "E421" | "E422" | "E423" | "E424" | "W360" | "W361" | "W362" | "W363" | "W364" | "M180" | "M280" | "M281" | "M282" | "E320" | "E321" | "E322" | "E323" | "E324" | "E325" | "E326" | "E327" | "E328" | "E329" | "E330" | "W310" | "W311" | "W312" | "W313" | "W314" | "M130" | "M131" | "M132" | "M230" | "M231" | "M232" | "M233" | "M234" | "M235" | "M236" | "M237" | "M238" | "E380" | "E381" | "E382" | "E383" | "W340" | "W341" | "W342" | "W343" | "M260" | "I100" | "I101" | "I102" | "I103" | "I104" | "I105" | "I200" | "I201" | "I202" | "I203" | "I204" | "I206" | "I207" | "R100" | "R101" | "R200" | "R201" | "R202" | "R203" | "R204" | "R205" | "R206" | "R207" | "S100" | "S200" | "S101" | "S102" | "S103" | "S104" | "S201" | "S202" | "S203" | "S204" | "S205"yesStable code to branch on; E-codes are errors, W-codes are warnings.
warnings[].severity"error" | "warning"yesErrors stop rendering; warnings never do.
warnings[].messagestringyesWhat is wrong, in one sentence.
warnings[].lineintegeryes1-based line in the submitted source. minimum 1.
warnings[].columnintegeryes1-based column in that line. minimum 1.
warnings[].lengthintegeryesNumber of characters the problem covers. minimum 1.
warnings[].hintstring | nullyesA concrete suggestion for fixing it, or null.
warnings[].fixobjectnoThe one certain fix, to apply as it is. Present only when exactly one fix is certain.
warnings[].fix.labelstringyesWhat the fix does, in a few words, for a button.
warnings[].fix.editsFixEdit[]yesThe edits, all against the source the diagnostic was found in.
secretsobjectyes
secrets.countintegeryes
secrets.kindsstring[]yes

AddBoardTabBody

FieldTypeRequiredDescription
namestringyesat least 1 character; at most 60 characters.
sourcestringnoDiagram source; the first line is the header, such as flow "Title" (draw_diagram lists every kind). at least 1 character; at most 120000 characters.
afterstring | nullnoat least 12 characters; at most 12 characters; pattern ^[0-9A-Za-z]+$.

UpdateBoardTabBody

FieldTypeRequiredDescription
namestringnoat least 1 character; at most 60 characters.
afterstring | nullnoat least 12 characters; at most 12 characters; pattern ^[0-9A-Za-z]+$.

EditBoardTabBody

FieldTypeRequiredDescription
baseVersionintegeryes
operationsobject[]yes
operations[].op"rename" | "set" | "add_node" | "remove" | "add_edge" | "remove_edge" | "move" | "replace_text"yes
operations[].targetstringnoId, label, table.column, or "header". at most 2000 characters.
operations[].tostringnorename: the new name. Edges: the end. at most 2000 characters.
operations[].fromstringnoEdges: the start. at most 2000 characters.
operations[].optionstringnoat most 40 characters; pattern ^[a-z][A-Za-z0-9_-]*$.
operations[].valuestring | nullnoset: null removes the option. at most 2000 characters.
operations[].idstringnoat most 2000 characters.
operations[].labelstringnoadd_edge on sankey: the amount. at most 2000 characters.
operations[].typestringnoadd_node: node type, or statement word (c4 person, tree dir). at most 2000 characters.
operations[].optionsobjectno
operations[].statementstringnoadd_node: the whole line, for a kind with no plain node statement. at most 2000 characters.
operations[].intostring | nullnoA block; null is the top level. at most 2000 characters.
operations[].afterstringnoat most 2000 characters.
operations[].arrow"<-->" | "-->" | "<->" | "..>" | "->" | "--"no
operations[].findstringnoat most 2000 characters.
operations[].replacestringnoat most 2000 characters.
operations[].allbooleanno

ReplaceBoardTabBody

FieldTypeRequiredDescription
baseVersionintegeryes
sourcestringyesDiagram source; the first line is the header, such as flow "Title" (draw_diagram lists every kind). at least 1 character; at most 120000 characters.

BoardHistory

FieldTypeRequiredDescription
entriesBoardHistoryEntry[]yes
entries[].versionintegeryes
entries[].typestringyes
entries[].actorBoardActoryes
entries[].actor.kind"person" | "agent" | "key"yes
entries[].actor.labelstringyes
entries[].countsobjectyes
entries[].counts.addedintegeryes
entries[].counts.removedintegeryes
entries[].counts.renamedintegeryes
entries[].counts.movedintegeryes
entries[].counts.changedintegeryes
entries[].atintegeryes
entries[].restorablebooleanyes

BoardTabVersion

FieldTypeRequiredDescription
versionintegeryes
sourcestringyes

RestoreBoardTabBody

FieldTypeRequiredDescription
versionintegeryes

BoardAccess

FieldTypeRequiredDescription
access"org" | "restricted"yes
orgRole"view" | "edit"yes
grantsBoardGrant[]yes
grants[].kind"user" | "group"yes
grants[].idstringyes
grants[].namestringyesA member's email address, or a group's name.
grants[].role"view" | "edit" | "manage"yesview: look; edit: change the tabs; manage: also change who may open the board.
joinLinksBoardJoinLink[]yes
joinLinks[].idstringyes
joinLinks[].role"view" | "edit"yes
joinLinks[].createdAtintegeryes
joinLinks[].expiresAtintegeryes
canManagebooleanyes
guestLinkbooleanyesTrue when anyone signed in with the link may watch the board, as the board chose.
guests"ok" | "off" | "confidential"yesWhether guests may open the board now: ok, or off when the owner does not allow guests on boards, or confidential for a Confidential board. Only ok lets a guest in.

BoardGrant

FieldTypeRequiredDescription
kind"user" | "group"yes
idstringyes
namestringyesA member's email address, or a group's name.
role"view" | "edit" | "manage"yesview: look; edit: change the tabs; manage: also change who may open the board.
FieldTypeRequiredDescription
idstringyes
role"view" | "edit"yes
createdAtintegeryes
expiresAtintegeryes

SetBoardAccessBody

FieldTypeRequiredDescription
access"org" | "restricted"yes
orgRole"view" | "edit"yes
guestLinkbooleannoAnyone signed in with the link may watch the board, read only. Left out, it stays as it is.

SetBoardGrantBody

FieldTypeRequiredDescription
kind"user" | "group"yes
idstringyesat least 1 character; at most 64 characters.
role"view" | "edit" | "manage"yesview: look; edit: change the tabs; manage: also change who may open the board.
FieldTypeRequiredDescription
idstringyes
role"view" | "edit"yes
createdAtintegeryes
expiresAtintegeryes
urlstringyesThe link to share. Its token is not stored and cannot be shown again.

CreateBoardJoinLinkBody

FieldTypeRequiredDescription
role"view" | "edit"yes

BoardAccessRequestList

FieldTypeRequiredDescription
itemsBoardAccessRequest[]yes
items[].idstringyes
items[].boardstringyesat least 22 characters; at most 22 characters; pattern ^[0-9A-Za-z]+$.
items[].boardNamestringyes
items[].emailstringyes
items[].notestring | nullyes
items[].memberbooleanyesFalse for a person outside the organisation: approving invites them.
items[].createdAtintegeryes

BoardAccessRequest

FieldTypeRequiredDescription
idstringyes
boardstringyesat least 22 characters; at most 22 characters; pattern ^[0-9A-Za-z]+$.
boardNamestringyes
emailstringyes
notestring | nullyes
memberbooleanyesFalse for a person outside the organisation: approving invites them.
createdAtintegeryes

DecideBoardAccessRequestBody

FieldTypeRequiredDescription
decision"approve" | "decline"yes
role"view" | "edit"no

ImportToBoardBody

FieldTypeRequiredDescription
namestringnoat least 1 character; at most 60 characters.
afterstring | nullnoat least 12 characters; at most 12 characters; pattern ^[0-9A-Za-z]+$.
fromobject | object | object | object | object | object | object | objectyes

SaveBoardTabResult

FieldTypeRequiredDescription
diagramobjectyes
diagram.idstringyes
diagram.namestring | nullyes
diagram.versionintegeryes
status"saved" | "held" | "unchanged"yes
approvalobject | nullyes
approval.codestringyes
approval.messagestringyes
tabBoardTabyes
tab.idstringyesat least 12 characters; at most 12 characters; pattern ^[0-9A-Za-z]+$.
tab.namestringyes
tab.kindstringyesThe kind the source declares, such as flow.
tab.positionnumberyes
tab.versionintegeryes
tab.updatedAtintegeryes
tab.updatedBystringyesWho changed it last: an email address, an agent and its member, or a key name.
tab.libraryobject | nullyes
tab.library.diagramIdstringyes
tab.library.versionintegeryes
tab.library.savedbooleanyesTrue while the tab holds what was saved or imported.

SaveBoardTabBody

FieldTypeRequiredDescription
to"new" | "linked"yesnew: a new library diagram. linked: a new version of the library diagram the tab is linked to.
namestringnoat least 1 character; at most 200 characters.
folderstring | nullnoFolder names from the outermost in, joined with a slash, such as "Payments/Checkout", with no slash at either end. Folder names may use letters A to Z, numbers, spaces, - and _. No space at either end of a name and never two together. Up to 5 levels and 40 characters a name. at most 204 characters; pattern ^[A-Za-z0-9_-]+(?: [A-Za-z0-9_-]+)*(?:/[A-Za-z0-9_-]+(?: [A-Za-z0-9_-]+)*){0,4}$.
libraryVersionintegernoFor linked: the library diagram's version the tab last saw. Left out, the tab's own link. minimum 0.

BoardExportBody

FieldTypeRequiredDescription
format"svg" | "png" | "diagram" | "markdown" | "view-link" | "pdf" | "pptx" | "zip"yes
tabsintegeryesminimum 1; maximum 100.

DiagramBoards

FieldTypeRequiredDescription
itemsobject[]yes
items[].idstringyesat least 22 characters; at most 22 characters; pattern ^[0-9A-Za-z]+$.
items[].namestringyes
items[].tabstringyesat least 12 characters; at most 12 characters; pattern ^[0-9A-Za-z]+$.
hiddenintegeryesminimum 0.

BoardWhere

FieldTypeRequiredDescription
slugstringyes
boardstringyesat least 22 characters; at most 22 characters; pattern ^[0-9A-Za-z]+$.

JoinBoardBody

FieldTypeRequiredDescription
tokenstringyesat least 16 characters; at most 128 characters.

BoardAccessRequestBody

FieldTypeRequiredDescription
notestringnoat most 200 characters.

BoardRevisionResult

FieldTypeRequiredDescription
changedbooleanyes
revisionanyyes
revision.idstringyesat least 12 characters; at most 12 characters; pattern ^[0-9A-Za-z]+$.
revision.tabstringyes
revision.namestringyes
revision.authorRevisionPersonyes
revision.author.kind"person" | "agent" | "key"yes
revision.author.labelstringyes
revision.authorIdstring | nullyes
revision.visibility"private" | "board" | "people"yesprivate: the author only; board: everyone the board is open to; people: the author and the people named.
revision.peoplestring[]yesThe account ids it is shared with by name.
revision.status"open" | "pending" | "merged" | "discarded"yesopen, pending (a merge waits for approval), merged, or discarded.
revision.baseVersionintegeryesThe main version it forked from, or was last updated from.
revision.versionintegeryes
revision.behindintegeryesMain versions made since baseVersion.
revision.createdAtintegeryes
revision.updatedAtintegeryes
revision.updatedByRevisionPersonyes
revision.updatedBy.kind"person" | "agent" | "key"yes
revision.updatedBy.labelstringyes
revision.readablebooleanyesFalse for a private revision shown by its name only, to the people who manage the board.
revision.minebooleanyes
revision.requestobject | nullyes
revision.request.byRevisionPersonyes
revision.request.atintegeryes
revision.request.notestring | nullyes
revision.reviewobject | nullyes
revision.review.byRevisionPersonyes
revision.review.atintegeryes
revision.review.commentstring | nullyes
revision.mergedVersioninteger | nullyes
revision.mergedByanyyes
revision.mergedBy.kind"person" | "agent" | "key"yes
revision.mergedBy.labelstringyes
revision.closedAtinteger | nullyes
listBoardRevisionListno
list.mainVersionintegeryes
list.protectedbooleanyesTrue when a merge into main needs the approval of a person who manages the board.
list.revisionsBoardRevision[]yes
list.revisions[].idstringyesat least 12 characters; at most 12 characters; pattern ^[0-9A-Za-z]+$.
list.revisions[].tabstringyes
list.revisions[].namestringyes
list.revisions[].authorRevisionPersonyes
list.revisions[].authorIdstring | nullyes
list.revisions[].visibility"private" | "board" | "people"yesprivate: the author only; board: everyone the board is open to; people: the author and the people named.
list.revisions[].peoplestring[]yesThe account ids it is shared with by name.
list.revisions[].status"open" | "pending" | "merged" | "discarded"yesopen, pending (a merge waits for approval), merged, or discarded.
list.revisions[].baseVersionintegeryesThe main version it forked from, or was last updated from.
list.revisions[].versionintegeryes
list.revisions[].behindintegeryesMain versions made since baseVersion.
list.revisions[].createdAtintegeryes
list.revisions[].updatedAtintegeryes
list.revisions[].updatedByRevisionPersonyes
list.revisions[].readablebooleanyesFalse for a private revision shown by its name only, to the people who manage the board.
list.revisions[].minebooleanyes
list.revisions[].requestobject | nullyes
list.revisions[].reviewobject | nullyes
list.revisions[].mergedVersioninteger | nullyes
list.revisions[].mergedByanyyes
list.revisions[].closedAtinteger | nullyes
list.hiddenintegeryesOpen revisions the caller may not see.
list.limitintegeryesOpen revisions a tab may have.
sourcestringno
resultsobject[]no
results[].opstringyes
results[].appliedbooleanyes
results[].linesinteger[]yes
results[].messagestringyes
results[].hintstring | nullyes
changesobject[]no
changes[].changestringyes
changes[].subjectstringyes
changes[].namestringyes
changes[].lineinteger | nullyes
changes[].detailstringyes
countsobjectno
counts.addedintegeryes
counts.removedintegeryes
counts.renamedintegeryes
counts.movedintegeryes
counts.changedintegeryes
warningsDiagnostic[]no
warnings[].code"E100" | "E101" | "E110" | "E111" | "E120" | "E121" | "E123" | "E124" | "E125" | "E130" | "E131" | "E132" | "E133" | "E134" | "E135" | "E136" | "E137" | "E138" | "E139" | "E140" | "W200" | "W201" | "W202" | "W203" | "W204" | "W205" | "W206" | "W207" | "W208" | "W209" | "W500" | "W600" | "W601" | "W700" | "W701" | "W702" | "W703" | "W704" | "W705" | "W706" | "W707" | "W708" | "W709" | "W710" | "M100" | "M101" | "M102" | "M103" | "M104" | "M110" | "M200" | "M201" | "M202" | "M203" | "M204" | "M205" | "M206" | "M207" | "M208" | "M209" | "M210" | "M211" | "M212" | "M213" | "M214" | "M215" | "M216" | "M217" | "M218" | "E300" | "E301" | "E302" | "E303" | "E304" | "W300" | "W301" | "W302" | "W303" | "M120" | "M220" | "M221" | "M222" | "E340" | "E341" | "E342" | "E343" | "E344" | "E345" | "W320" | "W321" | "W322" | "W323" | "M240" | "M241" | "M242" | "E360" | "E361" | "E362" | "E363" | "E364" | "E365" | "E366" | "E367" | "W330" | "W331" | "W332" | "W333" | "W334" | "M250" | "M251" | "E400" | "E401" | "E402" | "E403" | "W350" | "W351" | "W352" | "W353" | "M270" | "M271" | "E420" | "E421" | "E422" | "E423" | "E424" | "W360" | "W361" | "W362" | "W363" | "W364" | "M180" | "M280" | "M281" | "M282" | "E320" | "E321" | "E322" | "E323" | "E324" | "E325" | "E326" | "E327" | "E328" | "E329" | "E330" | "W310" | "W311" | "W312" | "W313" | "W314" | "M130" | "M131" | "M132" | "M230" | "M231" | "M232" | "M233" | "M234" | "M235" | "M236" | "M237" | "M238" | "E380" | "E381" | "E382" | "E383" | "W340" | "W341" | "W342" | "W343" | "M260" | "I100" | "I101" | "I102" | "I103" | "I104" | "I105" | "I200" | "I201" | "I202" | "I203" | "I204" | "I206" | "I207" | "R100" | "R101" | "R200" | "R201" | "R202" | "R203" | "R204" | "R205" | "R206" | "R207" | "S100" | "S200" | "S101" | "S102" | "S103" | "S104" | "S201" | "S202" | "S203" | "S204" | "S205"yesStable code to branch on; E-codes are errors, W-codes are warnings.
warnings[].severity"error" | "warning"yesErrors stop rendering; warnings never do.
warnings[].messagestringyesWhat is wrong, in one sentence.
warnings[].lineintegeryes1-based line in the submitted source. minimum 1.
warnings[].columnintegeryes1-based column in that line. minimum 1.
warnings[].lengthintegeryesNumber of characters the problem covers. minimum 1.
warnings[].hintstring | nullyesA concrete suggestion for fixing it, or null.
warnings[].fixobjectnoThe one certain fix, to apply as it is. Present only when exactly one fix is certain.
warnings[].fix.labelstringyesWhat the fix does, in a few words, for a button.
warnings[].fix.editsFixEdit[]yesThe edits, all against the source the diagnostic was found in.
secretsobjectno
secrets.countintegeryes
secrets.kindsstring[]yes
entriesobject[]no
entries[].versionintegeryes
entries[].typestringyes
entries[].actorRevisionPersonyes
entries[].actor.kind"person" | "agent" | "key"yes
entries[].actor.labelstringyes
entries[].countsobjectyes
entries[].counts.addedintegeryes
entries[].counts.removedintegeryes
entries[].counts.renamedintegeryes
entries[].counts.movedintegeryes
entries[].counts.changedintegeryes
entries[].atintegeryes
compareBoardRevisionCompareno
compare.mainVersionintegeryes
compare.versionintegeryes
compare.behindintegeryes
compare.samebooleanyes
compare.countsobjectyes
compare.counts.addedintegeryes
compare.counts.removedintegeryes
compare.counts.renamedintegeryes
compare.counts.movedintegeryes
compare.counts.changedintegeryes
compare.changesobject[]yes
compare.changes[].changestringyes
compare.changes[].subjectstringyes
compare.changes[].namestringyes
compare.changes[].lineinteger | nullyes
compare.changes[].detailstringyes
compare.truncatedbooleanyes
compare.summarystringyes
compare.conflictsBoardMergeConflict[]yes
compare.conflicts[].keystringyesThe statement: its id, its label in quotes, or an edge by its ends. A resolution names it.
compare.conflicts[].subjectstringyes
compare.conflicts[].basestring | nullyes
compare.conflicts[].mainstring | nullyes
compare.conflicts[].revisionstring | nullyes
compare.mergeablebooleanyes
compare.mainstringyesMain's source now.
compare.mergedstring | nullyesMain as the merge would leave it; null while a conflict is open.
compare.revisionstringyes
mergeobjectno
merge.status"merged" | "pending"yes
merge.mainVersionintegeryes
merge.method"same" | "fast-forward" | "replay" | "statements" | nullyes
sentintegerno

BoardRevisionCompare

FieldTypeRequiredDescription
mainVersionintegeryes
versionintegeryes
behindintegeryes
samebooleanyes
countsobjectyes
counts.addedintegeryes
counts.removedintegeryes
counts.renamedintegeryes
counts.movedintegeryes
counts.changedintegeryes
changesobject[]yes
changes[].changestringyes
changes[].subjectstringyes
changes[].namestringyes
changes[].lineinteger | nullyes
changes[].detailstringyes
truncatedbooleanyes
summarystringyes
conflictsBoardMergeConflict[]yes
conflicts[].keystringyesThe statement: its id, its label in quotes, or an edge by its ends. A resolution names it.
conflicts[].subjectstringyes
conflicts[].basestring | nullyes
conflicts[].mainstring | nullyes
conflicts[].revisionstring | nullyes
mergeablebooleanyes
mainstringyesMain's source now.
mergedstring | nullyesMain as the merge would leave it; null while a conflict is open.
revisionstringyes

CreateBoardRevisionBody

FieldTypeRequiredDescription
namestringyesat least 1 character; at most 60 characters.
fromVersionintegerno
visibility"private" | "board" | "people"noprivate: the author only; board: everyone the board is open to; people: the author and the people named.

UpdateBoardRevisionBody

FieldTypeRequiredDescription
namestringnoat least 1 character; at most 60 characters.
visibility"private" | "board" | "people"noprivate: the author only; board: everyone the board is open to; people: the author and the people named.
peoplestring[]no

EditBoardRevisionBody

FieldTypeRequiredDescription
baseVersionintegeryes
operationsobject[]yes
operations[].op"rename" | "set" | "add_node" | "remove" | "add_edge" | "remove_edge" | "move" | "replace_text"yes
operations[].targetstringnoId, label, table.column, or "header". at most 2000 characters.
operations[].tostringnorename: the new name. Edges: the end. at most 2000 characters.
operations[].fromstringnoEdges: the start. at most 2000 characters.
operations[].optionstringnoat most 40 characters; pattern ^[a-z][A-Za-z0-9_-]*$.
operations[].valuestring | nullnoset: null removes the option. at most 2000 characters.
operations[].idstringnoat most 2000 characters.
operations[].labelstringnoadd_edge on sankey: the amount. at most 2000 characters.
operations[].typestringnoadd_node: node type, or statement word (c4 person, tree dir). at most 2000 characters.
operations[].optionsobjectno
operations[].statementstringnoadd_node: the whole line, for a kind with no plain node statement. at most 2000 characters.
operations[].intostring | nullnoA block; null is the top level. at most 2000 characters.
operations[].afterstringnoat most 2000 characters.
operations[].arrow"<-->" | "-->" | "<->" | "..>" | "->" | "--"no
operations[].findstringnoat most 2000 characters.
operations[].replacestringnoat most 2000 characters.
operations[].allbooleanno

ReplaceBoardRevisionBody

FieldTypeRequiredDescription
baseVersionintegeryes
sourcestringyesDiagram source; the first line is the header, such as flow "Title" (draw_diagram lists every kind). at least 1 character; at most 120000 characters.

RestoreBoardRevisionBody

FieldTypeRequiredDescription
versionintegeryes

UpdateBoardRevisionFromMainBody

FieldTypeRequiredDescription
resolutionsBoardMergeResolution[]no
resolutions[].keystringyesat least 1 character; at most 2000 characters.
resolutions[].take"main" | "revision" | "text"yes
resolutions[].textstring | nullnoWith take text: the line to keep; empty removes the statement. at most 2000 characters.

BoardMergeResolution

FieldTypeRequiredDescription
keystringyesat least 1 character; at most 2000 characters.
take"main" | "revision" | "text"yes
textstring | nullnoWith take text: the line to keep; empty removes the statement. at most 2000 characters.

MergeBoardRevisionBody

FieldTypeRequiredDescription
mainVersionintegernoThe main version the resolutions were made against.
resolutionsBoardMergeResolution[]no
resolutions[].keystringyesat least 1 character; at most 2000 characters.
resolutions[].take"main" | "revision" | "text"yes
resolutions[].textstring | nullnoWith take text: the line to keep; empty removes the statement. at most 2000 characters.

DeclineBoardMergeBody

FieldTypeRequiredDescription
commentstringnoat least 1 character; at most 500 characters.

BoardSwitchRequestBody

FieldTypeRequiredDescription
revisionstring | nullyesThe revision to switch to, or null for main. at least 12 characters; at most 12 characters; pattern ^[0-9A-Za-z]+$.

BoardProtectionBody

FieldTypeRequiredDescription
mergeApprovalbooleanyes

OrgBoardGuests

FieldTypeRequiredDescription
allowGuestsbooleanyesWhether a board may be shared with anyone signed in, read only. Off by default.
sharedBoardsintegeryesBoards that share their link with guests now (their label is not Confidential).

OrgBoardGuestsChanged

FieldTypeRequiredDescription
allowGuestsbooleanyesWhether a board may be shared with anyone signed in, read only. Off by default.
sharedBoardsintegeryesBoards that share their link with guests now (their label is not Confidential).
guestsClosedintegeryesGuests' live connections that turning it off closed.

SetOrgBoardGuestsBody

FieldTypeRequiredDescription
allowGuestsbooleanyes

OrgSecurity

FieldTypeRequiredDescription
requireTwoFactorbooleanyesWhether every member must have two-step sign-in on to use the organisation.
sinceinteger | nullyesWhen it was turned on, in milliseconds since the epoch, or null.
canManagebooleanyesWhether the caller may change it: the owner and the admins.
membersobjectyes
members.totalintegeryes
members.withTwoFactorintegeryes
withoutobject[]yesThe members without two-step sign-in, for the owner and the admins; empty for anyone else. At most 200.
without[].userIdstringyes
without[].emailstringyes
without[].namestring | nullyes
without[].rolestringyes
without[].remindedAtinteger | nullyes

SetOrgSecurityBody

FieldTypeRequiredDescription
requireTwoFactorbooleanyes

TwoFactorReminders

FieldTypeRequiredDescription
sentstring[]yesThe members a reminder went to.
skippedobject[]yesMembers reminded less than a day before, and when they can be reminded again.
skipped[].userIdstringyes
skipped[].nextAtintegeryes

RemindTwoFactorBody

FieldTypeRequiredDescription
userIdsstring[]noThe members to remind. Left out, every member without two-step sign-in.

OrgConnectors

FieldTypeRequiredDescription
availablebooleanyesWhether the plan has connectors: Enterprise.
planstringyes
domainsstring[]yesThe domains the organisation verified, which a From address must be on.
emailOrgEmailConnector[]yesThe email connectors, at most one a provider: the default first, then in the order they were added.
email[].provider"resend" | "sendgrid" | "postmark" | "mailgun" | "brevo"yes
email[].fromEmailstringyes
email[].fromNamestring | nullyes
email[].replyTostring | nullyes
email[].region"us" | "eu" | nullyesMailgun's region; null for every other provider.
email[].tokenLast4stringyesThe last four characters of the token. The token itself is never answered.
email[].enabledbooleanyes
email[].isDefaultbooleanyesWhether it is the default, the connector tried first. At most one is.
email[].testedAtinteger | nullyes
email[].lastErrorstring | nullyesWhy the last email through it failed, in our words, or null.
email[].lastErrorAtinteger | nullyes
email[].keyVersionintegeryesThe version of the organisation's data key the token is sealed with.
email[].updatedAtintegeryes
defaultProvider"resend" | "sendgrid" | "postmark" | "mailgun" | "brevo" | nullyesThe provider tried first, or null when there is no connector.

OrgEmailConnector

FieldTypeRequiredDescription
provider"resend" | "sendgrid" | "postmark" | "mailgun" | "brevo"yes
fromEmailstringyes
fromNamestring | nullyes
replyTostring | nullyes
region"us" | "eu" | nullyesMailgun's region; null for every other provider.
tokenLast4stringyesThe last four characters of the token. The token itself is never answered.
enabledbooleanyes
isDefaultbooleanyesWhether it is the default, the connector tried first. At most one is.
testedAtinteger | nullyes
lastErrorstring | nullyesWhy the last email through it failed, in our words, or null.
lastErrorAtinteger | nullyes
keyVersionintegeryesThe version of the organisation's data key the token is sealed with.
updatedAtintegeryes

SetOrgEmailConnectorBody

FieldTypeRequiredDescription
tokenstringnoThe provider's API token. Required for a new connector; left out, the stored one is kept. at least 8 characters; at most 500 characters.
fromEmailstringyesat least 3 characters; at most 254 characters; pattern ^[^\s@]+@[^\s@]+\.[^\s@]+$.
fromNamestring | nullnoat most 80 characters.
replyTostring | nullnoat least 3 characters; at most 254 characters; pattern ^[^\s@]+@[^\s@]+\.[^\s@]+$.
region"us" | "eu" | nullno
enabledbooleanno
makeDefaultbooleannoMake it the default. The organisation's first connector is the default whatever this says.

OrgConnectorTest

FieldTypeRequiredDescription
okbooleanyes
reasonstring | nullyes
tostringyes

BoardMessageBody

FieldTypeRequiredDescription
textstringyesWhat the person asks of their agent, in their words. Kept on the board like a tab, never in the audit log. at least 1 character; at most 2000 characters.
tabstring | nullnoThe tab on screen, or null. at least 12 characters; at most 12 characters; pattern ^[0-9A-Za-z]+$.
revisionstring | nullnoThe revision on screen, or null for main. at least 12 characters; at most 12 characters; pattern ^[0-9A-Za-z]+$.
problemsBoardAgentProblem[]noThe tab's problems, for Send problems.
problems[].codestringyespattern ^[A-Z]\d{3,4}$.
problems[].severity"error" | "warning"yes
problems[].lineintegeryesminimum 1; maximum 1000000.
problems[].columnintegeryesminimum 1; maximum 1000000.
problems[].messagestringyesat least 1 character; at most 500 characters.
problems[].hintstring | nullyesat least 1 character; at most 500 characters.

BoardAgentMessagesSetting

FieldTypeRequiredDescription
setting"connector" | "managers"yesconnector: only the member who connected the agent; managers: also the owners and admins.

FindPatternResponse

Patterns that match a request, best first, with summaries and no source.

FieldTypeRequiredDescription
querystringyesThe query that was searched.
matchesobject[]yesUp to the limit, best match first. Empty when nothing fits.
matches[].idstringyesThe pattern id, as find_pattern returns it, such as three-tier-network. at least 1 character; at most 60 characters.
matches[].titlestringyes
matches[].summarystringyesOne sentence: what the diagram shows.
matches[].kindstringyesA diagram kind: flow, sequence, schema, git, gantt, class, state, timeline, journey, mindmap, treemap, pie, quadrant, layers, c4, matrix, sankey, xychart, tree, swimlane, requirement, block, packet, kanban, radar, usecase, venn, fishbone, or wardley today. Later versions add kinds, so expect others.
matches[].tagsstring[]yes
matches[].providers("neutral" | "aws" | "azure" | "gcp")[]yesThe flavours the pattern comes in.
matches[].scorenumberyesHow well it matches; only the order of the results is meaningful.
matches[].origin"organisation"noPresent on a pattern of your organisation's own, which it approved and which comes first. Absent on the built-in patterns.
matches[].label"Your organisation's pattern"noPresent, with origin, on a pattern of your organisation: the words to show beside it.
nextstringyesThe next step in one sentence.

FindPatternInput

Words that describe the architecture wanted, and optional filters.

FieldTypeRequiredDescription
querystringyesThe architecture wanted, in plain words, such as "three tier network". at least 1 character; at most 200 characters.
provider"neutral" | "aws" | "azure" | "gcp"noOnly patterns that come in this flavour: neutral, aws, azure, or gcp.
tagsstring[]noTags every result must have, such as "load balancer". Up to 5.
kind"flow" | "sequence" | "schema" | "git" | "gantt" | "class" | "state" | "timeline" | "journey" | "mindmap" | "treemap" | "pie" | "quadrant" | "layers" | "c4" | "matrix" | "sankey" | "xychart" | "tree" | "swimlane" | "requirement" | "block" | "packet" | "kanban" | "radar" | "usecase" | "venn" | "fishbone" | "wardley"noOnly patterns of this diagram kind: flow, sequence, schema, git, gantt, class, state, timeline, journey, mindmap, treemap, pie, quadrant, layers, c4, matrix, sankey, xychart, tree, swimlane, requirement, block, packet, kanban, radar, usecase, venn, fishbone, or wardley.
limitintegernoMost results to return, up to 5. minimum 1; maximum 5; default 5.

GetPatternResponse

A pattern filled for one flavour, with its slots and advice.

FieldTypeRequiredDescription
foundbooleanyesTrue when the pattern and flavour exist and the slot values are usable. When false, problems says why and nothing else is filled.
idstringyesThe pattern id that was asked for.
titlestring | nullyes
patternSummarystring | nullyesOne sentence: what the pattern shows.
whenToUsestring | nullyes
kindstring | nullyesA diagram kind: flow, sequence, schema, git, gantt, class, state, timeline, journey, mindmap, treemap, pie, quadrant, layers, c4, matrix, sankey, xychart, tree, swimlane, requirement, block, packet, kanban, radar, usecase, venn, fishbone, or wardley today. Later versions add kinds, so expect others.
flavour"neutral" | "aws" | "azure" | "gcp" | nullyesThe flavour that was filled.
flavours("neutral" | "aws" | "azure" | "gcp")[]yesEvery flavour this pattern comes in; empty when the pattern was not found.
sourcestring | nullyesPlotwork source, valid and ready to use; null when not found.
slotsobject[]yesEvery slot the source uses, with the value it has.
slots[].idstringyesThe slot id; the key to use in slots.
slots[].valuestringyesThe text the slot has in the source: the value sent, or the default.
slots[].defaultstringyesThe default text.
slots[].meaningstringyesWhat belongs in this slot.
slots[].isDefaultbooleanyesTrue when the slot kept its default.
notesobject | nullyesHow to adapt the pattern: what to keep, what to rename, and when to split.
notes.keepstringyesWhat to leave exactly as it is.
notes.renamestringyesWhat to rename or replace, and how.
notes.splitstringyesWhen the diagram has grown too big, and where to cut it.
problemsobject[]yesMistakes in the id, the flavour, or the slot values, each with a fix. Empty when found.
problems[].code"unknown-pattern" | "unknown-flavour" | "unknown-slot" | "bad-slot-value" | "bad-source"yes
problems[].messagestringyes
problems[].hintstringyesHow to fix it.
treeobject[]yesThe groups, overlays, and nodes as drawn, depth first, so you can see what to rename.
tree[].depthintegeryesHow deep the item sits: 0 for the top level.
tree[].kind"group" | "overlay" | "node" | "actor" | "table"yes
tree[].idstringyesThe id written in the source.
tree[].labelstringyes
tree[].typestring | nullyesThe group type, node type, or actor type; null for a table or an untyped group.
outlinestring[]yesThe text description of the diagram.
fileobject | nullnoThe whole pattern as a pattern file, when file was true and the pattern was found.
file.$schemastringno
file.namestringyes
file.titlestringyes
file.summarystringyes
file.whenToUsestringno
file.tagsstring[]no
file.templatesobjectyes
file.templates.neutralstringno
file.templates.awsstringno
file.templates.azurestringno
file.templates.gcpstringno
file.slotsobject[]no
file.slots[].idstringyes
file.slots[].defaultstringyes
file.slots[].meaningstringyes
file.notesobjectno
file.notes.keepstringno
file.notes.renamestringno
file.notes.splitstringno
nextstringyesThe next step in one sentence.

GetPatternInput

A pattern id, the flavour to draw, and the slot values to use.

FieldTypeRequiredDescription
idstringyesThe pattern id, as find_pattern returns it, such as three-tier-network. at least 1 character; at most 60 characters.
provider"neutral" | "aws" | "azure" | "gcp"noneutral (generic glyphs, no vendor names; the default), or aws, azure, or gcp for that provider's icons. Not every pattern comes in every flavour; the answer lists the ones it has. default "neutral".
slotsobjectnoSlot values keyed by slot id, such as {"office": "Branch office"}: plain text of up to 60 characters, no quotes or line breaks. Omit a slot to keep its default. get_pattern lists the slots and what they mean.
filebooleannotrue also returns the whole pattern as a pattern file, to edit, check_pattern and publish_pattern.

DrawFromPatternResponse

A pattern filled, checked, and drawn in one call.

FieldTypeRequiredDescription
foundbooleanyesTrue when the pattern and flavour exist and the slot values are usable. When false, problems says why and nothing else is filled.
idstringyesThe pattern id that was asked for.
titlestring | nullyes
patternSummarystring | nullyesOne sentence: what the pattern shows.
whenToUsestring | nullyes
kindstring | nullyesA diagram kind: flow, sequence, schema, git, gantt, class, state, timeline, journey, mindmap, treemap, pie, quadrant, layers, c4, matrix, sankey, xychart, tree, swimlane, requirement, block, packet, kanban, radar, usecase, venn, fishbone, or wardley today. Later versions add kinds, so expect others.
flavour"neutral" | "aws" | "azure" | "gcp" | nullyesThe flavour that was filled.
flavours("neutral" | "aws" | "azure" | "gcp")[]yesEvery flavour this pattern comes in; empty when the pattern was not found.
sourcestring | nullyesPlotwork source, valid and ready to use; null when not found.
slotsobject[]yesEvery slot the source uses, with the value it has.
slots[].idstringyesThe slot id; the key to use in slots.
slots[].valuestringyesThe text the slot has in the source: the value sent, or the default.
slots[].defaultstringyesThe default text.
slots[].meaningstringyesWhat belongs in this slot.
slots[].isDefaultbooleanyesTrue when the slot kept its default.
notesobject | nullyesHow to adapt the pattern: what to keep, what to rename, and when to split.
notes.keepstringyesWhat to leave exactly as it is.
notes.renamestringyesWhat to rename or replace, and how.
notes.splitstringyesWhen the diagram has grown too big, and where to cut it.
problemsobject[]yesMistakes in the id, the flavour, or the slot values, each with a fix. Empty when found.
problems[].code"unknown-pattern" | "unknown-flavour" | "unknown-slot" | "bad-slot-value" | "bad-source"yes
problems[].messagestringyes
problems[].hintstringyesHow to fix it.
validbooleanyesTrue when the source has no errors. When false, nothing was drawn: fix the errors and call again.
errorsDiagnostic[]yesEvery error found in one pass, each with line, column, and a hint. Empty when valid.
errors[].code"E100" | "E101" | "E110" | "E111" | "E120" | "E121" | "E123" | "E124" | "E125" | "E130" | "E131" | "E132" | "E133" | "E134" | "E135" | "E136" | "E137" | "E138" | "E139" | "E140" | "W200" | "W201" | "W202" | "W203" | "W204" | "W205" | "W206" | "W207" | "W208" | "W209" | "W500" | "W600" | "W601" | "W700" | "W701" | "W702" | "W703" | "W704" | "W705" | "W706" | "W707" | "W708" | "W709" | "W710" | "M100" | "M101" | "M102" | "M103" | "M104" | "M110" | "M200" | "M201" | "M202" | "M203" | "M204" | "M205" | "M206" | "M207" | "M208" | "M209" | "M210" | "M211" | "M212" | "M213" | "M214" | "M215" | "M216" | "M217" | "M218" | "E300" | "E301" | "E302" | "E303" | "E304" | "W300" | "W301" | "W302" | "W303" | "M120" | "M220" | "M221" | "M222" | "E340" | "E341" | "E342" | "E343" | "E344" | "E345" | "W320" | "W321" | "W322" | "W323" | "M240" | "M241" | "M242" | "E360" | "E361" | "E362" | "E363" | "E364" | "E365" | "E366" | "E367" | "W330" | "W331" | "W332" | "W333" | "W334" | "M250" | "M251" | "E400" | "E401" | "E402" | "E403" | "W350" | "W351" | "W352" | "W353" | "M270" | "M271" | "E420" | "E421" | "E422" | "E423" | "E424" | "W360" | "W361" | "W362" | "W363" | "W364" | "M180" | "M280" | "M281" | "M282" | "E320" | "E321" | "E322" | "E323" | "E324" | "E325" | "E326" | "E327" | "E328" | "E329" | "E330" | "W310" | "W311" | "W312" | "W313" | "W314" | "M130" | "M131" | "M132" | "M230" | "M231" | "M232" | "M233" | "M234" | "M235" | "M236" | "M237" | "M238" | "E380" | "E381" | "E382" | "E383" | "W340" | "W341" | "W342" | "W343" | "M260" | "I100" | "I101" | "I102" | "I103" | "I104" | "I105" | "I200" | "I201" | "I202" | "I203" | "I204" | "I206" | "I207" | "R100" | "R101" | "R200" | "R201" | "R202" | "R203" | "R204" | "R205" | "R206" | "R207" | "S100" | "S200" | "S101" | "S102" | "S103" | "S104" | "S201" | "S202" | "S203" | "S204" | "S205"yesStable code to branch on; E-codes are errors, W-codes are warnings.
errors[].severity"error" | "warning"yesErrors stop rendering; warnings never do.
errors[].messagestringyesWhat is wrong, in one sentence.
errors[].lineintegeryes1-based line in the submitted source. minimum 1.
errors[].columnintegeryes1-based column in that line. minimum 1.
errors[].lengthintegeryesNumber of characters the problem covers. minimum 1.
errors[].hintstring | nullyesA concrete suggestion for fixing it, or null.
errors[].fixobjectnoThe one certain fix, to apply as it is. Present only when exactly one fix is certain.
errors[].fix.labelstringyesWhat the fix does, in a few words, for a button.
errors[].fix.editsFixEdit[]yesThe edits, all against the source the diagnostic was found in.
warningsDiagnostic[]yesQuality warnings for a valid diagram: too dense, too wide, text cut, unconnected nodes, and suggestions for an icon or a group type. Empty when invalid.
warnings[].code"E100" | "E101" | "E110" | "E111" | "E120" | "E121" | "E123" | "E124" | "E125" | "E130" | "E131" | "E132" | "E133" | "E134" | "E135" | "E136" | "E137" | "E138" | "E139" | "E140" | "W200" | "W201" | "W202" | "W203" | "W204" | "W205" | "W206" | "W207" | "W208" | "W209" | "W500" | "W600" | "W601" | "W700" | "W701" | "W702" | "W703" | "W704" | "W705" | "W706" | "W707" | "W708" | "W709" | "W710" | "M100" | "M101" | "M102" | "M103" | "M104" | "M110" | "M200" | "M201" | "M202" | "M203" | "M204" | "M205" | "M206" | "M207" | "M208" | "M209" | "M210" | "M211" | "M212" | "M213" | "M214" | "M215" | "M216" | "M217" | "M218" | "E300" | "E301" | "E302" | "E303" | "E304" | "W300" | "W301" | "W302" | "W303" | "M120" | "M220" | "M221" | "M222" | "E340" | "E341" | "E342" | "E343" | "E344" | "E345" | "W320" | "W321" | "W322" | "W323" | "M240" | "M241" | "M242" | "E360" | "E361" | "E362" | "E363" | "E364" | "E365" | "E366" | "E367" | "W330" | "W331" | "W332" | "W333" | "W334" | "M250" | "M251" | "E400" | "E401" | "E402" | "E403" | "W350" | "W351" | "W352" | "W353" | "M270" | "M271" | "E420" | "E421" | "E422" | "E423" | "E424" | "W360" | "W361" | "W362" | "W363" | "W364" | "M180" | "M280" | "M281" | "M282" | "E320" | "E321" | "E322" | "E323" | "E324" | "E325" | "E326" | "E327" | "E328" | "E329" | "E330" | "W310" | "W311" | "W312" | "W313" | "W314" | "M130" | "M131" | "M132" | "M230" | "M231" | "M232" | "M233" | "M234" | "M235" | "M236" | "M237" | "M238" | "E380" | "E381" | "E382" | "E383" | "W340" | "W341" | "W342" | "W343" | "M260" | "I100" | "I101" | "I102" | "I103" | "I104" | "I105" | "I200" | "I201" | "I202" | "I203" | "I204" | "I206" | "I207" | "R100" | "R101" | "R200" | "R201" | "R202" | "R203" | "R204" | "R205" | "R206" | "R207" | "S100" | "S200" | "S101" | "S102" | "S103" | "S104" | "S201" | "S202" | "S203" | "S204" | "S205"yesStable code to branch on; E-codes are errors, W-codes are warnings.
warnings[].severity"error" | "warning"yesErrors stop rendering; warnings never do.
warnings[].messagestringyesWhat is wrong, in one sentence.
warnings[].lineintegeryes1-based line in the submitted source. minimum 1.
warnings[].columnintegeryes1-based column in that line. minimum 1.
warnings[].lengthintegeryesNumber of characters the problem covers. minimum 1.
warnings[].hintstring | nullyesA concrete suggestion for fixing it, or null.
warnings[].fixobjectnoThe one certain fix, to apply as it is. Present only when exactly one fix is certain.
warnings[].fix.labelstringyesWhat the fix does, in a few words, for a button.
warnings[].fix.editsFixEdit[]yesThe edits, all against the source the diagnostic was found in.
summarystring | nullyesOne-line description of the diagram, usable as alt text; null when invalid.
outlinestring[]yesThe diagram as plain text in reading order, to check it says what you meant; empty when invalid.
outlineTruncatedbooleanyesTrue when the summary level cut the outline short. Call again with detail "full" to read all of it.
sizeobject | nullyesNatural size of the laid-out diagram; null when invalid.
size.widthintegeryesWidth in px. minimum 1.
size.heightintegeryesHeight in px. minimum 1.
qualityobjectnoHow clean the picture looks (score, grade, measures) and up to three changes that would help; read it instead of looking. Absent when invalid.
quality.scoreintegeryes0 to 100; 100 is a picture with nothing to fix. The same diagram always gets the same score. minimum 0; maximum 100.
quality.grade"clean" | "fair" | "cluttered"yesclean is 85 or more, fair 60 or more, cluttered below.
quality.measuresobjectyesWhat the score is made from: crossings, lineOverBox, labelOverlaps, smallestTextPx (in an 880px column), aspectRatio, emptySpace (0 to 1), longestLine (px), detour (1 is straight), the counts of boxes, lines, labels, series, and slices, and any measure the kind adds.
quality.hintsstring[]yesUp to three changes, the one worth most first, each naming the statement or option to edit.
quality.linestringyesThe grade, the score, and the first hint in one line.
noticesNote[]noInformation notes, such as an icon alias drawn as the real icon; absent when there is none.
notices[].codestringyesA stable code, such as I122 for an icon alias.
notices[].severity"info"yesA note never stops a drawing and is not a warning.
notices[].messagestringyes
notices[].lineintegeryesminimum 1.
notices[].columnintegeryesminimum 1.
notices[].lengthintegeryesminimum 1.
notices[].hintstring | nullyesThe text to write instead.
rendersobject[]yesOne picture per requested color scheme, light first; empty when invalid, when svg is never, and when every picture was left out (see picturesOmitted).
renders[].scheme"light" | "dark"yesThe color scheme this picture is drawn in.
renders[].svgstringyesSelf-contained SVG markup with an accessible title and description.
renders[].sizeSizeyesNatural size of a rendered diagram in px.
renders[].size.widthintegeryesWidth in px. minimum 1.
renders[].size.heightintegeryesHeight in px. minimum 1.
picturesOmittedobjectnoPresent only when pictures were left out because the answer would have been too big for an AI client to read in one piece.
picturesOmitted.schemes("light" | "dark")[]yesThe color schemes whose pictures were left out.
picturesOmitted.charactersintegeryesHow many characters the pictures left out came to.
picturesOmitted.limitintegeryesThe most characters one answer may hold before the pictures are left out.
picturesOmitted.whystringyesWhy they were left out, and what to do.
viewUrlstringnoA link that shows a valid diagram in a browser; give it to the person who wants to look. It holds the drawing itself: the source is in the part after #, never sent to a server, so nothing is saved on Plotwork and it appears in no Diagrams list; anyone with the link can read it. Absent when too long; next says so.
pngUrlstringnoThe viewUrl with &download=png: opening it in a browser saves the diagram as a PNG for Slack, email, or a wiki. The PNG is drawn in the person's browser, not on a server, so it is a link to open, not an image address to embed. Absent when too long.
svgUrlstringnoThe viewUrl with &download=svg: a person opens it to download the SVG. Not a file address for curl; use saveCommand. Absent when too long.
saveCommandstringnoRun in a shell to save the SVG into the repository: the CLI decodes the link locally, fetches nothing, and embeds the source. Set --out to the path; add --scheme dark for dark. Absent when too long.
nextstringyesThe next step in one sentence.

DrawFromPatternInput

A pattern id, the flavour and slot values to use, and what to return.

FieldTypeRequiredDescription
idstringyesThe pattern id, as find_pattern returns it, such as three-tier-network. at least 1 character; at most 60 characters.
provider"neutral" | "aws" | "azure" | "gcp"noneutral (generic glyphs, no vendor names; the default), or aws, azure, or gcp for that provider's icons. Not every pattern comes in every flavour; the answer lists the ones it has. default "neutral".
slotsobjectnoSlot values keyed by slot id, such as {"office": "Branch office"}: plain text of up to 60 characters, no quotes or line breaks. Omit a slot to keep its default. get_pattern lists the slots and what they mean.
schemes"light" | "dark" | "both"nolight, dark, or both (the default): the light picture and the dark one a dark page needs. default "both".
detail"summary" | "full"nosummary (the default), or full: the whole outline, and the source embedded in each SVG. default "summary".
svg"auto" | "always" | "never"noauto (the default): over MCP the SVG text stays out of the answer (picturesOmitted). always returns it. never draws nothing, cheapest. Checks run either way. The HTTP API treats auto as always. default "auto".
embedSourcebooleannoWrite the source into each SVG so read_diagram can give it back. Set it when you save the SVG in a repository or publish it to edit later; anyone with the file or link can then read the source. default false.
settingsobjectnoThe repo's plotwork.config.json, if any. Schema: https://docs.plotwork.dev/schemas/plotwork.config.json (opens in a new tab).

CheckPatternResponse

Whether a pattern file would be saved, its problems with fixes, and the source each flavour draws.

FieldTypeRequiredDescription
validbooleanyesTrue when the file passes every check a save runs, so publish_pattern or the portal's import would take it.
idstring | nullyesThe id it would have, org:; null when the name is not valid.
kindstring | nullyesThe kind of diagram every flavour draws; null when not valid.
flavours("neutral" | "aws" | "azure" | "gcp")[]yesThe flavours the file gives.
problemsobject[]yesEvery problem at once, each with its field and a fix. Empty when valid.
problems[].fieldstringyesWhere the problem is: name, title, templates.aws, slots.0.default, and so on; json for a file that is not JSON.
problems[].messagestringyes
problems[].hintstringyesHow to fix it.
sourcesobjectyesEach flavour filled with the slot defaults, keyed by flavour: send one to draw_diagram to see it and its warnings. Empty when not valid.
nextstringyesThe next step in one sentence.

CheckPatternInput

A pattern file to check before it is published or imported.

FieldTypeRequiredDescription
patternobjectyesThe pattern file. Every field is described at https://docs.plotwork.dev/schemas/plotwork.pattern.json (opens in a new tab); get_pattern with file true gives one to start from.
pattern.$schemastringno
pattern.namestringyes
pattern.titlestringyes
pattern.summarystringyes
pattern.whenToUsestringno
pattern.tagsstring[]no
pattern.templatesobjectyes
pattern.templates.neutralstringno
pattern.templates.awsstringno
pattern.templates.azurestringno
pattern.templates.gcpstringno
pattern.slotsobject[]no
pattern.slots[].idstringyes
pattern.slots[].defaultstringyes
pattern.slots[].meaningstringyes
pattern.notesobjectno
pattern.notes.keepstringno
pattern.notes.renamestringno
pattern.notes.splitstringno

ProviderVersions

FieldTypeRequiredDescription
source"registry" | "fallback"yesregistry when the list is the Terraform Registry's; fallback when the Registry could not be read and the list is the one release this build was made with.
lateststringyesThe newest stable version, or the newest beta while no stable version exists. at most 64 characters.
itemsProviderVersion[]yesEvery version the Registry lists, newest first, at most 100.
items[].versionstringyesThe version, as required_providers names it. at most 64 characters.
items[].channel"stable" | "beta"yesbeta for a pre-release (a version with a suffix such as -beta.3), which a version range never picks; stable otherwise.
items[].publishedAtstring | nullyesWhen the Registry published it, as an ISO 8601 time, or null when that is not known (the committed fallback). at most 40 characters.

ProviderVersion

FieldTypeRequiredDescription
versionstringyesThe version, as required_providers names it. at most 64 characters.
channel"stable" | "beta"yesbeta for a pre-release (a version with a suffix such as -beta.3), which a version range never picks; stable otherwise.
publishedAtstring | nullyesWhen the Registry published it, as an ISO 8601 time, or null when that is not known (the committed fallback). at most 40 characters.

StorageGoogleStart

FieldTypeRequiredDescription
urlstringyesGoogle’s consent page. The browser goes there next.

StorageIssuerDocument

FieldTypeRequiredDescription
issuerstringyes
jwks_uristringyes
response_types_supportedstring[]yes
subject_types_supportedstring[]yes
id_token_signing_alg_values_supportedstring[]yes
claims_supportedstring[]yes

StorageJwks

FieldTypeRequiredDescription
keysobject[]yes
keys[].kty"RSA"yes
keys[].nstringyes
keys[].estringyes
keys[].kidstringyes
keys[].alg"RS256"yes
keys[].use"sig"yes

StorageOverview

FieldTypeRequiredDescription
availablebooleanyesWhether the plan sends the library to your storage: Pro and Enterprise.
planstringyes
issuerstring | nullyesPlotwork’s issuer for this organisation, which a bucket trusts; null when this server is no issuer.
googleobjectyes
google.configuredbooleanyesWhether this server can connect Google Drive.
google.pickerbooleanyesWhether the Google folder picker is set up, so an existing folder can be chosen.
destinationsStorageDestination[]yesAt most one of each type.
destinations[].idstringyes
destinations[].type"google_drive" | "s3" | "azure_blob" | "gcs"yesgoogle_drive, s3, azure_blob or gcs.
destinations[].state"setup" | "on" | "paused"yessetup while the steps are not done (nothing is sent), on, or paused.
destinations[].connectedbooleanyesFalse for Google Drive until a Google account has granted access; true for a bucket.
destinations[].targetStorageGoogleDriveTarget | StorageS3Target | StorageAzureBlobTarget | StorageGcsTargetyes
destinations[].sendStorageSendyes
destinations[].send.foldersarray | nullyesLibrary folders to send, each with the folders inside it; null for every folder that has no access rule.
destinations[].send.formats("svg" | "source")[]yessvg sends the picture; source sends the .diagram text the picture carries, when it carries one.
destinations[].send.scheme"published" | "light" | "dark"yesA picture that follows the reader’s color scheme is sent as it is, or pinned to light or dark.
destinations[].send.mirrorDeletionsbooleanyesRemove a file when its diagram is deleted from the library or moved out of what is sent.
destinations[].send.skipConfidentialbooleanyesLeave out diagrams labelled Confidential.
destinations[].subjectstring | nullyesThe subject Plotwork’s issuer signs for this destination, which the bucket’s trust names. Null for Google Drive.
destinations[].createdAtintegeryes
destinations[].updatedAtintegeryes
destinations[].statusStorageStatusyes
destinations[].status.queuedintegeryes
destinations[].status.deliveredintegeryes
destinations[].status.droppedintegeryes
destinations[].status.droppedLast24hintegeryes
destinations[].status.filesintegeryesDiagrams the destination holds a copy of now.
destinations[].status.lastSuccessAtinteger | nullyes
destinations[].status.lastErrorAtinteger | nullyes
destinations[].status.lastErrorstring | nullyesWhat failed last, in our words. Never what the destination answered.
destinations[].status.nextAttemptAtinteger | nullyes
destinations[].status.failingSinceinteger | nullyes

StorageDestination

FieldTypeRequiredDescription
idstringyes
type"google_drive" | "s3" | "azure_blob" | "gcs"yesgoogle_drive, s3, azure_blob or gcs.
state"setup" | "on" | "paused"yessetup while the steps are not done (nothing is sent), on, or paused.
connectedbooleanyesFalse for Google Drive until a Google account has granted access; true for a bucket.
targetStorageGoogleDriveTarget | StorageS3Target | StorageAzureBlobTarget | StorageGcsTargetyes
sendStorageSendyes
send.foldersarray | nullyesLibrary folders to send, each with the folders inside it; null for every folder that has no access rule.
send.formats("svg" | "source")[]yessvg sends the picture; source sends the .diagram text the picture carries, when it carries one.
send.scheme"published" | "light" | "dark"yesA picture that follows the reader’s color scheme is sent as it is, or pinned to light or dark.
send.mirrorDeletionsbooleanyesRemove a file when its diagram is deleted from the library or moved out of what is sent.
send.skipConfidentialbooleanyesLeave out diagrams labelled Confidential.
subjectstring | nullyesThe subject Plotwork’s issuer signs for this destination, which the bucket’s trust names. Null for Google Drive.
createdAtintegeryes
updatedAtintegeryes
statusStorageStatusyes
status.queuedintegeryes
status.deliveredintegeryes
status.droppedintegeryes
status.droppedLast24hintegeryes
status.filesintegeryesDiagrams the destination holds a copy of now.
status.lastSuccessAtinteger | nullyes
status.lastErrorAtinteger | nullyes
status.lastErrorstring | nullyesWhat failed last, in our words. Never what the destination answered.
status.nextAttemptAtinteger | nullyes
status.failingSinceinteger | nullyes

StorageGoogleDriveTarget

FieldTypeRequiredDescription
folderIdstring | nullyesThe Drive folder the library goes into, as the folder picker or a new folder gave it. pattern ^[A-Za-z0-9_-]{10,200}$.
folderNamestring | nullyesThe folder's name, for the portal to show. at least 1 character; at most 200 characters.

StorageS3Target

FieldTypeRequiredDescription
roleArnstringyesThe IAM role that trusts Plotwork’s issuer for this organisation. pattern ^arn:aws(-[a-z]+)*:iam::\d{12}:role\/[\w+=,.@/-]{1,512}$.
bucketstringyespattern ^[a-z0-9][a-z0-9._-]{1,220}[a-z0-9]$.
regionstringyespattern ^[a-z]{2}(-gov|-iso[a-z]*)?-[a-z]+-\d$.
prefixstringyesWhere in the bucket the files go, such as plotwork/. Empty for the top. at most 200 characters; pattern ^(?!\/)[A-Za-z0-9!_.*'()/ -]*$.

StorageAzureBlobTarget

FieldTypeRequiredDescription
tenantIdstringyesThe Microsoft Entra tenant.
clientIdstringyesThe app registration whose federated credential trusts Plotwork’s issuer.
accountstringyespattern ^[a-z0-9]{3,24}$.
containerstringyespattern ^[a-z0-9](?!.*--)[a-z0-9-]{1,61}[a-z0-9]$.
prefixstringyesWhere in the bucket the files go, such as plotwork/. Empty for the top. at most 200 characters; pattern ^(?!\/)[A-Za-z0-9!_.*'()/ -]*$.

StorageGcsTarget

FieldTypeRequiredDescription
projectNumberstringyespattern ^\d{6,20}$.
poolIdstringyespattern ^[a-z0-9-]{4,32}$.
providerIdstringyespattern ^[a-z0-9-]{4,32}$.
bucketstringyespattern ^[a-z0-9][a-z0-9._-]{1,220}[a-z0-9]$.
prefixstringyesWhere in the bucket the files go, such as plotwork/. Empty for the top. at most 200 characters; pattern ^(?!\/)[A-Za-z0-9!_.*'()/ -]*$.
serviceAccountstring | nullyesA service account to act as, when the bucket grants it rather than the pool. Null to use the pool’s identity directly. pattern ^[a-z0-9-]{6,30}@[a-z0-9-]{6,30}\.iam\.gserviceaccount\.com$.

StorageSend

FieldTypeRequiredDescription
foldersarray | nullyesLibrary folders to send, each with the folders inside it; null for every folder that has no access rule.
formats("svg" | "source")[]yessvg sends the picture; source sends the .diagram text the picture carries, when it carries one.
scheme"published" | "light" | "dark"yesA picture that follows the reader’s color scheme is sent as it is, or pinned to light or dark.
mirrorDeletionsbooleanyesRemove a file when its diagram is deleted from the library or moved out of what is sent.
skipConfidentialbooleanyesLeave out diagrams labelled Confidential.

StorageStatus

FieldTypeRequiredDescription
queuedintegeryes
deliveredintegeryes
droppedintegeryes
droppedLast24hintegeryes
filesintegeryesDiagrams the destination holds a copy of now.
lastSuccessAtinteger | nullyes
lastErrorAtinteger | nullyes
lastErrorstring | nullyesWhat failed last, in our words. Never what the destination answered.
nextAttemptAtinteger | nullyes
failingSinceinteger | nullyes

CreateStorageBody

FieldTypeRequiredDescription
type"s3" | "azure_blob" | "gcs"yesA bucket. Google Drive is added by signing in with Google.
targetStorageS3Target | StorageAzureBlobTarget | StorageGcsTargetyes
sendStorageSendno
send.foldersarray | nullyesLibrary folders to send, each with the folders inside it; null for every folder that has no access rule.
send.formats("svg" | "source")[]yessvg sends the picture; source sends the .diagram text the picture carries, when it carries one.
send.scheme"published" | "light" | "dark"yesA picture that follows the reader’s color scheme is sent as it is, or pinned to light or dark.
send.mirrorDeletionsbooleanyesRemove a file when its diagram is deleted from the library or moved out of what is sent.
send.skipConfidentialbooleanyesLeave out diagrams labelled Confidential.

UpdateStorageBody

FieldTypeRequiredDescription
targetStorageGoogleDriveTarget | StorageS3Target | StorageAzureBlobTarget | StorageGcsTargetno
createFolderstringnoGoogle Drive only: make a folder of this name at the top of My Drive and send there. at least 1 character; at most 200 characters.
sendStorageSendno
send.foldersarray | nullyesLibrary folders to send, each with the folders inside it; null for every folder that has no access rule.
send.formats("svg" | "source")[]yessvg sends the picture; source sends the .diagram text the picture carries, when it carries one.
send.scheme"published" | "light" | "dark"yesA picture that follows the reader’s color scheme is sent as it is, or pinned to light or dark.
send.mirrorDeletionsbooleanyesRemove a file when its diagram is deleted from the library or moved out of what is sent.
send.skipConfidentialbooleanyesLeave out diagrams labelled Confidential.
state"on" | "paused"noTurn sending on (the library is sent at once) or pause it.

StorageTest

FieldTypeRequiredDescription
okbooleanyes
errorstring | nullyes
linkstring | nullyesWhere to see the sample file, in Drive or the cloud console.

StorageSync

FieldTypeRequiredDescription
queuedintegeryesDiagrams queued to be sent.

DocumentPlacements

FieldTypeRequiredDescription
placementsDocumentPlacement[]yes
placements[].idstringyes
placements[].diagramIdstringyes
placements[].diagramNamestring | nullyes
placements[].kind"slides" | "docs"yesslides for a Google Slides deck, docs for a Google Doc.
placements[].fileIdstringyes
placements[].fileNamestringyes
placements[].pageIdstring | nullyesThe slide, for a deck; null for a Doc.
placements[].status"ok" | "failing" | "gone"yesok, failing (the last send failed; lastError says why) or gone (the file or the picture is no longer there).
placements[].lastErrorstring | nullyes
placements[].lastSentAtinteger | nullyes
placements[].currentbooleanyesWhether the file shows the library's current version.
placements[].createdAtintegeryes
placements[].linkstringyesThe file in Google.

DocumentPlacement

FieldTypeRequiredDescription
idstringyes
diagramIdstringyes
diagramNamestring | nullyes
kind"slides" | "docs"yesslides for a Google Slides deck, docs for a Google Doc.
fileIdstringyes
fileNamestringyes
pageIdstring | nullyesThe slide, for a deck; null for a Doc.
status"ok" | "failing" | "gone"yesok, failing (the last send failed; lastError says why) or gone (the file or the picture is no longer there).
lastErrorstring | nullyes
lastSentAtinteger | nullyes
currentbooleanyesWhether the file shows the library's current version.
createdAtintegeryes
linkstringyesThe file in Google.

DocumentDeckPages

FieldTypeRequiredDescription
slidesobject[]yes
slides[].idstringyes
slides[].indexintegeryes
widthnumberyesThe slide width, in points.
heightnumberyesThe slide height, in points.

DocumentPlacementAnswer

FieldTypeRequiredDescription
placementDocumentPlacementyes
placement.idstringyes
placement.diagramIdstringyes
placement.diagramNamestring | nullyes
placement.kind"slides" | "docs"yesslides for a Google Slides deck, docs for a Google Doc.
placement.fileIdstringyes
placement.fileNamestringyes
placement.pageIdstring | nullyesThe slide, for a deck; null for a Doc.
placement.status"ok" | "failing" | "gone"yesok, failing (the last send failed; lastError says why) or gone (the file or the picture is no longer there).
placement.lastErrorstring | nullyes
placement.lastSentAtinteger | nullyes
placement.currentbooleanyesWhether the file shows the library's current version.
placement.createdAtintegeryes
placement.linkstringyesThe file in Google.

DocumentPlaceBody

FieldTypeRequiredDescription
diagramIdstringyesThe library diagram.
kind"slides" | "docs"yesslides for a Google Slides deck, docs for a Google Doc.
fileIdstringyesThe deck or Doc, as the Google Picker gave it. pattern ^[A-Za-z0-9_-]{10,200}$.
fileNamestringyesThe file's name, for the portal to show. at least 1 character; at most 300 characters.
pageIdstringnoThe slide to place the picture on. Required for a deck. pattern ^[A-Za-z0-9_.:-]{1,200}$.

LocalUsageAck

FieldTypeRequiredDescription
acceptedintegeryesHow many counts were stored. A count sent again replaces the one stored, so a retry never adds twice. minimum 0.
ignoredintegeryesHow many counts were dropped because their tool or kind is not one this server knows. A 200 means the client may treat the days as sent. minimum 0.

LocalUsageBody

FieldTypeRequiredDescription
schema1yesThe version of this request shape. Always 1.
clientLocalUsageClientyes
client.name"plotwork-mcp"yesAlways plotwork-mcp.
client.versionstringyesThe package version, in semver form. at most 40 characters; pattern ^\d{1,6}\.\d{1,6}\.\d{1,6}(?:-[0-9A-Za-z.-]{1,32})?(?:\+[0-9A-Za-z.-]{1,32})?$.
client.os"linux" | "darwin" | "win32" | "other"yesThe operating system family. Anything else is other.
client.nodeintegeryesThe Node major version, a whole number. minimum 18; maximum 99.
daysLocalUsageDay[]yesAt most 31 finished days.
days[].daystringyesA UTC date from 40 days ago to yesterday. Nothing is accepted for today. pattern ^\d{4}-\d{2}-\d{2}$.
days[].idstringyesA pseudonym for one install for one month: the first 128 bits of an HMAC-SHA-256 of plotwork-usage: and the month, keyed with a secret that never leaves the device. It changes every month, so installs can be counted within a month and cannot be followed from one month to the next. pattern ^[0-9a-f]{32}$.
days[].countsLocalUsageCount[]yesAt most 500 counts. A tool, kind, and outcome may appear once a day.
days[].counts[].toolstringyesThe name of the local MCP tool, such as draw_diagram. A name this server does not know is ignored, not refused, so an older server accepts a newer package. pattern ^[a-z][a-z0-9_]{0,63}$.
days[].counts[].kindstringyesThe diagram kind the source declared, such as flow, or none for a call with no source or one that names no kind. A kind this server does not know is ignored, not refused, so an older server accepts a newer package. pattern ^[a-z][a-z0-9]{0,31}$.
days[].counts[].outcome"ok" | "rejected" | "error"yesok produced its answer, rejected was refused because of its input, error failed inside the tool.
days[].counts[].countintegeryesA whole number from 1 to 1,000,000. minimum 1; maximum 1000000.

LocalUsageClient

FieldTypeRequiredDescription
name"plotwork-mcp"yesAlways plotwork-mcp.
versionstringyesThe package version, in semver form. at most 40 characters; pattern ^\d{1,6}\.\d{1,6}\.\d{1,6}(?:-[0-9A-Za-z.-]{1,32})?(?:\+[0-9A-Za-z.-]{1,32})?$.
os"linux" | "darwin" | "win32" | "other"yesThe operating system family. Anything else is other.
nodeintegeryesThe Node major version, a whole number. minimum 18; maximum 99.

LocalUsageDay

FieldTypeRequiredDescription
daystringyesA UTC date from 40 days ago to yesterday. Nothing is accepted for today. pattern ^\d{4}-\d{2}-\d{2}$.
idstringyesA pseudonym for one install for one month: the first 128 bits of an HMAC-SHA-256 of plotwork-usage: and the month, keyed with a secret that never leaves the device. It changes every month, so installs can be counted within a month and cannot be followed from one month to the next. pattern ^[0-9a-f]{32}$.
countsLocalUsageCount[]yesAt most 500 counts. A tool, kind, and outcome may appear once a day.
counts[].toolstringyesThe name of the local MCP tool, such as draw_diagram. A name this server does not know is ignored, not refused, so an older server accepts a newer package. pattern ^[a-z][a-z0-9_]{0,63}$.
counts[].kindstringyesThe diagram kind the source declared, such as flow, or none for a call with no source or one that names no kind. A kind this server does not know is ignored, not refused, so an older server accepts a newer package. pattern ^[a-z][a-z0-9]{0,31}$.
counts[].outcome"ok" | "rejected" | "error"yesok produced its answer, rejected was refused because of its input, error failed inside the tool.
counts[].countintegeryesA whole number from 1 to 1,000,000. minimum 1; maximum 1000000.

LocalUsageCount

FieldTypeRequiredDescription
toolstringyesThe name of the local MCP tool, such as draw_diagram. A name this server does not know is ignored, not refused, so an older server accepts a newer package. pattern ^[a-z][a-z0-9_]{0,63}$.
kindstringyesThe diagram kind the source declared, such as flow, or none for a call with no source or one that names no kind. A kind this server does not know is ignored, not refused, so an older server accepts a newer package. pattern ^[a-z][a-z0-9]{0,31}$.
outcome"ok" | "rejected" | "error"yesok produced its answer, rejected was refused because of its input, error failed inside the tool.
countintegeryesA whole number from 1 to 1,000,000. minimum 1; maximum 1000000.

SyntaxResponse

The diagram language for one scope: the overview, or one kind in full.

FieldTypeRequiredDescription
answerstringyesWhat this answer is: overview, a topic (import-formats, icon-words), or the kind it describes in full (flow, sequence, schema, git, gantt, class, state, timeline, journey, mindmap, treemap, pie, quadrant, layers, c4, matrix, sankey, xychart, tree, swimlane, requirement, block, packet, kanban, radar, usecase, venn, fishbone, or wardley today; later versions add kinds, so expect others).
howToGetAKindstringyesIn plain words: what this answer holds and how to get the rest.
kindsstring[]yesHeader keywords: the first line names the kind.
kindDetailsobject[]yesThe overview lists every kind in the order of kinds, with its header, noun, and summary, and a pointer in more. A kind answer holds that kind alone, in full.
kindDetails[].kindstringyesA diagram kind: flow, sequence, schema, git, gantt, class, state, timeline, journey, mindmap, treemap, pie, quadrant, layers, c4, matrix, sankey, xychart, tree, swimlane, requirement, block, packet, kanban, radar, usecase, venn, fishbone, or wardley today. Later versions add kinds, so expect others.
kindDetails[].headerstringyesThe header line, such as flow "Title".
kindDetails[].nounstringyesWhat the kind's diagrams are called in a sentence, such as flow or database schema.
kindDetails[].summarystringyesOne sentence: what the kind draws.
kindDetails[].statementsobject[]noThe statements the kind adds to the header. Empty for a kind whose language the shared tables of this reference already describe.
kindDetails[].statements[].syntaxstringyesThe statement with its parts named, such as: task "Name" days=.
kindDetails[].statements[].meaningstringyesWhat the statement does, and what it needs.
kindDetails[].statements[].examplestringyesOne line that parses.
kindDetails[].limitsobject[]noThe quality thresholds the kind adds. Empty for a kind whose limits are in the limits table of this reference.
kindDetails[].limits[].namestringyesWhat is counted, such as tasks.
kindDetails[].limits[].valueintegeryesMore than this in one diagram draws a quality warning.
kindDetails[].limits[].meaningstringyesWhy the limit exists and what to do past it.
kindDetails[].morestringnoOnly in the overview, where statements and limits are left out: what a call with this kind returns that the overview does not, and how to ask for it.
nodeTypesobject[]no
nodeTypes[].type"person" | "agent" | "client" | "service" | "gateway" | "function" | "database" | "cache" | "queue" | "storage" | "identity" | "secret" | "external" | "step" | "decision" | "terminal"yes
nodeTypes[].shape"card" | "pill"yesHow the node is drawn.
nodeTypes[].isTintedbooleanyesTrue when the card is filled and outlined in its tone, as for decisions.
nodeTypes[].defaultTone"neutral" | "blue" | "violet" | "aqua" | "orange" | "green" | "amber" | "red"yesColor family used when tone= is not set.
nodeTypes[].defaultIconstring | nullyesIcon used when icon= is not set, or null for none.
nodeTypes[].isDashedbooleanyesTrue when the outline is dashed, as for external systems.
nodeTypes[].usableAsActorbooleanyesTrue when a sequence diagram actor may use this type.
tones("neutral" | "blue" | "violet" | "aqua" | "orange" | "green" | "amber" | "red")[]no
directions("auto" | "right" | "down" | "left" | "up")[]noValues for direction= on a flow header.
arrowsobject[]no
arrows[].tokenstringyesThe arrow as written in source.
arrows[].line"solid" | "dashed" | "dotted"yesHow the line is drawn.
arrows[].heads"end" | "both" | "none"yesWhich ends carry an arrowhead.
arrows[].meaningstringyesWhat the arrow says, so the right one is chosen.
blockTypes("alt" | "opt" | "loop" | "par")[]noFrames a sequence diagram can wrap around messages.
columnFlags("pk" | "fk" | "unique" | "nullable")[]noFlags a schema column row may carry.
schemes("light" | "dark")[]noThe color schemes a picture is drawn in, chosen where it is drawn (a tool's scheme argument), not in the source.
themes("plotwork" | "slate" | "ocean" | "forest" | "sunset" | "mono" | "contrast")[]noColour themes: theme= on the header of any kind, such as flow "Title" theme=ocean. plotwork is the default; contrast reaches WCAG AAA. Each holds light and dark, and tones keep their meaning. An organisation's brand, on the hosted service, wins over it.
iconSets("lucide" | "simple" | "status" | "aws" | "gcp" | "azure" | "alibaba" | "oci" | "ibm" | "cloudflare" | "digitalocean" | "vercel" | "k8s")[]no
iconCountintegernoNumber of bundled icons; use search_icons to find names.
iconProvidersobject[]noCloud and platform providers, each an icon set holding the provider (set:cloud) and its products.
iconProviders[].set"aws" | "gcp" | "azure" | "alibaba" | "oci" | "ibm" | "cloudflare" | "digitalocean" | "vercel"yesIcon set prefix, as in aws:lambda.
iconProviders[].titlestringyesThe provider the set stands for.
iconProviders[].iconCountintegeryesIcons in the set: the provider itself (set:cloud) and its products.
iconProviders[].examplestringyesOne icon of the set that is bundled, for example aws:lambda.
overlayobjectnoA dashed frame around members that may sit in different groups; it owns none of them.
overlay.optionsstring[]yesOptions an overlay statement takes after its name, as in: overlay id "Name" members=a,b type=scale-group.
overlay.frame"solid" | "dashed" | "dotted"yesHow an overlay is always drawn.
overlay.meaningstringyesWhat an overlay is for, so it is used where a group would be wrong.
groupobjectnoHow a flow group looks and what it accepts; its corner tab shows its icon and name.
group.optionsstring[]yesOptions a group statement takes after its name, as in: group id "Name" type=region provider=aws {.
group.defaultTone"neutral" | "blue" | "violet" | "aqua" | "orange" | "green" | "amber" | "red"yesColor family of a group with no type when tone= is not set.
group.exampleobjectyesA complete architecture diagram: typed groups nested by provider, a provider icon on every node, stack marks, and a dotted edge. Copy and edit it.
group.example.kindstringyesA diagram kind: flow, sequence, schema, git, gantt, class, state, timeline, journey, mindmap, treemap, pie, quadrant, layers, c4, matrix, sankey, xychart, tree, swimlane, requirement, block, packet, kanban, radar, usecase, venn, fishbone, or wardley today. Later versions add kinds, so expect others.
group.example.titlestringyes
group.example.sourcestringyesA complete diagram that is checked by the build; copy and edit it.
group.typesobject[]yesEvery group type. A type gives the group a default icon, tone, frame style, and a shade that deepens with nesting; icon= and tone= override them.
group.types[].type"cloud" | "account" | "region" | "zone" | "network" | "subnet" | "public-subnet" | "private-subnet" | "management-subnet" | "isolated-subnet" | "resource-group" | "cluster" | "scale-group" | "service-plan" | "web-tier" | "app-tier" | "data-tier" | "storage-account" | "messaging" | "edge" | "security" | "identity-boundary" | "trust-boundary" | "observability" | "ci-cd" | "environment" | "cloud-boundary" | "on-premises" | "client-side" | "external-systems"yesValue for type= on a group.
group.types[].titlestringyesWhat the frame is called in the text description.
group.types[].meaningstringyesWhat the author means by this type, so the right one is chosen.
group.types[].tone"neutral" | "blue" | "violet" | "aqua" | "orange" | "green" | "amber" | "red"yesColor family the frame and tab get when tone= is not set.
group.types[].frame"solid" | "dashed" | "dotted"yesHow the outline is drawn.
group.types[].iconstringyesIcon in the corner tab when the group has no provider.
group.types[].providerIconsobjectyesIcon in the corner tab for each provider whose icon differs from the generic one, keyed by provider set.
flowLookobject[]noOptions that shape a flow diagram: spacing=, edges= and fit= on the header, main=on on an edge, and the align statement.
flowLook[].keystringyesThe option or statement as written, such as spacing or align.
flowLook[].scope"header" | "line" | "statement"yesheader: on the flow header line. line: on an edge. statement: a line of its own.
flowLook[].valuesstringyesWhat it takes.
flowLook[].meaningstringyesWhat it does.
flowLook[].examplestringyesOne line that parses.
lineOptionsobject[]noOptions that animate a line (animate=on makes dashes travel toward the arrowhead) or number the steps of a flow or sequence (numbered=on, start=, and step= on a line). All are off by default.
lineOptions[].keystringyesThe option as written, such as animate or step.
lineOptions[].scope"header" | "line"yesheader: on the flow or sequence header line. line: on an edge or a message.
lineOptions[].valuesstringyesWhat the option takes.
lineOptions[].meaningstringyesWhat it does, and the cases where it is refused.
lineOptions[].examplestringyesOne line that parses.
labelIconsobject[]noEdge labels that name an outcome and get its status icon automatically (a tick for yes, a cross for no, a clock for expired); one per icon in a kind answer, every one in topic icon-words. icon=none on the edge removes it.
labelIcons[].labelstringyesAn edge label that gets an icon automatically, matched whole and ignoring case.
labelIcons[].iconstringyesThe icon the label gets.
verbIconsobject[]noThe icons a flow edge label draws when it names a relationship with a verb. icon= on the edge wins, icon=none removes it, and icons=off on the header turns them all off.
verbIcons[].iconstringyesThe icon drawn in the label.
verbIcons[].wordsstring[]yesPhrases that draw it: the whole label, or its first words followed by what is acted on ("reads orders").
stylestring[]noHow to make a flow diagram look finished: verbs on arrows, role= on lines that mean something, typed groups, product names.
autoIconsobjectnoItems with no icon= get the icon their label names for certain (a brand, a cloud product, a common role). icon=none keeps one item plain; icons=off on the header keeps them all plain.
autoIcons.keystringyesThe header option: icons.
autoIcons.valuesstringyesWhat it takes.
autoIcons.meaningstringyesWhat it does, and how one item opts out.
autoIcons.examplestringyesOne header line that parses.
roleIconsobject[]noThe plain icons for common roles, drawn on flow and sequence service and external items, C4 elements, layers blocks, mind map topics, and swimlane lanes. The last role word of the label wins.
roleIcons[].iconstringyesThe icon drawn.
roleIcons[].wordsstring[]yesWhole words of a label of three words or fewer that draw it.
statusIconsobject[]noColored status and outcome icons: a green check, a red X, and so on.
statusIcons[].refstringyesValue for icon=, such as status:success.
statusIcons[].tone"neutral" | "blue" | "violet" | "aqua" | "orange" | "green" | "amber" | "red"yesColor the icon is always drawn in, whatever tone its owner has.
statusIcons[].meaningstringyesWhat the icon says, so the right one is chosen.
limitsobjectnoBounds and quality thresholds.
limits.maxSourceLengthintegeryes
limits.maxFlowNodesintegeryesQuality lint: more nodes than this warns, for a diagram with no groups.
limits.nodesPerGroupintegeryesEach group of a flow diagram raises the node limit by this many.
limits.maxFlowNodesCeilingintegeryesThe node limit never rises above this, whatever the groups.
limits.maxSchemaTablesintegeryes
limits.maxSequenceActorsintegeryes
limits.maxNumberedStepsintegeryesMore numbered steps than this in one diagram warns (W200).
limits.maxStackMarksintegeryesMost technology marks a node carries in stack=.
limits.targetWidthintegeryesColumn width in px that diagrams are checked against.
editingobjectnoHow to edit an existing Plotwork SVG: read it back with read_diagram, change the source, draw it, and save or publish it again.
editing.stepsstring[]yesIn order: how to change a diagram that already exists as a Plotwork SVG, a hosted link or a file in the repository.
editing.embedSourcestringyesWhen to set embedSource true on draw_diagram or render_diagram, that publish_diagram embeds the source unless it is false, and what it means for who can read the source.
diagnosticCodesobject[]no
diagnosticCodes[].namestringyesIdentifier of the code.
diagnosticCodes[].codestringyesThe code to branch on, such as E120.
diagnosticCodes[].severity"error" | "warning"yes
examplesobject[]yesTested examples: the overview holds the ones for the kinds the shared tables describe in full, a kind answer holds its own.
examples[].kindstringyesA diagram kind: flow, sequence, schema, git, gantt, class, state, timeline, journey, mindmap, treemap, pie, quadrant, layers, c4, matrix, sankey, xychart, tree, swimlane, requirement, block, packet, kanban, radar, usecase, venn, fishbone, or wardley today. Later versions add kinds, so expect others.
examples[].titlestringyes
examples[].sourcestringyesA complete diagram that is checked by the build; copy and edit it.
importFormatsobject[]noOnly for topic import-formats: every format import_source reads, a line each.
importFormats[].formatstringyesThe format, as import_source takes it.
importFormats[].readsstringyesWhat it reads.
importFormats[].drawsstringyesThe diagram it draws.
importFormats[].optionsstringyesThe options it takes.

See also

DocWhy
API referenceEvery endpoint, and the error envelope
Tool referenceThe same operations as callable tools
Language referenceWhat the diagram source may contain