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.
copy design using api

i have a public design for example this one
https://cad.onshape.com/documents/fc8af75b1e15f82459f28f6f/w/431848f670c2fa7a12ebc577/e/b9af0e7afeae426fd3426fdd
im trying to copy it using the api
method = POST
path = f"/api/documents/d/{source_did}/w/{source_wid}/copy" body = { "newName": new_doc_name, "isPublic": is_public }
i get document not found , but when i use the same ids , but with a different endpoint to get the document details:
method= GET
path = f"/api/documents/{doc_id}"
i get the document details
am i using the wrong endpoint or is there another method?
i know i can do this from the viewer by simply pressing the button in the image , but is there a way to do it using the api??
Comments
I think you need
body = { "newName": new_doc_name, "isPublic": is_public, "ownerId": <your user id> }
just tried it but got the same error:(
Might be an authentication thing. Have you tried it using Glassworks?
https://cad.onshape.com/glassworks/explorer/#/Document/copyWorkspace
Yeah, this one works for me:
https://cad.onshape.com/glassworks/explorer/#/Document/copyWorkspace
Learn more about the Gospel of Christ ( Here )
CADSharp - We make custom features and integrated Onshape apps! Learn How to FeatureScript Here 🔴
truns out i have to add v6 before the endpoint -_- and also the user id is the email
wth
The version I used was v11:
Learn more about the Gospel of Christ ( Here )
CADSharp - We make custom features and integrated Onshape apps! Learn How to FeatureScript Here 🔴