@tgsnake/skema 2.1.0 → 2.2.0-browser.0
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.
- package/dist/src/deps.d.ts +4 -3
- package/dist/src/deps.js +4 -4
- package/dist/src/errors/exceptions/All.d.ts +41 -1
- package/dist/src/errors/exceptions/All.js +41 -1
- package/dist/src/errors/exceptions/BadRequest400.d.ts +124 -0
- package/dist/src/errors/exceptions/BadRequest400.js +143 -19
- package/dist/src/errors/exceptions/Forbidden403.d.ts +24 -0
- package/dist/src/errors/exceptions/Forbidden403.js +24 -0
- package/dist/src/errors/exceptions/InternalServerError500.d.ts +8 -0
- package/dist/src/errors/exceptions/InternalServerError500.js +8 -0
- package/dist/src/errors/exceptions/NotAcceptable406.d.ts +4 -0
- package/dist/src/errors/exceptions/NotAcceptable406.js +4 -0
- package/package.json +54 -52
|
@@ -57,6 +57,18 @@ export class AdExpired extends BadRequest {
|
|
|
57
57
|
id = 'AD_EXPIRED';
|
|
58
58
|
message = 'The ad has expired (too old or not found).';
|
|
59
59
|
}
|
|
60
|
+
export class AicomposeToneInvalid extends BadRequest {
|
|
61
|
+
id = 'AICOMPOSE_TONE_INVALID';
|
|
62
|
+
message = 'The specified tone is invalid.';
|
|
63
|
+
}
|
|
64
|
+
export class AicomposeToneTitleInvalid extends BadRequest {
|
|
65
|
+
id = 'AICOMPOSE_TONE_TITLE_INVALID';
|
|
66
|
+
message = 'The specified tone title is invalid.';
|
|
67
|
+
}
|
|
68
|
+
export class AiComposeTaskMissing extends BadRequest {
|
|
69
|
+
id = 'AI_COMPOSE_TASK_MISSING';
|
|
70
|
+
message = '';
|
|
71
|
+
}
|
|
60
72
|
export class AlbumPhotosTooMany extends BadRequest {
|
|
61
73
|
id = 'ALBUM_PHOTOS_TOO_MANY';
|
|
62
74
|
message = 'You have uploaded too many profile photos, delete some before retrying.';
|
|
@@ -125,6 +137,10 @@ export class BasePortLocInvalid extends BadRequest {
|
|
|
125
137
|
id = 'BASE_PORT_LOC_INVALID';
|
|
126
138
|
message = 'The base port location is invalid';
|
|
127
139
|
}
|
|
140
|
+
export class BirthdayAlready extends BadRequest {
|
|
141
|
+
id = 'BIRTHDAY_ALREADY';
|
|
142
|
+
message = 'The target user already has a birthday set.';
|
|
143
|
+
}
|
|
128
144
|
export class BirthdayInvalid extends BadRequest {
|
|
129
145
|
id = 'BIRTHDAY_INVALID';
|
|
130
146
|
message = 'An invalid age was specified, must be between 0 and 150 years.';
|
|
@@ -181,6 +197,10 @@ export class BotCommandInvalid extends BadRequest {
|
|
|
181
197
|
id = 'BOT_COMMAND_INVALID';
|
|
182
198
|
message = 'The specified command is invalid.';
|
|
183
199
|
}
|
|
200
|
+
export class BotCreateLimitExceeded extends BadRequest {
|
|
201
|
+
id = 'BOT_CREATE_LIMIT_EXCEEDED';
|
|
202
|
+
message = "The current user already owns the maximum allowed number of owned bots, as specified by [`bots_create_limit_default` »](https://core.telegram.org/api/config#bots-create-limit-default) and [`bots_create_limit_premium` »](https://core.telegram.org/api/config#bots-create-limit-premium); if the current user doesn't have Telegram Premium, upgrading to Premium will allow them to create more bots. .";
|
|
203
|
+
}
|
|
184
204
|
export class BotDomainInvalid extends BadRequest {
|
|
185
205
|
id = 'BOT_DOMAIN_INVALID';
|
|
186
206
|
message = 'Bot domain invalid.';
|
|
@@ -197,6 +217,10 @@ export class BotGroupsBlocked extends BadRequest {
|
|
|
197
217
|
id = 'BOT_GROUPS_BLOCKED';
|
|
198
218
|
message = "This bot can't be added to groups.";
|
|
199
219
|
}
|
|
220
|
+
export class BotIdInvalid extends BadRequest {
|
|
221
|
+
id = 'BOT_ID_INVALID';
|
|
222
|
+
message = 'The specified bot ID is invalid.';
|
|
223
|
+
}
|
|
200
224
|
export class BotInlineDisabled extends BadRequest {
|
|
201
225
|
id = 'BOT_INLINE_DISABLED';
|
|
202
226
|
message = "This bot can't be used in inline mode.";
|
|
@@ -333,6 +357,10 @@ export class CallAlreadyDeclined extends BadRequest {
|
|
|
333
357
|
id = 'CALL_ALREADY_DECLINED';
|
|
334
358
|
message = 'The call was already declined.';
|
|
335
359
|
}
|
|
360
|
+
export class CallNotActive extends BadRequest {
|
|
361
|
+
id = 'CALL_NOT_ACTIVE';
|
|
362
|
+
message = 'The specified call is not active.';
|
|
363
|
+
}
|
|
336
364
|
export class CallOccupyFailed extends BadRequest {
|
|
337
365
|
id = 'CALL_OCCUPY_FAILED';
|
|
338
366
|
message = 'The call failed because the user is already making another call.';
|
|
@@ -509,6 +537,10 @@ export class ChatTooBig extends BadRequest {
|
|
|
509
537
|
id = 'CHAT_TOO_BIG';
|
|
510
538
|
message = 'This method is not available for groups with more than `chat_read_mark_size_threshold` members, [see client configuration »](https://core.telegram.org/api/config#client-configuration).';
|
|
511
539
|
}
|
|
540
|
+
export class ChatWriteForbidden extends BadRequest {
|
|
541
|
+
id = 'CHAT_WRITE_FORBIDDEN';
|
|
542
|
+
message = "You can't write in this chat.";
|
|
543
|
+
}
|
|
512
544
|
export class CodeEmpty extends BadRequest {
|
|
513
545
|
id = 'CODE_EMPTY';
|
|
514
546
|
message = 'The provided code is empty.';
|
|
@@ -531,7 +563,7 @@ export class CollectibleNotFound extends BadRequest {
|
|
|
531
563
|
}
|
|
532
564
|
export class CollectionIdInvalid extends BadRequest {
|
|
533
565
|
id = 'COLLECTION_ID_INVALID';
|
|
534
|
-
message = '';
|
|
566
|
+
message = 'The specified collection ID is invalid.';
|
|
535
567
|
}
|
|
536
568
|
export class ColorInvalid extends BadRequest {
|
|
537
569
|
id = 'COLOR_INVALID';
|
|
@@ -599,7 +631,7 @@ export class CreateCallFailed extends BadRequest {
|
|
|
599
631
|
}
|
|
600
632
|
export class CredentialInvalid extends BadRequest {
|
|
601
633
|
id = 'CREDENTIAL_INVALID';
|
|
602
|
-
message = '';
|
|
634
|
+
message = 'The specified credential is invalid.';
|
|
603
635
|
}
|
|
604
636
|
export class CurrencyTotalAmountInvalid extends BadRequest {
|
|
605
637
|
id = 'CURRENCY_TOTAL_AMOUNT_INVALID';
|
|
@@ -655,7 +687,7 @@ export class EmailHashExpired extends BadRequest {
|
|
|
655
687
|
}
|
|
656
688
|
export class EmailInstallMissing extends BadRequest {
|
|
657
689
|
id = 'EMAIL_INSTALL_MISSING';
|
|
658
|
-
message = '';
|
|
690
|
+
message = 'Attempting to send a code to the recovery email, but no email is configured.';
|
|
659
691
|
}
|
|
660
692
|
export class EmailInvalid extends BadRequest {
|
|
661
693
|
id = 'EMAIL_INVALID';
|
|
@@ -733,6 +765,18 @@ export class EntityBoundsInvalid extends BadRequest {
|
|
|
733
765
|
id = 'ENTITY_BOUNDS_INVALID';
|
|
734
766
|
message = 'A specified [entity offset or length](https://core.telegram.org/api/entities#entity-length) is invalid, see [here »](https://core.telegram.org/api/entities#entity-length) for info on how to properly compute the entity offset/length.';
|
|
735
767
|
}
|
|
768
|
+
export class EntityDateFormatInvalid extends BadRequest {
|
|
769
|
+
id = 'ENTITY_DATE_FORMAT_INVALID';
|
|
770
|
+
message = 'One of the passed messageEntityFormattedDate objects has an invalid format (i.e. an invalid combination of the format flags).';
|
|
771
|
+
}
|
|
772
|
+
export class EntityDateInvalid extends BadRequest {
|
|
773
|
+
id = 'ENTITY_DATE_INVALID';
|
|
774
|
+
message = 'One of the passed messageEntityFormattedDate objects has an invalid date: the allowed value ranges from `0` to the current date plus 1098 days (`time()+1098*86400`).';
|
|
775
|
+
}
|
|
776
|
+
export class EntityDateTooLong extends BadRequest {
|
|
777
|
+
id = 'ENTITY_DATE_TOO_LONG';
|
|
778
|
+
message = '';
|
|
779
|
+
}
|
|
736
780
|
export class EntityMentionUserInvalid extends BadRequest {
|
|
737
781
|
id = 'ENTITY_MENTION_USER_INVALID';
|
|
738
782
|
message = 'You mentioned an invalid user.';
|
|
@@ -759,12 +803,16 @@ export class ExtendedMediaAmountInvalid extends BadRequest {
|
|
|
759
803
|
}
|
|
760
804
|
export class ExtendedMediaEmpty extends BadRequest {
|
|
761
805
|
id = 'EXTENDED_MEDIA_EMPTY';
|
|
762
|
-
message = '';
|
|
806
|
+
message = 'The specified extended media is empty.';
|
|
763
807
|
}
|
|
764
808
|
export class ExtendedMediaInvalid extends BadRequest {
|
|
765
809
|
id = 'EXTENDED_MEDIA_INVALID';
|
|
766
810
|
message = 'The specified paid media is invalid.';
|
|
767
811
|
}
|
|
812
|
+
export class ExtendedMediaPeerInvalid extends BadRequest {
|
|
813
|
+
id = 'EXTENDED_MEDIA_PEER_INVALID';
|
|
814
|
+
message = '';
|
|
815
|
+
}
|
|
768
816
|
export class ExternalUrlInvalid extends BadRequest {
|
|
769
817
|
id = 'EXTERNAL_URL_INVALID';
|
|
770
818
|
message = 'External URL invalid.';
|
|
@@ -847,7 +895,7 @@ export class FileReferenceInvalid extends BadRequest {
|
|
|
847
895
|
}
|
|
848
896
|
export class FileReferenceXEmpty extends BadRequest {
|
|
849
897
|
id = 'FILE_REFERENCE_X_EMPTY';
|
|
850
|
-
message = '';
|
|
898
|
+
message = 'The file reference of the media file at offset {value} in the multi_media array is invalid.';
|
|
851
899
|
}
|
|
852
900
|
export class FileReferenceXExpired extends BadRequest {
|
|
853
901
|
id = 'FILE_REFERENCE_X_EXPIRED';
|
|
@@ -1111,11 +1159,11 @@ export class InputRequestTooLong extends BadRequest {
|
|
|
1111
1159
|
}
|
|
1112
1160
|
export class InputStarsAmountInvalid extends BadRequest {
|
|
1113
1161
|
id = 'INPUT_STARS_AMOUNT_INVALID';
|
|
1114
|
-
message = '';
|
|
1162
|
+
message = 'The specified offer amount in stars is invalid, see [here »](https://core.telegram.org/api/gifts#collectible-gift-purchase-offers) for the allowed range.';
|
|
1115
1163
|
}
|
|
1116
1164
|
export class InputStarsNanosInvalid extends BadRequest {
|
|
1117
1165
|
id = 'INPUT_STARS_NANOS_INVALID';
|
|
1118
|
-
message = '';
|
|
1166
|
+
message = 'The specified offer amount in nanotons is invalid, see [here »](https://core.telegram.org/api/gifts#collectible-gift-purchase-offers) for the allowed range.';
|
|
1119
1167
|
}
|
|
1120
1168
|
export class InputTextEmpty extends BadRequest {
|
|
1121
1169
|
id = 'INPUT_TEXT_EMPTY';
|
|
@@ -1205,6 +1253,10 @@ export class LimitInvalid extends BadRequest {
|
|
|
1205
1253
|
id = 'LIMIT_INVALID';
|
|
1206
1254
|
message = 'The provided limit is invalid.';
|
|
1207
1255
|
}
|
|
1256
|
+
export class LimitPerPostInvalid extends BadRequest {
|
|
1257
|
+
id = 'LIMIT_PER_POST_INVALID';
|
|
1258
|
+
message = 'The specified reactions_limit value is invalid.';
|
|
1259
|
+
}
|
|
1208
1260
|
export class LinkNotModified extends BadRequest {
|
|
1209
1261
|
id = 'LINK_NOT_MODIFIED';
|
|
1210
1262
|
message = 'Discussion link not modified.';
|
|
@@ -1213,6 +1265,14 @@ export class LocationInvalid extends BadRequest {
|
|
|
1213
1265
|
id = 'LOCATION_INVALID';
|
|
1214
1266
|
message = 'The provided location is invalid.';
|
|
1215
1267
|
}
|
|
1268
|
+
export class ManagerInvalid extends BadRequest {
|
|
1269
|
+
id = 'MANAGER_INVALID';
|
|
1270
|
+
message = 'The specified manager bot is invalid.';
|
|
1271
|
+
}
|
|
1272
|
+
export class ManagerPermissionMissing extends BadRequest {
|
|
1273
|
+
id = 'MANAGER_PERMISSION_MISSING';
|
|
1274
|
+
message = 'The specified manager bot does not have the [user](https://core.telegram.org/constructor/user).`bot_can_manage_bots` flag set.';
|
|
1275
|
+
}
|
|
1216
1276
|
export class MaxDateInvalid extends BadRequest {
|
|
1217
1277
|
id = 'MAX_DATE_INVALID';
|
|
1218
1278
|
message = 'The specified maximum date is invalid.';
|
|
@@ -1319,7 +1379,7 @@ export class MessagePollClosed extends BadRequest {
|
|
|
1319
1379
|
}
|
|
1320
1380
|
export class MessageRequired extends BadRequest {
|
|
1321
1381
|
id = 'MESSAGE_REQUIRED';
|
|
1322
|
-
message = '';
|
|
1382
|
+
message = 'A non-empty list of IDs must be passed to `id`.';
|
|
1323
1383
|
}
|
|
1324
1384
|
export class MessageTooLong extends BadRequest {
|
|
1325
1385
|
id = 'MESSAGE_TOO_LONG';
|
|
@@ -1353,6 +1413,10 @@ export class MsgVoiceMissing extends BadRequest {
|
|
|
1353
1413
|
id = 'MSG_VOICE_MISSING';
|
|
1354
1414
|
message = 'The specified message is not a voice message.';
|
|
1355
1415
|
}
|
|
1416
|
+
export class MsgVoiceTooLong extends BadRequest {
|
|
1417
|
+
id = 'MSG_VOICE_TOO_LONG';
|
|
1418
|
+
message = 'The specified voice message is too long to be transcribed.';
|
|
1419
|
+
}
|
|
1356
1420
|
export class MsgWaitFailed extends BadRequest {
|
|
1357
1421
|
id = 'MSG_WAIT_FAILED';
|
|
1358
1422
|
message = 'A waiting call returned an error.';
|
|
@@ -1361,6 +1425,10 @@ export class MultiMediaTooLong extends BadRequest {
|
|
|
1361
1425
|
id = 'MULTI_MEDIA_TOO_LONG';
|
|
1362
1426
|
message = 'Too many media files for album.';
|
|
1363
1427
|
}
|
|
1428
|
+
export class NameInvalid extends BadRequest {
|
|
1429
|
+
id = 'NAME_INVALID';
|
|
1430
|
+
message = 'The specified bot name is invalid.';
|
|
1431
|
+
}
|
|
1364
1432
|
export class NeedActionMissing extends BadRequest {
|
|
1365
1433
|
id = 'NEED_ACTION_MISSING';
|
|
1366
1434
|
message = '';
|
|
@@ -1453,6 +1521,10 @@ export class ParticipantVersionOutdated extends BadRequest {
|
|
|
1453
1521
|
id = 'PARTICIPANT_VERSION_OUTDATED';
|
|
1454
1522
|
message = 'The other participant does not use an up to date telegram client with support for calls.';
|
|
1455
1523
|
}
|
|
1524
|
+
export class PasskeyOriginMismatch extends BadRequest {
|
|
1525
|
+
id = 'PASSKEY_ORIGIN_MISMATCH';
|
|
1526
|
+
message = "Third-party clients currently don't support passkeys even when changing the origin.";
|
|
1527
|
+
}
|
|
1456
1528
|
export class PasswordEmpty extends BadRequest {
|
|
1457
1529
|
id = 'PASSWORD_EMPTY';
|
|
1458
1530
|
message = 'The provided password is empty.';
|
|
@@ -1635,7 +1707,7 @@ export class PinnedTooMuch extends BadRequest {
|
|
|
1635
1707
|
}
|
|
1636
1708
|
export class PinnedTopicNotModified extends BadRequest {
|
|
1637
1709
|
id = 'PINNED_TOPIC_NOT_MODIFIED';
|
|
1638
|
-
message = '';
|
|
1710
|
+
message = 'The specified topic is already pinned.';
|
|
1639
1711
|
}
|
|
1640
1712
|
export class PinRestricted extends BadRequest {
|
|
1641
1713
|
id = 'PIN_RESTRICTED';
|
|
@@ -1675,7 +1747,7 @@ export class PremiumAccountRequired extends BadRequest {
|
|
|
1675
1747
|
}
|
|
1676
1748
|
export class PremiumPurposeInvalid extends BadRequest {
|
|
1677
1749
|
id = 'PREMIUM_PURPOSE_INVALID';
|
|
1678
|
-
message = '';
|
|
1750
|
+
message = 'The specified InputStorePaymentPurpose is invalid.';
|
|
1679
1751
|
}
|
|
1680
1752
|
export class PricingChatInvalid extends BadRequest {
|
|
1681
1753
|
id = 'PRICING_CHAT_INVALID';
|
|
@@ -1693,6 +1765,14 @@ export class PrivacyValueInvalid extends BadRequest {
|
|
|
1693
1765
|
id = 'PRIVACY_VALUE_INVALID';
|
|
1694
1766
|
message = 'The specified privacy rule combination is invalid.';
|
|
1695
1767
|
}
|
|
1768
|
+
export class PublicBroadcastExpected extends BadRequest {
|
|
1769
|
+
id = 'PUBLIC_BROADCAST_EXPECTED';
|
|
1770
|
+
message = '`channel` only accepts a channel, but a supergroup was passed.';
|
|
1771
|
+
}
|
|
1772
|
+
export class PublicKeyInvalid extends BadRequest {
|
|
1773
|
+
id = 'PUBLIC_KEY_INVALID';
|
|
1774
|
+
message = 'The specified e2e public key is invalid.';
|
|
1775
|
+
}
|
|
1696
1776
|
export class PublicKeyRequired extends BadRequest {
|
|
1697
1777
|
id = 'PUBLIC_KEY_REQUIRED';
|
|
1698
1778
|
message = 'A public key is required.';
|
|
@@ -1829,17 +1909,21 @@ export class ReplyToUserInvalid extends BadRequest {
|
|
|
1829
1909
|
id = 'REPLY_TO_USER_INVALID';
|
|
1830
1910
|
message = 'The replied-to user is invalid.';
|
|
1831
1911
|
}
|
|
1912
|
+
export class RequestMsgExpired extends BadRequest {
|
|
1913
|
+
id = 'REQUEST_MSG_EXPIRED';
|
|
1914
|
+
message = 'The request specified in request_msg_id has already expired.';
|
|
1915
|
+
}
|
|
1832
1916
|
export class RequestTokenInvalid extends BadRequest {
|
|
1833
1917
|
id = 'REQUEST_TOKEN_INVALID';
|
|
1834
1918
|
message = 'The master DC did not accept the `request_token` from the CDN DC. Continue downloading the file from the master DC using upload.getFile.';
|
|
1835
1919
|
}
|
|
1836
1920
|
export class ResellStarsTooFew extends BadRequest {
|
|
1837
1921
|
id = 'RESELL_STARS_TOO_FEW';
|
|
1838
|
-
message = '';
|
|
1922
|
+
message = 'The offered price is too low.';
|
|
1839
1923
|
}
|
|
1840
1924
|
export class ResellStarsTooMuch extends BadRequest {
|
|
1841
1925
|
id = 'RESELL_STARS_TOO_MUCH';
|
|
1842
|
-
message = '';
|
|
1926
|
+
message = 'The offered price is too high.';
|
|
1843
1927
|
}
|
|
1844
1928
|
export class ResetRequestMissing extends BadRequest {
|
|
1845
1929
|
id = 'RESET_REQUEST_MISSING';
|
|
@@ -2027,7 +2111,7 @@ export class StargiftAlreadyUpgraded extends BadRequest {
|
|
|
2027
2111
|
}
|
|
2028
2112
|
export class StargiftAttributeInvalid extends BadRequest {
|
|
2029
2113
|
id = 'STARGIFT_ATTRIBUTE_INVALID';
|
|
2030
|
-
message = '';
|
|
2114
|
+
message = 'One of the specified star gift attributes is invalid.';
|
|
2031
2115
|
}
|
|
2032
2116
|
export class StargiftInvalid extends BadRequest {
|
|
2033
2117
|
id = 'STARGIFT_INVALID';
|
|
@@ -2035,7 +2119,7 @@ export class StargiftInvalid extends BadRequest {
|
|
|
2035
2119
|
}
|
|
2036
2120
|
export class StargiftMessageInvalid extends BadRequest {
|
|
2037
2121
|
id = 'STARGIFT_MESSAGE_INVALID';
|
|
2038
|
-
message = '';
|
|
2122
|
+
message = 'The specified inputInvoiceStarGift.message is invalid.';
|
|
2039
2123
|
}
|
|
2040
2124
|
export class StargiftNotFound extends BadRequest {
|
|
2041
2125
|
id = 'STARGIFT_NOT_FOUND';
|
|
@@ -2043,19 +2127,23 @@ export class StargiftNotFound extends BadRequest {
|
|
|
2043
2127
|
}
|
|
2044
2128
|
export class StargiftNotOwner extends BadRequest {
|
|
2045
2129
|
id = 'STARGIFT_NOT_OWNER';
|
|
2046
|
-
message = '
|
|
2130
|
+
message = "You're not the owner of the gift you trying to transfer.";
|
|
2047
2131
|
}
|
|
2048
2132
|
export class StargiftNotUnique extends BadRequest {
|
|
2049
2133
|
id = 'STARGIFT_NOT_UNIQUE';
|
|
2050
|
-
message = '
|
|
2134
|
+
message = "You can't transfer a non-collectible gift.";
|
|
2135
|
+
}
|
|
2136
|
+
export class StargiftObjectInvalid extends BadRequest {
|
|
2137
|
+
id = 'STARGIFT_OBJECT_INVALID';
|
|
2138
|
+
message = 'The specified star gift object is invalid.';
|
|
2051
2139
|
}
|
|
2052
2140
|
export class StargiftOfferInvalid extends BadRequest {
|
|
2053
2141
|
id = 'STARGIFT_OFFER_INVALID';
|
|
2054
|
-
message = '';
|
|
2142
|
+
message = 'The specified offer amount is invalid.';
|
|
2055
2143
|
}
|
|
2056
2144
|
export class StargiftOfferNotAllowed extends BadRequest {
|
|
2057
2145
|
id = 'STARGIFT_OFFER_NOT_ALLOWED';
|
|
2058
|
-
message = '
|
|
2146
|
+
message = "You can't send a purchase offer for this gift.";
|
|
2059
2147
|
}
|
|
2060
2148
|
export class StargiftOwnerInvalid extends BadRequest {
|
|
2061
2149
|
id = 'STARGIFT_OWNER_INVALID';
|
|
@@ -2071,7 +2159,7 @@ export class StargiftResellCurrencyNotAllowed extends BadRequest {
|
|
|
2071
2159
|
}
|
|
2072
2160
|
export class StargiftResellTooEarly extends BadRequest {
|
|
2073
2161
|
id = 'STARGIFT_RESELL_TOO_EARLY_X';
|
|
2074
|
-
message = '';
|
|
2162
|
+
message = 'You will be able to resell this gift in {value} seconds.';
|
|
2075
2163
|
}
|
|
2076
2164
|
export class StargiftSlugInvalid extends BadRequest {
|
|
2077
2165
|
id = 'STARGIFT_SLUG_INVALID';
|
|
@@ -2237,6 +2325,10 @@ export class StoryIdInvalid extends BadRequest {
|
|
|
2237
2325
|
id = 'STORY_ID_INVALID';
|
|
2238
2326
|
message = 'The specified story ID is invalid.';
|
|
2239
2327
|
}
|
|
2328
|
+
export class StoryLiveAlready extends BadRequest {
|
|
2329
|
+
id = 'STORY_LIVE_ALREADY_X';
|
|
2330
|
+
message = 'This peer already has an active live story, and its ID is equal to {value}.';
|
|
2331
|
+
}
|
|
2240
2332
|
export class StoryNotModified extends BadRequest {
|
|
2241
2333
|
id = 'STORY_NOT_MODIFIED';
|
|
2242
2334
|
message = "The new story information you passed is equal to the previous story information, thus it wasn't modified.";
|
|
@@ -2305,6 +2397,10 @@ export class TermsUrlInvalid extends BadRequest {
|
|
|
2305
2397
|
id = 'TERMS_URL_INVALID';
|
|
2306
2398
|
message = 'The specified [invoice](https://core.telegram.org/constructor/invoice).`terms_url` is invalid.';
|
|
2307
2399
|
}
|
|
2400
|
+
export class TextdraftPeerInvalid extends BadRequest {
|
|
2401
|
+
id = 'TEXTDRAFT_PEER_INVALID';
|
|
2402
|
+
message = '';
|
|
2403
|
+
}
|
|
2308
2404
|
export class ThemeFileInvalid extends BadRequest {
|
|
2309
2405
|
id = 'THEME_FILE_INVALID';
|
|
2310
2406
|
message = 'Invalid theme file provided.';
|
|
@@ -2353,6 +2449,10 @@ export class TodoItemsEmpty extends BadRequest {
|
|
|
2353
2449
|
id = 'TODO_ITEMS_EMPTY';
|
|
2354
2450
|
message = 'A checklist was specified, but no [checklist items](https://core.telegram.org/api/todo) were passed.';
|
|
2355
2451
|
}
|
|
2452
|
+
export class TodoItemsTooMuch extends BadRequest {
|
|
2453
|
+
id = 'TODO_ITEMS_TOO_MUCH';
|
|
2454
|
+
message = 'You specified too many todo list items.';
|
|
2455
|
+
}
|
|
2356
2456
|
export class TodoItemDuplicate extends BadRequest {
|
|
2357
2457
|
id = 'TODO_ITEM_DUPLICATE';
|
|
2358
2458
|
message = 'Duplicate [checklist items](https://core.telegram.org/api/todo) detected.';
|
|
@@ -2453,6 +2553,10 @@ export class UntilDateInvalid extends BadRequest {
|
|
|
2453
2553
|
id = 'UNTIL_DATE_INVALID';
|
|
2454
2554
|
message = 'Invalid until date provided.';
|
|
2455
2555
|
}
|
|
2556
|
+
export class UrlExpired extends BadRequest {
|
|
2557
|
+
id = 'URL_EXPIRED';
|
|
2558
|
+
message = 'The specified OAuth request has expired.';
|
|
2559
|
+
}
|
|
2456
2560
|
export class UrlInvalid extends BadRequest {
|
|
2457
2561
|
id = 'URL_INVALID';
|
|
2458
2562
|
message = 'Invalid URL provided.';
|
|
@@ -2485,6 +2589,10 @@ export class UsernamePurchaseAvailable extends BadRequest {
|
|
|
2485
2589
|
id = 'USERNAME_PURCHASE_AVAILABLE';
|
|
2486
2590
|
message = 'The specified username can be purchased on https://fragment.com.';
|
|
2487
2591
|
}
|
|
2592
|
+
export class UsernameSuffixMissing extends BadRequest {
|
|
2593
|
+
id = 'USERNAME_SUFFIX_MISSING';
|
|
2594
|
+
message = 'The required `bot` suffix is missing from the passed username.';
|
|
2595
|
+
}
|
|
2488
2596
|
export class UserpicUploadRequired extends BadRequest {
|
|
2489
2597
|
id = 'USERPIC_UPLOAD_REQUIRED';
|
|
2490
2598
|
message = 'You must have a profile picture to publish your geolocation.';
|
|
@@ -2529,6 +2637,10 @@ export class UserBotRequired extends BadRequest {
|
|
|
2529
2637
|
id = 'USER_BOT_REQUIRED';
|
|
2530
2638
|
message = 'This method can only be called by a bot.';
|
|
2531
2639
|
}
|
|
2640
|
+
export class UserBotToBotDisabled extends BadRequest {
|
|
2641
|
+
id = 'USER_BOT_TO_BOT_DISABLED';
|
|
2642
|
+
message = '';
|
|
2643
|
+
}
|
|
2532
2644
|
export class UserChannelsTooMuch extends BadRequest {
|
|
2533
2645
|
id = 'USER_CHANNELS_TOO_MUCH';
|
|
2534
2646
|
message = 'One of the users you tried to add is already in too many channels/supergroups.';
|
|
@@ -2585,6 +2697,10 @@ export class VideoContentTypeInvalid extends BadRequest {
|
|
|
2585
2697
|
id = 'VIDEO_CONTENT_TYPE_INVALID';
|
|
2586
2698
|
message = "The video's content type is invalid.";
|
|
2587
2699
|
}
|
|
2700
|
+
export class VideoDurationInvalid extends BadRequest {
|
|
2701
|
+
id = 'VIDEO_DURATION_INVALID';
|
|
2702
|
+
message = 'The duration of the specified video is invalid.';
|
|
2703
|
+
}
|
|
2588
2704
|
export class VideoFileInvalid extends BadRequest {
|
|
2589
2705
|
id = 'VIDEO_FILE_INVALID';
|
|
2590
2706
|
message = 'The specified video file is invalid.';
|
|
@@ -2629,6 +2745,14 @@ export class WcConvertUrlInvalid extends BadRequest {
|
|
|
2629
2745
|
id = 'WC_CONVERT_URL_INVALID';
|
|
2630
2746
|
message = 'WC convert URL invalid.';
|
|
2631
2747
|
}
|
|
2748
|
+
export class WebappReqIdInvalid extends BadRequest {
|
|
2749
|
+
id = 'WEBAPP_REQ_ID_INVALID';
|
|
2750
|
+
message = 'The specified webapp_req_id is invalid.';
|
|
2751
|
+
}
|
|
2752
|
+
export class WebauthTokenExpired extends BadRequest {
|
|
2753
|
+
id = 'WEBAUTH_TOKEN_EXPIRED';
|
|
2754
|
+
message = 'The specified auth token has expired.';
|
|
2755
|
+
}
|
|
2632
2756
|
export class WebdocumentInvalid extends BadRequest {
|
|
2633
2757
|
id = 'WEBDOCUMENT_INVALID';
|
|
2634
2758
|
message = 'Invalid webdocument URL provided.';
|
|
@@ -33,6 +33,14 @@ export declare class BotAccessForbidden extends Forbidden {
|
|
|
33
33
|
id: string;
|
|
34
34
|
message: string;
|
|
35
35
|
}
|
|
36
|
+
export declare class BotForumCreateForbidden extends Forbidden {
|
|
37
|
+
id: string;
|
|
38
|
+
message: string;
|
|
39
|
+
}
|
|
40
|
+
export declare class BotGuardNotSupported extends Forbidden {
|
|
41
|
+
id: string;
|
|
42
|
+
message: string;
|
|
43
|
+
}
|
|
36
44
|
export declare class BotVerifierForbidden extends Forbidden {
|
|
37
45
|
id: string;
|
|
38
46
|
message: string;
|
|
@@ -41,6 +49,10 @@ export declare class BroadcastForbidden extends Forbidden {
|
|
|
41
49
|
id: string;
|
|
42
50
|
message: string;
|
|
43
51
|
}
|
|
52
|
+
export declare class ChannelPrivate extends Forbidden {
|
|
53
|
+
id: string;
|
|
54
|
+
message: string;
|
|
55
|
+
}
|
|
44
56
|
export declare class ChannelPublicGroupNa extends Forbidden {
|
|
45
57
|
id: string;
|
|
46
58
|
message: string;
|
|
@@ -137,6 +149,10 @@ export declare class GroupcallAlreadyStarted extends Forbidden {
|
|
|
137
149
|
id: string;
|
|
138
150
|
message: string;
|
|
139
151
|
}
|
|
152
|
+
export declare class GroupcallChangeForbidden extends Forbidden {
|
|
153
|
+
id: string;
|
|
154
|
+
message: string;
|
|
155
|
+
}
|
|
140
156
|
export declare class GroupcallForbidden extends Forbidden {
|
|
141
157
|
id: string;
|
|
142
158
|
message: string;
|
|
@@ -193,6 +209,10 @@ export declare class TakeoutRequired extends Forbidden {
|
|
|
193
209
|
id: string;
|
|
194
210
|
message: string;
|
|
195
211
|
}
|
|
212
|
+
export declare class UserBannedInChannel extends Forbidden {
|
|
213
|
+
id: string;
|
|
214
|
+
message: string;
|
|
215
|
+
}
|
|
196
216
|
export declare class UserBotInvalid extends Forbidden {
|
|
197
217
|
id: string;
|
|
198
218
|
message: string;
|
|
@@ -205,6 +225,10 @@ export declare class UserDeleted extends Forbidden {
|
|
|
205
225
|
id: string;
|
|
206
226
|
message: string;
|
|
207
227
|
}
|
|
228
|
+
export declare class UserDisallowedStargifts extends Forbidden {
|
|
229
|
+
id: string;
|
|
230
|
+
message: string;
|
|
231
|
+
}
|
|
208
232
|
export declare class UserInvalid extends Forbidden {
|
|
209
233
|
id: string;
|
|
210
234
|
message: string;
|
|
@@ -33,6 +33,14 @@ export class BotAccessForbidden extends Forbidden {
|
|
|
33
33
|
id = 'BOT_ACCESS_FORBIDDEN';
|
|
34
34
|
message = 'The specified method *can* be used over a [business connection](https://core.telegram.org/api/bots/connected-business-bots) for some operations, but the specified query attempted an operation that is not allowed over a business connection.';
|
|
35
35
|
}
|
|
36
|
+
export class BotForumCreateForbidden extends Forbidden {
|
|
37
|
+
id = 'BOT_FORUM_CREATE_FORBIDDEN';
|
|
38
|
+
message = "Since the bot's user.bot_forum_can_manage_topics flag is **not** set, the user cannot create or modify bot forum topics.";
|
|
39
|
+
}
|
|
40
|
+
export class BotGuardNotSupported extends Forbidden {
|
|
41
|
+
id = 'BOT_GUARD_NOT_SUPPORTED';
|
|
42
|
+
message = '';
|
|
43
|
+
}
|
|
36
44
|
export class BotVerifierForbidden extends Forbidden {
|
|
37
45
|
id = 'BOT_VERIFIER_FORBIDDEN';
|
|
38
46
|
message = 'This bot cannot assign [verification icons](https://core.telegram.org/api/bots/verification).';
|
|
@@ -41,6 +49,10 @@ export class BroadcastForbidden extends Forbidden {
|
|
|
41
49
|
id = 'BROADCAST_FORBIDDEN';
|
|
42
50
|
message = 'Channel poll voters and reactions cannot be fetched to prevent deanonymization.';
|
|
43
51
|
}
|
|
52
|
+
export class ChannelPrivate extends Forbidden {
|
|
53
|
+
id = 'CHANNEL_PRIVATE';
|
|
54
|
+
message = "You haven't joined this channel/supergroup.";
|
|
55
|
+
}
|
|
44
56
|
export class ChannelPublicGroupNa extends Forbidden {
|
|
45
57
|
id = 'CHANNEL_PUBLIC_GROUP_NA';
|
|
46
58
|
message = 'channel/supergroup not available.';
|
|
@@ -137,6 +149,10 @@ export class GroupcallAlreadyStarted extends Forbidden {
|
|
|
137
149
|
id = 'GROUPCALL_ALREADY_STARTED';
|
|
138
150
|
message = 'The groupcall has already started, you can join directly using [phone.joinGroupCall](https://core.telegram.org/method/phone.joinGroupCall).';
|
|
139
151
|
}
|
|
152
|
+
export class GroupcallChangeForbidden extends Forbidden {
|
|
153
|
+
id = 'GROUPCALL_CHANGE_FORBIDDEN';
|
|
154
|
+
message = 'You cannot change this group call setting.';
|
|
155
|
+
}
|
|
140
156
|
export class GroupcallForbidden extends Forbidden {
|
|
141
157
|
id = 'GROUPCALL_FORBIDDEN';
|
|
142
158
|
message = 'The group call has already ended.';
|
|
@@ -193,6 +209,10 @@ export class TakeoutRequired extends Forbidden {
|
|
|
193
209
|
id = 'TAKEOUT_REQUIRED';
|
|
194
210
|
message = 'A [takeout](https://core.telegram.org/api/takeout) session needs to be initialized first, [see here » for more info](https://core.telegram.org/api/takeout).';
|
|
195
211
|
}
|
|
212
|
+
export class UserBannedInChannel extends Forbidden {
|
|
213
|
+
id = 'USER_BANNED_IN_CHANNEL';
|
|
214
|
+
message = "You're banned from sending messages in supergroups/channels.";
|
|
215
|
+
}
|
|
196
216
|
export class UserBotInvalid extends Forbidden {
|
|
197
217
|
id = 'USER_BOT_INVALID';
|
|
198
218
|
message = 'User accounts must provide the `bot` method parameter when calling this method. If there is no such method parameter, this method can only be invoked by bot accounts.';
|
|
@@ -205,6 +225,10 @@ export class UserDeleted extends Forbidden {
|
|
|
205
225
|
id = 'USER_DELETED';
|
|
206
226
|
message = "You can't send this secret message because the other participant deleted their account.";
|
|
207
227
|
}
|
|
228
|
+
export class UserDisallowedStargifts extends Forbidden {
|
|
229
|
+
id = 'USER_DISALLOWED_STARGIFTS';
|
|
230
|
+
message = '';
|
|
231
|
+
}
|
|
208
232
|
export class UserInvalid extends Forbidden {
|
|
209
233
|
id = 'USER_INVALID';
|
|
210
234
|
message = 'Invalid user provided.';
|
|
@@ -17,6 +17,10 @@ export declare class InternalServerError extends RPCError {
|
|
|
17
17
|
code: number;
|
|
18
18
|
name: string;
|
|
19
19
|
}
|
|
20
|
+
export declare class AicomposeTimeout extends InternalServerError {
|
|
21
|
+
id: string;
|
|
22
|
+
message: string;
|
|
23
|
+
}
|
|
20
24
|
export declare class ApiCallError extends InternalServerError {
|
|
21
25
|
id: string;
|
|
22
26
|
message: string;
|
|
@@ -161,6 +165,10 @@ export declare class NoWorkersRunning extends InternalServerError {
|
|
|
161
165
|
id: string;
|
|
162
166
|
message: string;
|
|
163
167
|
}
|
|
168
|
+
export declare class OauthRequestInvalid extends InternalServerError {
|
|
169
|
+
id: string;
|
|
170
|
+
message: string;
|
|
171
|
+
}
|
|
164
172
|
export declare class ParticipantCallFailed extends InternalServerError {
|
|
165
173
|
id: string;
|
|
166
174
|
message: string;
|
|
@@ -17,6 +17,10 @@ export class InternalServerError extends RPCError {
|
|
|
17
17
|
code = 500;
|
|
18
18
|
name = 'INTERNAL_SERVER_ERROR';
|
|
19
19
|
}
|
|
20
|
+
export class AicomposeTimeout extends InternalServerError {
|
|
21
|
+
id = 'AICOMPOSE_TIMEOUT';
|
|
22
|
+
message = 'A timeout occurred while composing the message.';
|
|
23
|
+
}
|
|
20
24
|
export class ApiCallError extends InternalServerError {
|
|
21
25
|
id = 'API_CALL_ERROR';
|
|
22
26
|
message = 'API call error due to Telegram having internal problems. Please try again later';
|
|
@@ -161,6 +165,10 @@ export class NoWorkersRunning extends InternalServerError {
|
|
|
161
165
|
id = 'No_workers_running';
|
|
162
166
|
message = 'The Telegram server is restarting its workers. Try again later.';
|
|
163
167
|
}
|
|
168
|
+
export class OauthRequestInvalid extends InternalServerError {
|
|
169
|
+
id = 'OAUTH_REQUEST_INVALID';
|
|
170
|
+
message = 'The specified OAuth request is invalid.';
|
|
171
|
+
}
|
|
164
172
|
export class ParticipantCallFailed extends InternalServerError {
|
|
165
173
|
id = 'PARTICIPANT_CALL_FAILED';
|
|
166
174
|
message = 'Failure while making call due to Telegram having internal problems. Please try again later';
|
|
@@ -93,6 +93,10 @@ export declare class PhonePasswordFlood extends NotAcceptable {
|
|
|
93
93
|
id: string;
|
|
94
94
|
message: string;
|
|
95
95
|
}
|
|
96
|
+
export declare class PollMemberRestricted extends NotAcceptable {
|
|
97
|
+
id: string;
|
|
98
|
+
message: string;
|
|
99
|
+
}
|
|
96
100
|
export declare class PrecheckoutFailed extends NotAcceptable {
|
|
97
101
|
id: string;
|
|
98
102
|
message: string;
|
|
@@ -93,6 +93,10 @@ export class PhonePasswordFlood extends NotAcceptable {
|
|
|
93
93
|
id = 'PHONE_PASSWORD_FLOOD';
|
|
94
94
|
message = 'You have tried logging in too many times.';
|
|
95
95
|
}
|
|
96
|
+
export class PollMemberRestricted extends NotAcceptable {
|
|
97
|
+
id = 'POLL_MEMBER_RESTRICTED';
|
|
98
|
+
message = 'Only channel subscribers can vote in this poll.';
|
|
99
|
+
}
|
|
96
100
|
export class PrecheckoutFailed extends NotAcceptable {
|
|
97
101
|
id = 'PRECHECKOUT_FAILED';
|
|
98
102
|
message = 'Precheckout failed, a detailed and localized description for the error will be emitted via an [updateServiceNotification as specified here »](https://core.telegram.org/api/errors#406-not-acceptable).';
|