# Create a notification app

`POST /service/@id/tinopay/notification-apps` · TinoPay, service owner's sign-in token

Step 4. `type` cannot change after creation. `bot_token`: required for Zalo (your own bot); for Telegram, given means your own bot, empty means the shared bot @allpay_telebot (`endpoint` is a group ID starting with `-`); not sent for Lark (`endpoint` is the Lark bot webhook URL). `virtual_accounts`: VA numbers of that bank account, empty means every VA. Returns 201.

## HTTP request

| Item | Value |
| --- | --- |
| URL | `https://api.tino.vn/service/@id/tinopay/notification-apps` |
| Method | `POST` |
| Authentication | the TinoPay service owner's sign-in token (`Authorization: Bearer <token>`); the `/v1` gateway does not expose TinoPay yet |
| Content-Type | `application/json` |

## Parameters

| Name | In | Type | Required | Description |
| --- | --- | --- | --- | --- |
| `id` | path | int | yes | TinoPay service ID |
| `type` | body | string | yes | telegram \| zalo \| lark (không đổi được sau khi tạo) |
| `name` | body | string | yes | ≤ 250 |
| `endpoint` | body | string | yes | — |
| `bot_token` | body | string | — | — |
| `bank_account_id` | body | string | yes | — |
| `virtual_accounts` | body | array | — | — |
| `status` | body | string | — | active \| inactive |

## Example request

```bash
curl -X POST "https://api.tino.vn/service/100001/tinopay/notification-apps" \
  -H "Authorization: Bearer $TINO_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
  "type": "zalo",
  "name": "Nhóm kế toán",
  "endpoint": "zgr-1a2b3c4d5e6f7a8b9c0d",
  "bot_token": "<bot_token>",
  "bank_account_id": "9c1e6f2a-5b7d-4e1a-9f3c-2d8b6a4e0c11",
  "virtual_accounts": [
    "9624QA01"
  ]
}'
```

`$TINO_TOKEN` is the TinoPay service owner's sign-in token. Path parameters in the example are sample values.

SDK ([SDK & examples](/en/docs/sdk)): no dedicated function yet, use `client.request("POST", "/service/@id/tinopay/notification-apps")`.

## Example response

```json
{
 "data": {
  "id": 7,
  "type": "zalo",
  "name": "Nhóm kế toán",
  "endpoint": "zgr-1a2b3c4d5e6f7a8b9c0d",
  "bot": "own",
  "bot_token_masked": "<masked>",
  "bank_account_id": "9c1e6f2a-5b7d-4e1a-9f3c-2d8b6a4e0c11",
  "virtual_accounts": [
   "9624QA01"
  ],
  "status": "active",
  "last_error": null,
  "last_error_at": null,
  "created_at": "2026-10-22T09:00:00+07:00",
  "updated_at": "2026-10-22T09:00:00+07:00"
 }
}
```

Sample built from the TinoPay API v1 documentation (Tino relays TinoPay data as is); values are examples.
