PLM 360 General Discussion

Active Contributor
Posts: 37
Registered: ‎04-28-2008
Message 1 of 5 (282 Views)
Accepted Solution

REST response question

282 Views, 4 Replies
11-05-2012 05:13 PM

I'm working my way through what the REST API can provide and I have a question about record relationships.  Here's a sample of the XML data returned for an object that has some children on its BOM:




From the above I can determine that this record has no parents (no value in the Value element for REL_INV_BOM.  I can also determine that it has 4 children, and I can determine what each of those children might be - including their version, release, and state name.  What I don't see there is Quantity information for each child.


It also appears that the only tabs for which any information is provided are the Item Details, BOM, and Where Used tabs.  This means no access to Grid, Workflow, Attachments, Milestones, Project Management, Relationships, etc. 


Is that the case, or am I missing something?  If that's all that is currently available, are there plans to expose more information in the future?


Product Support
Posts: 279
Registered: ‎03-27-2012
Message 2 of 5 (273 Views)

Re: REST response question

11-06-2012 12:54 PM in reply to: ForrestJudd



Correct, and yes we will be expanding on what is available by REST in the future


As for what you can do with REST, I suggest looking into the developers section in the wikihelp:


Joe Piggee
Support Specialist
Product Support
Autodesk, Inc.

Active Contributor
Posts: 37
Registered: ‎04-28-2008
Message 3 of 5 (269 Views)

Re: REST response question

11-06-2012 01:25 PM in reply to: piggeej

Thanks Joe, very helpful as always.  I do have one more question.  Is it in any way possible to make web requests from a script?  I really need to get at BOM information for records, but that tab is currently unavailable using the existing scripting API.  However, if I can make a web request from a script, I can use REST to get the BOM information for the record in question.


I tried using XMLHttpRequest, but that functionality doesn't appear to be available in scripting.  Although now that I think about it, the short run time cap for scripts might make that method nonviable anyway.

Posts: 70
Registered: ‎11-04-2011
Message 4 of 5 (255 Views)

Re: REST response question

11-07-2012 02:00 PM in reply to: ForrestJudd



For BOM relationship information, we have a "boms" end point in the existing REST API:  /api/rest/v1/workspaces/<wsid>/items/<dmsid>/boms


This will provide you with the BOM information you seek :smileyhappy:


As for the XMLHttpRequest from script, I'd like to chat with you a bit to understand how you would use this feature.  BTW, this would be a great one to add to the IdeaStation!




Jared Sund
Sr. Product Line Manager, Product Lifecycle Management
Autodesk, Inc.
Active Contributor
Posts: 37
Registered: ‎04-28-2008
Message 5 of 5 (252 Views)

Re: REST response question

11-07-2012 02:13 PM in reply to: jared.sund



Thanks for that!  Are there any other endpoints that are not documented on the wikihelp?  The only features documented on the wikihelp are authorization (login, logout, and get user information), GET for workspaces, and GET for item information.  There is also no documentation for any POST or PUT for item information update, assuming those calls even exist.


My immediate need for HttpWebRequest from a script would be to make a call to the REST API to get access to Item BOM information.  It's my understanding that the built-in scripting doesn't have access to Item BOM information.  If I could make a web request, though, I could get that BOM information using REST and use that in my script instead.


The basic gist of what I want to do is take an item specified by a user and 'explode' its BOM out onto a grid.  Each grid row would have one of the children and the child's quantity, and that quantity would be modified by the quantity of the parent.


The way it stands now, users will have to review the Item's BOM on a different browser tab (or in a different window) and manually add each line item to the grid with the appropriate quantity.  This could be tedious for larger assesmblies, and the process is open to mistakes in both item and quantity specification.

You are not logged in.

Log into access your profile, ask and answer questions, share ideas and more. Haven't signed up yet? Register

Are you familiar with the Autodesk Expert Elites? The Expert Elite program is made up of customers that help other customers by sharing knowledge and exemplifying an engaging style of collaboration. To learn more, please visit our Expert Elite website.

Ask the Community