---
title: "private-giftcodes.{userId}"
url: https://lumean.app/developers/docs/realtime/giftcodes
locale: ru
description: "Подарочные коды и статус реселлера владельца ключа: выпуск партии, смена статуса кода, смена статуса реселлера и его заявки. Значения кодов в событиях не передаются — только маски; полный код отдают `GET /reseller/codes` и `GET /reseller/codes/{uuid}`. Право ключа — `reseller.read`."
generated: 2026-11-08
scopes: [reseller.read]
spec_version: 1.0.0
---

# private-giftcodes.{userId}

Подарочные коды и статус реселлера владельца ключа: выпуск партии, смена статуса кода, смена статуса реселлера и его заявки. Значения кодов в событиях не передаются — только маски; полный код отдают `GET /reseller/codes` и `GET /reseller/codes/{uuid}`. Право ключа — `reseller.read`.

- Право ключа: `reseller.read`

## Параметры канала

| Поле | Тип | Описание | Пример |
| --- | --- | --- | --- |
| `userId` | `integer` | числовой идентификатор владельца ключа, его отдаёт `GET /user`. | `42` |

## События

### `.status.changed` — Status changed

Сменился статус подарочного кода.

**Payload**

| Поле | Тип | Обяз. | Описание |
| --- | --- | --- | --- |
| `gift_code` | `object` | обяз. |  |
| `gift_code.uuid` | `string` | обяз. |  |
| `gift_code.code_masked` | `string` | обяз. |  |
| `gift_code.nominal` | `integer` | обяз. |  |
| `gift_code.nominal_formatted` | `number` | обяз. |  |
| `gift_code.source` | `string` — `purchase` · `reseller` | обяз. |  |
| `gift_code.funding` | `string` — `rub` · `crypto` · `mixed` | обяз. |  |
| `gift_code.status` | `string` — `active` · `refunding` · `redeemed` · `refunded` · `cancelled` · `annulled` | обяз. |  |
| `gift_code.activatable_at` | `string` | обяз. |  |
| `gift_code.redeemed_at` | `string (date-time) \| null` | обяз. |  |
| `gift_code.cancelled_at` | `string (date-time) \| null` | обяз. |  |
| `gift_code.created_at` | `string` | обяз. |  |
| `gift_code.currency_asset` | `object` | обяз. |  |
| `gift_code.currency_asset.code` | `string` | обяз. |  |
| `gift_code.currency_asset.precision` | `integer` | обяз. |  |

### `.issued` — Issued

Выпущена партия подарочных кодов: сводка партии без значений кодов.

**Payload**

| Поле | Тип | Обяз. | Описание |
| --- | --- | --- | --- |
| `batch` | `object` | обяз. |  |
| `batch.uuid` | `string` | обяз. |  |
| `batch.source` | `string` — `purchase` · `reseller` | обяз. |  |
| `batch.codes_count` | `integer` | обяз. |  |
| `batch.nominal_total` | `integer` | обяз. |  |
| `batch.nominal_total_formatted` | `number` | обяз. |  |
| `batch.created_at` | `string` | обяз. |  |
| `batch.currency_asset` | `object` | обяз. |  |
| `batch.currency_asset.code` | `string` | обяз. |  |
| `batch.currency_asset.precision` | `integer` | обяз. |  |

### `.reseller.application.status.changed` — Reseller application status changed

Сменился статус заявки на роль реселлера.

**Payload**

| Поле | Тип | Обяз. | Описание |
| --- | --- | --- | --- |
| `application` | `object` | обяз. |  |
| `application.id` | `integer` | обяз. |  |
| `application.status` | `string` — `pending` · `approved` · `rejected` · `withdrawn` | обяз. |  |
| `application.admin_comment` | `string \| null` | обяз. |  |
| `application.reviewed_at` | `string (date-time) \| null` | обяз. |  |
| `application.created_at` | `string` | обяз. |  |

### `.reseller.status.changed` — Reseller status changed

Сменился статус реселлера.

**Payload**

| Поле | Тип | Обяз. | Описание |
| --- | --- | --- | --- |
| `reseller` | `object` | обяз. |  |
| `reseller.id` | `integer` | обяз. |  |
| `reseller.status` | `string` — `active` · `blocked` · `revoked` | обяз. |  |
| `reseller.discount_bps` | `integer` | обяз. |  |
| `reseller.blocked_reason` | `string \| null` | обяз. |  |
| `reseller.approved_at` | `string` | обяз. |  |
| `reseller.currency_asset` | `object` | обяз. |  |
| `reseller.currency_asset.code` | `string` | обяз. |  |
| `reseller.currency_asset.precision` | `integer` | обяз. |  |

---

- Эта же страница в браузере: https://lumean.app/developers/docs/realtime/giftcodes
- Машинный справочник целиком: https://api.lumean.app/docs/llm.md
