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

Community Tip - Learn all about PTC Community Badges. Engage with PTC and see how many you can earn! X

Create A Part to Document Relationship using the REST API

beeler
3-Newcomer

Create A Part to Document Relationship using the REST API

I would like to create a WTPartReferenceLink between a part I have created in '/Windchill/servlet/odata/ProdMgmt/Parts' and a document I have created in '/Windchill/servlet/odata/DocMgmt/Documents'.

However, When I POST '/Windchill/servlet/odata/ProdMgmt/Parts('OR:wt.part.WTPart:###')/References', I receive a 501, OPERATION_NOT_SUPPORTED.

How can I create this reference link using the REST API? I was unable to find the instructions in the 'Windchill REST Services User’s Guide'.

 

Thanks!

8 REPLIES 8

Hello,

 

I don't if you have found a answer, but just ask PTC and currently it's not possible to create reference neither described link using the REST API between WtPart and WtDocument. (We are in Windchill 11.1 M20)

 

Have you found another way to do that? 

We also have this need.

Thank you

 

Regards,

Thierry

CM_10339207
5-Regular Member
(To:tchampier)

We also have the same need, it's been two years since this question already and we cannot find anything related. If you found an answer back in the days please consider to share it !

CM_10339207
5-Regular Member
(To:Marco_Tosin)

Hello @Marco_Tosin. I just did, but there's nothing there. Just this:

CM_10339207_0-1658941183836.png

I think this might be a configuration problem? Maybe a bad update? The best solution I've found is to browse this URL /Windchill/netmarkets/html/wrs/odata-to-swagger.jsp?v=2&d=ClfStructure and change d depending on what I need. The result looks like this: 

CM_10339207_1-1658941323415.png

 

Do you have any other advice ? Thanks in advance. 

 

The link I pointed you to is free also for those who do not have SW under maintenance, and I just got there from three different browsers.
The image I had attached was captured from that very link.
The other way to access the documentation is from the Windchill interface and is also described in the image I had attached (read below text)

 

1. To display the Customization icon on the Browse tab, in the Preference Management utility, set Client Customization to Yes.
2. In the Browse tab, click the Customization icon. The Customization page opens.
3. Click Documentation.
4. Under the API menu, click OData REST APIs. The Windchill REST Services catalog opens.
 
 
Marco

Hello,

 

We are still not resolved our issue.

In the current REST API (we are with Windchill 12.0.2.4), there's still no API to create/update a link between a WTPart and a WTDocument.

 

Do you know if this functionality will be available in a near future? 

Do you know another way to do it?

 

Thank you for your feedback.

 

Regards,

Thierry

HelesicPetr
22-Sapphire I
(To:tchampier)

Hello @tchampier 

If you can not find the API you need try to create it.

 

In the guide there are hints how to do so.

 

https://www.ptc.com/en/support/article/CS183488

 

One our customer creates many own rest apis for own integration.

Thank you for your feedback. I will check that, even if I'm not sure that I will be able to create a new custom API by myself 🙂

 

Have a nice day.

Thierry

Announcements


Top Tags