curl --request POST \
--url https://plugin-pix-direct.api.lerian.net/v1/qrcodes/dynamic \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"type": "IMMEDIATE",
"key": "12345678901",
"amount": 50,
"recipientName": "João da Silva",
"payer": {
"document": "98765432100",
"validate": true,
"name": "Maria Santos"
},
"dueDate": "2024-12-31",
"expirationTime": 3600,
"city": "São Paulo",
"zipCode": "01234567",
"recipientConciliationId": "CONC123456789",
"partnerId": "019c96a0-0c0c-7221-8cf3-13313fb60081",
"description": [
{
"name": "Invoice",
"value": "INV-001"
}
]
}
'import requests
url = "https://plugin-pix-direct.api.lerian.net/v1/qrcodes/dynamic"
payload = {
"type": "IMMEDIATE",
"key": "12345678901",
"amount": 50,
"recipientName": "João da Silva",
"payer": {
"document": "98765432100",
"validate": True,
"name": "Maria Santos"
},
"dueDate": "2024-12-31",
"expirationTime": 3600,
"city": "São Paulo",
"zipCode": "01234567",
"recipientConciliationId": "CONC123456789",
"partnerId": "019c96a0-0c0c-7221-8cf3-13313fb60081",
"description": [
{
"name": "Invoice",
"value": "INV-001"
}
]
}
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({
type: 'IMMEDIATE',
key: '12345678901',
amount: 50,
recipientName: 'João da Silva',
payer: {document: '98765432100', validate: true, name: 'Maria Santos'},
dueDate: '2024-12-31',
expirationTime: 3600,
city: 'São Paulo',
zipCode: '01234567',
recipientConciliationId: 'CONC123456789',
partnerId: '019c96a0-0c0c-7221-8cf3-13313fb60081',
description: [{name: 'Invoice', value: 'INV-001'}]
})
};
fetch('https://plugin-pix-direct.api.lerian.net/v1/qrcodes/dynamic', 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://plugin-pix-direct.api.lerian.net/v1/qrcodes/dynamic",
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([
'type' => 'IMMEDIATE',
'key' => '12345678901',
'amount' => 50,
'recipientName' => 'João da Silva',
'payer' => [
'document' => '98765432100',
'validate' => true,
'name' => 'Maria Santos'
],
'dueDate' => '2024-12-31',
'expirationTime' => 3600,
'city' => 'São Paulo',
'zipCode' => '01234567',
'recipientConciliationId' => 'CONC123456789',
'partnerId' => '019c96a0-0c0c-7221-8cf3-13313fb60081',
'description' => [
[
'name' => 'Invoice',
'value' => 'INV-001'
]
]
]),
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://plugin-pix-direct.api.lerian.net/v1/qrcodes/dynamic"
payload := strings.NewReader("{\n \"type\": \"IMMEDIATE\",\n \"key\": \"12345678901\",\n \"amount\": 50,\n \"recipientName\": \"João da Silva\",\n \"payer\": {\n \"document\": \"98765432100\",\n \"validate\": true,\n \"name\": \"Maria Santos\"\n },\n \"dueDate\": \"2024-12-31\",\n \"expirationTime\": 3600,\n \"city\": \"São Paulo\",\n \"zipCode\": \"01234567\",\n \"recipientConciliationId\": \"CONC123456789\",\n \"partnerId\": \"019c96a0-0c0c-7221-8cf3-13313fb60081\",\n \"description\": [\n {\n \"name\": \"Invoice\",\n \"value\": \"INV-001\"\n }\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://plugin-pix-direct.api.lerian.net/v1/qrcodes/dynamic")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"type\": \"IMMEDIATE\",\n \"key\": \"12345678901\",\n \"amount\": 50,\n \"recipientName\": \"João da Silva\",\n \"payer\": {\n \"document\": \"98765432100\",\n \"validate\": true,\n \"name\": \"Maria Santos\"\n },\n \"dueDate\": \"2024-12-31\",\n \"expirationTime\": 3600,\n \"city\": \"São Paulo\",\n \"zipCode\": \"01234567\",\n \"recipientConciliationId\": \"CONC123456789\",\n \"partnerId\": \"019c96a0-0c0c-7221-8cf3-13313fb60081\",\n \"description\": [\n {\n \"name\": \"Invoice\",\n \"value\": \"INV-001\"\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://plugin-pix-direct.api.lerian.net/v1/qrcodes/dynamic")
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 \"type\": \"IMMEDIATE\",\n \"key\": \"12345678901\",\n \"amount\": 50,\n \"recipientName\": \"João da Silva\",\n \"payer\": {\n \"document\": \"98765432100\",\n \"validate\": true,\n \"name\": \"Maria Santos\"\n },\n \"dueDate\": \"2024-12-31\",\n \"expirationTime\": 3600,\n \"city\": \"São Paulo\",\n \"zipCode\": \"01234567\",\n \"recipientConciliationId\": \"CONC123456789\",\n \"partnerId\": \"019c96a0-0c0c-7221-8cf3-13313fb60081\",\n \"description\": [\n {\n \"name\": \"Invoice\",\n \"value\": \"INV-001\"\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"qrCode": "00020101021226850014br.gov.bcb.pix2563qrcode.example.com.br/v2/cobv/9d36b84fc70b478fb95c12729b90ca255204000053039865802BR5913Merchant Name6009Sao Paulo62070503***63042C43"
}Create dynamic QR code
Generate a single-use, dynamic, Pix QR code with advanced features like expiration, payer validation, and additional payment information. Ideal for invoicing and controlled payments.
curl --request POST \
--url https://plugin-pix-direct.api.lerian.net/v1/qrcodes/dynamic \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"type": "IMMEDIATE",
"key": "12345678901",
"amount": 50,
"recipientName": "João da Silva",
"payer": {
"document": "98765432100",
"validate": true,
"name": "Maria Santos"
},
"dueDate": "2024-12-31",
"expirationTime": 3600,
"city": "São Paulo",
"zipCode": "01234567",
"recipientConciliationId": "CONC123456789",
"partnerId": "019c96a0-0c0c-7221-8cf3-13313fb60081",
"description": [
{
"name": "Invoice",
"value": "INV-001"
}
]
}
'import requests
url = "https://plugin-pix-direct.api.lerian.net/v1/qrcodes/dynamic"
payload = {
"type": "IMMEDIATE",
"key": "12345678901",
"amount": 50,
"recipientName": "João da Silva",
"payer": {
"document": "98765432100",
"validate": True,
"name": "Maria Santos"
},
"dueDate": "2024-12-31",
"expirationTime": 3600,
"city": "São Paulo",
"zipCode": "01234567",
"recipientConciliationId": "CONC123456789",
"partnerId": "019c96a0-0c0c-7221-8cf3-13313fb60081",
"description": [
{
"name": "Invoice",
"value": "INV-001"
}
]
}
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({
type: 'IMMEDIATE',
key: '12345678901',
amount: 50,
recipientName: 'João da Silva',
payer: {document: '98765432100', validate: true, name: 'Maria Santos'},
dueDate: '2024-12-31',
expirationTime: 3600,
city: 'São Paulo',
zipCode: '01234567',
recipientConciliationId: 'CONC123456789',
partnerId: '019c96a0-0c0c-7221-8cf3-13313fb60081',
description: [{name: 'Invoice', value: 'INV-001'}]
})
};
fetch('https://plugin-pix-direct.api.lerian.net/v1/qrcodes/dynamic', 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://plugin-pix-direct.api.lerian.net/v1/qrcodes/dynamic",
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([
'type' => 'IMMEDIATE',
'key' => '12345678901',
'amount' => 50,
'recipientName' => 'João da Silva',
'payer' => [
'document' => '98765432100',
'validate' => true,
'name' => 'Maria Santos'
],
'dueDate' => '2024-12-31',
'expirationTime' => 3600,
'city' => 'São Paulo',
'zipCode' => '01234567',
'recipientConciliationId' => 'CONC123456789',
'partnerId' => '019c96a0-0c0c-7221-8cf3-13313fb60081',
'description' => [
[
'name' => 'Invoice',
'value' => 'INV-001'
]
]
]),
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://plugin-pix-direct.api.lerian.net/v1/qrcodes/dynamic"
payload := strings.NewReader("{\n \"type\": \"IMMEDIATE\",\n \"key\": \"12345678901\",\n \"amount\": 50,\n \"recipientName\": \"João da Silva\",\n \"payer\": {\n \"document\": \"98765432100\",\n \"validate\": true,\n \"name\": \"Maria Santos\"\n },\n \"dueDate\": \"2024-12-31\",\n \"expirationTime\": 3600,\n \"city\": \"São Paulo\",\n \"zipCode\": \"01234567\",\n \"recipientConciliationId\": \"CONC123456789\",\n \"partnerId\": \"019c96a0-0c0c-7221-8cf3-13313fb60081\",\n \"description\": [\n {\n \"name\": \"Invoice\",\n \"value\": \"INV-001\"\n }\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://plugin-pix-direct.api.lerian.net/v1/qrcodes/dynamic")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"type\": \"IMMEDIATE\",\n \"key\": \"12345678901\",\n \"amount\": 50,\n \"recipientName\": \"João da Silva\",\n \"payer\": {\n \"document\": \"98765432100\",\n \"validate\": true,\n \"name\": \"Maria Santos\"\n },\n \"dueDate\": \"2024-12-31\",\n \"expirationTime\": 3600,\n \"city\": \"São Paulo\",\n \"zipCode\": \"01234567\",\n \"recipientConciliationId\": \"CONC123456789\",\n \"partnerId\": \"019c96a0-0c0c-7221-8cf3-13313fb60081\",\n \"description\": [\n {\n \"name\": \"Invoice\",\n \"value\": \"INV-001\"\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://plugin-pix-direct.api.lerian.net/v1/qrcodes/dynamic")
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 \"type\": \"IMMEDIATE\",\n \"key\": \"12345678901\",\n \"amount\": 50,\n \"recipientName\": \"João da Silva\",\n \"payer\": {\n \"document\": \"98765432100\",\n \"validate\": true,\n \"name\": \"Maria Santos\"\n },\n \"dueDate\": \"2024-12-31\",\n \"expirationTime\": 3600,\n \"city\": \"São Paulo\",\n \"zipCode\": \"01234567\",\n \"recipientConciliationId\": \"CONC123456789\",\n \"partnerId\": \"019c96a0-0c0c-7221-8cf3-13313fb60081\",\n \"description\": [\n {\n \"name\": \"Invoice\",\n \"value\": \"INV-001\"\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"qrCode": "00020101021226850014br.gov.bcb.pix2563qrcode.example.com.br/v2/cobv/9d36b84fc70b478fb95c12729b90ca255204000053039865802BR5913Merchant Name6009Sao Paulo62070503***63042C43"
}Authorizations
JWT Bearer token authentication. Obtain token from /v1/login/oauth/access_token endpoint
using client credentials (clientId and clientSecret).
Include token in Authorization header:
Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9...
Token expires after 3600 seconds (1 hour).
Body
Specifies the QR Code type. For IMMEDIATE, this indicates a single-use QR Code generated for instant Pix payments with a predefined amount and expiration time.
IMMEDIATE "IMMEDIATE"
Pix key of the recipient.
"12345678901"
Amount for the dynamic QR code.
50
Name of the recipient (payee).
"João da Silva"
Payer information.
Show child attributes
Show child attributes
Due date for the payment (YYYY-MM-DD).
"2024-12-31"
Expiration time in seconds after which the QR code becomes invalid.
3600
City of the recipient.
"São Paulo"
ZIP code of the recipient (8 digits).
"01234567"
Identifier for conciliation by the recipient.
"CONC123456789"
Identifier for the partner system.
"019c96a0-0c0c-7221-8cf3-13313fb60081"
List of descriptions for the payment.
Show child attributes
Show child attributes
Response
Dynamic QR code created successfully
Generated Pix QR code string.
"00020101021226850014br.gov.bcb.pix2563qrcode.example.com.br/v2/cobv/9d36b84fc70b478fb95c12729b90ca255204000053039865802BR5913Merchant Name6009Sao Paulo62070503***63042C43"
Was this page helpful?

