Skip to main content
PUT
Update task schedule by ID

Authorizations

Authorization
string
header
required

Use a valid Bearer token to authenticate.

Path Parameters

scheduleId
string
required

Unique identifier for the task schedule that generated by system. Example: 6352736c628401059b37a2e2

Body

application/json
hubId
string
required

Fundamental entity within an organization, serving as the central point for managing various operational components. Use GET /hubs endpoint to get the list of Hub IDs. Example: 634e98498ce07d29474a7e29

name
string
required

The name of task schedule. User can define task schedule name with task's flow name combined with running time, or something else. Example: Daily Morning Visit

periode
string
required

There are 5 types of periode: daily, weekly, monthly, byDate, custom. Period of time when the task scheduler running. Example: daily

flow
string
required

The unique name of organization's flow. Use Flow /flows API to get the list of flow names. Example: Visit

flowId
string
required

The Identifier of organization's flow. Use Flow /flows API to get the list of flow ids. Example: 67be687c128306111e022022

startTime
string
required

Start date of task scheduler to active. this field only available when periode's value is one of: daily, weekly, monthly Example: 2022-11-02

endTime
string
required

End date of task scheduler to active. this field only available when periode's value is one of: daily, weekly, monthly Example: 2022-11-05

task
object
required

data of task according to selected flow. Example: { 'receiverName':'miguel', 'coordinates':'-6.230815251,106.75684387', 'address':'rawamangun jakarta timur' }

schedules
object[]
required

Object with format according to value of periode. Configuration for the time of task scheduler will run. Example for periode of daily: [{ 'time':['07:00'] }] Example for periode of weekly: [{ 'day':'sunday', 'time':['07:00'] }] Example for periode of monthly: [{ 'date':'1', 'time':['07:00'] }] Example for periode of byDate: [{ 'date':'2022-11-03', 'time':['07:00'] }]

interval
integer | null

Number units of frequency between each scheduled execution. For example, an interval of 2 with a frequency of daily means the task will run every 2 days. This required when select the custom periode. Example: daily

Required range: 1 <= x <= 99
frequency
enum<string> | null

Specified unit of time for the scheduling interval. Determines how often the scheduled task will run based on the interval value.This required when select the custom periode. Example: daily

Available options:
daily,
weekly,
monthly

Response

Success

status
boolean

Status of response.

message
string

Message of API response.

data
object

Detail of object task schedule.