# Вывод денежных средств по мобильному номеру

## Создание транзакции для вывода по средств по мобильному номеру

<mark style="color:green;">`POST`</mark> <https://prapi.tarlanpayments.kz/transaction/api/v1/primal/payout/phone>

<mark style="color:green;">`POST`</mark> <https://sandboxapi.tarlanpayments.kz/transaction/api/v1/primal/payout/phone>

#### Request Body

| Name                                                     | Type    | Description                                                                                                                                      |
| -------------------------------------------------------- | ------- | ------------------------------------------------------------------------------------------------------------------------------------------------ |
| phone\_number<mark style="color:red;">\*</mark>          | String  | Номер мобильного телефона для вывода средств                                                                                                     |
| callback\_url                                            | String  | URL проекта для оправки коллбэка со статусом транзакции (см [Отправка callback](/platezhnyi-shlyuz/webhook-platezhnoi-sistemy/status-oplaty.md)) |
| description<mark style="color:red;">\*</mark>            | String  | Описание платежа (50 символов)                                                                                                                   |
| merchant\_id<mark style="color:red;">\*</mark>           | Integer | Идентификатор мерчанта присваиваемый платежной системой                                                                                          |
| project\_client\_id                                      | String  | Идентификатор клиента на стороне проекта                                                                                                         |
| project\_id<mark style="color:red;">\*</mark>            | Integer | Идентификатор проекта присваиваемый платежной системой                                                                                           |
| project\_reference\_id<mark style="color:red;">\*</mark> | String  | Номер заказа на стороне проекта                                                                                                                  |
| user\_email                                              | String  | Почта пользователя                                                                                                                               |

#### Header

| Name                                            | Type   | Description                                                                                         |
| ----------------------------------------------- | ------ | --------------------------------------------------------------------------------------------------- |
| Authorization<mark style="color:red;">\*</mark> | String | Bearer  Авторотационный хэш (см [Формирование подписи](/platezhnyi-shlyuz/formirovanie-podpisi.md)) |

{% tabs %}
{% tab title="200: OK Пример успешного ответа" %}

```json
{
    "status": true,
    "message": "Success",
    "result": {
        "transaction_id": 139271,
        "issuer_name": "Bank",
        "recipient_name": "John Doe",
        "card_type": "Visa",
    }
}
```

{% endtab %}

{% tab title="500: Internal Server Error Пример ответа с ошибкой" %}

```json
{
    "status": false,
    "status_code": 5000,
    "message": "transaction already exists",
    "result": {}
}
```

{% endtab %}
{% endtabs %}

{% code lineNumbers="true" fullWidth="true" %}

```bash
curl --location 'https://prapi.tarlanpayments.kz/phone/api/v1/primal/payout/phone' \
--header 'accept: application/json' \
--header 'Content-Type: application/json' \
--header 'Authorization: Bearer 123' \
--data-raw '{
    "phone_number": "77777777777",
    "callback_url": "string",
    "user_email": "122@1212.kz",
    "project_reference_id": "1213",
    "amount": 10,
    "project_id": 99,
    "merchant_id": 99,
    "description": "test payout for visa+",
    "project_client_id": "99"
}'
```

{% endcode %}

## Проведение транзакции для вывода по средств по мобильному номеру

<mark style="color:green;">`POST`</mark> <https://prapi.tarlanpayments.kz/transaction/api/v1/payout/phone>

<mark style="color:green;">`POST`</mark> <https://sandboxapi.tarlanpayments.kz/transaction/api/v1/payout/phone>

#### Request Body

| Name                                              | Type   | Description                                                                                                               |
| ------------------------------------------------- | ------ | ------------------------------------------------------------------------------------------------------------------------- |
| transaction\_id<mark style="color:red;">\*</mark> | String | Идентификатор транзакции полученный в методе [создания ](#sozdanie-tranzakcii-dlya-vyvoda-po-sredstv-po-mobilnomu-nomeru) |

{% tabs %}
{% tab title="200: OK Пример успешного ответа" %}

```json
{
    "status": true,
    "message": "Success",
    "result": {
        "transaction_id": 139271,
        "transaction_status_code": "success",
        "acquirer_code": "jusan"
    }
}
```

{% endtab %}

{% tab title="500: Internal Server Error Пример ответа с ошибкой" %}

```json
{
    "status": false,
    "status_code": 5000,
    "message": "transaction already exists",
    "result": {}
}
```

{% endtab %}
{% endtabs %}

{% code lineNumbers="true" fullWidth="true" %}

```bash
curl --location 'https://prapi.tarlanpayments.kz/phone/api/v1/payout/phone' \
--header 'accept: application/json' \
--header 'Content-Type: application/json' \
--header 'Authorization: Bearer 1222' \
--data '{
    "transaction_id": 139271
}'
```

{% endcode %}


---

# 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://docs.tarlanpayments.kz/platezhnyi-shlyuz/platezhi-bez-formy-oplaty/vyvod-denezhnykh-sredstv-po-mobilnomu-nomeru.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.
