# 3. Create

## **Create Wallet**

<mark style="color:yellow;">`POST`</mark> `{{WalletUrl}}/api/v1/wallet`&#x20;

{% hint style="info" %}
**Note:** Before making the service call, the apikeypublic and apiclientpublic information must be included in the Header section.

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

**The parameters that must be sent to the service 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>Evet</td><td>It is the public access key used for authentication in API requests.</td></tr><tr><td>apiclientpublic</td><td>string</td><td>Evet</td><td>It is the public key that specifies the identity of the client making the API call.</td></tr></tbody></table>

{% tabs %}
{% tab title="Service Request - JSON" %}

```json
{
  "WalletOwnerId": "9edb23f2-7362-42a8-8eb4-0c89ffb397b0",
  "Name": "{{$randomFirstName}}",
  "RegionId": 1,
  "CurrencyCode": "try", // usd, eur, all
  "Alias": "1234567890", // 10 digit number
  "Description": "Cüzdanım"
}
```

{% endtab %}
{% endtabs %}

## **Service Request**

| Parameter     | Type   | Description                                                                                           |
| ------------- | ------ | ----------------------------------------------------------------------------------------------------- |
| WalletOwnerId | Guid   | Wallet owner's identity information                                                                   |
| Name          | string | The name to be assigned to the wallet account                                                         |
| RegionId      | int    | <p>Country identity information for the wallet<br><br>See: <a href="broken-reference">Regions</a></p> |
| CurrencyCode  | string | <p>Currency<br><br>See: <a href="../../system-data/currency">Currency</a></p>                         |
| Alias         | string | Unique wallet number                                                                                  |
| Description   | string | Description to be assigned to the wallet account                                                      |

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

```json
{
    "Value": {
        "Id": "30bac1c0-ad6b-4c50-a52e-1b34f9b487a7",
        "WalletOwnerId": "b5708099-be62-4d34-af06-27132082eb78",
        "Name": "Wilson",
        "Alias": "8203287943",
        "MerchantId": 2071,
        "RegionId": 1,
        "CurrencyCode": "TRY",
        "Balance": 0,
        "AvailableBalance": 0,
        "TotalGiftBalance": 0,
        "BlockedBalance": 0,
        "FrozenUntil": "0001-01-01T00:00:00",
        "IsFrozen": false,
        "IsDeleted": false,
        "CreatedAt": "2025-04-24T09:05:47.980805Z",
        "UpdatedAt": null,
        "TransactionId": null
    },
    "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>The field that indicates whether the API call was successful or not.</td></tr><tr><td>IsSuccess</td><td>bool</td><td>It is the value that indicates whether the service call was successfully completed or not.</td></tr><tr><td>Errors</td><td>Array</td><td>It is the data structure that lists the error information encountered during the request.</td></tr><tr><td>Value</td><td>Array&#x3C;Items></td><td>It is the list structure representing the main data object returned by the service.</td></tr></tbody></table>

## **Service Response (Value)**

<table><thead><tr><th width="234.05859375">Parameter</th><th width="162.38671875">Type</th><th width="348.94140625">Description</th></tr></thead><tbody><tr><td>Id</td><td>Guid</td><td>It is the unique identifier of the entity recorded in the system.</td></tr><tr><td>WalletOwnerId</td><td>Guid</td><td>It is the unique identification information of the wallet owner.</td></tr><tr><td>Name</td><td>string</td><td>It is the name or business title of the wallet owner.</td></tr><tr><td>Alias</td><td>string</td><td>It is the alternate name or short name assigned to the wallet.</td></tr><tr><td>MerchantId</td><td>Guid</td><td>It is the merchant ID associated with the wallet.</td></tr><tr><td>RegionId</td><td>string</td><td>It is the code representing the geographic region where the wallet owner is registered.</td></tr><tr><td>CurrencyCode</td><td>string</td><td>It is the international currency code of the currency used (e.g., TRY, USD).</td></tr><tr><td>Balance</td><td>decimal</td><td>It is the total available balance of the wallet.</td></tr><tr><td>AvailableBalance</td><td>decimal</td><td>It represents the amount of balance available for use.</td></tr><tr><td>TotalGiftBalance</td><td>decimal</td><td>It is the total gift balance amount in the wallet.</td></tr><tr><td>BlockedBalance</td><td>decimal</td><td>It is the blocked balance amount that cannot be used.</td></tr><tr><td>FrozenUntil</td><td>DateTime</td><td>It is the date that remains valid until the end of the wallet's frozen period.</td></tr><tr><td>IsFrozen</td><td>bool</td><td>It is the status field that indicates whether the wallet is currently frozen.</td></tr><tr><td>IsDeleted</td><td>bool</td><td>It is the field that indicates whether the wallet has been deleted from the system.</td></tr><tr><td>CreatedAt</td><td>DateTime</td><td>It is the date and time when the record was created in the system.</td></tr><tr><td>UpdatedAt</td><td>DateTime</td><td>It is the timestamp when the record was last updated in the system.</td></tr><tr><td>TransactionId</td><td>Guid</td><td>It is the identifier for the last transaction made from the wallet account.</td></tr></tbody></table>
