AI resources
Enable automatic generation

Creates a daily, weekly, or monthly schedule to automatically generate Other Operations reports from an existing configuration, identified by its structure_id. In case of success, the request returns a response with status 201.

POST

https://api.mercadopago.com/v1/reporting/operations/{reportId}/schedule
Request parameters
Header
Authorization
string

REQUIRED

Access Token obtained through the developer panel. Must be sent in all requests.
Path
reportId
string

REQUIRED

Other Operations report type.
activities_collection: Collection report.
activities_after_collection: Post-collection report.
activities_withdraw: Withdrawal report.
Body
type
string

REQUIRED

Schedule configuration type. The only possible value is frequency.
frequency: Generates the report according to the frequency configured in `data`.
data
object

REQUIRED

Data that defines how often and at what time the report is generated.
structure_id
string

REQUIRED

UUID of the report configuration for which the schedule will be created.
notifiers
array
List of notifier UUIDs sent with the schedule request. Obtain these identifiers from the report configuration.
Response parameters
id
string
Unique identifier of the created schedule.
status
string
Current status of the schedule.
active: The schedule is active and will generate reports according to the configured frequency.
type
string
Schedule configuration type.
frequency: The report is generated according to the configured frequency.
data
object
Frequency settings of the created schedule.
Errors

400Invalid schedule fields.

validation_error

One or more schedule fields are invalid. Use frequency as type, set period to daily, weekly, or monthly, provide an hour from 0 to 23, and send a valid structure_id. Then submit the request again.

404Configuration not found.

configuration_not_found

No configuration matches the specified reportId and structure_id. Retrieve the active configuration and verify its identifier, or create a configuration before scheduling the report.

409An active schedule already exists.

schedule_already_exists

An active schedule already exists for the report configuration. Keep the existing schedule, or disable automatic generation before creating a new one.

Request
curl -X POST \
    'https://api.mercadopago.com/v1/reporting/operations/{reportId}/schedule'\
    -H 'Content-Type: application/json' \
       -H 'Authorization: Bearer APP_USR-4*********782856-12*********f202ca494*********f0baa4bb3*********648' \
    -d '{
  "type": "frequency",
  "data": {
    "hour": 0,
    "value": 1
  }
}'
Response
{
  "id": "bd6d0d3c-7303-476b-a25a-4090036dcee8",
  "data": {
    "hour": 6,
    "value": 1
  }
}