-
Notifications
You must be signed in to change notification settings - Fork 0
/
functions.json
9039 lines (9039 loc) · 305 KB
/
functions.json
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
{
"invokeAfterMsg": {
"doc": "Invokes a query after successful completion of one of the previous queries.",
"parameters": {
"msg_id": {
"type": "long",
"doc": "Message identifier on which a current query depends"
},
"query": {
"type": "!X",
"doc": "The query itself"
}
}
},
"invokeAfterMsgs": {
"doc": "Invokes a query after a successful completion of previous queries",
"parameters": {
"msg_ids": {
"type": "Vector<long>",
"doc": "List of messages on which a current query depends"
},
"query": {
"type": "!X",
"doc": "The query itself"
}
}
},
"initConnection": {
"doc": "Initialize connection",
"parameters": {
"flags": {
"type": "#",
"doc": "Flags, see [TL conditional fields](https://core.telegram.org/mtproto/TL-combinators#conditional-fields)"
},
"api_id": {
"type": "int",
"doc": "Application identifier (see. [App configuration](https://core.telegram.org/myapp))"
},
"device_model": {
"type": "string",
"doc": "Device model"
},
"system_version": {
"type": "string",
"doc": "Operation system version"
},
"app_version": {
"type": "string",
"doc": "Application version"
},
"system_lang_code": {
"type": "string",
"doc": "Code for the language used on the device's OS, ISO 639-1 standard"
},
"lang_pack": {
"type": "string",
"doc": "Language pack to use"
},
"lang_code": {
"type": "string",
"doc": "Code for the language used on the client, ISO 639-1 standard"
},
"proxy": {
"type": "flags.0?InputClientProxy",
"doc": "Info about an MTProto proxy"
},
"params": {
"type": "flags.1?JSONValue",
"doc": "Additional initConnection parameters. \nFor now, only the `tz_offset` field is supported, for specifying timezone offset in seconds."
},
"query": {
"type": "!X",
"doc": "The query itself"
}
}
},
"invokeWithLayer": {
"doc": "Invoke the specified query using the specified API [layer](https://core.telegram.org/api/invoking#layers)",
"parameters": {
"layer": {
"type": "int",
"doc": "The layer to use"
},
"query": {
"type": "!X",
"doc": "The query"
}
}
},
"invokeWithoutUpdates": {
"doc": "Invoke a request without subscribing the used connection for [updates](https://core.telegram.org/api/updates) (this is enabled by default for [file queries](https://core.telegram.org/api/files)).",
"parameters": {
"query": {
"type": "!X",
"doc": "The query"
}
}
},
"invokeWithMessagesRange": {
"doc": "Invoke with the given message range",
"parameters": {
"range": {
"type": "MessageRange",
"doc": "Message range"
},
"query": {
"type": "!X",
"doc": "Query"
}
}
},
"invokeWithTakeout": {
"doc": "Invoke a method within a [takeout session, see here » for more info](https://core.telegram.org/api/takeout).",
"parameters": {
"takeout_id": {
"type": "long",
"doc": "[Takeout session ID »](https://core.telegram.org/api/takeout)"
},
"query": {
"type": "!X",
"doc": "Query"
}
}
},
"auth.sendCode": {
"doc": "Send the verification code for login",
"parameters": {
"phone_number": {
"type": "string",
"doc": "Phone number in international format"
},
"api_id": {
"type": "int",
"doc": "Application identifier (see [App configuration](https://core.telegram.org/myapp))"
},
"api_hash": {
"type": "string",
"doc": "Application secret hash (see [App configuration](https://core.telegram.org/myapp))"
},
"settings": {
"type": "CodeSettings",
"doc": "Settings for the code type to send"
}
}
},
"auth.signUp": {
"doc": "Registers a validated phone number in the system.",
"parameters": {
"phone_number": {
"type": "string",
"doc": "Phone number in the international format"
},
"phone_code_hash": {
"type": "string",
"doc": "SMS-message ID"
},
"first_name": {
"type": "string",
"doc": "New user first name"
},
"last_name": {
"type": "string",
"doc": "New user last name"
}
}
},
"auth.signIn": {
"doc": "Signs in a user with a validated phone number.",
"parameters": {
"flags": {
"type": "#",
"doc": "Flags, see [TL conditional fields](https://core.telegram.org/mtproto/TL-combinators#conditional-fields)"
},
"phone_number": {
"type": "string",
"doc": "Phone number in the international format"
},
"phone_code_hash": {
"type": "string",
"doc": "SMS-message ID, obtained from [auth.sendCode](https://core.telegram.org/method/auth.sendCode)"
},
"phone_code": {
"type": "flags.0?string",
"doc": "Valid numerical code from the SMS-message"
},
"email_verification": {
"type": "flags.1?EmailVerification",
"doc": "Email verification code or token"
}
}
},
"auth.logOut": {
"doc": "Logs out the user.",
"parameters": {}
},
"auth.resetAuthorizations": {
"doc": "Terminates all user's authorized sessions except for the current one.",
"parameters": {}
},
"auth.exportAuthorization": {
"doc": "Returns data for copying authorization to another data-center.",
"parameters": {
"dc_id": {
"type": "int",
"doc": "Number of a target data-center"
}
}
},
"auth.importAuthorization": {
"doc": "Logs in a user using a key transmitted from his native data-center.",
"parameters": {
"id": {
"type": "long",
"doc": "User ID"
},
"bytes": {
"type": "bytes",
"doc": "Authorization key"
}
}
},
"auth.bindTempAuthKey": {
"doc": "Binds a temporary authorization key `temp_auth_key_id` to the permanent authorization key `perm_auth_key_id`. Each permanent key may only be bound to one temporary key at a time, binding a new temporary key overwrites the previous one.",
"parameters": {
"perm_auth_key_id": {
"type": "long",
"doc": "Permanent auth\\_key\\_id to bind to"
},
"nonce": {
"type": "long",
"doc": "Random long from [Binding message contents](#binding-message-contents)"
},
"expires_at": {
"type": "int",
"doc": "Unix timestamp to invalidate temporary key, see [Binding message contents](#binding-message-contents)"
},
"encrypted_message": {
"type": "bytes",
"doc": "See [Generating encrypted\\_message](#generating-encrypted-message)"
}
}
},
"auth.importBotAuthorization": {
"doc": "Login as a bot",
"parameters": {
"flags": {
"type": "int",
"doc": "Reserved for future use"
},
"api_id": {
"type": "int",
"doc": "Application identifier (see. [App configuration](https://core.telegram.org/myapp))"
},
"api_hash": {
"type": "string",
"doc": "Application identifier hash (see. [App configuration](https://core.telegram.org/myapp))"
},
"bot_auth_token": {
"type": "string",
"doc": "Bot token (see [bots](https://core.telegram.org/bots))"
}
}
},
"auth.checkPassword": {
"doc": "Try logging to an account protected by a [2FA password](https://core.telegram.org/api/srp).",
"parameters": {
"password": {
"type": "InputCheckPasswordSRP",
"doc": "The account's password (see [SRP](https://core.telegram.org/api/srp))"
}
}
},
"auth.requestPasswordRecovery": {
"doc": "Request recovery code of a [2FA password](https://core.telegram.org/api/srp), only for accounts with a [recovery email configured](https://core.telegram.org/api/srp#email-verification).",
"parameters": {}
},
"auth.recoverPassword": {
"doc": "Reset the [2FA password](https://core.telegram.org/api/srp) using the recovery code sent using [auth.requestPasswordRecovery](https://core.telegram.org/method/auth.requestPasswordRecovery).",
"parameters": {
"flags": {
"type": "#",
"doc": "Flags, see [TL conditional fields](https://core.telegram.org/mtproto/TL-combinators#conditional-fields)"
},
"code": {
"type": "string",
"doc": "Code received via email"
},
"new_settings": {
"type": "flags.0?account.PasswordInputSettings",
"doc": "New password"
}
}
},
"auth.resendCode": {
"doc": "Resend the login code via another medium, the phone code type is determined by the return value of the previous auth.sendCode/auth.resendCode: see [login](https://core.telegram.org/api/auth) for more info.",
"parameters": {
"phone_number": {
"type": "string",
"doc": "The phone number"
},
"phone_code_hash": {
"type": "string",
"doc": "The phone code hash obtained from [auth.sendCode](https://core.telegram.org/method/auth.sendCode)"
}
}
},
"auth.cancelCode": {
"doc": "Cancel the login verification code",
"parameters": {
"phone_number": {
"type": "string",
"doc": "Phone number"
},
"phone_code_hash": {
"type": "string",
"doc": "Phone code hash from [auth.sendCode](https://core.telegram.org/method/auth.sendCode)"
}
}
},
"auth.dropTempAuthKeys": {
"doc": "Delete all temporary authorization keys **except for** the ones specified",
"parameters": {
"except_auth_keys": {
"type": "Vector<long>",
"doc": "The auth keys that **shouldn't** be dropped."
}
}
},
"auth.exportLoginToken": {
"doc": "Generate a login token, for [login via QR code](https://core.telegram.org/api/qr-login). \nThe generated login token should be encoded using base64url, then shown as a `tg://login?token=base64encodedtoken` [deep link »](https://core.telegram.org/api/links#qr-code-login-links) in the QR code.",
"parameters": {
"api_id": {
"type": "int",
"doc": "Application identifier (see. [App configuration](https://core.telegram.org/myapp))"
},
"api_hash": {
"type": "string",
"doc": "Application identifier hash (see. [App configuration](https://core.telegram.org/myapp))"
},
"except_ids": {
"type": "Vector<long>",
"doc": "List of already logged-in user IDs, to prevent logging in twice with the same user"
}
}
},
"auth.importLoginToken": {
"doc": "Login using a redirected login token, generated in case of DC mismatch during [QR code login](https://core.telegram.org/api/qr-login).",
"parameters": {
"token": {
"type": "bytes",
"doc": "Login token"
}
}
},
"auth.acceptLoginToken": {
"doc": "Accept QR code login token, logging in the app that generated it.",
"parameters": {
"token": {
"type": "bytes",
"doc": "Login token embedded in QR code, for more info, see [login via QR code](https://core.telegram.org/api/qr-login)."
}
}
},
"auth.checkRecoveryPassword": {
"doc": "Check if the [2FA recovery code](https://core.telegram.org/api/srp) sent using [auth.requestPasswordRecovery](https://core.telegram.org/method/auth.requestPasswordRecovery) is valid, before passing it to [auth.recoverPassword](https://core.telegram.org/method/auth.recoverPassword).",
"parameters": {
"code": {
"type": "string",
"doc": "Code received via email"
}
}
},
"auth.importWebTokenAuthorization": {
"doc": "Login by importing an authorization token",
"parameters": {
"api_id": {
"type": "int",
"doc": "[API ID](https://core.telegram.org/api/obtaining_api_id)"
},
"api_hash": {
"type": "string",
"doc": "[API hash](https://core.telegram.org/api/obtaining_api_id)"
},
"web_auth_token": {
"type": "string",
"doc": "The authorization token"
}
}
},
"auth.requestFirebaseSms": {
"doc": "Request an SMS code via Firebase.",
"parameters": {
"flags": {
"type": "#",
"doc": "Flags, see [TL conditional fields](https://core.telegram.org/mtproto/TL-combinators#conditional-fields)"
},
"phone_number": {
"type": "string",
"doc": "Phone number"
},
"phone_code_hash": {
"type": "string",
"doc": "Phone code hash returned by [auth.sendCode](https://core.telegram.org/method/auth.sendCode)"
},
"safety_net_token": {
"type": "flags.0?string",
"doc": "On Android, a JWS object obtained as described in the [auth documentation »](https://core.telegram.org/api/auth)"
},
"ios_push_secret": {
"type": "flags.1?string",
"doc": "Secret token received via an apple push notification"
}
}
},
"auth.resetLoginEmail": {
"doc": "Reset the [login email »](https://core.telegram.org/api/auth#email-verification).",
"parameters": {
"phone_number": {
"type": "string",
"doc": "Phone number of the account"
},
"phone_code_hash": {
"type": "string",
"doc": "Phone code hash, obtained as described in the [documentation »](https://core.telegram.org/api/auth)"
}
}
},
"account.registerDevice": {
"doc": "Register device to receive [PUSH notifications](https://core.telegram.org/api/push-updates)",
"parameters": {
"flags": {
"type": "#",
"doc": "Flags, see [TL conditional fields](https://core.telegram.org/mtproto/TL-combinators#conditional-fields)"
},
"no_muted": {
"type": "flags.0?true",
"doc": "Avoid receiving (silent and invisible background) notifications. Useful to save battery."
},
"token_type": {
"type": "int",
"doc": "Device token type, see [PUSH updates](https://core.telegram.org/api/push-updates#subscribing-to-notifications) for the possible values."
},
"token": {
"type": "string",
"doc": "Device token, see [PUSH updates](https://core.telegram.org/api/push-updates#subscribing-to-notifications) for the possible values."
},
"app_sandbox": {
"type": "Bool",
"doc": "If [(boolTrue)](https://core.telegram.org/constructor/boolTrue) is transmitted, a sandbox-certificate will be used during transmission."
},
"secret": {
"type": "bytes",
"doc": "For FCM and APNS VoIP, optional encryption key used to encrypt push notifications"
},
"other_uids": {
"type": "Vector<long>",
"doc": "List of user identifiers of other users currently using the client"
}
}
},
"account.unregisterDevice": {
"doc": "Deletes a device by its token, stops sending PUSH-notifications to it.",
"parameters": {
"token_type": {
"type": "int",
"doc": "Device token type, see [PUSH updates](https://core.telegram.org/api/push-updates#subscribing-to-notifications) for the possible values."
},
"token": {
"type": "string",
"doc": "Device token, see [PUSH updates](https://core.telegram.org/api/push-updates#subscribing-to-notifications) for the possible values."
},
"other_uids": {
"type": "Vector<long>",
"doc": "List of user identifiers of other users currently using the client"
}
}
},
"account.updateNotifySettings": {
"doc": "Edits notification settings from a given user/group, from all users/all groups.",
"parameters": {
"peer": {
"type": "InputNotifyPeer",
"doc": "Notification source"
},
"settings": {
"type": "InputPeerNotifySettings",
"doc": "Notification settings"
}
}
},
"account.getNotifySettings": {
"doc": "Gets current notification settings for a given user/group, from all users/all groups.",
"parameters": {
"peer": {
"type": "InputNotifyPeer",
"doc": "Notification source"
}
}
},
"account.resetNotifySettings": {
"doc": "Resets all notification settings from users and groups.",
"parameters": {}
},
"account.updateProfile": {
"doc": "Updates user profile.",
"parameters": {
"flags": {
"type": "#",
"doc": "Flags, see [TL conditional fields](https://core.telegram.org/mtproto/TL-combinators#conditional-fields)"
},
"first_name": {
"type": "flags.0?string",
"doc": "New user first name"
},
"last_name": {
"type": "flags.1?string",
"doc": "New user last name"
},
"about": {
"type": "flags.2?string",
"doc": "New bio"
}
}
},
"account.updateStatus": {
"doc": "Updates online user status.",
"parameters": {
"offline": {
"type": "Bool",
"doc": "If [(boolTrue)](https://core.telegram.org/constructor/boolTrue) is transmitted, user status will change to [(userStatusOffline)](https://core.telegram.org/constructor/userStatusOffline)."
}
}
},
"account.getWallPapers": {
"doc": "Returns a list of available [wallpapers](https://core.telegram.org/api/wallpapers).",
"parameters": {
"hash": {
"type": "long",
"doc": "[Hash for pagination, for more info click here](https://core.telegram.org/api/offsets#hash-generation)"
}
}
},
"account.reportPeer": {
"doc": "Report a peer for violation of telegram's Terms of Service",
"parameters": {
"peer": {
"type": "InputPeer",
"doc": "The peer to report"
},
"reason": {
"type": "ReportReason",
"doc": "The reason why this peer is being reported"
},
"message": {
"type": "string",
"doc": "Comment for report moderation"
}
}
},
"account.checkUsername": {
"doc": "Validates a username and checks availability.",
"parameters": {
"username": {
"type": "string",
"doc": "username \nAccepted characters: A-z (case-insensitive), 0-9 and underscores. \nLength: 5-32 characters."
}
}
},
"account.updateUsername": {
"doc": "Changes username for the current user.",
"parameters": {
"username": {
"type": "string",
"doc": "username or empty string if username is to be removed \nAccepted characters: a-z (case-insensitive), 0-9 and underscores. \nLength: 5-32 characters."
}
}
},
"account.getPrivacy": {
"doc": "Get privacy settings of current account",
"parameters": {
"key": {
"type": "InputPrivacyKey",
"doc": "Peer category whose privacy settings should be fetched"
}
}
},
"account.setPrivacy": {
"doc": "Change privacy settings of current account",
"parameters": {
"key": {
"type": "InputPrivacyKey",
"doc": "New privacy rule"
},
"rules": {
"type": "Vector<InputPrivacyRule>",
"doc": "Peers to which the privacy rule will apply."
}
}
},
"account.deleteAccount": {
"doc": "Delete the user's account from the telegram servers.",
"parameters": {
"flags": {
"type": "#",
"doc": "Flags, see [TL conditional fields](https://core.telegram.org/mtproto/TL-combinators#conditional-fields)"
},
"reason": {
"type": "string",
"doc": "Why is the account being deleted, can be empty"
},
"password": {
"type": "flags.0?InputCheckPasswordSRP",
"doc": "[2FA password](https://core.telegram.org/api/srp): this field can be omitted even for accounts with 2FA enabled: in this case account account deletion will be delayed by 7 days [as specified in the docs »](https://core.telegram.org/api/account-deletion)"
}
}
},
"account.getAccountTTL": {
"doc": "Get days to live of account",
"parameters": {}
},
"account.setAccountTTL": {
"doc": "Set account self-destruction period",
"parameters": {
"ttl": {
"type": "AccountDaysTTL",
"doc": "Time to live in days"
}
}
},
"account.sendChangePhoneCode": {
"doc": "Verify a new phone number to associate to the current account",
"parameters": {
"phone_number": {
"type": "string",
"doc": "New phone number"
},
"settings": {
"type": "CodeSettings",
"doc": "Phone code settings"
}
}
},
"account.changePhone": {
"doc": "Change the phone number of the current account",
"parameters": {
"phone_number": {
"type": "string",
"doc": "New phone number"
},
"phone_code_hash": {
"type": "string",
"doc": "Phone code hash received when calling [account.sendChangePhoneCode](https://core.telegram.org/method/account.sendChangePhoneCode)"
},
"phone_code": {
"type": "string",
"doc": "Phone code received when calling [account.sendChangePhoneCode](https://core.telegram.org/method/account.sendChangePhoneCode)"
}
}
},
"account.updateDeviceLocked": {
"doc": "When client-side passcode lock feature is enabled, will not show message texts in incoming [PUSH notifications](https://core.telegram.org/api/push-updates).",
"parameters": {
"period": {
"type": "int",
"doc": "Inactivity period after which to start hiding message texts in [PUSH notifications](https://core.telegram.org/api/push-updates)."
}
}
},
"account.getAuthorizations": {
"doc": "Get logged-in sessions",
"parameters": {}
},
"account.resetAuthorization": {
"doc": "Log out an active [authorized session](https://core.telegram.org/api/auth) by its hash",
"parameters": {
"hash": {
"type": "long",
"doc": "Session hash"
}
}
},
"account.getPassword": {
"doc": "Obtain configuration for two-factor authorization with password",
"parameters": {}
},
"account.getPasswordSettings": {
"doc": "Get private info associated to the password info (recovery email, telegram [passport](https://core.telegram.org/passport) info & so on)",
"parameters": {
"password": {
"type": "InputCheckPasswordSRP",
"doc": "The password (see [SRP](https://core.telegram.org/api/srp))"
}
}
},
"account.updatePasswordSettings": {
"doc": "Set a new 2FA password",
"parameters": {
"password": {
"type": "InputCheckPasswordSRP",
"doc": "The old password (see [SRP](https://core.telegram.org/api/srp))"
},
"new_settings": {
"type": "account.PasswordInputSettings",
"doc": "The new password (see [SRP](https://core.telegram.org/api/srp))"
}
}
},
"account.sendConfirmPhoneCode": {
"doc": "Send confirmation code to cancel account deletion, for more info [click here »](https://core.telegram.org/api/account-deletion)",
"parameters": {
"hash": {
"type": "string",
"doc": "The hash from the service notification, for more info [click here »](https://core.telegram.org/api/account-deletion)"
},
"settings": {
"type": "CodeSettings",
"doc": "Phone code settings"
}
}
},
"account.confirmPhone": {
"doc": "Confirm a phone number to cancel account deletion, for more info [click here »](https://core.telegram.org/api/account-deletion)",
"parameters": {
"phone_code_hash": {
"type": "string",
"doc": "Phone code hash, for more info [click here »](https://core.telegram.org/api/account-deletion)"
},
"phone_code": {
"type": "string",
"doc": "SMS code, for more info [click here »](https://core.telegram.org/api/account-deletion)"
}
}
},
"account.getTmpPassword": {
"doc": "Get temporary payment password",
"parameters": {
"password": {
"type": "InputCheckPasswordSRP",
"doc": "SRP password parameters"
},
"period": {
"type": "int",
"doc": "Time during which the temporary password will be valid, in seconds; should be between 60 and 86400"
}
}
},
"account.getWebAuthorizations": {
"doc": "Get web [login widget](https://core.telegram.org/widgets/login) authorizations",
"parameters": {}
},
"account.resetWebAuthorization": {
"doc": "Log out an active web [telegram login](https://core.telegram.org/widgets/login) session",
"parameters": {
"hash": {
"type": "long",
"doc": "[Session](https://core.telegram.org/constructor/webAuthorization) hash"
}
}
},
"account.resetWebAuthorizations": {
"doc": "Reset all active web [telegram login](https://core.telegram.org/widgets/login) sessions",
"parameters": {}
},
"account.getAllSecureValues": {
"doc": "Get all saved [Telegram Passport](https://core.telegram.org/passport) documents, [for more info see the passport docs »](https://core.telegram.org/passport/encryption#encryption)",
"parameters": {}
},
"account.getSecureValue": {
"doc": "Get saved [Telegram Passport](https://core.telegram.org/passport) document, [for more info see the passport docs »](https://core.telegram.org/passport/encryption#encryption)",
"parameters": {
"types": {
"type": "Vector<SecureValueType>",
"doc": "Requested value types"
}
}
},
"account.saveSecureValue": {
"doc": "Securely save [Telegram Passport](https://core.telegram.org/passport) document, [for more info see the passport docs »](https://core.telegram.org/passport/encryption#encryption)",
"parameters": {
"value": {
"type": "InputSecureValue",
"doc": "Secure value, [for more info see the passport docs »](https://core.telegram.org/passport/encryption#encryption)"
},
"secure_secret_id": {
"type": "long",
"doc": "Passport secret hash, [for more info see the passport docs »](https://core.telegram.org/passport/encryption#encryption)"
}
}
},
"account.deleteSecureValue": {
"doc": "Delete stored [Telegram Passport](https://core.telegram.org/passport) documents, [for more info see the passport docs »](https://core.telegram.org/passport/encryption#encryption)",
"parameters": {
"types": {
"type": "Vector<SecureValueType>",
"doc": "Document types to delete"
}
}
},
"account.getAuthorizationForm": {
"doc": "Returns a Telegram Passport authorization form for sharing data with a service",
"parameters": {
"bot_id": {
"type": "long",
"doc": "User identifier of the service's bot"
},
"scope": {
"type": "string",
"doc": "Telegram Passport element types requested by the service"
},
"public_key": {
"type": "string",
"doc": "Service's public key"
}
}
},
"account.acceptAuthorization": {
"doc": "Sends a Telegram Passport authorization form, effectively sharing data with the service",
"parameters": {
"bot_id": {
"type": "long",
"doc": "Bot ID"
},
"scope": {
"type": "string",
"doc": "Telegram Passport element types requested by the service"
},
"public_key": {
"type": "string",
"doc": "Service's public key"
},
"value_hashes": {
"type": "Vector<SecureValueHash>",
"doc": "Types of values sent and their hashes"
},
"credentials": {
"type": "SecureCredentialsEncrypted",
"doc": "Encrypted values"
}
}
},
"account.sendVerifyPhoneCode": {
"doc": "Send the verification phone code for telegram [passport](https://core.telegram.org/passport).",
"parameters": {
"phone_number": {
"type": "string",
"doc": "The phone number to verify"
},
"settings": {
"type": "CodeSettings",
"doc": "Phone code settings"
}
}
},
"account.verifyPhone": {
"doc": "Verify a phone number for telegram [passport](https://core.telegram.org/passport).",
"parameters": {
"phone_number": {
"type": "string",
"doc": "Phone number"
},
"phone_code_hash": {
"type": "string",
"doc": "Phone code hash received from the call to [account.sendVerifyPhoneCode](https://core.telegram.org/method/account.sendVerifyPhoneCode)"
},
"phone_code": {
"type": "string",
"doc": "Code received after the call to [account.sendVerifyPhoneCode](https://core.telegram.org/method/account.sendVerifyPhoneCode)"
}
}
},
"account.sendVerifyEmailCode": {
"doc": "Send an email verification code.",
"parameters": {
"purpose": {
"type": "EmailVerifyPurpose",
"doc": "Verification purpose."
},
"email": {
"type": "string",
"doc": "The email where to send the code."
}
}
},
"account.verifyEmail": {
"doc": "Verify an email address.",
"parameters": {
"purpose": {
"type": "EmailVerifyPurpose",
"doc": "Verification purpose"
},
"verification": {
"type": "EmailVerification",
"doc": "Email verification code or token"
}
}
},
"account.initTakeoutSession": {
"doc": "Initialize a [takeout session, see here » for more info](https://core.telegram.org/api/takeout).",
"parameters": {
"flags": {
"type": "#",
"doc": "Flags, see [TL conditional fields](https://core.telegram.org/mtproto/TL-combinators#conditional-fields)"
},
"contacts": {
"type": "flags.0?true",
"doc": "Whether to export contacts"
},
"message_users": {
"type": "flags.1?true",
"doc": "Whether to export messages in private chats"
},
"message_chats": {
"type": "flags.2?true",
"doc": "Whether to export messages in [basic groups](https://core.telegram.org/api/channel#basic-groups)"
},
"message_megagroups": {
"type": "flags.3?true",
"doc": "Whether to export messages in [supergroups](https://core.telegram.org/api/channel#supergroups)"
},
"message_channels": {
"type": "flags.4?true",
"doc": "Whether to export messages in [channels](https://core.telegram.org/api/channel#channels)"
},
"files": {
"type": "flags.5?true",
"doc": "Whether to export files"
},
"file_max_size": {
"type": "flags.5?long",
"doc": "Maximum size of files to export"
}
}
},
"account.finishTakeoutSession": {
"doc": "Terminate a [takeout session, see here » for more info](https://core.telegram.org/api/takeout).",
"parameters": {
"flags": {
"type": "#",
"doc": "Flags, see [TL conditional fields](https://core.telegram.org/mtproto/TL-combinators#conditional-fields)"
},
"success": {
"type": "flags.0?true",
"doc": "Data exported successfully"
}
}
},
"account.confirmPasswordEmail": {
"doc": "Verify an email to use as [2FA recovery method](https://core.telegram.org/api/srp).",
"parameters": {
"code": {
"type": "string",
"doc": "The phone code that was received after [setting a recovery email](https://core.telegram.org/api/srp#email-verification)"
}
}
},
"account.resendPasswordEmail": {
"doc": "Resend the code to verify an email to use as [2FA recovery method](https://core.telegram.org/api/srp).",
"parameters": {}
},
"account.cancelPasswordEmail": {
"doc": "Cancel the code that was sent to verify an email to use as [2FA recovery method](https://core.telegram.org/api/srp).",
"parameters": {}
},
"account.getContactSignUpNotification": {
"doc": "Whether the user will receive notifications when contacts sign up",
"parameters": {}
},
"account.setContactSignUpNotification": {
"doc": "Toggle contact sign up notifications",
"parameters": {
"silent": {
"type": "Bool",
"doc": "Whether to disable contact sign up notifications"
}
}
},
"account.getNotifyExceptions": {
"doc": "Returns list of chats with non-default notification settings",
"parameters": {
"flags": {
"type": "#",
"doc": "Flags, see [TL conditional fields](https://core.telegram.org/mtproto/TL-combinators#conditional-fields)"
},
"compare_sound": {
"type": "flags.1?true",
"doc": "If set, chats with non-default sound will be returned"
},
"compare_stories": {
"type": "flags.2?true",
"doc": "If set, chats with non-default notification settings for stories will be returned"
},
"peer": {
"type": "flags.0?InputNotifyPeer",
"doc": "If specified, only chats of the specified category will be returned"
}
}
},
"account.getWallPaper": {
"doc": "Get info about a certain [wallpaper](https://core.telegram.org/api/wallpapers)",
"parameters": {