Request

Response

    Beta APIs are subject to change. Please avoid using them in production environments.

    Get Hubs

    In this tutorial, you will learn how to to retrieve all the hubs that you have access to.

    By the end of this tutorial, you will be able to:

    You will use the following Query in this tutorial:

    TypeOperationDescription
    Query hubs Retrieve all the hubs that you have access to.

    Step 1 - 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 Data Exchange Explorer.

      Query

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

      Response

      {
          "data": {
              "hubs": {
                  "results": [
                      {
                          "id": "b.768cae14-76b3-4531-9030-25212dab4e48",
                          "name": "Construction Records Testing"
                      }
                  ]
              }
          }
      }
      
      Show More

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

    Once the query runs successfully, your explorer should resemble the following image.

    ../../../../_images/Getting_Started-Task-1.png