ValidateRequestedInfoRequest
Only users can use this request. See code examples.
---functions--- payments.validateRequestedInfo#b6c8f12b flags:# save:flags.0?true invoice:InputInvoice info:PaymentRequestedInfo = payments.ValidatedRequestedInfo
Returns
| payments.ValidatedRequestedInfo |
This type can only be an instance of:
| ValidatedRequestedInfo |
Parameters
| invoice | InputInvoice | |
| info | PaymentRequestedInfo | |
| save | flag | This argument defaults to None and can be omitted. |
Known RPC errors
This request can cause 1 known error:
MessageIdInvalidError | The specified message ID is invalid or you can't do that operation on such message. |
You can import these from telethon.errors.
Example
from telethon.sync import TelegramClient
from telethon import functions, types
with TelegramClient(name, api_id, api_hash) as client:
result = client(functions.payments.ValidateRequestedInfoRequest(
invoice=types.InputInvoiceMessage(
peer='username',
msg_id=42
),
info=types.PaymentRequestedInfo(
name='some string here',
phone='some string here',
email='some string here',
shipping_address=types.PostAddress(
street_line1='some string here',
street_line2='some string here',
city='some string here',
state='some string here',
country_iso2='some string here',
post_code='some string here'
)
),
save=True
))
print(result.stringify())