Deferred Content

The GET APIs conserve resources by returning deferred content for some objects. The deferred data is available from a URI specified in the response. Alternatively, you can request that normally deferred data is returned with the response. You can include an expand query parameter that allows you to return more information about the object.

Note: Including expand query parameters causes the request to take longer.

You can use the expand query parameter for any deferred object. For example, when you make a GET /accounts API call, the response includes several objects structured like the AccountRole object in the example below:

[
  {
    "AccountRole": {
      "__deferred": {
      "uri": "https://my328080.Helpdesk.ondemand.com/sap/c4c/odata/v1/c4codata/AccountCollection('00163E038C2E1EE299C1BB0BE9398F9B')/AccountRole"
      }
    }
  }
]

To see the entire object in the response, include the object name in the expand parameter.

For example, GET /accounts?expand=AccountRole returns the AccountRole as:

[
  {
    "AccountRole": [
      {
        "Account": {
          "__deferred": {
            "uri": "https://my328080.Helpdesk.ondemand.com/sap/c4c/odata/v1/c4codata/AccountRoleCollection('00163E038C2E1EE299C1C3CD297CCFA0')/Account"
          }
        },
        "ObjectID": "00163E038C2E1EE299C1C3CD297CCFA0",
        "ETag": "1390880972384",
        "BusinessCharacterCodeText": "Customer",
        "RoleCodeText": "Customer",
        "__metadata": {
          "etag": "W/\"datetimeoffset'2014-01-28T03%3A49%3A32.3845460Z'\"",
          "type": "c4codata.AccountRole",
          "uri": "https://my328080.Helpdesk.ondemand.com/sap/c4c/odata/v1/c4codata/AccountRoleCollection('00163E038C2E1EE299C1C3CD297CCFA0')"
        },
        "RoleCode": "Helpdesk000",
        "ParentObjectID": "00163E038C2E1EE299C1BB0BE9398F9B",
        "BusinessCharacterCode": "Helpdesk000"
      }
    ],
  }
]