Пишу тг Бота на aiogram 3, во время введения системы оплаты, ошибок в коде PyCharm не выдаёт, но при активации происходит ошибка START_PARAM_INVALID
Вот кусок кода, в котором он и видит ошибку. Заранее спасибо за помощь:
from aiogram import Bot
from aiogram.types import Message, LabeledPrice, PreCheckoutQuery
async def order(message:Message, bot: Bot):
await bot.send_invoice(
chat_id=message.chat.id,
title="Оплата рекламы вашего объявления",
description= 'После оплаты в течении 5-15 минут в группе будет выложен пост с вашим товаром.',
payload='Payment',
provider_token= '381764678:TEST:69972',
currency= 'rub',
prices=[
LabeledPrice(
label='Размещение Объявления',
amount=55000
),
#LabeledPrice(
# label='НДС',
# amount=5500
#),
LabeledPrice(
label='Скидка',
amount=55000
)
],
start_parameter='Fount Of Discounts',
photo_url='https://cdnb.artstation.com/p/assets/images/images/019/595/159/large/ian-pestridge-vanguard.jpg?1564182626',
photo_size= 100,
photo_width= 1080,
photo_height= 1148,
send_phone_number_to_provider= True,
is_flexible= False,
disable_notification= True,
allow_sending_without_reply= True,
request_timeout=30
)
async def pre_checkout_query(precheckoutquery: PreCheckoutQuery, bot: Bot):
await bot.answer_pre_checkout_query(pre_checkout_query.id, ok=True)
Ответы (1 шт):
Автор решения: Vladyslav
→ Ссылка
Необходимо заменить строку
start_parameter='Fount Of Discounts',
на
start_parameter='fount-of-discounts',