Sincronizar cobrança
curl --request POST \
--url https://api.mingopay.com.br/v1/payment-intents/{id}/synchronize \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.mingopay.com.br/v1/payment-intents/{id}/synchronize"
headers = {"Authorization": "Bearer <token>"}
response = requests.post(url, headers=headers)
print(response.text)const options = {method: 'POST', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.mingopay.com.br/v1/payment-intents/{id}/synchronize', 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.mingopay.com.br/v1/payment-intents/{id}/synchronize",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.mingopay.com.br/v1/payment-intents/{id}/synchronize"
req, _ := http.NewRequest("POST", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.mingopay.com.br/v1/payment-intents/{id}/synchronize")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.mingopay.com.br/v1/payment-intents/{id}/synchronize")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"organizationId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"amountCents": 123,
"feeCents": 123,
"netCents": 123,
"currency": "BRL",
"method": "pix",
"status": "created",
"metadata": {},
"createdAt": "2023-11-07T05:31:56Z",
"updatedAt": "2023-11-07T05:31:56Z",
"environment": "sandbox",
"providerFeeCents": 123,
"platformFeeCents": 123,
"commissionCents": 1,
"mingoFeeCents": 1,
"customerId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"externalReference": "<string>",
"provider": "<string>",
"providerReference": "<string>",
"description": "<string>",
"expiresAt": "2023-11-07T05:31:56Z",
"paidAt": "2023-11-07T05:31:56Z",
"subaccountId": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
}{
"error": "<string>",
"message": "<string>",
"requestId": "<string>",
"details": [
{
"path": "<string>",
"message": "<string>"
}
]
}{
"error": "<string>",
"message": "<string>",
"requestId": "<string>",
"details": [
{
"path": "<string>",
"message": "<string>"
}
]
}{
"error": "<string>",
"message": "<string>",
"requestId": "<string>",
"details": [
{
"path": "<string>",
"message": "<string>"
}
]
}{
"error": "<string>",
"message": "<string>",
"requestId": "<string>",
"details": [
{
"path": "<string>",
"message": "<string>"
}
]
}{
"error": "<string>",
"message": "<string>",
"requestId": "<string>",
"details": [
{
"path": "<string>",
"message": "<string>"
}
]
}{
"error": "<string>",
"message": "<string>",
"requestId": "<string>",
"details": [
{
"path": "<string>",
"message": "<string>"
}
]
}{
"error": "<string>",
"message": "<string>",
"requestId": "<string>",
"details": [
{
"path": "<string>",
"message": "<string>"
}
]
}Sincronizar cobrança
Consulta o provedor e aplica o estado atual. Use para reconciliação; webhooks permanecem o fluxo principal. Exige payment_intents:read.
POST
/
v1
/
payment-intents
/
{id}
/
synchronize
Sincronizar cobrança
curl --request POST \
--url https://api.mingopay.com.br/v1/payment-intents/{id}/synchronize \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.mingopay.com.br/v1/payment-intents/{id}/synchronize"
headers = {"Authorization": "Bearer <token>"}
response = requests.post(url, headers=headers)
print(response.text)const options = {method: 'POST', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.mingopay.com.br/v1/payment-intents/{id}/synchronize', 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.mingopay.com.br/v1/payment-intents/{id}/synchronize",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.mingopay.com.br/v1/payment-intents/{id}/synchronize"
req, _ := http.NewRequest("POST", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.mingopay.com.br/v1/payment-intents/{id}/synchronize")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.mingopay.com.br/v1/payment-intents/{id}/synchronize")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"organizationId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"amountCents": 123,
"feeCents": 123,
"netCents": 123,
"currency": "BRL",
"method": "pix",
"status": "created",
"metadata": {},
"createdAt": "2023-11-07T05:31:56Z",
"updatedAt": "2023-11-07T05:31:56Z",
"environment": "sandbox",
"providerFeeCents": 123,
"platformFeeCents": 123,
"commissionCents": 1,
"mingoFeeCents": 1,
"customerId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"externalReference": "<string>",
"provider": "<string>",
"providerReference": "<string>",
"description": "<string>",
"expiresAt": "2023-11-07T05:31:56Z",
"paidAt": "2023-11-07T05:31:56Z",
"subaccountId": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
}{
"error": "<string>",
"message": "<string>",
"requestId": "<string>",
"details": [
{
"path": "<string>",
"message": "<string>"
}
]
}{
"error": "<string>",
"message": "<string>",
"requestId": "<string>",
"details": [
{
"path": "<string>",
"message": "<string>"
}
]
}{
"error": "<string>",
"message": "<string>",
"requestId": "<string>",
"details": [
{
"path": "<string>",
"message": "<string>"
}
]
}{
"error": "<string>",
"message": "<string>",
"requestId": "<string>",
"details": [
{
"path": "<string>",
"message": "<string>"
}
]
}{
"error": "<string>",
"message": "<string>",
"requestId": "<string>",
"details": [
{
"path": "<string>",
"message": "<string>"
}
]
}{
"error": "<string>",
"message": "<string>",
"requestId": "<string>",
"details": [
{
"path": "<string>",
"message": "<string>"
}
]
}{
"error": "<string>",
"message": "<string>",
"requestId": "<string>",
"details": [
{
"path": "<string>",
"message": "<string>"
}
]
}Autorizações
Resposta
Cobrança sincronizada.
