Drawing: the complete drawing
POST /drawing runs the template with the values given and returns the complete drawing as ParametrIQ drawing
text (.piq): still parametric, with its labelled variables set to the values given, and its layers. It opens in
ParametrIQ CAD as it is. What the template printed as it ran (PRINT) comes back too.
The body is a template (as template, or as source from one of your storages) and values for its labelled variables, as described on the API page.
Example
POST /drawing
X-API-KEY: your-api-key
Content-Type: application/json
{
"template": "L=400,\"Length\"\nW=300,\"Width\"\nP1=[L,0]\nP2=[L,W]\nP3=[0,W]\nPOLYLINE @1,[P0,P1,P2,P3],TRUE,0",
"values": { "L": 500, "W": 250 }
}
{
"drawing": "//Product// PiQ SaaS\n//Units// MILLIMETERS\nLAYERTABLE \"FEFCO\"\n … L=500,\"Length\"\nW=250,\"Width\"\n …",
"printed": []
}
To get the drawing as a file to download instead, use Export with the format piq.