Список событий вебхуков

LanbillingX отправит вам данные в формате JSON для выбранных событий.

Ниже приведены примеры данных для каждого события.

Клиенты

Создание клиента
{
  "event": "create_user",
  "parameters": {
    "type": 1,
    "sole_proprietor": true,
    "inn": "123456789012",
    "organization": "ИП Иванов Иван Иванович",
    "kpp": "123456789",
    "ogrn": "1027700000000",
    "okpo": "12345678",
    "ceo": "Иванов Иван Иванович",
    "act_on_what": "Регистрация в качестве ИП",
    "accountant": "Петрова Мария Сергеевна",
    "user_surname": "Сидоров",
    "user_name": "Алексей",
    "user_patronymic": "Иванович",
    "passport_series": "1234",
    "passport_number": "567890",
    "passport_issue_place": "УФМС России по г. Москве",
    "passport_issue_department": "ОВД по району Пресня",
    "passport_issue_date": "2010-05-20",
    "birth_place": "Москва",
    "birth_date": "1985-10-15",
    "bik": "044525225",
    "bank_name": "Сбербанк России",
    "branch_bank_name": "Отделение №1",
    "correspondent_account": "30101810400000000225",
    "bank_account": "40702810900000000001",
    "phone": "+7 (495) 123-45-67",
    "mobile": "+7 (903) 456-78-90",
    "email": "example@example.com",
    "contact_person": "Елена Васильевна",
    "login": "ivanov_ivan",
    "password": "securePassword123",
    "descr": "Компания занимается оптовыми поставками оборудования.",
    "days_for_paying_orders": 1,
    "addresses": [
      {
        "type": 1,
        "address": "ул. Пушкина, д. 1, кв. 1, Москва, 101000"
      }
    ],
    "user_id": 54321
  }
}
Изменение клиента
{
  "event": "change_user",
  "parameters": {
    "type": 1,
    "sole_proprietor": true,
    "inn": "123456789012",
    "organization": "ИП Иванов Иван Иванович",
    "kpp": "123456789",
    "ogrn": "1027700000000",
    "okpo": "12345678",
    "ceo": "Иванов Иван Иванович",
    "act_on_what": "Регистрация в качестве ИП",
    "accountant": "Петрова Мария Сергеевна",
    "user_surname": "Сидоров",
    "user_name": "Алексей",
    "user_patronymic": "Иванович",
    "passport_series": "1234",
    "passport_number": "567890",
    "passport_issue_place": "УФМС России по г. Москве",
    "passport_issue_department": "ОВД по району Пресня",
    "passport_issue_date": "2010-05-20",
    "birth_place": "Москва",
    "birth_date": "1985-10-15",
    "bik": "044525225",
    "bank_name": "Сбербанк России",
    "branch_bank_name": "Отделение №1",
    "correspondent_account": "30101810400000000225",
    "bank_account": "40702810900000000001",
    "phone": "+7 (495) 123-45-67",
    "mobile": "+7 (903) 456-78-90",
    "email": "example@example.com",
    "contact_person": "Елена Васильевна",
    "login": "ivanov_ivan",
    "password": "securePassword123",
    "descr": "Компания занимается оптовыми поставками оборудования.",
    "days_for_paying_orders": 1,
    "addresses": [
      {
        "type": 1,
        "address": "ул. Пушкина, д. 1, кв. 1, Москва, 101000"
      }
    ],
    "user_id": 54321
  }
}
Удаление клиента
{
  "event": "delete_user",
  "parameters": {
    "type": 1,
    "sole_proprietor": true,
    "inn": "123456789012",
    "organization": "ИП Иванов Иван Иванович",
    "kpp": "123456789",
    "ogrn": "1027700000000",
    "okpo": "12345678",
    "ceo": "Иванов Иван Иванович",
    "act_on_what": "Регистрация в качестве ИП",
    "accountant": "Петрова Мария Сергеевна",
    "user_surname": "Сидоров",
    "user_name": "Алексей",
    "user_patronymic": "Иванович",
    "passport_series": "1234",
    "passport_number": "567890",
    "passport_issue_place": "УФМС России по г. Москве",
    "passport_issue_department": "ОВД по району Пресня",
    "passport_issue_date": "2010-05-20",
    "birth_place": "Москва",
    "birth_date": "1985-10-15",
    "bik": "044525225",
    "bank_name": "Сбербанк России",
    "branch_bank_name": "Отделение №1",
    "correspondent_account": "30101810400000000225",
    "bank_account": "40702810900000000001",
    "phone": "+7 (495) 123-45-67",
    "mobile": "+7 (903) 456-78-90",
    "email": "example@example.com",
    "contact_person": "Елена Васильевна",
    "login": "ivanov_ivan",
    "password": "securePassword123",
    "descr": "Компания занимается оптовыми поставками оборудования.",
    "days_for_paying_orders": 1,
    "addresses": [
      {
        "type": 1,
        "address": "ул. Пушкина, д. 1, кв. 1, Москва, 101000"
      }
    ],
    "user_id": 54321
  }
}

Договоры

Создание договора
{
  "event": "create_agreement",
  "parameters": {
    "user_id": 54321,
    "pay_code": "PAY123456",
    "organization_id": 1,
    "agreement_number": "number123",
    "create_date": "2000-01-01",
    "agreement_id": 54321,
    "balance": 0,
    "credit": 0,
    "currency_symbol": "rub"
  }
}
Изменение договора
{
  "event": "change_agreement",
  "parameters": {
    "user_id": 54321,
    "pay_code": "PAY123456",
    "organization_id": 1,
    "agreement_number": "number123",
    "create_date": "2000-01-01",
    "agreement_id": 54321,
    "balance": 0,
    "credit": 0,
    "currency_symbol": "rub"
  }
}
Закрытие договора
{
  "event": "close_agreement",
  "parameters": {
    "user_id": 54321,
    "pay_code": "PAY123456",
    "organization_id": 1,
    "agreement_number": "number123",
    "create_date": "2000-01-01",
    "agreement_id": 54321,
    "balance": 0,
    "credit": 0,
    "currency_symbol": "rub"
  }
}

Подписки

Создание подписки
{
  "event": "create_subscription",
  "parameters": {
    "subscription_id": 54321,
    "subscription_instance_id": 54321,
    "agreement_id": 54321,
    "agreement_number": "number123",
    "tariff_id": 54321,
    "subscription_instance_start_date": "1970-01-01 00:00:00",
    "subscription_instance_end_date": "1970-01-01 00:00:00",
    "last_tariffication_period_start": "2023-10-01 00:00:00",
    "last_tariffication_period_end": "2023-10-31 00:00:00",
    "state": 2,
    "period_id": 54321,
    "period_type": 3,
    "period_length": 1,
    "current_blocking": 54321,
    "total_price": 100,
    "description": "Description",
    "err_details": "Bad error",
    "currency_symbol": "rub",
    "tariff_descr": "Tar descr",
    "services": [
      {
        "bulk_service": false,
        "service_id": 54321,
        "tariff_service_id": 54321,
        "price": 100,
        "service_description": "Description",
        "outer_id": "best_service",
        "multiplicator": 1,
        "weight": 1,
        "periodic_service": 1,
        "hidden_for_user": 0
      }
    ],
    "subscription_start_date": "1970-01-01 00:00:00",
    "subscription_end_date": "1970-01-01 00:00:00",
    "next_change_date": "2023-10-31 00:00:00"
  }
}
Изменение подписки
{
  "event": "change_subscription",
  "parameters": {
    "subscription_id": 54321,
    "subscription_instance_id": 54321,
    "agreement_id": 54321,
    "agreement_number": "number123",
    "tariff_id": 54321,
    "subscription_instance_start_date": "1970-01-01 00:00:00",
    "subscription_instance_end_date": "1970-01-01 00:00:00",
    "last_tariffication_period_start": "2023-10-01 00:00:00",
    "last_tariffication_period_end": "2023-10-31 00:00:00",
    "state": 2,
    "period_id": 54321,
    "period_type": 3,
    "period_length": 1,
    "current_blocking": 54321,
    "total_price": 100,
    "description": "Description",
    "err_details": "Bad error",
    "currency_symbol": "rub",
    "tariff_descr": "Tar descr",
    "services": [
      {
        "bulk_service": false,
        "service_id": 54321,
        "tariff_service_id": 54321,
        "price": 100,
        "service_description": "Description",
        "outer_id": "best_service",
        "multiplicator": 1,
        "weight": 1,
        "periodic_service": 1,
        "hidden_for_user": 0
      }
    ],
    "subscription_start_date": "1970-01-01 00:00:00",
    "subscription_end_date": "1970-01-01 00:00:00",
    "next_change_date": "2023-10-31 00:00:00"
  }
}
Блокировка подписки
{
  "event": "block_subscription",
  "parameters": {
    "subscription_id": 54321,
    "subscription_instance_id": 54321,
    "agreement_id": 54321,
    "agreement_number": "number123",
    "tariff_id": 54321,
    "subscription_instance_start_date": "1970-01-01 00:00:00",
    "subscription_instance_end_date": "1970-01-01 00:00:00",
    "last_tariffication_period_start": "2023-10-01 00:00:00",
    "last_tariffication_period_end": "2023-10-31 00:00:00",
    "state": 2,
    "period_id": 54321,
    "period_type": 3,
    "period_length": 1,
    "current_blocking": 54321,
    "total_price": 100,
    "description": "Description",
    "err_details": "Bad error",
    "currency_symbol": "rub",
    "tariff_descr": "Tar descr",
    "services": [
      {
        "bulk_service": false,
        "service_id": 54321,
        "tariff_service_id": 54321,
        "price": 100,
        "service_description": "Description",
        "outer_id": "best_service",
        "multiplicator": 1,
        "weight": 1,
        "periodic_service": 1,
        "hidden_for_user": 0
      }
    ],
    "subscription_start_date": "1970-01-01 00:00:00",
    "subscription_end_date": "1970-01-01 00:00:00",
    "next_change_date": "2023-10-31 00:00:00"
  }
}
Завершение подписки
{
  "event": "close_subscription",
  "parameters": {
    "subscription_id": 54321,
    "subscription_instance_id": 54321,
    "agreement_id": 54321,
    "agreement_number": "number123",
    "tariff_id": 54321,
    "subscription_instance_start_date": "1970-01-01 00:00:00",
    "subscription_instance_end_date": "1970-01-01 00:00:00",
    "last_tariffication_period_start": "2023-10-01 00:00:00",
    "last_tariffication_period_end": "2023-10-31 00:00:00",
    "state": 2,
    "period_id": 54321,
    "period_type": 3,
    "period_length": 1,
    "current_blocking": 54321,
    "total_price": 100,
    "description": "Description",
    "err_details": "Bad error",
    "currency_symbol": "rub",
    "tariff_descr": "Tar descr",
    "services": [
      {
        "bulk_service": false,
        "service_id": 54321,
        "tariff_service_id": 54321,
        "price": 100,
        "service_description": "Description",
        "outer_id": "best_service",
        "multiplicator": 1,
        "weight": 1,
        "periodic_service": 1,
        "hidden_for_user": 0
      }
    ],
    "subscription_start_date": "1970-01-01 00:00:00",
    "subscription_end_date": "1970-01-01 00:00:00",
    "next_change_date": "2023-10-31 00:00:00"
  }
}
Удаление подписки
{
  "event": "delete_subscription",
  "parameters": {
    "agreement_id": 676,
    "agreement_number": "bulk_test",
    "description": "",
    "subscription_additional_fields": [],
    "subscription_id": 5922,
    "subscription_instance_id": 5922,
    "tariff_id": 27,
    "user_id": 14,
    "user_name": "chages\"_test"
  }
}

Платежи

Создание платежа
{
  "event": "make_payment",
  "parameters": {
    "payment_id": 54321,
    "agreement_id": 54321,
    "auto_payment_id": 54321,
    "agreement_number": "AG123456",
    "manager_id": 54321,
    "is_vps": 54321,
    "document_id": 54321,
    "status": 0,
    "user_id": 54321,
    "amount": 100,
    "pay_date": "2000-01-31 00:00:00",
    "local_date": "2000-01-31 00:00:00",
    "cancel_date": "2000-01-31 00:00:00",
    "unqiue_payment_id": "PAY20240806",
    "comment": "Платёж по счету AG123456",
    "payment_order_number": "ORD20240806",
    "order_number": "ORD123456",
    "currency_symbol": "rub",
    "user_name": "Алексей Сидоров",
    "pay_code": "PAY123456",
    "inn": "123456789012",
    "manager_fio": "Иванов Иван Иванович",
    "user_login": "alexey_sidorov"
  }
}

Документы

Завершение генерации документа
{
  "event": "documents_generation",
  "parameters": {
    "payment_id": 54321,
    "agreement_id": 54321,
    "auto_payment_id": 54321,
    "agreement_number": "text",
    "manager_id": 54321,
    "is_vps": 54321,
    "document_id": 54321,
    "status": 0,
    "user_id": 54321,
    "amount": 100,
    "pay_date": "2000-01-31 00:00:00",
    "local_date": "2000-01-31 00:00:00",
    "cancel_date": "2000-01-31 00:00:00",
    "unqiue_payment_id": "text",
    "comment": "text",
    "payment_order_number": "text",
    "order_number": "text",
    "currency_symbol": "rub",
    "user_name": "text",
    "pay_code": "text",
    "inn": "text",
    "manager_fio": "text",
    "user_login": "text"
  }
}

У вас есть вопросы по этой статье? Пожалуйста, напишите нам на .