listScheduledOrdersByProfile
get
/ccagent/v1/scheduledOrders
List Scheduled Orders By Profile. Lists the scheduled orders corresponding to the given profileId. Optionally takes X-CCOrganization header which is a JSON field with organization ID as value.
Request
Supported Media Types
- application/json
Query Parameters
- profileId
-
Type:
string
Required:true
The customer profile id.- q
Type:string
The query string.- requireProfileDetail
Type:boolean
The flag indicating whether to fetch the profile detail.Header Parameters- X-CCOrganization
-
Type:
string
The organization Id to which the order belongs
Response
Supported Media Types- application/json
200 ResponseFollowing model is returned when operation succeeds.BodyRoot Schema : listScheduledOrdersByProfile_response- items
-
Type:
array
itemsAdditional Properties Allowed:The array of the Scheduled orders by the profile id. - limit
-
Type:
integer
The limit results of the Scheduled orders in a page. - offset
-
Type:
integer
The offset results of the Scheduled orders. - total
-
Type:
integer
The total number of the Scheduled orders. - totalResults
-
Type:
integer
The total results of the Scheduled orders.
Nested Schema : itemsNested Schema : itemsType:object
- createDate
-
Type:
string
The created date of the Scheduled order. - endDate
-
Type:
string
The end date of the Scheduled order. - Id
-
Type:
string
The Id of the Scheduled order. - lastScheduledRun
-
Type:
string
The last scheduled run of the user of the Scheduled order. - name
-
Type:
string
The name of the Scheduled order. - nextScheduledRun
-
Type:
string
The next scheduled run of the Scheduled order. - profileId
-
Type:
string
The profile Id of the user of the Scheduled order. - repositoryId
-
Type:
string
The repository Id of the user of the Scheduled order. - schedule
-
Type:
object
scheduleAdditional Properties Allowed:The schedule of the Scheduled order. - siteId
-
Type:
string
The site Id of the user of the Scheduled order. - startDate
-
Type:
string
The start date of the Scheduled order. - state
-
Type:
string
The status of the Scheduled order. - templateOrder
-
Type:
object
templateOrderAdditional Properties Allowed:The template order of the Scheduled order. - templateOrderId
-
Type:
string
The template order id Id of the user of the Scheduled order. - type
-
Type:
string
The type of the Scheduled order. - version
-
Type:
integer
The version of the Scheduled order.
Nested Schema : scheduleType:object
The schedule of the Scheduled order.- daysOfWeek
-
Type:
array
daysOfWeekAdditional Properties Allowed:The days of week of the Scheduled order. - interval
-
Type:
integer
The interval in term of number of days of the Scheduled order. - monthsInYear
-
Type:
array
monthsInYearAdditional Properties Allowed:The months in year of the Scheduled order. - occurenceInDay
-
Type:
integer
The occurence in day on the Scheduled order. - selectedDates
-
Type:
array
selectedDatesAdditional Properties Allowed:The selected dates in a month in year for the Scheduled order. - weeksInMonth
-
Type:
array
weeksInMonthAdditional Properties Allowed:The weeks in month of the Scheduled order.
Nested Schema : templateOrderType:object
The template order of the Scheduled order.- state
-
Type:
string
The state of the template order.
Nested Schema : daysOfWeekNested Schema : monthsInYearNested Schema : selectedDatesNested Schema : weeksInMonthExample application/json
{ "profileDetail":{ "lastName":"Butt", "firstName":"James", "repositoryId":"120099", "receiveEmail":"no", "shippingAddress":{ "lastName":"Butt", "firstName":"James", "country":"United States", "phoneNumber":"504-845-1427", "address2":"", "city":"New Orleans", "address1":"6649 N Blue Gum St", "postalCode":"70116", "county":"Orleans", "repositoryId":"140010", "state":"Los Angeles" }, "id":"120099", "email":"jbutt@gmail.com", "daytimeTelephoneNumber":"" }, "links":[ { "rel":"self", "href":"http://localhost:9080/ccagentui/v1/scheduledOrders?profileId=120939&requireProfileDetail=true" } ], "scheduledOrderHistory":{ "total":1, "totalResults":1, "offset":0, "limit":250, "items":[ { "lastError":null, "endDate":"2018-01-18T00:00:00.000Z", "executionStatusList":[ { "errorMessages":[ "Exception While cloning an order." ], "orderId":null, "repositoryId":"600005", "executionDate":"2016-11-23T00:00:00.000Z", "id":"600005", "orderSubmitted":false, "orderTotal":null } ], "type":"scheduledOrder", "version":1, "lastScheduledRun":null, "schedule":{ "daysInMonth":[ 1 ], "weeksInMonth":[ ], "monthsInYear":[ 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11 ], "daysOfWeek":[ ], "occurrenceInDay":1 }, "templateOrderId":"o90419", "clonedOrders":[ ], "profileId":"120939", "repositoryId":"sco30002", "name":"test 123231", "siteId":"siteUS", "nextScheduledRun":"2017-01-01T00:00:00.000Z", "state":null, "id":"sco30002", "startDate":"2016-12-01T00:00:00.000Z", "createDate":"2016-11-22T17:14:14.000Z" } ] } }
Default ResponseThe 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| |------------------|------------------| |100094|Organization passed in the header is currently inactive| |100095|The order or return request does not belong to the current organization of the shopper profile| |100096|The organization associated to the order or return request was deleted / does not exist| |100097|The organization associated to the order or return request is currently inactive| |100098|Current operation is being performed in an organization context and the shopper profile is not associated to any organization| |100099|Current operation is being performed in an organization context and the order or return request does not belong to any organization| |100101|The shopper profile does not belong to organization passed in the header|BodyRoot Schema : errorModelType:object
- devMessage
-
Type:
string
An optional non-localized message containing technical information for developers - errorCode
-
Type:
string
The numerical code identifying the error - errors
-
Type:
array
errorsAdditional Properties Allowed:An optional list of errors if multiple errors were encountered - message
-
Type:
string
The localized message describing the error - moreInfo
-
Type:
string
An optional non-localized message with more information - o:errorPath
-
Type:
string
An optional machine readable description of where the error occurred - status
-
Type:
string
The HTTP status code - type
-
Type:
string
The URI to the HTTP state code definition
Nested Schema : errorsNested Schema : itemsType:object
- devMessage
-
Type:
string
An optional non-localized message containing technical information for developers - errorCode
-
Type:
string
The numerical code identifying the error - message
-
Type:
string
The localized message describing the error - moreInfo
-
Type:
string
An optional non-localized message with more information - o:errorPath
-
Type:
string
An optional machine readable description of where the error occurred - status
-
Type:
string
The HTTP status code
Examples
Sample Response Payload returned by endpoint:
{ "profileDetail": { "lastName": "Butt", "firstName": "James", "repositoryId": "120099", "receiveEmail": "no", "shippingAddress": { "lastName": "Butt", "firstName": "James", "country": "United States", "phoneNumber": "504-845-1427", "address2": "", "city": "New Orleans", "address1": "6649 N Blue Gum St", "postalCode": "70116", "county": "Orleans", "repositoryId": "140010", "state": "Los Angeles" }, "id": "120099", "email": "jbutt@gmail.com", "daytimeTelephoneNumber": "" }, "links": [{ "rel": "self", "href": "http://localhost:9080/ccagentui/v1/scheduledOrders?profileId=120939&requireProfileDetail=true" }], "scheduledOrderHistory": { "total": 1, "totalResults": 1, "offset": 0, "limit": 250, "items": [{ "lastError": null, "endDate": "2018-01-18T00:00:00.000Z", "executionStatusList": [{ "errorMessages": ["Exception While cloning an order."], "orderId": null, "repositoryId": "600005", "executionDate": "2016-11-23T00:00:00.000Z", "id": "600005", "orderSubmitted": false, "orderTotal": null }], "type": "scheduledOrder", "version": 1, "lastScheduledRun": null, "schedule": { "daysInMonth": [1], "weeksInMonth": [], "monthsInYear": [ 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11 ], "daysOfWeek": [], "occurrenceInDay": 1 }, "templateOrderId": "o90419", "clonedOrders": [], "profileId": "120939", "repositoryId": "sco30002", "name": "test 123231", "siteId": "siteUS", "nextScheduledRun": "2017-01-01T00:00:00.000Z", "state": null, "id": "sco30002", "startDate": "2016-12-01T00:00:00.000Z", "createDate": "2016-11-22T17:14:14.000Z" }] } }