curl --request PATCH \
--url http://localhost:8080/menu-layout/buttons/{button_id} \
--header 'Content-Type: application/json' \
--data '
{
"text": {},
"icon": "<string>",
"enabled": true,
"visibility": "all",
"conditions": {
"has_active_subscription": true,
"subscription_is_active": true,
"has_traffic_limit": true,
"is_admin": true,
"is_moderator": true,
"referral_enabled": true,
"contests_visible": true,
"support_enabled": true,
"language_selection_enabled": true,
"happ_enabled": true,
"simple_subscription_enabled": true,
"show_trial": true,
"show_buy": true,
"has_saved_cart": true,
"min_balance_kopeks": 1,
"max_balance_kopeks": 1,
"min_registration_days": 1,
"max_registration_days": 1,
"min_referrals": 1,
"has_referrals": true,
"promo_group_ids": [
"<string>"
],
"exclude_promo_group_ids": [
"<string>"
],
"has_subscription_days_left": 1,
"max_subscription_days_left": 1,
"is_trial_user": true,
"has_autopay": true
},
"action": "<string>",
"dynamic_text": true,
"open_mode": "callback",
"webapp_url": "<string>",
"description": "<string>",
"sort_order": 123
}
'{
"type": "builtin",
"text": {},
"action": "<string>",
"builtin_id": "<string>",
"icon": "<string>",
"enabled": true,
"visibility": "all",
"conditions": {
"has_active_subscription": true,
"subscription_is_active": true,
"has_traffic_limit": true,
"is_admin": true,
"is_moderator": true,
"referral_enabled": true,
"contests_visible": true,
"support_enabled": true,
"language_selection_enabled": true,
"happ_enabled": true,
"simple_subscription_enabled": true,
"show_trial": true,
"show_buy": true,
"has_saved_cart": true,
"min_balance_kopeks": 1,
"max_balance_kopeks": 1,
"min_registration_days": 1,
"max_registration_days": 1,
"min_referrals": 1,
"has_referrals": true,
"promo_group_ids": [
"<string>"
],
"exclude_promo_group_ids": [
"<string>"
],
"has_subscription_days_left": 1,
"max_subscription_days_left": 1,
"is_trial_user": true,
"has_autopay": true
},
"dynamic_text": false,
"open_mode": "callback",
"webapp_url": "<string>",
"description": "<string>",
"sort_order": 123
}Обновить конфигурацию отдельной кнопки.
curl --request PATCH \
--url http://localhost:8080/menu-layout/buttons/{button_id} \
--header 'Content-Type: application/json' \
--data '
{
"text": {},
"icon": "<string>",
"enabled": true,
"visibility": "all",
"conditions": {
"has_active_subscription": true,
"subscription_is_active": true,
"has_traffic_limit": true,
"is_admin": true,
"is_moderator": true,
"referral_enabled": true,
"contests_visible": true,
"support_enabled": true,
"language_selection_enabled": true,
"happ_enabled": true,
"simple_subscription_enabled": true,
"show_trial": true,
"show_buy": true,
"has_saved_cart": true,
"min_balance_kopeks": 1,
"max_balance_kopeks": 1,
"min_registration_days": 1,
"max_registration_days": 1,
"min_referrals": 1,
"has_referrals": true,
"promo_group_ids": [
"<string>"
],
"exclude_promo_group_ids": [
"<string>"
],
"has_subscription_days_left": 1,
"max_subscription_days_left": 1,
"is_trial_user": true,
"has_autopay": true
},
"action": "<string>",
"dynamic_text": true,
"open_mode": "callback",
"webapp_url": "<string>",
"description": "<string>",
"sort_order": 123
}
'{
"type": "builtin",
"text": {},
"action": "<string>",
"builtin_id": "<string>",
"icon": "<string>",
"enabled": true,
"visibility": "all",
"conditions": {
"has_active_subscription": true,
"subscription_is_active": true,
"has_traffic_limit": true,
"is_admin": true,
"is_moderator": true,
"referral_enabled": true,
"contests_visible": true,
"support_enabled": true,
"language_selection_enabled": true,
"happ_enabled": true,
"simple_subscription_enabled": true,
"show_trial": true,
"show_buy": true,
"has_saved_cart": true,
"min_balance_kopeks": 1,
"max_balance_kopeks": 1,
"min_registration_days": 1,
"max_registration_days": 1,
"min_referrals": 1,
"has_referrals": true,
"promo_group_ids": [
"<string>"
],
"exclude_promo_group_ids": [
"<string>"
],
"has_subscription_days_left": 1,
"max_subscription_days_left": 1,
"is_trial_user": true,
"has_autopay": true
},
"dynamic_text": false,
"open_mode": "callback",
"webapp_url": "<string>",
"description": "<string>",
"sort_order": 123
}Запрос на обновление отдельной кнопки.
Новые локализованные тексты
Show child attributes
Эмодзи/иконка кнопки
10Включить/выключить
Новая видимость
all, admins, moderators, subscribers Новые условия показа
Show child attributes
Новый action (callback_data или URL)
Текст содержит плейсхолдеры
Режим открытия: callback или direct
callback, direct URL для Mini App при open_mode=direct
Описание кнопки
200Порядок сортировки
Successful Response
Конфигурация отдельной кнопки.
Тип кнопки
builtin, url, mini_app, callback Локализованные тексты кнопки: {lang_code: text}
Show child attributes
callback_data или URL в зависимости от типа
ID встроенной кнопки (для type=builtin)
Эмодзи/иконка кнопки (отдельно от текста)
10Кнопка активна
Видимость кнопки
all, admins, moderators, subscribers Дополнительные условия показа
Show child attributes
Текст содержит плейсхолдеры ({balance}, {username} и т.д.)
Режим открытия: callback (через бота) или direct (сразу Mini App)
callback, direct URL для Mini App при open_mode=direct
Описание кнопки для админ-панели
200Порядок сортировки (для отображения в админке)