Querying for All Contacts in an Account Using Uniformresponse to Return Multiple Records
You can query for a Siebel CRM component to return its responses in an array by sending a HTTPS GET request to the resource’s URI, and by setting the uniformresponse parameter to yes.
The following request queries for all Contact records in a given
Account record from the Siebel CRM Server by using the uniformresponse parameter:
URI:
GET https://<host_name>:<port_number>/siebel/v1.0/data/Account/Account/88-26CND/Contact?fields=First Name, Last Name&childlinks=Account,Position,Organization&uniformresponse=yes
HTTP Method: GET
Content Type: application/json
Authorization: Basic
Request body: None
Here are the response details for a successful request:
HTTP Code: 200
Content Type:
- Response body:
{ "items": [ { "Id": "0CR-1MF5Z6", "First Name": "JOHN", "Last Name": "SMITH", "Link": [ { "rel": "self", "href": "https://<host_name>:<port_number>/siebel/v1.0/data/Account/Account/88-26CND/Contact/0CR-1MF5Z6", "name": "Contact" }, { "rel": "canonical", "href": "https://<host_name>:<port_number>/siebel/v1.0/data/Account/Account/88-26CND/Contact/0CR-1MF5Z6", "name": "Contact" }, { "rel": "parent", "href": "https://<host_name>:<port_number>/siebel/v1.0/data/Account/Account/88-26CND", "name": "Account" }, { "rel": "child", "href": "https://<host_name>:<port_number>/siebel/v1.0/data/Account/Account/88-26CND/Contact/0CR-1MF5Z6/Position", "name": "Position" }, { "rel": "child", "href": "https://<host_name>:<port_number>/siebel/v1.0/data/Account/Account/88-26CND/Contact/0CR-1MF5Z6/Organization", "name": "Organization" }, { "rel": "child", "href": "https://<host_name>:<port_number>/siebel/v1.0/data/Account/Account/88-26CND/Contact/0CR-1MF5Z6/Account", "name": "Account" } ] } ], "Link": [ { "rel": "self", "href": "https://<host_name>:<port_number>/siebel/v1.0/data/Account/Account/88-26CND/Contact?&uniformresponse=y&childlinks=Account,Position,Organization&fields=First Name, Last Name", "name": "Contact" } ] }
Note: The response in this example is in an array even though the array has single element. This is because the request contains the uniformresponse parameter.