Cancelar Payout
curl --request PATCH \
--url https://api.stage.localpayment.com/api/payout/cancel \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"externalId": "1736488554"
}
'import requests
url = "https://api.stage.localpayment.com/api/payout/cancel"
payload = { "externalId": "1736488554" }
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({externalId: '1736488554'})
};
fetch('https://api.stage.localpayment.com/api/payout/cancel', 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.stage.localpayment.com/api/payout/cancel",
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([
'externalId' => '1736488554'
]),
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.stage.localpayment.com/api/payout/cancel"
payload := strings.NewReader("{\n \"externalId\": \"1736488554\"\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.stage.localpayment.com/api/payout/cancel")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"externalId\": \"1736488554\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.stage.localpayment.com/api/payout/cancel")
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 \"externalId\": \"1736488554\"\n}"
response = http.request(request)
puts response.read_body{
"externalId": "1736488510",
"internalId": "3d36811d-1c02-41ea-a576-68df62c4603a",
"status": {
"code": "900",
"description": "Cancelled",
"detail": "The payout was cancelled"
}
}{
"detail": "Given token not valid for any token type",
"code": "token_not_valid",
"messages": [
{
"token_class": "AccessToken",
"token_type": "access",
"message": "Token is invalid or expired"
}
]
}{
"Status": 404,
"Message": "This transacion does not exists.",
"TraceId": "dae2d1cb-7e9e-48a5-8530-980f38b31712"
}PAYOUTS
Cancelar Payout
PATCH
/
api
/
payout
/
cancel
Cancelar Payout
curl --request PATCH \
--url https://api.stage.localpayment.com/api/payout/cancel \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"externalId": "1736488554"
}
'import requests
url = "https://api.stage.localpayment.com/api/payout/cancel"
payload = { "externalId": "1736488554" }
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({externalId: '1736488554'})
};
fetch('https://api.stage.localpayment.com/api/payout/cancel', 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.stage.localpayment.com/api/payout/cancel",
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([
'externalId' => '1736488554'
]),
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.stage.localpayment.com/api/payout/cancel"
payload := strings.NewReader("{\n \"externalId\": \"1736488554\"\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.stage.localpayment.com/api/payout/cancel")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"externalId\": \"1736488554\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.stage.localpayment.com/api/payout/cancel")
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 \"externalId\": \"1736488554\"\n}"
response = http.request(request)
puts response.read_body{
"externalId": "1736488510",
"internalId": "3d36811d-1c02-41ea-a576-68df62c4603a",
"status": {
"code": "900",
"description": "Cancelled",
"detail": "The payout was cancelled"
}
}{
"detail": "Given token not valid for any token type",
"code": "token_not_valid",
"messages": [
{
"token_class": "AccessToken",
"token_type": "access",
"message": "Token is invalid or expired"
}
]
}{
"Status": 404,
"Message": "This transacion does not exists.",
"TraceId": "dae2d1cb-7e9e-48a5-8530-980f38b31712"
}Cancele um Payout para impedir que os fundos sejam transferidos. Use este recurso para interromper transações criadas por engano ou que precisem de correção.
Note Você só pode cancelar Payouts com status Bloqueado ou Em espera. Para detalhes sobre as transições de status, consulte a documentação Visão geral de Payout.Este endpoint protege suas transações garantindo que os fundos não sejam enviados ao destinatário errado ou com um valor incorreto.
Autorizações
Cabeçalhos
Token de acesso Bearer para autenticação. Este token é obtido nos endpoints Obter token de acesso ou Renovar token de acesso.
Resposta
OK
Última modificação em 10 de novembro de 2026

