Pular para o conteúdo principal

Testing the charge

After creating a PIX charge you can simulate the payment in the staging environment so that your implementation receives the same webhook flow used in production.

Required – send the required authentication headers for Lulipay API requests.


Endpoint

POST https://gateway.lulipay.com/v1/payouts/simulations

Headers

NameTypeDescription
Content-TypeStringapplication/json
x-api-tokenStringAuthentication token (required)
x-country-codeStringCountry code (required, e.g. BR)
x-providerStringProvider name (required)
x-provider-idStringProvider identifier assigned by Lulipay

Request Body

NameTypeDescription
transaction_idStringID returned when the QR Code was created
statusStringcompleted
{
"transaction_id": "bac1b8d7-24ce-4b53-b6d9-babd3aa60968",
"status": "completed"
}

cURL example

curl --request POST \
--url https://gateway.lulipay.com/v1/payins/simulations \
--header 'Content-Type: application/json' \
--header 'x-api-token: YOUR_API_TOKEN' \
--header 'x-country-code: BR' \
--header 'x-provider: YOUR_PROVIDER_NAME' \
--header 'x-provider-id: YOUR_PROVIDER_ID' \
--data '{
"transaction_id": "bac1b8d7-24ce-4b53-b6d9-babd3aa60968",
"status": "completed"
}'

Response 200 OK

{
"message": "Charge successfully marked as completed in staging environment"
}

When this endpoint is triggered the charge status is updated to completed and the configured webhook is delivered exactly as it would be in production.

A QR Code status can be paid or canceled. Without calling this test endpoint the charge remains waiting.

Support

For testing issues, contact: