Update a scheduled report (or pause it with enabled: false)
PATCH
/v1/report-schedules/{schedule}
const url = 'https://api.replifier.com/v1/report-schedules/rsc_01hx0000000000000000000000';const options = { method: 'PATCH', headers: {'Content-Type': 'application/json'}, body: '{"name":"example","frequency":"daily","hour":1,"weekday":1,"dayOfMonth":1,"rangeDays":7,"recipients":["hello@example.com"],"locale":"es-MX","enabled":true}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request PATCH \ --url https://api.replifier.com/v1/report-schedules/rsc_01hx0000000000000000000000 \ --header 'Content-Type: application/json' \ --data '{ "name": "example", "frequency": "daily", "hour": 1, "weekday": 1, "dayOfMonth": 1, "rangeDays": 7, "recipients": [ "hello@example.com" ], "locale": "es-MX", "enabled": true }'Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”schedule
required
string
Example
rsc_01hx0000000000000000000000Request Bodyrequired
Section titled “Request Bodyrequired”Media typeapplication/json
object
name
string
frequency
string
hour
Brand local hour (in its time zone)
integer
weekday
1 = Monday … 7 = Sunday; required only if weekly
integer
dayOfMonth
Required only if monthly
integer
recipients
Emails of active organization members
Array<string>
locale
string
enabled
boolean
Responses
Section titled “Responses”Schedule
Media typeapplication/json
object
id
required
string
brandId
required
string
name
required
string
frequency
required
string
hour
required
number
weekday
required
number
dayOfMonth
required
number
rangeDays
required
number
recipients
required
Array<string>
locale
required
string
enabled
required
boolean
nextRunAt
required
string
lastRunAt
required
string
lastStatus
required
string
createdBy
required
string
createdAt
required
string
updatedAt
required
string
Example
{ "lastStatus": "sent"}Invalid data
Media typeapplication/json
object
error
required
object
code
required
string
message
required
string
cause
required
string
fix
required
string
requestId
required
string
Example
{ "error": { "code": "not_found" }}No session, expired session, or invalid, expired or revoked API key
Media typeapplication/json
object
error
required
object
code
required
string
message
required
string
cause
required
string
fix
required
string
requestId
required
string
Example
{ "error": { "code": "not_found" }}Not allowed, API key missing the scope, IP not allowed, or request rejected (csrf_rejected)
Media typeapplication/json
object
error
required
object
code
required
string
message
required
string
cause
required
string
fix
required
string
requestId
required
string
Example
{ "error": { "code": "not_found" }}Does not exist or is not visible to you
Media typeapplication/json
object
error
required
object
code
required
string
message
required
string
cause
required
string
fix
required
string
requestId
required
string
Example
{ "error": { "code": "not_found" }}Internal error
Media typeapplication/json
object
error
required
object
code
required
string
message
required
string
cause
required
string
fix
required
string
requestId
required
string
Example
{ "error": { "code": "not_found" }}