# 15. Check Balance (Wallet)

## Check Balance with Wallet 'Id'

<mark style="color:green;">`GET`</mark>`{{WalletUrl}}/api/v1/wallet/balances?Id=0000-0000-0000-0000-0000`&#x20;

{% hint style="info" %}
**Note**: To use this service, it is mandatory to include the **apikeypublic** and **apiclientpublic** parameters in the Header field.

\
[<mark style="color:green;">**WalletAPI Address**</mark>](https://developer.paywall.one/payment-orchestration-integration-document/environment)
{% endhint %}

**The parameters that need to be sent to the service (Headers) are as follows:**

<table><thead><tr><th width="162">Parameter</th><th width="79">Type</th><th width="107">Required</th><th width="403">Description</th></tr></thead><tbody><tr><td>apikeypublic</td><td>string</td><td>Yes</td><td>It is the general key information used for API access.</td></tr><tr><td>apiclientpublic</td><td>string</td><td>Yes</td><td>It is the information that identifies the client connecting to the API.</td></tr></tbody></table>

**The parameters that need to be sent to the service (QueryString) are as follows:**

<table><thead><tr><th width="260.65234375">Parameter</th><th>Description</th></tr></thead><tbody><tr><td>Id</td><td>The identity information of the wallet whose balance you want to query.</td></tr></tbody></table>

{% tabs %}
{% tab title="Service Reguest - JSON" %}
{% code lineNumbers="true" %}

```json
{
    "Value": {
        "Id": "30bac1c0-ad6b-4c50-a52e-1b34f9b487a7",
        "Name": "juzdan1",
        "Alias": "8203287943",
        "WalletBalance": 975.00,
        "GiftBalances": [],
        "TotalGiftBalance": 0,
        "BlockedBalance": 0,
        "TotalBalance": 975.00,
        "AvailableBalance": 975.00
    },
    "Errors": [],
    "IsSuccess": true,
    "IsFailure": false
}
```

{% endcode %}
{% endtab %}
{% endtabs %}

## Service Response

<table><thead><tr><th width="192">Parameter</th><th width="147.89192708333331">Type</th><th>Description</th></tr></thead><tbody><tr><td>IsFailure</td><td>bool</td><td>Indicates whether the transaction has failed.</td></tr><tr><td>IsSuccess</td><td>bool</td><td>Indicates whether the transaction was successful.</td></tr><tr><td>Errors</td><td>Array</td><td>Lists the error information that occurred during the transaction.</td></tr><tr><td>Value</td><td>Array&#x3C;Items></td><td>It is the list of data returned as a result of the transaction.</td></tr></tbody></table>

## Service Response (Value)

<table><thead><tr><th width="234.05859375">Parameter</th><th width="162.38671875">Type</th><th width="368.59375">Description</th></tr></thead><tbody><tr><td>Id</td><td>Guid</td><td>It is the unique identifier of the wallet.</td></tr><tr><td>Name</td><td>String</td><td>It is the name information of the wallet owner.</td></tr><tr><td>Alias</td><td>String</td><td>It is the alias information defined for the wallet.</td></tr><tr><td>WalletBalance</td><td>Decimal</td><td><p>It returns the total balance in the wallet.</p><p><br><mark style="color:red;"><strong>*</strong> Does not include GiftBalance.</mark></p></td></tr><tr><td>GiftBalances</td><td>List</td><td>It returns the list of gift balances assigned to the wallet.</td></tr><tr><td>TotalGiftBalance</td><td>Decimal</td><td>It returns the total gift balance in the wallet.</td></tr><tr><td>BlockedBalance</td><td>Decimal</td><td>It returns the unavailable (blocked) balance.</td></tr><tr><td>TotalBalance</td><td>Decimal</td><td>Total balance in the wallet<br><br><mark style="color:green;">Formula:</mark> <mark style="color:blue;">WalletBalance</mark> + <mark style="color:purple;">TotalGiftBalance</mark></td></tr><tr><td>AvailableBalance</td><td>Decimal</td><td>The available balance in the wallet. This balance includes gift balances. Additionally, if there is a blocked balance, the available balance is reduced by the blocked balance amount.<br><br><mark style="color:green;">Formula:</mark> (<mark style="color:blue;">WalletBalance</mark> + <mark style="color:purple;">TotalGiftBalance</mark>) - <mark style="color:red;">BlockedBalance</mark></td></tr></tbody></table>
