Resource Types

A REST resource can be a single resource or a collection resource.

Singular Resources

A singular resource represents a single entity, such as an employee or a purchase order. It has the following features:

The following table describes the properties of a link object.

Property Description

rel

Defines the relationship to the target resource. Types of links include:

  • rel="self": Identifies the link context in the response.
  • rel="canonical": Provides the preferred version of the resource URL.
  • rel="child": Provides a link to a child resource.
  • rel="parent": Provides a link back to the parent resource.

href

A URL for accessing the resource.

name

A unique identifier for the link.

destinationURL

When an Oracle CPQ action has a destination tab with a configured destination, the destination URL is returned in the JSON response. For example,"destinationURL":

"https://sitename.oracle.com/commerce/display_company_profile.jsp?action_id=17905905&document_id=4356178&bsId=18016533&versionId=15514396&destination_url="

Note: The destination URL value may change from release to release. Consequently, logic should not rely on a specific fragment of the URL.

Collection Resources

A collection resource represents a list of items, such as a list of assets or transactions. A collection resource can:

The following table describes collection resource parameters.

Parameter Description

items

An array of records in a collection. Each item or record is a singular resource.

hasMore

A Boolean value that indicates whether there are more items to be retrieved. The valid values are:True - more values to retrieveFalse - no more values to retrieve

totalResults

An integer value that specifies the total number of resource instances in the response. It includes the instances in the current response and the instances yet to be retrieved.

limit

An integer value that specifies the paging size that the server uses for a client request. The default value is 25. The server might override this value to improve application performance.

count

An integer value that specifies the number of items in the paging response. This value matches the value in theitemsparameter.

offset

An integer value that specifies the index of the first item to be returned. The default value is 0. For example:

If offset=0, the response contains all the items, starting from the first item in the collection.If offset=10 and count=20, the response contains resources from 11 to 30.

See Manage Collections to learn more about filtering, sorting, paginating, or expanding collection resources.

Related Topics

Related Topics Link IconSee Also