Skip to content

Correct a design that has not been ordered

PATCH
/v1/designs/{id}
curl --request PATCH \
--url https://api.pixonaut.app/v1/designs/example \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{ "expectedRevision": 1, "values": { "namn": { "content": "Merry Christmas" } } }'

Operation ID: designs.update

Applies values on top of the design’s document under the rules its template version sets, keeps the size it was committed at, and sends it back to awaiting approval: any approval, made or scheduled, is cleared, and nothing is printed or ordered until it is approved again. Renders a proof of the corrected document, which becomes the design’s proof (proofId); a correction whose proof cannot be rendered is refused, and writes nothing. Or, with proofToken instead, makes a correction proof’s document the design’s next revision and that proof the design’s proof, refused proof_not_for_design for a proof of another design, or of no design, proof_adjusts_layout for a layout adjustment’s proof, which POST /v1/designs/standing takes, and revision_changed once the design has moved past the revision the proof was made from. Emits design.edited. A correction that leaves the document as it is writes nothing — not a revision, not a cleared approval, not an event — and answers edited: false. Refused once any print of the design has an order.

id
required
string
Media typeapplication/json
Any of:
object
proofToken
required

The token POST /v1/designs/{id}/correction-proofs answered for this design. The design must still be at the revision the proof was made from.

string
>= 1 characters

Examples

Design to order: Correcting a design before it is ordered

{
"expectedRevision": 1,
"values": {
"namn": {
"content": "Merry Christmas"
}
}
}

Corrected, and awaiting approval; or nothing to correct

Media typeapplication/json
object
edited
required

Whether this correction wrote a revision. False when it left the document as it was: nothing was written, the approval stands, and revision is the current one.

boolean
lowResolution
required

The pictures that print below printFloorDpi at the design’s print size. A warning: nothing is refused for it.

Array<object>
object
actualPx
required

The picture’s pixels along the edge that decides.

number
assetId
required
string
effectiveDpi
required

Pixels per inch along that edge, as printed.

number
layerId
required

The layer the picture fills, or the artwork’s own key for its image background.

string
minPx
required

The pixels that edge needs at the floor.

number
printFloorDpi
required

The minimum print resolution the design’s pictures were judged against: the template’s own, else the tenant’s.

number
proofId
required

The design’s proof now: the one rendered of the revision this wrote, or, when nothing was written, the proof the design already had (null when it has none). Its image is GET /v1/designs/{id}/proof.

string | null
revision
required
integer

Examples

Design to order: Correcting a design before it is ordered

{
"edited": true,
"lowResolution": [],
"printFloorDpi": 150,
"proofId": "prf_9c1e2d3f4a5b6c7d8e9f0a1b",
"revision": 2
}
X-Request-Id
required
string

Every response names the request it answers in X-Request-Id: the id the request was sent with in that header, when it is well formed, else one the API gave it. Quote it when reporting a refusal or a failure: the API’s log lines for that request carry it.

Refused: bad_request

Media typeapplication/json
object
error
required
string

Examples

Examplebad_request

bad_request

{
"error": "bad_request"
}
X-Request-Id
required
string

Every response names the request it answers in X-Request-Id: the id the request was sent with in that header, when it is well formed, else one the API gave it. Quote it when reporting a refusal or a failure: the API’s log lines for that request carry it.

Refused: unauthorized

Media typeapplication/json
object
error
required
string

Examples

Exampleunauthorized

unauthorized

{
"error": "unauthorized"
}
X-Request-Id
required
string

Every response names the request it answers in X-Request-Id: the id the request was sent with in that header, when it is well formed, else one the API gave it. Quote it when reporting a refusal or a failure: the API’s log lines for that request carry it.

Refused: origin_forbidden, forbidden, feature_disabled, workspace_suspended

Media typeapplication/json
object
error
required
string
feature

The feature the tenant does not have. Always sent with feature_disabled.

string

Examples

feature_disabled

{
"error": "feature_disabled",
"feature": "api"
}
X-Request-Id
required
string

Every response names the request it answers in X-Request-Id: the id the request was sent with in that header, when it is well formed, else one the API gave it. Quote it when reporting a refusal or a failure: the API’s log lines for that request carry it.

Refused: not_found, unknown_proof

Media typeapplication/json
object
error
required
string

Examples

not_found

{
"error": "not_found"
}
X-Request-Id
required
string

Every response names the request it answers in X-Request-Id: the id the request was sent with in that header, when it is well formed, else one the API gave it. Quote it when reporting a refusal or a failure: the API’s log lines for that request carry it.

Refused: not_editable, revision_changed, proof_not_for_design, proof_adjusts_layout

Media typeapplication/json
object
error
required
string
reason

ordered: a print of the design has an order, so it is what was made; duplicate it instead. erased: the design’s personal data was erased, and it takes nothing more. cut_from_layout: the design is one placement’s print cut from a panel layout’s canvas; commit a new design through the layout (POST /v1/designs/layout) instead. linked: the design is one placement’s print of a linked group, which one design drives; commit the group’s placements again instead. Always sent with not_editable.

string
revision

Always sent with revision_changed.

integer

Examples

not_editable

{
"error": "not_editable",
"reason": "erased"
}
X-Request-Id
required
string

Every response names the request it answers in X-Request-Id: the id the request was sent with in that header, when it is well formed, else one the API gave it. Quote it when reporting a refusal or a failure: the API’s log lines for that request carry it.

Refused: proof_expired

Media typeapplication/json
object
error
required
string

Examples

Exampleproof_expired

proof_expired

{
"error": "proof_expired"
}
X-Request-Id
required
string

Every response names the request it answers in X-Request-Id: the id the request was sent with in that header, when it is well formed, else one the API gave it. Quote it when reporting a refusal or a failure: the API’s log lines for that request carry it.

Refused: asset_map_too_large, constraint_violation, design_doc_unreadable, payload_too_large

Media typeapplication/json
object
bytes

Always sent with asset_map_too_large, and may be sent with payload_too_large.

number
error
required
string
maxBytes

Always sent with asset_map_too_large, payload_too_large.

number
violations

Always sent with constraint_violation.

Array<object>
object
characters

On a text_draws_fallback_glyphs or text_draws_missing_glyphs warning: the characters the text’s font cannot draw, each once, in the order the text first holds them. Absent on every other violation.

Array<string>
given
required
language

The language whose overrides break the rule, when only the template as it reads in that language does. Absent, the original.

string
layerId
required
string
prop
required
string
rule
required
string
severity
required

error refuses a publish; warning is worth the author’s attention and never does.

string

Examples

asset_map_too_large

{
"bytes": 0,
"error": "asset_map_too_large",
"maxBytes": 0
}
X-Request-Id
required
string

Every response names the request it answers in X-Request-Id: the id the request was sent with in that header, when it is well formed, else one the API gave it. Quote it when reporting a refusal or a failure: the API’s log lines for that request carry it.

Refused: rate_limited

Media typeapplication/json
object
error
required
string

Examples

Examplerate_limited

rate_limited

{
"error": "rate_limited"
}
X-Request-Id
required
string

Every response names the request it answers in X-Request-Id: the id the request was sent with in that header, when it is well formed, else one the API gave it. Quote it when reporting a refusal or a failure: the API’s log lines for that request carry it.

The caller left before the render started

Media typeapplication/json
object
error
required
string

Examples

Exampleclient_closed_request

client_closed_request

{
"error": "client_closed_request"
}
X-Request-Id
required
string

Every response names the request it answers in X-Request-Id: the id the request was sent with in that header, when it is well formed, else one the API gave it. Quote it when reporting a refusal or a failure: the API’s log lines for that request carry it.

Refused: db_error, render_failed. A request that failed unexpectedly answers as text instead.

object
error
required
string

Examples

db_error

{
"error": "db_error"
}
X-Request-Id
required
string

Every response names the request it answers in X-Request-Id: the id the request was sent with in that header, when it is well formed, else one the API gave it. Quote it when reporting a refusal or a failure: the API’s log lines for that request carry it.

Refused: assets_unavailable, lock_timeout

Media typeapplication/json
object
error
required
string

Examples

assets_unavailable

{
"error": "assets_unavailable"
}
X-Request-Id
required
string

Every response names the request it answers in X-Request-Id: the id the request was sent with in that header, when it is well formed, else one the API gave it. Quote it when reporting a refusal or a failure: the API’s log lines for that request carry it.

Questions? Write to [email protected].

Status · Terms of service · Privacy policy · Subprocessors