API REST programming javascript code headers ajax jquery
Discussion List
-
DXF flat-pattern export via /partstudios/.../translations fails with generic {1} failed to translate
Hi all — I'm trying to export sheet-metal flat patterns as DXF via the REST API from a Node/TypeScript backend, across many configurations of a configured Part Studio (one document, many CSV-driven configs). Each configuration resolves to valid sheet-metal parts; in the Onshape UI, the Sheet Metal Table shows correct flat…
-
How can I programmatically create a plane at an arbitrary orientation using the Onshape REST API?
Hi everyone: I’m working with the Onshape REST API to programmatically generate sketches and extrudes. I’ve successfully used the API to: Create sketches on standard planes (e.g., "Front") Define circles, rectangles, and line segments Extrude sketches into 3D geometry Now I want to define a new reference plane — for…
-
Is there an example of a Request Body for the Update Element Metadata API method?
I am refactoring some of our code to remove the deprecated Elements methods with the new MetaData methods and I'm having trouble figuring out the format of the JSON for the Request Body. The API Explorer has the following definition but it's not clear to me how to set these JSON Values. I've been able to successfully Get…
-
Onshape REST API using JavaScript
We are using the Onshape REST Api to extract data from Onshape. We have this working using C# as well as Node.js, but I would like to do the same from client-side javascript. Everything is in place using Ajax and I've verified all authorization headers are correct. My problem is currently with the "Date" header throwing…