Payments with Pyrogram
[pyrogram]
api_id = 123456
api_hash = 123abc456def789ghi
bot_token = 123456:abcdefg
[paybot]
stripe_token = 123456:TEST:somerandomsecret
You can get the required api_id
and _hash
from Telegram.
The bot_token
needs to be retrieved from @BotFather.
Set up Payments with Stripe through aforementioned BotFather.
/mybots
-> Your desired Bot -> Bot Settings -> Payments -> Stripe.
Choose Test (if you want to test) or Live (if you got a fleshed-out product).
BotFather will guide you through Stripe's bots and set everything up.
Once everything is set up, you should be good to go. Run the script with python PyroBot.py
(or whatever you renamed it to).
Update 13. Sep. 2020: This should be updated for Pyrogram v1. Since I edited this Gist via the Webinterface, I have no IDE to correctly typehint me lol.
update.message.from_id
doesn't seem to be sent anymore. Please update toupdate.message.peer_id.user_id