Welcome to the Onshape forum! Ask questions and join in the discussions about everything Onshape.
First time visiting? Here are some places to start:- Looking for a certain topic? Check out the categories filter or use Search (upper right).
- Need support? Ask a question to our Community Support category.
- Please submit support tickets for bugs but you can request improvements in the Product Feedback category.
- Be respectful, on topic and if you see a problem, Flag it.
If you would like to contact our Community Manager personally, feel free to send a private message or an email.
OnShape API GET request for a gltf object for assemblies
earlgreyaroma
Member Posts: 4 EDU
in General
Hi,
is there a way to get a gltf object from a whole assembly (the parts should be displayed assembled) directly or with some tricks? I couldn't find anything in the glassworks explorer except for getting singular parts gltfs and my knowledge in web development and this kind of stuff is lacking. Thanks in advance.
0
Answers
You can use the https://cad.onshape.com/glassworks/explorer#/Assembly/translateFormat to export an assembly to GLTF. The format name is "GLTF", for example
Hope that helps!
Paul
For example Once you do this, the response will include a URL to poll for the status of the translation (the translation isn't instantaneous). Once the requestState is "Done" , you can use the `resultExternalDataIds` to download the data using the API , https://cad.onshape.com/glassworks/explorer#/Document/downloadExternalData.
Note: resultExternalDataIds maps to fid in the downloadExternalData request. For more information: https://onshape-public.github.io/docs/translation/#general-translations