GET /api/v1/profile/{dataModelName}/{Id}/calculated-insights/{ci-name}
Returns data model objects and a computed view based on indexes and search filters.
Syntax
- HTTP method
- GET
- Availability
- Customer 360 Audiences v1.0, Salesforce v51.0
- Formats
- REST
- URI
- /api/v1/profile/{dataModelName}/{Id}/calculated-insights/{ci-name}
Request Parameters
| Field Name | Field Type | Description |
|---|---|---|
| dataModelName | string | Required. Data model object API name. Example: UnifiedIndividual__dlm |
| id | string | Required. The value of an indexed column. Example: 003726a3-061d-33e7-a5a5-96ecae866a61 |
| ci_name | string | Required. The calculated insight name. Example: IndividualChildrenCount__cio |
| searchKey | string | Index name if object's ID is different from primary key. Example: FirstName__c |
| dimensions | string | Comma separated name of the dimensions to be part of result from the computed view. By default includes all the dimensions. Example: Id__c |
| measures | string | Comma separated name of the measures to be part of result from the computed view. By default includes all the measures. Example: TotalSales__c |
| limit | int | The numbers of items to return. Example: 10 |
| filters | string | Filters are applied only on the parent object. Example: [FirstName__c=Angel] |
Examples
- Request
-
1http://{TSE}.360a.salesforce.com/api/v1/profile/{dataModelName}/{Id}/calculated-insights/{ci-name} - Response
-
1{ 2 "data": [ 3 { 4 "GenderId__c": "Male", 5 "DataSourceId__c": "Customers", 6 "Sales_And_Discounts_By_Customer__cio": { 7 "TotalDiscounts__c": "0.600000000000000100", 8 "Id__c": "233280554", 9 "Product": "Multi grain bread" 10 }, 11 "MaritalStatusId__c": "Widowed", 12 "LastName__c": "Kathman", 13 "ChildrenCount__c": "1", 14 "Id__c": "233280554", 15 "BirthDate__c": "1962-08-08T00:00:00", 16 "DataSourceObjectId__c": "Individual_Id", 17 "InternalOrganizationId__c": "", 18 "FirstName__c": "Angel" 19 }, 20 { 21 "GenderId__c": "Male", 22 "DataSourceId__c": "Customers", 23 "Sales_And_Discounts_By_Customer__cio": { 24 "TotalDiscounts__c": "0.600000000000000100", 25 "Id__c": "233280554", 26 "Product": "Yogurt" 27 }, 28 "MaritalStatusId__c": "Widowed", 29 "LastName__c": "Kathman", 30 "ChildrenCount__c": "1", 31 "Id__c": "233280554", 32 "BirthDate__c": "1962-08-08T00:00:00", 33 "DataSourceObjectId__c": "Individual_Id", 34 "InternalOrganizationId__c": "", 35 "FirstName__c": "Angel" 36 } 37 ] 38}
HTTP Responses
| Response | Reason |
|---|---|
| 200 OK | Callback successfully verified |
| 400 Bad Request | Invalid request |
| 403 Forbidden | Failed to pass authorization. |
| 404 Not Found | Incorrect callback ID, verification key, or both. |
| 422 Unprocessable Entity | Attribute name used in fields/filter parameter does not exist. |
| 500 Server Error | Internal error |