Skip to content
Connect an agent

Plotwork

Get the Plotwork connection

Whether the workspace has connected a Plotwork account, and which one.

GET/v1/plotwork

TL;DR

QuestionAnswer
What does it do?Get the Plotwork connection.
What does it need?An API key or an OAuth access token.
What does it take?Nothing.
What does it return?Status 200 with a body of type PlotworkConnection.
In the SDK?flung.plotwork.get()
What can go wrong?401 Missing, unknown, revoked or expired API key; 422 The request failed validation; 429 Too many requests for this credential; wait for retry-after seconds. Every failure has the same error shape.

What it does

Whether the workspace has connected a Plotwork account, and which one. Never a token.

Example

curl
curl -X GET 'https://api.flung.dev/v1/plotwork' \  --header "Authorization: Bearer $FLUNG_API_KEY"

A successful answer looks like this:

json
{  "connected": true,  "status": "active",  "account": {    "id": "string",    "name": "string",    "email": "string",    "organisation": {      "slug": "string",      "name": "string"    }  },  "connectedAt": "2026-11-01T09:00:00.000Z"}

Responses

StatusMeaningBody
200The connection.PlotworkConnection
401Missing, unknown, revoked or expired API key.Error
422The request failed validation.Error
429Too many requests for this credential; wait for retry-after seconds.Error

Response body

A 200 answer has the type PlotworkConnection.

FieldTypeRequiredDescription
connectedbooleanyes
status"active" | "needs_reconnect" | nullyesneeds_reconnect once Plotwork ended the grant: a person connects it again in the portal. Null when not connected.
accountobject | nullyes
account.idstringyes
account.namestring | nullyes
account.emailstring | nullyes
account.organisationobject | nullyesThe Plotwork organisation whose library it reads, or null for the person's own.
account.organisation.slugstringyes
account.organisation.namestringyes
connectedAtstring | nullyes

See also

DocWhy
API referenceEvery endpoint
SchemasEvery request and response type
ErrorsEvery error code and what to do about it