maxapi-python 1.2.5__py3-none-any.whl → 2.0.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- maxapi_python-2.0.0.dist-info/METADATA +217 -0
- maxapi_python-2.0.0.dist-info/RECORD +140 -0
- {maxapi_python-1.2.5.dist-info → maxapi_python-2.0.0.dist-info}/WHEEL +1 -1
- pymax/__init__.py +50 -105
- pymax/api/__init__.py +17 -0
- pymax/api/auth/__init__.py +1 -0
- pymax/api/auth/enums.py +17 -0
- pymax/api/auth/payloads.py +129 -0
- pymax/api/auth/service.py +313 -0
- pymax/api/auth/types.py +13 -0
- pymax/api/chats/__init__.py +8 -0
- pymax/api/chats/enums.py +27 -0
- pymax/api/chats/payloads.py +103 -0
- pymax/api/chats/service.py +277 -0
- pymax/api/facade.py +32 -0
- pymax/api/messages/__init__.py +1 -0
- pymax/api/messages/enums.py +17 -0
- pymax/api/messages/payloads.py +92 -0
- pymax/api/messages/service.py +337 -0
- pymax/api/models.py +13 -0
- pymax/api/response.py +123 -0
- pymax/api/self/__init__.py +2 -0
- pymax/api/self/enums.py +11 -0
- pymax/api/self/payloads.py +41 -0
- pymax/api/self/service.py +142 -0
- pymax/api/session/__init__.py +1 -0
- pymax/api/session/enums.py +10 -0
- pymax/api/session/payloads.py +76 -0
- pymax/api/session/service.py +72 -0
- pymax/api/uploads/__init__.py +1 -0
- pymax/api/uploads/models.py +49 -0
- pymax/api/uploads/payloads.py +25 -0
- pymax/api/uploads/service.py +458 -0
- pymax/api/users/__init__.py +2 -0
- pymax/api/users/enums.py +12 -0
- pymax/api/users/payloads.py +16 -0
- pymax/api/users/service.py +124 -0
- pymax/app.py +273 -0
- pymax/auth/__init__.py +25 -0
- pymax/auth/base.py +37 -0
- pymax/auth/email.py +0 -0
- pymax/auth/models.py +5 -0
- pymax/auth/providers.py +127 -0
- pymax/auth/qr.py +135 -0
- pymax/auth/service.py +25 -0
- pymax/auth/sms.py +122 -0
- pymax/base.py +204 -0
- pymax/client.py +106 -0
- pymax/client_web.py +83 -0
- pymax/config.py +215 -0
- pymax/connection/__init__.py +1 -0
- pymax/connection/connection.py +205 -0
- pymax/connection/pending.py +46 -0
- pymax/connection/readers/__init__.py +2 -0
- pymax/connection/readers/base.py +6 -0
- pymax/connection/readers/tcp.py +29 -0
- pymax/connection/readers/ws.py +14 -0
- pymax/dispatch/__init__.py +10 -0
- pymax/dispatch/dispatcher.py +222 -0
- pymax/dispatch/enums.py +12 -0
- pymax/dispatch/mapping.py +73 -0
- pymax/dispatch/resolvers.py +52 -0
- pymax/dispatch/router.py +216 -0
- pymax/exceptions.py +22 -89
- pymax/files/__init__.py +9 -0
- pymax/files/base.py +82 -0
- pymax/files/file.py +76 -0
- pymax/files/photo.py +108 -0
- pymax/files/static.py +10 -0
- pymax/files/video.py +74 -0
- pymax/formatting/__init__.py +0 -0
- pymax/formatting/markdown.py +217 -0
- pymax/infra/__init__.py +1 -0
- pymax/infra/auth.py +55 -0
- pymax/infra/base.py +15 -0
- pymax/infra/chat.py +240 -0
- pymax/infra/message.py +252 -0
- pymax/infra/protocol.py +9 -0
- pymax/infra/self.py +139 -0
- pymax/infra/user.py +107 -0
- pymax/logging.py +129 -0
- pymax/protocol/__init__.py +11 -0
- pymax/protocol/base.py +13 -0
- pymax/protocol/enums.py +180 -0
- pymax/protocol/models.py +33 -0
- pymax/protocol/tcp/__init__.py +1 -0
- pymax/protocol/tcp/compression.py +97 -0
- pymax/protocol/tcp/framing.py +68 -0
- pymax/protocol/tcp/payload.py +127 -0
- pymax/protocol/tcp/protocol.py +68 -0
- pymax/protocol/ws/__init__.py +1 -0
- pymax/protocol/ws/protocol.py +27 -0
- pymax/py.typed +0 -0
- pymax/routers.py +8 -0
- pymax/session/__init__.py +3 -0
- pymax/session/models.py +11 -0
- pymax/session/protocol.py +14 -0
- pymax/session/store.py +232 -0
- pymax/telemetry/__init__.py +3 -0
- pymax/telemetry/navigation.py +181 -0
- pymax/telemetry/payloads.py +142 -0
- pymax/telemetry/service.py +225 -0
- pymax/transport/__init__.py +0 -0
- pymax/transport/base.py +14 -0
- pymax/transport/tcp.py +93 -0
- pymax/transport/websocket.py +50 -0
- pymax/types/__init__.py +2 -0
- pymax/types/domain/__init__.py +11 -0
- pymax/types/domain/attachments/__init__.py +11 -0
- pymax/types/domain/attachments/audio.py +35 -0
- pymax/types/domain/attachments/call.py +26 -0
- pymax/types/domain/attachments/contact.py +32 -0
- pymax/types/domain/attachments/control.py +20 -0
- pymax/types/domain/attachments/enums.py +27 -0
- pymax/types/domain/attachments/file.py +56 -0
- pymax/types/domain/attachments/keyboards/__init__.py +1 -0
- pymax/types/domain/attachments/keyboards/inline.py +19 -0
- pymax/types/domain/attachments/photo.py +45 -0
- pymax/types/domain/attachments/share.py +29 -0
- pymax/types/domain/attachments/sticker.py +50 -0
- pymax/types/domain/attachments/video.py +90 -0
- pymax/types/domain/auth.py +161 -0
- pymax/types/domain/base.py +17 -0
- pymax/types/domain/chat.py +426 -0
- pymax/types/domain/element.py +24 -0
- pymax/types/domain/enums.py +24 -0
- pymax/types/domain/error.py +20 -0
- pymax/types/domain/folder.py +74 -0
- pymax/types/domain/login.py +35 -0
- pymax/types/domain/message.py +378 -0
- pymax/types/domain/name.py +20 -0
- pymax/types/domain/profile.py +15 -0
- pymax/types/domain/session.py +52 -0
- pymax/types/domain/sync.py +80 -0
- pymax/types/domain/user.py +117 -0
- pymax/types/events/__init__.py +3 -0
- pymax/types/events/file.py +5 -0
- pymax/types/events/message.py +37 -0
- pymax/types/events/video.py +5 -0
- maxapi_python-1.2.5.dist-info/METADATA +0 -202
- maxapi_python-1.2.5.dist-info/RECORD +0 -33
- pymax/core.py +0 -398
- pymax/crud.py +0 -96
- pymax/files.py +0 -138
- pymax/filters.py +0 -164
- pymax/formatter.py +0 -31
- pymax/formatting.py +0 -74
- pymax/interfaces.py +0 -558
- pymax/mixins/__init__.py +0 -40
- pymax/mixins/auth.py +0 -594
- pymax/mixins/channel.py +0 -130
- pymax/mixins/group.py +0 -458
- pymax/mixins/handler.py +0 -285
- pymax/mixins/message.py +0 -879
- pymax/mixins/scheduler.py +0 -28
- pymax/mixins/self.py +0 -259
- pymax/mixins/socket.py +0 -306
- pymax/mixins/telemetry.py +0 -118
- pymax/mixins/user.py +0 -219
- pymax/mixins/websocket.py +0 -151
- pymax/models.py +0 -8
- pymax/navigation.py +0 -187
- pymax/payloads.py +0 -403
- pymax/protocols.py +0 -123
- pymax/static/constant.py +0 -96
- pymax/static/enum.py +0 -231
- pymax/types.py +0 -1220
- pymax/utils.py +0 -90
- {maxapi_python-1.2.5.dist-info → maxapi_python-2.0.0.dist-info}/licenses/LICENSE +0 -0
pymax/static/enum.py
DELETED
|
@@ -1,231 +0,0 @@
|
|
|
1
|
-
from enum import Enum
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
class Opcode(int, Enum):
|
|
5
|
-
PING = 1 # ✅
|
|
6
|
-
DEBUG = 2
|
|
7
|
-
RECONNECT = 3
|
|
8
|
-
LOG = 5 # ✅
|
|
9
|
-
SESSION_INIT = 6 # ✅
|
|
10
|
-
PROFILE = 16 # ✅
|
|
11
|
-
AUTH_REQUEST = 17 # ✅
|
|
12
|
-
AUTH = 18 # ✅
|
|
13
|
-
LOGIN = 19 # ✅
|
|
14
|
-
LOGOUT = 20 # ✅
|
|
15
|
-
SYNC = 21
|
|
16
|
-
CONFIG = 22
|
|
17
|
-
AUTH_CONFIRM = 23 # ✅
|
|
18
|
-
PRESET_AVATARS = 25
|
|
19
|
-
ASSETS_GET = 26
|
|
20
|
-
ASSETS_UPDATE = 27
|
|
21
|
-
ASSETS_GET_BY_IDS = 28
|
|
22
|
-
ASSETS_ADD = 29
|
|
23
|
-
SEARCH_FEEDBACK = 31
|
|
24
|
-
CONTACT_INFO = 32 # ✅
|
|
25
|
-
CONTACT_ADD = 33
|
|
26
|
-
CONTACT_UPDATE = 34 # ✅
|
|
27
|
-
CONTACT_PRESENCE = 35
|
|
28
|
-
CONTACT_LIST = 36
|
|
29
|
-
CONTACT_SEARCH = 37
|
|
30
|
-
CONTACT_MUTUAL = 38
|
|
31
|
-
CONTACT_PHOTOS = 39
|
|
32
|
-
CONTACT_SORT = 40
|
|
33
|
-
CONTACT_VERIFY = 42
|
|
34
|
-
REMOVE_CONTACT_PHOTO = 43
|
|
35
|
-
CONTACT_INFO_BY_PHONE = 46 # ✅
|
|
36
|
-
CHAT_INFO = 48 # ✅
|
|
37
|
-
CHAT_HISTORY = 49 # ✅
|
|
38
|
-
CHAT_MARK = 50 # ✅
|
|
39
|
-
CHAT_MEDIA = 51
|
|
40
|
-
CHAT_DELETE = 52
|
|
41
|
-
CHATS_LIST = 53 # ✅
|
|
42
|
-
CHAT_CLEAR = 54
|
|
43
|
-
CHAT_UPDATE = 55 # ✅
|
|
44
|
-
CHAT_CHECK_LINK = 56
|
|
45
|
-
CHAT_JOIN = 57 # ✅
|
|
46
|
-
CHAT_LEAVE = 58 # ✅
|
|
47
|
-
CHAT_MEMBERS = 59 # ✅
|
|
48
|
-
PUBLIC_SEARCH = 60
|
|
49
|
-
CHAT_CLOSE = 61
|
|
50
|
-
CHAT_CREATE = 63
|
|
51
|
-
MSG_SEND = 64 # ✅
|
|
52
|
-
MSG_TYPING = 65
|
|
53
|
-
MSG_DELETE = 66 # ✅
|
|
54
|
-
MSG_EDIT = 67 # ✅
|
|
55
|
-
CHAT_SEARCH = 68
|
|
56
|
-
MSG_SHARE_PREVIEW = 70
|
|
57
|
-
MSG_GET = 71
|
|
58
|
-
MSG_SEARCH_TOUCH = 72
|
|
59
|
-
MSG_SEARCH = 73
|
|
60
|
-
MSG_GET_STAT = 74
|
|
61
|
-
CHAT_SUBSCRIBE = 75
|
|
62
|
-
VIDEO_CHAT_START = 76
|
|
63
|
-
CHAT_MEMBERS_UPDATE = 77 # ✅
|
|
64
|
-
VIDEO_CHAT_HISTORY = 79
|
|
65
|
-
PHOTO_UPLOAD = 80 # ✅
|
|
66
|
-
STICKER_UPLOAD = 81
|
|
67
|
-
VIDEO_UPLOAD = 82 # ✅
|
|
68
|
-
VIDEO_PLAY = 83 # ✅
|
|
69
|
-
CHAT_PIN_SET_VISIBILITY = 86
|
|
70
|
-
FILE_UPLOAD = 87 # ✅
|
|
71
|
-
FILE_DOWNLOAD = 88 # ✅
|
|
72
|
-
LINK_INFO = 89 # ✅
|
|
73
|
-
MSG_DELETE_RANGE = 92
|
|
74
|
-
SESSIONS_INFO = 96 # ✅
|
|
75
|
-
SESSIONS_CLOSE = 97 # ✅
|
|
76
|
-
PHONE_BIND_REQUEST = 98
|
|
77
|
-
PHONE_BIND_CONFIRM = 99
|
|
78
|
-
CONFIRM_PRESENT = 101
|
|
79
|
-
GET_INBOUND_CALLS = 103
|
|
80
|
-
EXTERNAL_CALLBACK = 105
|
|
81
|
-
AUTH_VALIDATE_PASSWORD = 107 # ✅
|
|
82
|
-
AUTH_VALIDATE_HINT = 108 # ✅
|
|
83
|
-
AUTH_VERIFY_EMAIL = 109 # ✅
|
|
84
|
-
AUTH_CHECK_EMAIL = 110 # ✅
|
|
85
|
-
AUTH_SET_2FA = 111 # ✅
|
|
86
|
-
AUTH_CREATE_TRACK = 112 # ✅
|
|
87
|
-
AUTH_LOGIN_CHECK_PASSWORD = 115 # ✅
|
|
88
|
-
CHAT_COMPLAIN = 117
|
|
89
|
-
MSG_SEND_CALLBACK = 118
|
|
90
|
-
SUSPEND_BOT = 119
|
|
91
|
-
LOCATION_STOP = 124
|
|
92
|
-
LOCATION_SEND = 125
|
|
93
|
-
LOCATION_REQUEST = 126
|
|
94
|
-
GET_LAST_MENTIONS = 127
|
|
95
|
-
NOTIF_MESSAGE = 128 # ✅
|
|
96
|
-
NOTIF_TYPING = 129
|
|
97
|
-
NOTIF_MARK = 130
|
|
98
|
-
NOTIF_CONTACT = 131
|
|
99
|
-
NOTIF_PRESENCE = 132
|
|
100
|
-
NOTIF_CONFIG = 134
|
|
101
|
-
NOTIF_CHAT = 135 # ✅
|
|
102
|
-
NOTIF_ATTACH = 136 # ✅
|
|
103
|
-
NOTIF_CALL_START = 137
|
|
104
|
-
NOTIF_CONTACT_SORT = 139
|
|
105
|
-
NOTIF_MSG_DELETE_RANGE = 140
|
|
106
|
-
NOTIF_MSG_DELETE = 142
|
|
107
|
-
NOTIF_CALLBACK_ANSWER = 143
|
|
108
|
-
CHAT_BOT_COMMANDS = 144
|
|
109
|
-
BOT_INFO = 145
|
|
110
|
-
NOTIF_LOCATION = 147
|
|
111
|
-
NOTIF_LOCATION_REQUEST = 148
|
|
112
|
-
NOTIF_ASSETS_UPDATE = 150
|
|
113
|
-
NOTIF_DRAFT = 152
|
|
114
|
-
NOTIF_DRAFT_DISCARD = 153
|
|
115
|
-
NOTIF_MSG_DELAYED = 154
|
|
116
|
-
NOTIF_MSG_REACTIONS_CHANGED = 155 # ✅
|
|
117
|
-
NOTIF_MSG_YOU_REACTED = 156
|
|
118
|
-
CALLS_TOKEN = 158
|
|
119
|
-
NOTIF_PROFILE = 159
|
|
120
|
-
WEB_APP_INIT_DATA = 160
|
|
121
|
-
DRAFT_SAVE = 176
|
|
122
|
-
DRAFT_DISCARD = 177
|
|
123
|
-
MSG_REACTION = 178 # ✅
|
|
124
|
-
MSG_CANCEL_REACTION = 179 # ✅
|
|
125
|
-
MSG_GET_REACTIONS = 180 # ✅
|
|
126
|
-
MSG_GET_DETAILED_REACTIONS = 181
|
|
127
|
-
STICKER_CREATE = 193
|
|
128
|
-
STICKER_SUGGEST = 194
|
|
129
|
-
VIDEO_CHAT_MEMBERS = 195
|
|
130
|
-
CHAT_HIDE = 196
|
|
131
|
-
CHAT_SEARCH_COMMON_PARTICIPANTS = 198
|
|
132
|
-
PROFILE_DELETE = 199
|
|
133
|
-
PROFILE_DELETE_TIME = 200
|
|
134
|
-
ASSETS_REMOVE = 259
|
|
135
|
-
ASSETS_MOVE = 260
|
|
136
|
-
ASSETS_LIST_MODIFY = 261
|
|
137
|
-
FOLDERS_GET = 272 # ✅
|
|
138
|
-
FOLDERS_GET_BY_ID = 273
|
|
139
|
-
FOLDERS_UPDATE = 274 # ✅
|
|
140
|
-
FOLDERS_REORDER = 275
|
|
141
|
-
FOLDERS_DELETE = 276 # ✅
|
|
142
|
-
NOTIF_FOLDERS = 277
|
|
143
|
-
|
|
144
|
-
GET_QR = 288 # ✅
|
|
145
|
-
GET_QR_STATUS = 289 # ✅
|
|
146
|
-
LOGIN_BY_QR = 291 # ✅
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
class ChatType(str, Enum):
|
|
150
|
-
DIALOG = "DIALOG"
|
|
151
|
-
CHAT = "CHAT"
|
|
152
|
-
CHANNEL = "CHANNEL"
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
class MessageType(str, Enum):
|
|
156
|
-
TEXT = "TEXT"
|
|
157
|
-
SYSTEM = "SYSTEM"
|
|
158
|
-
SERVICE = "SERVICE"
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
class MessageStatus(str, Enum):
|
|
162
|
-
EDITED = "EDITED"
|
|
163
|
-
REMOVED = "REMOVED"
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
class ElementType(str, Enum):
|
|
167
|
-
TEXT = "text"
|
|
168
|
-
MENTION = "mention"
|
|
169
|
-
LINK = "link"
|
|
170
|
-
EMOJI = "emoji"
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
class AuthType(str, Enum):
|
|
174
|
-
START_AUTH = "START_AUTH"
|
|
175
|
-
CHECK_CODE = "CHECK_CODE"
|
|
176
|
-
REGISTER = "REGISTER"
|
|
177
|
-
RESEND = "RESEND"
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
class AccessType(str, Enum):
|
|
181
|
-
PUBLIC = "PUBLIC"
|
|
182
|
-
PRIVATE = "PRIVATE"
|
|
183
|
-
SECRET = "SECRET" # nosec B105
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
class DeviceType(str, Enum):
|
|
187
|
-
WEB = "WEB"
|
|
188
|
-
ANDROID = "ANDROID"
|
|
189
|
-
IOS = "IOS"
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
class AttachType(str, Enum):
|
|
193
|
-
PHOTO = "PHOTO"
|
|
194
|
-
VIDEO = "VIDEO"
|
|
195
|
-
FILE = "FILE"
|
|
196
|
-
STICKER = "STICKER"
|
|
197
|
-
AUDIO = "AUDIO"
|
|
198
|
-
CONTROL = "CONTROL"
|
|
199
|
-
CONTACT = "CONTACT"
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
class FormattingType(str, Enum):
|
|
203
|
-
STRONG = "STRONG"
|
|
204
|
-
EMPHASIZED = "EMPHASIZED"
|
|
205
|
-
UNDERLINE = "UNDERLINE"
|
|
206
|
-
STRIKETHROUGH = "STRIKETHROUGH"
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
class MarkupType(str, Enum):
|
|
210
|
-
BOLD = "**"
|
|
211
|
-
ITALIC = "*"
|
|
212
|
-
UNDERLINE = "__"
|
|
213
|
-
STRIKETHROUGH = "~~"
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
class ContactAction(str, Enum):
|
|
217
|
-
ADD = "ADD"
|
|
218
|
-
REMOVE = "REMOVE"
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
class ReadAction(str, Enum):
|
|
222
|
-
READ_MESSAGE = "READ_MESSAGE"
|
|
223
|
-
READ_REACTION = "READ_REACTION"
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
class Capability(int, Enum):
|
|
227
|
-
DEFAULT = 0 # В душе не чаю что это такое но при первой установке 2фа там 0 3 4 так что пусть будет дефолт
|
|
228
|
-
ESIA_VERIFIED_FLAG = 1
|
|
229
|
-
SECOND_FACTOR_PASSWORD_ENABLED = 2
|
|
230
|
-
SECOND_FACTOR_HAS_EMAIL = 3
|
|
231
|
-
SECOND_FACTOR_HAS_HINT = 4
|