? Question


GunTab can send your app real-time updates about your transactions, so you know when to prepare a shipment, when to ship, and when you've been paid.

What are webhooks?

Webhooks are HTTP POST requests that GunTab makes to the URL of your choice. These requests include a JSON-formatted payload with details about a transaction. These requests occur when GunTab updates a transaction to one of the webhook-enabled transaction statuses.

How do I configure webhooks?

You can add a webhook endpoint, and review your existing webhook endpoints, from your webhook dashboard. Webhooks will be sent to every endpoint you configure, for every eligible transaction status.

What are the webhook-enabled transaction statuses?

When a transaction enters any one of these statuses, a webhook is sent:

  • canceled
  • pending_buyer_inspection_period
  • pending_disbursement_processing
  • pending_dispute_review
  • pending_payment_processing
  • pending_refund_processing
  • pending_shipment
  • pending_shipment_delivery
  • succeeded

What do the JSON payloads look like?

Here is an example JSON payload that would be posted to your webhook endpoint:

  "invoice_id": "86ebdc65-23ef-4eea-b495-c24f0e29b11b",
  "seller_order_id": "55555",
  "status": "pending_shipment",
  "transaction_id": "6ce94826-a153-4835-819e-b329f7d07741"

The values are defined as follows:

  • invoice_id: The GunTab Invoice ID for the transaction.
  • seller_order_id: Your order ID for the transaction, which you provided when creating the Invoice.
  • status: The new status that the transaction just entered. Details on how to interpret these values can be found below.
  • transaction_id: The GunTab ID for the transaction.

What is the recommended usage for a seller?

If you are a seller, we recommend the following usage:

  1. pending_payment_processing: Package the order for shipment (but do not send).
  2. pending_shipment: Send the shipment and "mark as shipped" in GunTab.
  3. pending_shipment_delivery: No action necessary, this status is informational. GunTab will notify the buyer of delivery.
  4. pending_buyer_inspection_period: Expect your disbursement to be sent in 3 days or less.
  5. pending_disbursement_processing: No action necessary, this status is informational. Expect your disbursement to be visible in your online banking in 1-2 business days.
  6. succeeded: No action necessary, this status is informational. Your disbursement should be visible in your online banking.

Be on the lookout for status values that indicate a problem:

  • canceled: The buyer decided not to purchase. This is similar to pending_refund_processing, except the merchandise was not shipped.
  • pending_dispute_review: The buyer disputed the transaction and GunTab is reviewing.
  • pending_seller_inspection_period: Inspect the returned merchandise within 3 days.
  • pending_refund_processing: The the shipment was returned to sender after being lost or successfully disputed. This is similar to canceled, except the merchandise was probably shipped.

Can I simulate/test webhooks?

Yes. From your list of webhook endpoints you can click to "Test" an endpoint. For each test you can select which status you want to POST to your endpoint.