Request

Response

    Retrieve Hubs

    This topic provides instructions on the following:

    You will use the following operation in this topic:

    TypeOperationDescription
    Query hubs Retrieves all hubs accessible to you.

    Request a List of Hubs

    The following steps demonstrate how you can run the hubs query to retrieve a list of Hubs that you have access to.

    1. Enter the following query in the Query Pane of the Manufacturing Data Model Explorer.

      Query

      query GetHubs {
         hubs{
            pagination {
               cursor
               pageSize
            }
            results {
               id
               name
               alternativeIdentifiers{
                  dataManagementAPIHubId
               }
            }
         }
      }
      
      Show More
    2. Click Play. The response will display a list of hubs to which you have access.

      Response

      {
         "data": {
            "hubs": {
               "pagination": {
                  "cursor": null,
                  "pageSize": 2
               },
               "results": [
                  {
                     "id": "urn:adsk.ace:prod.scope:5ef7cc13-e774-461a-8124-403f58122488",
                     "name": "Ashutosh_Hub_Prd",
                     "alternativeIdentifiers": {
                        "dataManagementAPIHubId": "a.YnVzaW5lc3M6YXV0b2Rlc2s3MzIx"
                     }
                  },
                  {
                     "id": "urn:adsk.ace:prod.scope:42db5214-7dfe-431a-8275-2ea47d5686d5",
                     "name": "L2-Forge-Data-Team",
                     "alternativeIdentifiers": {
                        "dataManagementAPIHubId": "a.YnVzaW5lc3M6YXV0b2Rlc2s2MTA0"
                     }
                  }
               ]
            }
         }
      }
      
      Show More

    The hub ID is essential for querying the list of projects within a specific hub.