cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - Need help navigating or using the PTC Community? Contact the community team. X

Pull WT Part structure for different revision using SWAGGER API

Riz-4165786
12-Amethyst

Pull WT Part structure for different revision using SWAGGER API

I am exploring SWAGGER Rest API. I am able to pull the part structure for latest revision using 

/structure/objects/{objectId}/descendants rest call. However, I would like to pull Part structure for previous revisions as well. I have checked parameters used in this API as well. But I don't see any exact parameter where we can pass the revision number and get the part structure. 

Does anybody has an idea idea what exactly we need to pass as a parameter to get the Part Structure for previous revision(s)?

 

Thank you in advance!

 

Thanks,

Rizvan

 

 

4 REPLIES 4

It's resolved now. we just need to pass versionIdentifier eq  "version number" as queryParams

shindemayur
14-Alexandrite
(To:Riz-4165786)

Hello,

Can you help me to get latest revision of a part?

 

I tried,

$filter : "latestiteration eq '1'"

 

but it gives output as "Invalid expresion"

There is an issue with the swagger api and it's documentation. use this condition.

latestIteration eq ‘1’, but it never returns the latest Iteration, it returns all the iteration data.

 

@Riz-4165786 not exactly an answer to your swagger issue, but there is a whole set of new APIs in Windchill, which is based on OData standard.

For Your use case try below Windchill REST Services (WRS) API

POST /Windchill/servlet/odata/ProdMgmt/Parts('part_id')/PTC.ProdMgmt.GetBOM?$expand=Components($expand=Part($select=Name,Number),PartUse,Occurrences) 
CSRF_NONCE: <csrf_nonce>
Content-Type: application/json

Request body:
{
  
}

This will give you a much comprehensive data.

Announcements


Top Tags