Request Body Objects

Overview

When query REST calls need to be more specific, Oracle CPQ can interpret several request parameters for applicable REST APIs.

Request body data must be written in JSON and adhere to standard JSON syntax rules.

ClosedJSON Syntax for Request Body Objects

Request body data is written in JSON and adhere to standard JSON syntax.The following table shows basic JSON syntax rules.

JSON Item Relation to Oracle CPQ REST Calls

:

Colons separate a name from its value in a name-value pair.

Colons must be placed between an attribute’s variable name and its value, and between an object and any values that are set within the object.

For example,

{
  "documents": {
     "_price_quantity":"74"
  }
}

{ }

Curly braces hold objects.

The entire request body input, as well as all objects, must be held by their own curly braces.

The main document {documents} and the sub-document {subDocName} are both objects.

Note: “documents” always refers to the main document, regardless of what the main document’s name is. To reference the sub-document, use “{subDocName}”, where {subDocName} is the variable name of the sub-document.

For example,

{
  "documents": {
     "_price_quantity": "74"
  }
}

[ ]

Square brackets hold arrays.

Each line item is an array, and therefore must have its value defined within square brackets.

For example,

{
   "lineItem":{
     "items": [
        {
           "_part_number": "part10",
           "_price_quantity": "1",
           "_price_book_var_name": "pb1"
        }
     ]
  }
}

,

Commas separate data.

Attribute name-value pairs must be separated by commas. Additionally, line items must be separated by commas.

For example,

{
  "lineItem": {
     "items": [
       {
           "_part_number": "part10",
           "_price_quantity": "1",
           "_price_book_var_name": "pb1"
        },
        {
           "_part_number": "part1",
           "_price_quantity": "5",
           "_price_book_var_name": "pb1"
        }
     ]
   }
}

Oracle CPQ can interpret several request parameters for applicable REST API services. Refer to the following topics for CPQ objects and parameters:

Topic Description
Copy Sequence Id Copy Sequence Id uniquely identifies a sequence associated to the copy action. A sequence informs the system which Commerce actions to perform while copying a Transaction and who should have access to the Copy action
Criteria Object This object can be used to retrieve specific and decrease the size of the response.
Destination URL Parameter This parameter contains he destination URL when an Oracle CPQ action has a destination tab with a configured destination.
Error Criteria Object This object can be used to request an error response if errors occur when opening a transaction line.

Interact Parameters (Cache Instance Id, Delta)

Interact parameters can result in less overall delay when using CPQ web services.

Line Item Grid Parameters Request attributes, objects and parameters that are specific to transaction Line Item Grids. It includes information for the following items: Item Grid Composite Attribute, Hierarchy Parameters, and Selection Parameter usage specific to transaction lines.
Partner Information Parameter This parameter supports new Transaction actions for Commerce integrations using REST services. This parameter contains the "partnerOpportunityId" and "partnerAccountId" parameters.
Revision Id Parameter Enables the server to identify the latest revision from the clients.
Selection Parameter The Selection parameter is used in the REST call request body to select specific items.
Skip Integration Parameter REST services automatically execute the integration tasks specified in the integration tab of the action definition. This parameter can be used " to disable the execution of integration tasks.
Skip Rules Parameter

This parameter can be used to optimize Commerce rules evaluation during REST API services. Customers can include the "skipRules" parameter in request body for Commerce Modify type REST API calls.

State Object This object allows filtering of state data in responses based on the query object provided for action APIs.

Related Topics

Related Topics Link IconSee Also