> For the complete documentation index, see [llms.txt](https://api.webimpian.support/bayarcash/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://api.webimpian.support/bayarcash/transaction/callback.md).

# Callback

***

<mark style="color:red;">v2</mark> <mark style="color:green;">`POST`</mark> `{return_url}`\ <mark style="color:red;">v3</mark> <mark style="color:blue;">`GET`</mark> `{return_url}`\ <mark style="color:red;">v3</mark> <mark style="color:green;">`POST`</mark> `{callback_url}`

***

If your server accept a callback from Bayarcash, make sure the response return `200` status code. Maximum retry from our side is 5 attempts every 300 seconds (5 minutes) from last attempts. Below are the status value & its corresponding label.

| Status Code | Status Description |
| ----------- | ------------------ |
| 0           | New                |
| 1           | Pending            |
| 2           | Failed             |
| 3           | Success            |
| 4           | Cancelled          |

***

### Transaction

Example of JSON structured request.

```json
{
    "record_type": "transaction",
    "transaction_id": string,
    "exchange_reference_number": string,
    "exchange_transaction_id": string,
    "order_number": string,
    "currency": string,
    "amount": string,
    "payer_name": string,
    "payer_email": string,
    "payer_bank_name": string,
    "status": integer,
    "status_description": string,
    "datetime": string,
    "checksum": string
}
```

***

### Transaction Receipt

Example of JSON structured request.

```json
{
    "transaction_id": string,
    "exchange_reference_number": string,
    "exchange_transaction_id": string,
    "order_number": string,
    "currency": string,
    "amount": string,
    "payer_bank_name": string,
    "status": string,
    "status_description": string,
    "checksum": string
}
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://api.webimpian.support/bayarcash/transaction/callback.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
