List the blank placements a template fits
const url = 'https://api.pixonaut.app/v1/templates/example/fitting-blanks?page=1&pageSize=50';const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url 'https://api.pixonaut.app/v1/templates/example/fitting-blanks?page=1&pageSize=50' \ --header 'Authorization: Bearer <token>'Operation ID: templates.fittingPlacements.list
Every placement on the tenant’s blanks, with the verdict for this artwork at the size it would print at there. It answers geometry, not whether the pairing is sold, and it answers for a draft or paused template too. The page is of BLANKS: one blank with three placements is three items, so page on page and total, not on the number of items. q keeps the blanks whose name holds it, case aside.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”A template id, baseId@version.
A template id, baseId@version.
Query Parameters
Section titled “Query Parameters”The page to read, from 1; the first when left out.
The page to read, from 1; the first when left out.
Responses
Section titled “Responses”A page of placements with their verdicts
object
object
Examples
Example
{ "items": [ { "blankId": "blank_tshirt", "blankName": "Classic T-shirt", "defaultHeightMm": 360, "defaultWidthMm": 280, "maxHeightMm": 360, "maxWidthMm": 280, "placementId": "front", "placementName": "Front", "printHeightMm": 360, "printWidthMm": 280, "verdict": { "legal": true } } ], "page": 1, "pageSize": 50, "total": 1}Headers
Section titled “Headers”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
object
Examples
unauthorized
{ "error": "unauthorized"}Headers
Section titled “Headers”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
object
The feature the tenant does not have. Always sent with feature_disabled.
Examples
feature_disabled
{ "error": "feature_disabled", "feature": "api"}forbidden
{ "error": "forbidden"}origin_forbidden
{ "error": "origin_forbidden"}workspace_suspended
{ "error": "workspace_suspended"}Headers
Section titled “Headers”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
object
Examples
not_found
{ "error": "not_found"}Headers
Section titled “Headers”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: invalid_query
object
Examples
invalid_query
{ "error": "invalid_query"}Headers
Section titled “Headers”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
object
Examples
rate_limited
{ "error": "rate_limited"}Headers
Section titled “Headers”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. A request that failed unexpectedly answers as text instead.
object
Examples
db_error
{ "error": "db_error"}Headers
Section titled “Headers”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].