This repository was archived by the owner on Apr 6, 2026. It is now read-only.
File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -342,7 +342,7 @@ def get_contact_details(self, contact_ids: list):
342342 payload = {"contactIds" : contact_ids }
343343 return self .send_command (self .OPCODE_MAP ['GET_CONTACT_DETAILS' ], payload )
344344
345- def get_conatct_by_phone (self , phone_number : str ):
345+ def get_contact_by_phone (self , phone_number : str ):
346346 payload = {"phone" : phone_number }
347347 return self .send_command (self .OPCODE_MAP ['FIND_BY_PHONE_NUMBER' ], payload )
348348
Original file line number Diff line number Diff line change @@ -87,4 +87,25 @@ api = MaxAPI(auth_token)
8787 api.get_file(id = 12345678 , chat_id = 12345678 , msg_id = " 12345678" )
8888 ```
8989
90+ 6 . ** Finding Contact by Phone Number:**
91+
92+ To find a contact by their phone number, use:
93+ ``` python
94+ api.get_contact_by_phone(phone_number = " +12345678901" )
95+ ```
96+
97+ 7 . ** Getting Chat by ID:**
98+
99+ To retrieve a specific chat by its ID, use:
100+ ``` python
101+ api.get_chat_by_id(chat_id = " 12345678" )
102+ ```
103+
104+ 8 . ** Getting All Chats:**
105+
106+ To retrieve all available chats, use:
107+ ``` python
108+ api.get_all_chats()
109+ ```
110+
90111The chat ID is required for most operations. You can obtain it from the chat URL or through other means specific to your application.
You can’t perform that action at this time.
0 commit comments