mirror of
https://github.com/pyrogram/pyrogram
synced 2025-08-28 04:48:06 +00:00
Add InputPhoneContact type
This commit is contained in:
parent
7d72738153
commit
2ab8fbe047
@ -30,4 +30,5 @@ from .client import ChatAction
|
||||
from .client import Client
|
||||
from .client import ParseMode
|
||||
from .client.input_media import InputMedia
|
||||
from .client.input_phone_contact import InputPhoneContact
|
||||
from .client import Emoji
|
||||
|
11
pyrogram/client/input_phone_contact.py
Normal file
11
pyrogram/client/input_phone_contact.py
Normal file
@ -0,0 +1,11 @@
|
||||
from pyrogram.api.types import InputPhoneContact as RawInputPhoneContact
|
||||
|
||||
|
||||
class InputPhoneContact:
|
||||
def __new__(cls, phone: str, first_name: str, last_name: str = ""):
|
||||
return RawInputPhoneContact(
|
||||
client_id=0,
|
||||
phone="+" + phone.strip("+"),
|
||||
first_name=first_name,
|
||||
last_name=last_name
|
||||
)
|
Loading…
x
Reference in New Issue
Block a user