# Get account loan info

```
GET /api/v1/account/loan
```

#### Query Parameters

<table><thead><tr><th width="176">Field</th><th width="98">Type</th><th width="95">Need</th><th width="189">Description</th><th>Example</th></tr></thead><tbody><tr><td><code>"account"</code></td><td>string</td><td>required</td><td>Account address</td><td><code>42trU9A5...</code></td></tr></tbody></table>

```
/api/v1/account/loan?account=42trU9A5...
```

#### Response

* Status 200: Successfully retrieved account loan info

```json
{
  "success": true,
  "data": {
    "borrowed": "1250.500000",
    "pending_interest": "3.250000",
    "collateral_utilization": "0.45",
    "total_interest_earned": "120.750000",
    "total_interest_paid": "85.300000",
    "spot_balances": [
      {
        "symbol": "SOL",
        "amount": "10.00000000",
        "ltv_ratio": "0.90",
        "market_value": "1500.000000",
        "collateral_value": "1350.000000"
      }
    ],
    "updated_at": 1716200000000
  },
  "error": null,
  "code": null
}
```

| Field                      | Type           | Description                                                                    |
| -------------------------- | -------------- | ------------------------------------------------------------------------------ |
| `'borrowed'`               | decimal string | Current borrowed amount in USD                                                 |
| `'pending_interest'`       | decimal string | Accrued interest not yet repaid                                                |
| `'collateral_utilization'` | decimal string | Ratio of borrowed amount to total spot collateral capacity                     |
| `'total_interest_earned'`  | decimal string | Total interest earned as a lender (cumulative)                                 |
| `'total_interest_paid'`    | decimal string | Total interest paid as a borrower (cumulative, returned as positive)           |
| `'spot_balances'`          | array          | Spot balances with their effective LTV and collateral contribution (see below) |
| `'updated_at'`             | integer        | Timestamp in milliseconds of last data update                                  |

**Spot Balance Fields**

| Field                | Type           | Description                                                         |
| -------------------- | -------------- | ------------------------------------------------------------------- |
| `'symbol'`           | string         | Spot asset symbol                                                   |
| `'amount'`           | decimal string | Spot balance amount                                                 |
| `'ltv_ratio'`        | decimal string | Effective LTV ratio used for loan collateral                        |
| `'market_value'`     | decimal string | Raw marked-to-market USD value of this positive spot balance        |
| `'collateral_value'` | decimal string | Effective collateral contribution of this asset after LTV/cap logic |

* Status 404: Account loan cache not found
* Status 500: Internal server error

#### Code Example (Python)

```python
import requests

response = requests.get(
    "/api/v1/account/loan",
    params={"account": "42trU9A5..."},
    headers={"Accept": "*/*"},
)

data = response.json()
```


---

# Agent Instructions: 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://pacifica.gitbook.io/docs/api-documentation/api/rest-api/account/get-account-loan-info.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.
