> For the complete documentation index, see [llms.txt](https://ivorypay.gitbook.io/ivorypay-on-off-ramp-documentation/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://ivorypay.gitbook.io/ivorypay-on-off-ramp-documentation/api-reference-settlements/get-by-id.md).

# Get Settlement by ID

Get a specific settlement by its ID.

Retrieves the details of a specific settlement.

## Endpoint

```
GET /v1/settlements/:id
```

## Authentication

| Header          | Value        |
| --------------- | ------------ |
| `Authorization` | Your API key |

## Path parameters

| Parameter | Type   | Description                                                           |
| --------- | ------ | --------------------------------------------------------------------- |
| `id`      | string | Settlement UUID (validated by `ParseUUIDPipe` — must be a valid UUID) |

## Example request

{% tabs %}
{% tab title="cURL" %}

```bash
curl -X GET https://ramp-api.ivorypay.io/api/v1/settlements/set-uuid-1 \
  -H "Authorization: your_api_key"
```

{% endtab %}

{% tab title="Node.js" %}

```javascript
const response = await fetch("https://ramp-api.ivorypay.io/api/v1/settlements/set-uuid-1", {
  method: "GET",
  headers: {
    "Authorization": "your_api_key",
  },
});

const data = await response.json();
console.log(data);
```

{% endtab %}

{% tab title="Python" %}

```python
import requests

response = requests.get(
    "https://ramp-api.ivorypay.io/api/v1/settlements/set-uuid-1",
    headers={
        "Authorization": "your_api_key",
    },
)

print(response.json())
```

{% endtab %}

{% tab title="Go" %}

```go
package main

import (
	"fmt"
	"io"
	"net/http"
)

func main() {
	req, _ := http.NewRequest("GET", "https://ramp-api.ivorypay.io/api/v1/settlements/set-uuid-1", nil)
	req.Header.Set("Authorization", "your_api_key")

	resp, err := http.DefaultClient.Do(req)
	if err != nil {
		panic(err)
	}
	defer resp.Body.Close()

	body, _ := io.ReadAll(resp.Body)
	fmt.Println(string(body))
}
```

{% endtab %}
{% endtabs %}

## Example response

The settlement entity has no `reference` column of its own; the deposit reference is only available via the joined `deposit` relation as `deposit.reference`.

```json
{
  "success": true,
  "message": "Settlement retrieved",
  "data": {
    "id": "set-uuid-1",
    "depositId": "dep-uuid-1",
    "fiatAmount": 99500,
    "fiatCurrency": "NGN",
    "cryptoAmount": 62.18,
    "token": "USDT",
    "chain": "BSC_MAINNET",
    "destinationAddress": "0xYourWallet...",
    "conversionRate": 1600,
    "platformFee": 0.31,
    "businessFee": 0,
    "gasFee": 0.5,
    "transactionHash": "0xsettlement123...",
    "status": "COMPLETED"
  }
}
```
