> ## Documentation Index
> Fetch the complete documentation index at: https://guides.saber.money/llms.txt
> Use this file to discover all available pages before exploring further.

# Fetching Transaction Status

> GET the buy transaction endpoint to retrieve an onramp order's status, amounts, fees, payment method, network, and withdrawal details.

Fetch details of a completed onramp transaction with a cryptocurrency withdrawal — fees, payment method, status, and more.

### Endpoint

**URL**: `https://api.saber.money/api/v2/wallet/w/transaction/buy/{transaction_id}`<br />**Method**: `GET`

***

### Headers

| Header         | Description                                                               |
| -------------- | ------------------------------------------------------------------------- |
| `X-Timestamp`  | A UNIX timestamp for the request. Used for generating a secure signature. |
| `X-Client-Id`  | Your unique client ID is provided by Saber Money.                         |
| `X-Request-Id` | A unique identifier for the request (optional but recommended).           |
| `X-User-Id`    | The unique ID of the user whose transaction is being fetched.             |
| `X-Secret-Key` | Your API secret key for authenticating the request.                       |

***

### Request Parameters

| Parameter        | Description                                                    | Example Value                          |
| ---------------- | -------------------------------------------------------------- | -------------------------------------- |
| `transaction_id` | The unique identifier of the transaction to fetch details for. | `50232ef8-5d3f-4d04-9889-ad963ef34ff1` |

**Sample request:**

```bash theme={null}
curl --location 'https://api.saber.money/api/v2/wallet/w/transaction/buy/50232ef8-5d3f-4d04-9889-ad963ef34ff1' \
  --header 'X-Timestamp: 1705491300' \
  --header 'X-Client-Id: CLIENT_ID_HERE' \
  --header 'X-Request-Id: hggqwei' \
  --header 'X-User-Id: USER_ID_HERE' \
  --header 'X-Secret-Key: SECRET_KEY_HERE'
```

### Response

**Sample response:**

```json theme={null}
{
  "success": true,
  "data": {
    "id": "50232ef8-5d3f-4d04-9889-ad963ef34ff1",
    "transaction_type": "ONRAMP_AND_WITHDRAW",
    "status": "ONRAMP_COMPLETED",
    "crypto_symbol": "USDT",
    "fiat_symbol": "INR",
    "source_id": "",
    "payment_method": "gpay_intent",
    "withdraw_address": "0x1f4d75864f1ceb33a75e26ded3393caa55f87d8e",
    "network": "BSC",
    "crypto_amount": 20,
    "fiat_amount": 1868.18,
    "base_price": 92.53,
    "final_price": 93.41,
    "total_fee": 0.19,
    "fee_currency": "USDT",
    "fee_breakup": {
      "platform_fee": 0,
      "network_fee": 0.19,
      "client_fee": 0,
      "discount": 0,
      "tax_on_fee": 0,
      "tds": 0
    },
    "created_at": 1705491300000,
    "updated_at": 1705491301000,
    "txn_hash": ""
  }
}
```

***

### Key Response Fields

| Field              | Description                                                                                                                                    | Example Value                                |
| ------------------ | ---------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------- |
| `id`               | Unique identifier of the transaction.                                                                                                          | `50232ef8-5d3f-4d04-9889-ad963ef34ff1`       |
| `transaction_type` | Type of transaction. Returns `ONRAMP_AND_WITHDRAW` for standard onramp users; may return `CRYPTO_BUY` for migrated users on the same endpoint. | `ONRAMP_AND_WITHDRAW`                        |
| `status`           | Current status of the transaction.                                                                                                             | `ONRAMP_COMPLETED`                           |
| `crypto_symbol`    | Cryptocurrency involved in the transaction.                                                                                                    | `USDT`                                       |
| `fiat_symbol`      | Fiat currency used in the transaction.                                                                                                         | `INR`                                        |
| `payment_method`   | Payment method used (e.g., `gpay_intent`).                                                                                                     | `gpay_intent`                                |
| `withdraw_address` | The wallet address to which the cryptocurrency was withdrawn.                                                                                  | `0x1f4d75864f1ceb33a75e26ded3393caa55f87d8e` |
| `network`          | Blockchain network used for the transaction.                                                                                                   | `BSC`                                        |
| `crypto_amount`    | Amount of cryptocurrency involved.                                                                                                             | `20`                                         |
| `fiat_amount`      | Amount of fiat currency used.                                                                                                                  | `1868.18`                                    |
| `total_fee`        | Total fees charged for the transaction.                                                                                                        | `0.19`                                       |
| `fee_currency`     | Currency in which the fees were charged.                                                                                                       | `USDT`                                       |
| `fee_breakup`      | Detailed breakdown of the fees (e.g., platform, network, client fees).                                                                         | `{ "network_fee": 0.19 }`                    |

***

### Notes

1. **Transaction Status**: Common statuses include `CREATED`, `ONRAMP_INITIATED`, `ONRAMP_COMPLETED`, `ONRAMP_INCONSISTENT`, `PROCESSING`, `COMPLETED`, `FAILED`, `REFUND_INITIATED`, `REFUND_COMPLETED`, and `REFUND_FAILED`. Use this field to determine the progress of the transaction. (The withdrawal-in-progress phase is reported as `PROCESSING`.)
2. **Fee Details**: `total_fee` gives the overall fee, while `fee_breakup` provides granular insights like platform and network fees.
3. **Network and Wallet Address**: Ensure that the `withdraw_address` and `network` match the user's intended withdrawal details.
4. **Transaction Type**: `transaction_type` will be `ONRAMP_AND_WITHDRAW` for most accounts but may be `CRYPTO_BUY` for migrated accounts; clients should accept both values.
5. **Use Cases**: Monitor the transaction progress; provide detailed insights to users about their transaction history.

**API Reference:** [Fetch Buy Transaction Status](https://saber-money.readme.io/reference/fetchbuytransactionstatus)


## Related topics

- [Fetching Transaction Status](/offramp/operations/fetch-status.md)
- [Frequently Asked Questions](/faq.md)
- [Fetching Quote](/onramp/operations/quote.md)
- [Overview](/offramp/overview.md)
