Create Charge (Bank Slip)
curl --request POST \
--url https://api.sandbox.wepayout.com.br/v2/payin/payments \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"merchant_id": 123,
"invoice": "<string>",
"notification_url": "<string>",
"payment_method": "<string>",
"amount": 123,
"currency": "<string>",
"country": "<string>",
"description": "<string>",
"buyer": {
"name": "<string>",
"email": "<string>",
"document": {
"type": "<string>",
"number": "<string>"
},
"address": {
"street": "<string>",
"number": "<string>",
"zipcode": "<string>",
"city": "<string>",
"district": "<string>",
"state_code": "<string>"
}
},
"originator_legal_entity": {},
"boleto": {
"expire_date": "<string>"
}
}
'import requests
url = "https://api.sandbox.wepayout.com.br/v2/payin/payments"
payload = {
"merchant_id": 123,
"invoice": "<string>",
"notification_url": "<string>",
"payment_method": "<string>",
"amount": 123,
"currency": "<string>",
"country": "<string>",
"description": "<string>",
"buyer": {
"name": "<string>",
"email": "<string>",
"document": {
"type": "<string>",
"number": "<string>"
},
"address": {
"street": "<string>",
"number": "<string>",
"zipcode": "<string>",
"city": "<string>",
"district": "<string>",
"state_code": "<string>"
}
},
"originator_legal_entity": {},
"boleto": { "expire_date": "<string>" }
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
merchant_id: 123,
invoice: '<string>',
notification_url: '<string>',
payment_method: '<string>',
amount: 123,
currency: '<string>',
country: '<string>',
description: '<string>',
buyer: {
name: '<string>',
email: '<string>',
document: {type: '<string>', number: '<string>'},
address: {
street: '<string>',
number: '<string>',
zipcode: '<string>',
city: '<string>',
district: '<string>',
state_code: '<string>'
}
},
originator_legal_entity: {},
boleto: {expire_date: '<string>'}
})
};
fetch('https://api.sandbox.wepayout.com.br/v2/payin/payments', 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/payin/payments",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'merchant_id' => 123,
'invoice' => '<string>',
'notification_url' => '<string>',
'payment_method' => '<string>',
'amount' => 123,
'currency' => '<string>',
'country' => '<string>',
'description' => '<string>',
'buyer' => [
'name' => '<string>',
'email' => '<string>',
'document' => [
'type' => '<string>',
'number' => '<string>'
],
'address' => [
'street' => '<string>',
'number' => '<string>',
'zipcode' => '<string>',
'city' => '<string>',
'district' => '<string>',
'state_code' => '<string>'
]
],
'originator_legal_entity' => [
],
'boleto' => [
'expire_date' => '<string>'
]
]),
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/payin/payments"
payload := strings.NewReader("{\n \"merchant_id\": 123,\n \"invoice\": \"<string>\",\n \"notification_url\": \"<string>\",\n \"payment_method\": \"<string>\",\n \"amount\": 123,\n \"currency\": \"<string>\",\n \"country\": \"<string>\",\n \"description\": \"<string>\",\n \"buyer\": {\n \"name\": \"<string>\",\n \"email\": \"<string>\",\n \"document\": {\n \"type\": \"<string>\",\n \"number\": \"<string>\"\n },\n \"address\": {\n \"street\": \"<string>\",\n \"number\": \"<string>\",\n \"zipcode\": \"<string>\",\n \"city\": \"<string>\",\n \"district\": \"<string>\",\n \"state_code\": \"<string>\"\n }\n },\n \"originator_legal_entity\": {},\n \"boleto\": {\n \"expire_date\": \"<string>\"\n }\n}")
req, _ := http.NewRequest("POST", 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.post("https://api.sandbox.wepayout.com.br/v2/payin/payments")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"merchant_id\": 123,\n \"invoice\": \"<string>\",\n \"notification_url\": \"<string>\",\n \"payment_method\": \"<string>\",\n \"amount\": 123,\n \"currency\": \"<string>\",\n \"country\": \"<string>\",\n \"description\": \"<string>\",\n \"buyer\": {\n \"name\": \"<string>\",\n \"email\": \"<string>\",\n \"document\": {\n \"type\": \"<string>\",\n \"number\": \"<string>\"\n },\n \"address\": {\n \"street\": \"<string>\",\n \"number\": \"<string>\",\n \"zipcode\": \"<string>\",\n \"city\": \"<string>\",\n \"district\": \"<string>\",\n \"state_code\": \"<string>\"\n }\n },\n \"originator_legal_entity\": {},\n \"boleto\": {\n \"expire_date\": \"<string>\"\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.sandbox.wepayout.com.br/v2/payin/payments")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"merchant_id\": 123,\n \"invoice\": \"<string>\",\n \"notification_url\": \"<string>\",\n \"payment_method\": \"<string>\",\n \"amount\": 123,\n \"currency\": \"<string>\",\n \"country\": \"<string>\",\n \"description\": \"<string>\",\n \"buyer\": {\n \"name\": \"<string>\",\n \"email\": \"<string>\",\n \"document\": {\n \"type\": \"<string>\",\n \"number\": \"<string>\"\n },\n \"address\": {\n \"street\": \"<string>\",\n \"number\": \"<string>\",\n \"zipcode\": \"<string>\",\n \"city\": \"<string>\",\n \"district\": \"<string>\",\n \"state_code\": \"<string>\"\n }\n },\n \"originator_legal_entity\": {},\n \"boleto\": {\n \"expire_date\": \"<string>\"\n }\n}"
response = http.request(request)
puts response.read_body{
"id": 123,
"merchant": {
"id": 123,
"name": "<string>"
},
"hash": "<string>",
"payment_page": "<string>",
"our_number": "<string>",
"invoice": "<string>",
"notification_url": "<string>",
"payment_method": "<string>",
"amount": 123,
"paid_amount": 123,
"refunded_amount": 123,
"currency": {
"id": 123,
"name": "<string>",
"code": "<string>",
"symbol": "<string>"
},
"description": "<string>",
"buyer": {},
"originator_legal_entity": {},
"boleto": {
"expire_date": "<string>",
"digitable_line": "<string>",
"bar_code_number": "<string>",
"agreement": {},
"fine": {},
"discount": {}
},
"status": {
"id": 123,
"name": "<string>"
},
"status_history": [
{}
],
"substatus": {},
"refunds": [
{}
],
"created_at": "<string>",
"updated_at": "<string>"
}Bank Slip
Create Charge (Bank Slip)
Generate a new Boleto payment request
POST
/
v2
/
payin
/
payments
Create Charge (Bank Slip)
curl --request POST \
--url https://api.sandbox.wepayout.com.br/v2/payin/payments \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"merchant_id": 123,
"invoice": "<string>",
"notification_url": "<string>",
"payment_method": "<string>",
"amount": 123,
"currency": "<string>",
"country": "<string>",
"description": "<string>",
"buyer": {
"name": "<string>",
"email": "<string>",
"document": {
"type": "<string>",
"number": "<string>"
},
"address": {
"street": "<string>",
"number": "<string>",
"zipcode": "<string>",
"city": "<string>",
"district": "<string>",
"state_code": "<string>"
}
},
"originator_legal_entity": {},
"boleto": {
"expire_date": "<string>"
}
}
'import requests
url = "https://api.sandbox.wepayout.com.br/v2/payin/payments"
payload = {
"merchant_id": 123,
"invoice": "<string>",
"notification_url": "<string>",
"payment_method": "<string>",
"amount": 123,
"currency": "<string>",
"country": "<string>",
"description": "<string>",
"buyer": {
"name": "<string>",
"email": "<string>",
"document": {
"type": "<string>",
"number": "<string>"
},
"address": {
"street": "<string>",
"number": "<string>",
"zipcode": "<string>",
"city": "<string>",
"district": "<string>",
"state_code": "<string>"
}
},
"originator_legal_entity": {},
"boleto": { "expire_date": "<string>" }
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
merchant_id: 123,
invoice: '<string>',
notification_url: '<string>',
payment_method: '<string>',
amount: 123,
currency: '<string>',
country: '<string>',
description: '<string>',
buyer: {
name: '<string>',
email: '<string>',
document: {type: '<string>', number: '<string>'},
address: {
street: '<string>',
number: '<string>',
zipcode: '<string>',
city: '<string>',
district: '<string>',
state_code: '<string>'
}
},
originator_legal_entity: {},
boleto: {expire_date: '<string>'}
})
};
fetch('https://api.sandbox.wepayout.com.br/v2/payin/payments', 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/payin/payments",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'merchant_id' => 123,
'invoice' => '<string>',
'notification_url' => '<string>',
'payment_method' => '<string>',
'amount' => 123,
'currency' => '<string>',
'country' => '<string>',
'description' => '<string>',
'buyer' => [
'name' => '<string>',
'email' => '<string>',
'document' => [
'type' => '<string>',
'number' => '<string>'
],
'address' => [
'street' => '<string>',
'number' => '<string>',
'zipcode' => '<string>',
'city' => '<string>',
'district' => '<string>',
'state_code' => '<string>'
]
],
'originator_legal_entity' => [
],
'boleto' => [
'expire_date' => '<string>'
]
]),
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/payin/payments"
payload := strings.NewReader("{\n \"merchant_id\": 123,\n \"invoice\": \"<string>\",\n \"notification_url\": \"<string>\",\n \"payment_method\": \"<string>\",\n \"amount\": 123,\n \"currency\": \"<string>\",\n \"country\": \"<string>\",\n \"description\": \"<string>\",\n \"buyer\": {\n \"name\": \"<string>\",\n \"email\": \"<string>\",\n \"document\": {\n \"type\": \"<string>\",\n \"number\": \"<string>\"\n },\n \"address\": {\n \"street\": \"<string>\",\n \"number\": \"<string>\",\n \"zipcode\": \"<string>\",\n \"city\": \"<string>\",\n \"district\": \"<string>\",\n \"state_code\": \"<string>\"\n }\n },\n \"originator_legal_entity\": {},\n \"boleto\": {\n \"expire_date\": \"<string>\"\n }\n}")
req, _ := http.NewRequest("POST", 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.post("https://api.sandbox.wepayout.com.br/v2/payin/payments")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"merchant_id\": 123,\n \"invoice\": \"<string>\",\n \"notification_url\": \"<string>\",\n \"payment_method\": \"<string>\",\n \"amount\": 123,\n \"currency\": \"<string>\",\n \"country\": \"<string>\",\n \"description\": \"<string>\",\n \"buyer\": {\n \"name\": \"<string>\",\n \"email\": \"<string>\",\n \"document\": {\n \"type\": \"<string>\",\n \"number\": \"<string>\"\n },\n \"address\": {\n \"street\": \"<string>\",\n \"number\": \"<string>\",\n \"zipcode\": \"<string>\",\n \"city\": \"<string>\",\n \"district\": \"<string>\",\n \"state_code\": \"<string>\"\n }\n },\n \"originator_legal_entity\": {},\n \"boleto\": {\n \"expire_date\": \"<string>\"\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.sandbox.wepayout.com.br/v2/payin/payments")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"merchant_id\": 123,\n \"invoice\": \"<string>\",\n \"notification_url\": \"<string>\",\n \"payment_method\": \"<string>\",\n \"amount\": 123,\n \"currency\": \"<string>\",\n \"country\": \"<string>\",\n \"description\": \"<string>\",\n \"buyer\": {\n \"name\": \"<string>\",\n \"email\": \"<string>\",\n \"document\": {\n \"type\": \"<string>\",\n \"number\": \"<string>\"\n },\n \"address\": {\n \"street\": \"<string>\",\n \"number\": \"<string>\",\n \"zipcode\": \"<string>\",\n \"city\": \"<string>\",\n \"district\": \"<string>\",\n \"state_code\": \"<string>\"\n }\n },\n \"originator_legal_entity\": {},\n \"boleto\": {\n \"expire_date\": \"<string>\"\n }\n}"
response = http.request(request)
puts response.read_body{
"id": 123,
"merchant": {
"id": 123,
"name": "<string>"
},
"hash": "<string>",
"payment_page": "<string>",
"our_number": "<string>",
"invoice": "<string>",
"notification_url": "<string>",
"payment_method": "<string>",
"amount": 123,
"paid_amount": 123,
"refunded_amount": 123,
"currency": {
"id": 123,
"name": "<string>",
"code": "<string>",
"symbol": "<string>"
},
"description": "<string>",
"buyer": {},
"originator_legal_entity": {},
"boleto": {
"expire_date": "<string>",
"digitable_line": "<string>",
"bar_code_number": "<string>",
"agreement": {},
"fine": {},
"discount": {}
},
"status": {
"id": 123,
"name": "<string>"
},
"status_history": [
{}
],
"substatus": {},
"refunds": [
{}
],
"created_at": "<string>",
"updated_at": "<string>"
}Create Charge (Bank Slip)
Generate a new Boleto payment request.Request Body
Merchant id of the account that is creating the payin. Mandatory if there is more than one account under your umbrella (sellers).
Your identification number, it must be unique on our database.
The url where we will submit the callbacks.
Payment method that will be used in payin.Allowed value:
boletoThe charge total amount in the smallest currency unit.Min:
500Currency code of the amount (ISO 4217). Example:
BRLCountry code (ISO 3166-1 alpha-2). Example:
BRInstructions that will be displayed to the user.
The person you are charging object.
Show Buyer Object
Show Buyer Object
The buyer name.
Buyer email address.
Use this object to inform the legal name of the final beneficiary.
Boleto specific instructions.
Show Boleto Object
Show Boleto Object
The payin expiration date. Format:
YYYY-MM-DDRequest Example
Boleto
curl --location 'https://api.sandbox.wepayout.co/v2/payin/payments' \
--header 'Content-Type: application/json' \
--header 'Authorization: Bearer YOUR_TOKEN_HERE' \
--data-raw '{
"payment_method": "boleto",
"invoice": "YOUR-INVOICE-CODE",
"currency": "BRL",
"amount": 500,
"country": "BR",
"buyer": {
"name": "Buyer Name",
"email": "buyer@example.com",
"document": {
"type": "CPF",
"number": "12345678901"
},
"address": {
"street": "Street Name",
"number": "123",
"zipcode": "12345000",
"city": "City Name",
"district": "District Name",
"state_code": "SP"
}
},
"originator_legal_entity": {
"name": "Company Name",
"document": "12345678901",
"helpdesk": "company.com"
},
"boleto": {
"expire_date": "2025-12-31"
}
}'
Response
WEpayments auto generated id, use this id to perform conciliation or perform queries via API / Dashboard.
WEpayments auto generated hash, use this hash to send your user to the payment page.
The WEpayments payment page where you can redirect the end customer.
The bank identification number.
Your identification number.
The url where callbacks are submitted.
Payment method used in payin.Value:
boletoThe payin total amount in cents.
The total amount of the payin paid.
Amount refunded from this charge.
Instructions displayed to the user.
The person you are charging object.
Final beneficiary object.
Boleto specific instructions object.
Status history object.
Substatus object. Can be null.
Refund object list.
Cash-in created date.
Cash-in update date.
Response Example
201 Bank Slip
{
"id": 54830,
"merchant": {
"id": 512,
"name": "Acme Sandbox Store"
},
"hash": "9c8d7e6f5a4b3c2f8b4d3c2e1a9a7d6c5f4e3a2b1c0d9e8f7a6b5c4d3e2f1a0",
"payment_page": "https://pagar.sandbox.goboleto.com/?hash=9c8d7e6f5a4b3c2f8b4d3c2e1a9a7d6c5f4e3a2b1c0d9e8f7a6b5c4d3e2f1a0",
"our_number": "991777551234",
"invoice": "f3a9b1d4-8a11-4d99-b9cd-1234567890ab",
"notification_url": null,
"payment_method": "boleto",
"amount": 500,
"paid_amount": null,
"refunded_amount": null,
"currency": {
"id": 19,
"name": "Reais",
"code": "BRL",
"symbol": "R$"
},
"description": "",
"created_at": "2026-04-30T12:20:39.000000Z",
"updated_at": "2026-04-30T12:20:39.000000Z",
"buyer": {
"name": "Maria Souza",
"email": "maria.souza@example.com",
"document": {
"type": "cpf",
"number": "12345678909"
},
"address": {
"country": "BR",
"city": "Barueri",
"street": "Alameda Rio Azul",
"number": "500",
"complement": "Bloco B Sala 1503",
"zipcode": "06454000",
"district": "Alphaville Industrial",
"state_code": "SP"
}
},
"originator_legal_entity": {
"name": "North Pole Commerce",
"document": "10987654321",
"helpdesk": "support.northpole.example"
},
"splits": [],
"boleto": {
"expire_date": "2027-12-31",
"digitable_line": "10499.63208 34000.100049 66666.344205 1 81490000000200",
"bar_code_number": "10491814900000002009632034000900041179634666",
"agreement": {
"number": "666666",
"digit": "6",
"agency": "9999",
"assignor_code": "9999/666666-6"
},
"fine": {
"percent": 2,
"amount": 10,
"date": "2027-12-30"
},
"discount": {
"percent": null,
"amount": null,
"daily_amount": null,
"date": null
}
},
"status": {
"id": 1,
"name": "Created"
},
"status_history": [
{
"status": {
"id": 1,
"name": "Created"
},
"updated_at": "2026-04-30T12:20:39.000000Z"
}
],
"substatus": null,
"refunds": [],
"automatic_pix": null
}
Related Resources
Create Charge (Pix)
Use the same endpoint with pix-specific required fields
Get Unique Charge
Retrieve a specific charge by ID
Was this page helpful?
⌘I

