Skip to main content
POST
/
v1
/
webhooks
/
cash-ins
Process an inbound upstream cash-in
curl --request POST \
  --url https://plugin-pix-direct.api.lerian.net/v1/webhooks/cash-ins \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "dtHrOp": "<string>",
  "endToEndId": "<string>",
  "idReqJdPi": "<string>",
  "pagador": {
    "cpfCnpj": "<string>",
    "ispb": "<string>",
    "nome": "<string>",
    "nrAgencia": "<string>",
    "nrConta": "<string>",
    "tpConta": 123,
    "tpPessoa": 123
  },
  "recebedor": {
    "cpfCnpj": "<string>",
    "ispb": "<string>",
    "nome": "<string>",
    "nrAgencia": "<string>",
    "nrConta": "<string>",
    "tpConta": 123,
    "tpPessoa": 123
  },
  "tpIniciacao": 123,
  "valor": 123,
  "bankIdPss": "<string>",
  "chave": "<string>",
  "cnpjIniciadorPagamento": "<string>",
  "dtContabil": "<string>",
  "dtHrLiquidacao": "<string>",
  "finalidade": 123,
  "idConciliacaoRecebedor": "<string>",
  "infEntreClientes": "<string>",
  "modalidadeAgente": 123,
  "prioridadePagamento": 123,
  "tpPrioridadePagamento": 123,
  "vlrDetalhe": [
    {
      "tipo": 123,
      "vlrTarifaDinheiroCompra": 123
    }
  ]
}
'
import requests

url = "https://plugin-pix-direct.api.lerian.net/v1/webhooks/cash-ins"

payload = {
    "dtHrOp": "<string>",
    "endToEndId": "<string>",
    "idReqJdPi": "<string>",
    "pagador": {
        "cpfCnpj": "<string>",
        "ispb": "<string>",
        "nome": "<string>",
        "nrAgencia": "<string>",
        "nrConta": "<string>",
        "tpConta": 123,
        "tpPessoa": 123
    },
    "recebedor": {
        "cpfCnpj": "<string>",
        "ispb": "<string>",
        "nome": "<string>",
        "nrAgencia": "<string>",
        "nrConta": "<string>",
        "tpConta": 123,
        "tpPessoa": 123
    },
    "tpIniciacao": 123,
    "valor": 123,
    "bankIdPss": "<string>",
    "chave": "<string>",
    "cnpjIniciadorPagamento": "<string>",
    "dtContabil": "<string>",
    "dtHrLiquidacao": "<string>",
    "finalidade": 123,
    "idConciliacaoRecebedor": "<string>",
    "infEntreClientes": "<string>",
    "modalidadeAgente": 123,
    "prioridadePagamento": 123,
    "tpPrioridadePagamento": 123,
    "vlrDetalhe": [
        {
            "tipo": 123,
            "vlrTarifaDinheiroCompra": 123
        }
    ]
}
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({
    dtHrOp: '<string>',
    endToEndId: '<string>',
    idReqJdPi: '<string>',
    pagador: {
      cpfCnpj: '<string>',
      ispb: '<string>',
      nome: '<string>',
      nrAgencia: '<string>',
      nrConta: '<string>',
      tpConta: 123,
      tpPessoa: 123
    },
    recebedor: {
      cpfCnpj: '<string>',
      ispb: '<string>',
      nome: '<string>',
      nrAgencia: '<string>',
      nrConta: '<string>',
      tpConta: 123,
      tpPessoa: 123
    },
    tpIniciacao: 123,
    valor: 123,
    bankIdPss: '<string>',
    chave: '<string>',
    cnpjIniciadorPagamento: '<string>',
    dtContabil: '<string>',
    dtHrLiquidacao: '<string>',
    finalidade: 123,
    idConciliacaoRecebedor: '<string>',
    infEntreClientes: '<string>',
    modalidadeAgente: 123,
    prioridadePagamento: 123,
    tpPrioridadePagamento: 123,
    vlrDetalhe: [{tipo: 123, vlrTarifaDinheiroCompra: 123}]
  })
};

fetch('https://plugin-pix-direct.api.lerian.net/v1/webhooks/cash-ins', 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/webhooks/cash-ins",
  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([
    'dtHrOp' => '<string>',
    'endToEndId' => '<string>',
    'idReqJdPi' => '<string>',
    'pagador' => [
        'cpfCnpj' => '<string>',
        'ispb' => '<string>',
        'nome' => '<string>',
        'nrAgencia' => '<string>',
        'nrConta' => '<string>',
        'tpConta' => 123,
        'tpPessoa' => 123
    ],
    'recebedor' => [
        'cpfCnpj' => '<string>',
        'ispb' => '<string>',
        'nome' => '<string>',
        'nrAgencia' => '<string>',
        'nrConta' => '<string>',
        'tpConta' => 123,
        'tpPessoa' => 123
    ],
    'tpIniciacao' => 123,
    'valor' => 123,
    'bankIdPss' => '<string>',
    'chave' => '<string>',
    'cnpjIniciadorPagamento' => '<string>',
    'dtContabil' => '<string>',
    'dtHrLiquidacao' => '<string>',
    'finalidade' => 123,
    'idConciliacaoRecebedor' => '<string>',
    'infEntreClientes' => '<string>',
    'modalidadeAgente' => 123,
    'prioridadePagamento' => 123,
    'tpPrioridadePagamento' => 123,
    'vlrDetalhe' => [
        [
                'tipo' => 123,
                'vlrTarifaDinheiroCompra' => 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://plugin-pix-direct.api.lerian.net/v1/webhooks/cash-ins"

	payload := strings.NewReader("{\n  \"dtHrOp\": \"<string>\",\n  \"endToEndId\": \"<string>\",\n  \"idReqJdPi\": \"<string>\",\n  \"pagador\": {\n    \"cpfCnpj\": \"<string>\",\n    \"ispb\": \"<string>\",\n    \"nome\": \"<string>\",\n    \"nrAgencia\": \"<string>\",\n    \"nrConta\": \"<string>\",\n    \"tpConta\": 123,\n    \"tpPessoa\": 123\n  },\n  \"recebedor\": {\n    \"cpfCnpj\": \"<string>\",\n    \"ispb\": \"<string>\",\n    \"nome\": \"<string>\",\n    \"nrAgencia\": \"<string>\",\n    \"nrConta\": \"<string>\",\n    \"tpConta\": 123,\n    \"tpPessoa\": 123\n  },\n  \"tpIniciacao\": 123,\n  \"valor\": 123,\n  \"bankIdPss\": \"<string>\",\n  \"chave\": \"<string>\",\n  \"cnpjIniciadorPagamento\": \"<string>\",\n  \"dtContabil\": \"<string>\",\n  \"dtHrLiquidacao\": \"<string>\",\n  \"finalidade\": 123,\n  \"idConciliacaoRecebedor\": \"<string>\",\n  \"infEntreClientes\": \"<string>\",\n  \"modalidadeAgente\": 123,\n  \"prioridadePagamento\": 123,\n  \"tpPrioridadePagamento\": 123,\n  \"vlrDetalhe\": [\n    {\n      \"tipo\": 123,\n      \"vlrTarifaDinheiroCompra\": 123\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/webhooks/cash-ins")
  .header("Authorization", "Bearer <token>")
  .header("Content-Type", "application/json")
  .body("{\n  \"dtHrOp\": \"<string>\",\n  \"endToEndId\": \"<string>\",\n  \"idReqJdPi\": \"<string>\",\n  \"pagador\": {\n    \"cpfCnpj\": \"<string>\",\n    \"ispb\": \"<string>\",\n    \"nome\": \"<string>\",\n    \"nrAgencia\": \"<string>\",\n    \"nrConta\": \"<string>\",\n    \"tpConta\": 123,\n    \"tpPessoa\": 123\n  },\n  \"recebedor\": {\n    \"cpfCnpj\": \"<string>\",\n    \"ispb\": \"<string>\",\n    \"nome\": \"<string>\",\n    \"nrAgencia\": \"<string>\",\n    \"nrConta\": \"<string>\",\n    \"tpConta\": 123,\n    \"tpPessoa\": 123\n  },\n  \"tpIniciacao\": 123,\n  \"valor\": 123,\n  \"bankIdPss\": \"<string>\",\n  \"chave\": \"<string>\",\n  \"cnpjIniciadorPagamento\": \"<string>\",\n  \"dtContabil\": \"<string>\",\n  \"dtHrLiquidacao\": \"<string>\",\n  \"finalidade\": 123,\n  \"idConciliacaoRecebedor\": \"<string>\",\n  \"infEntreClientes\": \"<string>\",\n  \"modalidadeAgente\": 123,\n  \"prioridadePagamento\": 123,\n  \"tpPrioridadePagamento\": 123,\n  \"vlrDetalhe\": [\n    {\n      \"tipo\": 123,\n      \"vlrTarifaDinheiroCompra\": 123\n    }\n  ]\n}")
  .asString();
require 'uri'
require 'net/http'

url = URI("https://plugin-pix-direct.api.lerian.net/v1/webhooks/cash-ins")

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  \"dtHrOp\": \"<string>\",\n  \"endToEndId\": \"<string>\",\n  \"idReqJdPi\": \"<string>\",\n  \"pagador\": {\n    \"cpfCnpj\": \"<string>\",\n    \"ispb\": \"<string>\",\n    \"nome\": \"<string>\",\n    \"nrAgencia\": \"<string>\",\n    \"nrConta\": \"<string>\",\n    \"tpConta\": 123,\n    \"tpPessoa\": 123\n  },\n  \"recebedor\": {\n    \"cpfCnpj\": \"<string>\",\n    \"ispb\": \"<string>\",\n    \"nome\": \"<string>\",\n    \"nrAgencia\": \"<string>\",\n    \"nrConta\": \"<string>\",\n    \"tpConta\": 123,\n    \"tpPessoa\": 123\n  },\n  \"tpIniciacao\": 123,\n  \"valor\": 123,\n  \"bankIdPss\": \"<string>\",\n  \"chave\": \"<string>\",\n  \"cnpjIniciadorPagamento\": \"<string>\",\n  \"dtContabil\": \"<string>\",\n  \"dtHrLiquidacao\": \"<string>\",\n  \"finalidade\": 123,\n  \"idConciliacaoRecebedor\": \"<string>\",\n  \"infEntreClientes\": \"<string>\",\n  \"modalidadeAgente\": 123,\n  \"prioridadePagamento\": 123,\n  \"tpPrioridadePagamento\": 123,\n  \"vlrDetalhe\": [\n    {\n      \"tipo\": 123,\n      \"vlrTarifaDinheiroCompra\": 123\n    }\n  ]\n}"

response = http.request(request)
puts response.read_body
{
  "dtHrCreditoSgct": "<string>",
  "dtHrReqJdPi": "<string>",
  "endToEndIdDevolucao": "<string>",
  "endToEndIdOriginal": "<string>",
  "idCreditoSgct": "<string>",
  "idReqJdPi": "<string>",
  "idReqSistemaCliente": "<string>"
}
{
  "code": "<string>",
  "detail": "<string>",
  "errors": [
    {
      "location": "<string>",
      "message": "<string>",
      "value": "<unknown>"
    }
  ],
  "instance": "<string>",
  "status": 123,
  "title": "<string>",
  "type": "about:blank"
}

Authorizations

Authorization
string
header
required

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

application/json
dtHrOp
string
required

Operation timestamp (ISO-8601).

endToEndId
string
required

SPI end-to-end id (idempotency + dedup key).

idReqJdPi
string
required

Upstream request id (becomes the local row id when a UUID).

pagador
object
required
recebedor
object
required
tpIniciacao
integer<int64>
required

Initiation type (eStartupType: Chave -> in route, QR -> inQrCode route).

valor
number<double>
required

Amount in reais (a JSON number).

bankIdPss
string

Saque/troco PSS participant ISPB (a v5.5.0 string).

chave
string

The Pix key (present for key-initiated cash-ins).

cnpjIniciadorPagamento
string

Payment initiator CNPJ (a v5.5.0 string).

dtContabil
string

Accounting date (optional).

dtHrLiquidacao
string

Settlement timestamp (optional).

finalidade
integer<int64>

Finality (eFinality).

idConciliacaoRecebedor
string

Recipient conciliation id (stamped on the row + the 24h marker).

infEntreClientes
string

Free-text inter-client info.

modalidadeAgente
integer<int64>

Agent modality (eModalityAgent).

prioridadePagamento
integer<int64>

Payment priority (ePaymentPriority).

tpPrioridadePagamento
integer<int64>

Payment priority type.

vlrDetalhe
object[] | null

Optional value-detail entries.

Response

OK

dtHrCreditoSgct
string

settlement-gateway credit timestamp (ISO-8601), on a credited result.

dtHrReqJdPi
string

Request timestamp (ISO-8601).

endToEndIdDevolucao
string

Echoed return end-to-end id.

endToEndIdOriginal
string

Echoed original end-to-end id.

idCreditoSgct
string

settlement-gateway credit lançamento id (GUID), on a credited result.

idReqJdPi
string

Echoed upstream request id.

idReqSistemaCliente
string

Echoed client-system request id.