Update Schedule
curl --request PATCH \
--url https://api.sandbox.wepayout.com.br/v2/automatic-pix/schedules/{id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"amount": 123
}'import requests
url = "https://api.sandbox.wepayout.com.br/v2/automatic-pix/schedules/{id}"
payload = { "amount": 123 }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({amount: 123})
};
fetch('https://api.sandbox.wepayout.com.br/v2/automatic-pix/schedules/{id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.sandbox.wepayout.com.br/v2/automatic-pix/schedules/{id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'amount' => 123
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.sandbox.wepayout.com.br/v2/automatic-pix/schedules/{id}"
payload := strings.NewReader("{\n \"amount\": 123\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.patch("https://api.sandbox.wepayout.com.br/v2/automatic-pix/schedules/{id}")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"amount\": 123\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.sandbox.wepayout.com.br/v2/automatic-pix/schedules/{id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"amount\": 123\n}"
response = http.request(request)
puts response.read_body{
"id": 1,
"merchant_id": 1,
"authorization": {
"id": 1,
"name": "Authorization Name"
},
"amount": 150.00,
"due_date": "2023-01-01",
"settlement_date": null,
"status": {
"id": 1,
"name": "PENDING"
},
"history": [
{
"id": 1,
"schedule_id": 1,
"status_id": 1,
"status_name": "PENDING",
"created_at": "2023-01-01T00:00:00Z"
}
],
"tx_id": null,
"attempts": [],
"created_at": "2023-01-01T00:00:00Z",
"buyer": {
"id": 1,
"name": "Buyer Name",
"document": "12345678900"
}
}
Schedules
Update Schedule
Update a schedule amount
PATCH
/
v2
/
automatic-pix
/
schedules
/
{id}
Update Schedule
curl --request PATCH \
--url https://api.sandbox.wepayout.com.br/v2/automatic-pix/schedules/{id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"amount": 123
}'import requests
url = "https://api.sandbox.wepayout.com.br/v2/automatic-pix/schedules/{id}"
payload = { "amount": 123 }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({amount: 123})
};
fetch('https://api.sandbox.wepayout.com.br/v2/automatic-pix/schedules/{id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.sandbox.wepayout.com.br/v2/automatic-pix/schedules/{id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'amount' => 123
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.sandbox.wepayout.com.br/v2/automatic-pix/schedules/{id}"
payload := strings.NewReader("{\n \"amount\": 123\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.patch("https://api.sandbox.wepayout.com.br/v2/automatic-pix/schedules/{id}")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"amount\": 123\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.sandbox.wepayout.com.br/v2/automatic-pix/schedules/{id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"amount\": 123\n}"
response = http.request(request)
puts response.read_body{
"id": 1,
"merchant_id": 1,
"authorization": {
"id": 1,
"name": "Authorization Name"
},
"amount": 150.00,
"due_date": "2023-01-01",
"settlement_date": null,
"status": {
"id": 1,
"name": "PENDING"
},
"history": [
{
"id": 1,
"schedule_id": 1,
"status_id": 1,
"status_name": "PENDING",
"created_at": "2023-01-01T00:00:00Z"
}
],
"tx_id": null,
"attempts": [],
"created_at": "2023-01-01T00:00:00Z",
"buyer": {
"id": 1,
"name": "Buyer Name",
"document": "12345678900"
}
}
Each schedule is tied to a specific authorization. The only field that can be updated on an existing schedule is amount. If you need to change any other detail — such as the due date or the payer — you must cancel the schedule and generate a new one.
This update applies only to the current schedule. The next billing cycle will be created with the authorization’s
minimum_authorization_amount as the default, regardless of the amount set here. To change the default for all future cycles, use the Update Authorization endpoint.The schedule can only be updated while its status is Pending. Once it moves to Sent or beyond, no further changes are possible.Path Parameters
The ID of the schedule to update.
Request Body
The new amount for the schedule. Must be greater than 0.
Response
Schedule ID
Merchant ID
Amount
Due Date
Settlement Date
Transaction ID
Creation Date
{
"id": 1,
"merchant_id": 1,
"authorization": {
"id": 1,
"name": "Authorization Name"
},
"amount": 150.00,
"due_date": "2023-01-01",
"settlement_date": null,
"status": {
"id": 1,
"name": "PENDING"
},
"history": [
{
"id": 1,
"schedule_id": 1,
"status_id": 1,
"status_name": "PENDING",
"created_at": "2023-01-01T00:00:00Z"
}
],
"tx_id": null,
"attempts": [],
"created_at": "2023-01-01T00:00:00Z",
"buyer": {
"id": 1,
"name": "Buyer Name",
"document": "12345678900"
}
}
Was this page helpful?
⌘I

