POST
/scheduleCreate Schedule
This endpoint allows you to create custom schedules to retrieve rate data for shops on specific date and time.
POST
/scheduleNote
All schedules are queued at the fifty-fifth minute of the previous hour. Shops scheduled within the current hour run the next day.
Important Notes
Parameters :
- scheduleName: Specifies the name of the schedule.
- shopId: Specifies the shop ID to be scheduled.
- year: Specifies the years for scheduling.
- "*" - No specific year
- "2016" - Only in 2016
- "2016,2017" - In 2016 and 2017
- month: Specifies the months for scheduling.
- "*" - All 12 months
- "1" - January
- "2" - February
- "3" - March
- "1,3" - January and March
- dayOfWeek: Specifies the days of the week.
- "*" - All days
- "0" - Sunday
- "1" - Monday
- "1,3,5" - Monday, Wednesday, Friday
- day: Specifies the days of the month.
- "*" - All days
- "1-31" - Specific days or ranges
- hour: Specifies the hour of the day (0-23) when the shop is triggered.
- "*" - Run hourly
- minute: Specifies the minute (0-59) within the hour when the shop is triggered.
- startDate: Specifies when the schedule should start.
- endDate: Specifies when the schedule should end.
Parameter Details
| Name | In | Type | Required | Description |
|---|---|---|---|---|
» scheduleName | body | string | Required | Specifies the name of the schedule. |
» shopId | body | number | Required | Specifies the shop ID to be scheduled. |
» year | body | string | Required | Specifies the years for scheduling. |
» month | body | string | Required | Specifies the months for scheduling. |
» dayOfWeek | body | string | Optional | Specifies the days of the week. |
» day | body | string | Required | Specifies the days of the month. |
» hour | body | string | Required | Specifies the hour of the day (0-23) when the shop is triggered. |
» minute | body | string | Required | Specifies the minute (0-59) within the hour when the shop is triggered. |
» startDate | body | string(date) | Required | Specifies when the schedule should start. |
» endDate | body | string(date) | Required | Specifies when the schedule should end. |
Responses
| Status | Meaning | Description | Schema |
|---|---|---|---|
| 201 | OK | Schedule created successfully | |
| 400 | Bad Request | Bad Request | None |
| 401 | Unauthorized | Authentication Failed or Account validity Expired | None |
| 429 | Too Many Requests | Too Many Requests | None |
| 500 | Internal Server Error | Internal Server Error | None |
Example Request
# You can also use wget
curl -X POST /schedule \
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer {access-token}'Body parameter
{
"scheduleName": "Sample Schedule",
"shopId": 1,
"year": "*",
"month": "1,2,12",
"dayOfWeek": "*",
"day": "1,15",
"hour": "0,12",
"minute": "0",
"startDate": "2019-08-24",
"endDate": "2019-08-24"
}Example responses
201 Response
{
"message": "Schedule Created Successfully",
"scheduleId": 123
}Need Support?
Our team is here to help you integrate and make the most of our APIs. Get in touch for technical support, custom solutions, or any questions.