Welcome to the Onshape forum! Ask questions and join in the discussions about everything Onshape.

First time visiting? Here are some places to start:
  1. Looking for a certain topic? Check out the categories filter or use Search (upper right).
  2. Need support? Ask a question to our Community Support category.
  3. Please submit support tickets for bugs but you can request improvements in the Product Feedback category.
  4. 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.

Restructuring imported assemblies via API

JoeySJoeyS Member Posts: 1
I'm importing an assembly that with has multiple instances of the same part number, as shown here (3x PN3):

PN1
- PN2
- PN3
- PN3
- PN3

OnShape creates 3x Documents that are all identical copies of PN3, and an assembly structure that references each of them individually.

I would like to do a few different things:
- programmatically update the assembly to point all references to PN3 to one of the three Documents, and delete the other 2 obsolete PN3 Documents
- programmatically create a folder/file structure for the correct copy of PN3
- programmatically move (or copy) the PN3 Document to the newly created folder/file structure -- I see the Move Elements API that seems like it could do this; I'm having trouble getting it to work

Does anyone have any tips for these actions?
Tagged:
Sign In or Register to comment.