Skip to main content
PATCH
Edit a canvas's design file with find-and-replace…

Authorizations

authorization
string
header
required

Path Parameters

projectId
string<uuid>
required

The project in the URL. The caller's project user is read from it.

Pattern: ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$
workspaceId
string<uuid>
required

PATCH /v2/api/projects/:projectId/workspaces/:workspaceId/canvases/:canvasId/design Parameter

Pattern: ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$
canvasId
string<uuid>
required

The canvas whose design file this is.

Pattern: ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$

Body

application/json

PATCH /v2/api/projects/:projectId/workspaces/:workspaceId/canvases/:canvasId/design Request body

edits
object[]
required

Find-and-replace edits applied in order. Each find must match the file exactly once; an edit that matches zero or several times is refused and nothing is saved.

Required array length: 1 - 50 elements
baseRev
integer
required

The rev of the design you read. The write is refused with 409 when the design has changed since, so read it again and redo the edit.

Required range: 0 <= x <= 9007199254740991
apiKey
string

Upsolve API key, generated under Account → Developer settings in the Upsolve Hub. Keys are user-scoped: pass organizationId alongside the key to select which org to act on.

Minimum string length: 1
organizationId
string

The ID of the organization. Required when using Supabase JWT authentication.

connectionId
string

The ID of the connection a guest has access to

source
enum<string>

Who is making the change, recorded on the revision. Defaults to mcp for an MCP client and user otherwise.

Available options:
user,
agent,
cli,
mcp,
system

Response

PATCH /v2/api/projects/:projectId/workspaces/:workspaceId/canvases/:canvasId/design Positive response

status
string
required
Allowed value: "success"
data
object
required