Skip to main content
12-Amethyst
May 4, 2019
Question

Windchill REST API request to receive all parts associated with particular drawing

  • May 4, 2019
  • 1 reply
  • 2726 views

Hi there,

The Windchill REST API can be used to retrieve all drawings of a particular part.

Example

https://windchill.acme.com/Windchill/servlet/rest/structure/drawings/OR%3Awt.part.WTPart%3A102799?useParts=true

Result:

{
"items": [{
"id": "OR:wt.epm.EPMDocument:102871",
"typeId": "WCTYPE|wt.epm.EPMDocument"
}]
}

What is the other way around?
Which API request(s) must be used if you know a CAD document and want to receive all the parts associated with the drawing?

many Thanks!

1 reply

12-Amethyst
June 6, 2019

@kfreydl below URL will give what you are looking for

GET <windchillserver>:<port>/Windchill/servlet/odata/CADDocumentMgmt/CADDocuments?$expand=PartAssociations($expand=RelatedParts)
kfreydl12-AmethystAuthor
12-Amethyst
June 14, 2019

Hi @amarsingh 

Thanks for the hint. This might be the solution. ".../CADDocumentMgmt/CADDocuments" is supported since REST API 1.4. We're using 1.3, so I'll check this after updating to the latest version.