getReport

get

/ccagent/v1/agentReports/{id}

Get Report. Returns the data for displaying chart with order count and order value information with the id set as 'chartOrders'.

Request

Supported Media Types
  • application/json
Path Parameters
id
Type: string
Required: true
Report Id.
Query Parameters
endDate
Type: string
Required: true
End date in ISO format for displaying the data
priceGroupId
Type: string
Required: true
PriceListGroup Id
startDate
Type: string
Required: true
Start date in ISO format for displaying the data

Response

Supported Media Types
  • application/json
200 Response
Following model is returned when operation succeeds.
Body
Root Schema : getReport_response
Nested Schema : orderCountData
Type: array
Data for orders created on each day between the start date and end date
Nested Schema : orderValueData
Type: array
Data for value of orders created on each day between the start date and end date
Nested Schema : items
Type: object
Nested Schema : items
Type: object
Example application/json

{
    "orderValueData":[
        {
            "count":0,
            "creationDate":"2015-04-26T18:30:00.000Z"
        },
        {
            "count":0,
            "creationDate":"2015-04-27T18:30:00.000Z"
        },
        {
            "count":7701.98,
            "creationDate":"2015-04-28T18:30:00.000Z"
        },
        {
            "count":0,
            "creationDate":"2015-04-29T18:30:00.000Z"
        },
        {
            "count":0,
            "creationDate":"2015-04-30T18:30:00.000Z"
        },
        {
            "count":0,
            "creationDate":"2015-05-01T18:30:00.000Z"
        },
        {
            "count":0,
            "creationDate":"2015-05-02T18:30:00.000Z"
        }
    ],
    "orderCountData":[
        {
            "count":0,
            "creationDate":"2015-04-26T18:30:00.000Z"
        },
        {
            "count":0,
            "creationDate":"2015-04-27T18:30:00.000Z"
        },
        {
            "count":8,
            "creationDate":"2015-04-28T18:30:00.000Z"
        },
        {
            "count":0,
            "creationDate":"2015-04-29T18:30:00.000Z"
        },
        {
            "count":0,
            "creationDate":"2015-04-30T18:30:00.000Z"
        },
        {
            "count":0,
            "creationDate":"2015-05-01T18:30:00.000Z"
        },
        {
            "count":0,
            "creationDate":"2015-05-02T18:30:00.000Z"
        }
    ],
    "links":[
        {
            "rel":"self",
            "href":"http://localhost:9080/ccagent/v1/agentReports/chartOrders?startDate=2015-04-26T18%3A30%3A00.000Z&endDate=2015-05-03T18%3A30%3A00.000Z"
        }
    ]
}
Default Response
The error response. The following are the internal error codes thrown by this API when the request processing fails in Oracle Commerce Cloud: |Error Code|Description| |------------------|------------------| |50001|Generic Internal Error| |200125|Blank input parameters.|
Body
Root Schema : errorModel
Type: object
Nested Schema : errors
Type: array
An optional list of errors if multiple errors were encountered
Nested Schema : items
Type: object

Examples

Sample Response Payload returned by endpoint:

{
  "orderValueData": [
    {
      "count": 0,
      "creationDate": "2015-04-26T18:30:00.000Z"
    },
    {
      "count": 0,
      "creationDate": "2015-04-27T18:30:00.000Z"
    },
    {
      "count": 7701.98,
      "creationDate": "2015-04-28T18:30:00.000Z"
    },
    {
      "count": 0,
      "creationDate": "2015-04-29T18:30:00.000Z"
    },
    {
      "count": 0,
      "creationDate": "2015-04-30T18:30:00.000Z"
    },
    {
      "count": 0,
      "creationDate": "2015-05-01T18:30:00.000Z"
    },
    {
      "count": 0,
      "creationDate": "2015-05-02T18:30:00.000Z"
    }
  ],
  "orderCountData": [
    {
      "count": 0,
      "creationDate": "2015-04-26T18:30:00.000Z"
    },
    {
      "count": 0,
      "creationDate": "2015-04-27T18:30:00.000Z"
    },
    {
      "count": 8,
      "creationDate": "2015-04-28T18:30:00.000Z"
    },
    {
      "count": 0,
      "creationDate": "2015-04-29T18:30:00.000Z"
    },
    {
      "count": 0,
      "creationDate": "2015-04-30T18:30:00.000Z"
    },
    {
      "count": 0,
      "creationDate": "2015-05-01T18:30:00.000Z"
    },
    {
      "count": 0,
      "creationDate": "2015-05-02T18:30:00.000Z"
    }
  ],
  "links": [{
    "rel": "self",
    "href": "http://localhost:9080/ccagent/v1/agentReports/chartOrders?startDate=2015-04-26T18%3A30%3A00.000Z&endDate=2015-05-03T18%3A30%3A00.000Z"
  }]
}