General

Payment webhooks: what they are and how to automate order confirmation

Learn what payment webhooks are, how they work and how to use them to automatically confirm orders paid by Pix, card and boleto in Brazil in your system or ERP.

By Equipe Sila Pay3 min read
Smiling developer in a coworking space, working on a laptop seen from the side

When a customer pays, someone has to tell your system: mark the order as paid, pick the stock, issue the invoice and send the confirmation. Checking bank statements by hand works at first, but it slows everything down as sales grow. That is exactly what payment webhooks are for.

What is a payment webhook

It is an automatic notification that the payment platform sends to an address (URL) in your system whenever something happens to a charge: a Pix was paid, a boleto cleared, a card purchase was approved or refunded. Instead of your system asking every few minutes whether the customer has paid, it is notified as soon as the status changes.

How it works, step by step

  1. You provide the URL: the address in your system that will receive the notifications, set up in the dashboard or sent in the postbackUrl field of a charge created via the API.
  2. The customer pays: by Pix, credit card or boleto.
  3. The platform sends the notification: an HTTP POST request with the event data in JSON.
  4. Your system confirms the order: it checks the notification, updates the status and replies with HTTP 200 to acknowledge it.

What a webhook contains

Each notification carries a unique event ID, the payment status and the transaction data. A simplified example: {"id": "evt_...", "status": "LIQUIDATED", "data": {"value": "16.5", "txId": "...", "method": "pix"}}.

With Sila Pay you can also choose in the dashboard which events you want to receive, such as purchase approved (purchase_approved), Pix paid (pix_paid), boleto paid (boleto_paid), Pix expired and purchase refunded.

Where webhooks help day to day

  • Automatic order updates: the order switches to "paid" in your system or ERP without anyone checking statements.
  • Stock and shipping: picking starts as soon as the payment is confirmed.
  • Digital products and services: grant access, tickets or bookings right after payment.
  • Expired charges: find out when a Pix or boleto expired unpaid and follow up with the customer.

Want to automate your order confirmations? Open your Sila Pay account

Best practices for receiving webhooks

  • Verify the signature: every Sila Pay notification includes the X-Silapay-Signature header, an HMAC-SHA256 computed with your secret. Check it before processing.
  • Reply quickly: return HTTP 200 within 5 seconds and leave slow tasks, such as issuing the invoice, for later.
  • Handle duplicates: if your system does not reply, the platform tries again; use the event id so you never process the same notification twice.
  • Use HTTPS and protect the secret: keep it on your server, never on your website or in your app.

Frequently asked questions

Do I need to be a developer to use webhooks?

Someone has to set up the address that receives the notifications. Many ERPs and e-commerce platforms already support this; if you use WooCommerce or Shopify, Sila Pay offers plugins to connect your store.

What is the difference between a webhook and an API?

With an API, your system calls the platform, for example to create a charge. With a webhook, the platform calls your system to tell it that something has changed. The two usually work together.

What if my system is down?

Sila Pay automatically retries when it does not receive an HTTP 200 response. Even so, it is worth keeping a reconciliation routine for longer outages.

Where can I find the documentation?

At doc.silapay.pro, with the list of events, the payload format and a signature verification example.

Confirm orders automatically, with no statement checks. Sign up for Sila Pay

#pagamentos#vendas online
ShareWhatsAppLinkedInX

Ready to put this into practice?

Create your Sila Pay account in minutes and start getting paid by Pix, card and payment link.

  • ✓ Free sign-up
  • ✓ No monthly fee
  • ✓ Next-day settlement
Create free account →

Get the next articles

Practical content about payments and online sales, straight to your inbox.

No spam. Unsubscribe anytime.

Read also

Sila Pay

Everything you need to sell, all in one place.

Get started →