Jinmin
Jinmin

Reputation: 1

The ProjectGuid and ModelGuid is not shown in the return from API

I am trying to obtain the ProjectGuid and ModelGuid to open the cloud model. I followed this link and used the projects/:project_id/items/:item_id/versions. However the return doesn't give me the modelGuid and projectGuid. See the below snip: enter image description here

And the example in this documentation also doesn't have the Guid returned.

Any suggestion will be appreciated?

I want get the projectGuid and modelGuid of the model in ACC/BIM360

Upvotes: 0

Views: 55

Answers (1)

Carol Gitonga
Carol Gitonga

Reputation: 97

For you to obtain the projectGuid and modelGuid of the model in ACC/BIM360 you are required to have uploaded your model in cloud through Revit Cloud Worksharing service which is C4R model/Autodesk Collaboration for Revit.

In this case, we can call APS Data Management API : https://aps.autodesk.com/en/docs/data/v2/reference/http/projects-project_id-versions-version_id-GET/ to obtain the projectGuid and modelGuid in the model's version tip like below.

{  
   "type":"versions",
   "id":"urn:adsk.wipprod:fs.file:vf.abcd1234?version=1",
   "attributes":{  
      "name":"fileName.rvt",
      "displayName":"fileName.rvt",
      ...
      "mimeType":"application/vnd.autodesk.r360",
      "storageSize":123456,
      "fileType":"rvt",
      "extension":{  
         "type":"versions:autodesk.bim360:C4RModel",
         ....
         "data":{  
            ...
            "projectGuid":"4157a149-21ea-4d56-a801-85a6d634cd85",
            ....
            "modelGuid":"4c0b9398-a907-4bd2-b616-458ba885f343",
            ....
         }
      }
   },
   ....
}

Keep note of the the element .attributes.extension.type it should be: "type": "versions:autodesk.bim360:C4RModel"

Upvotes: 0

Related Questions