@tgsnake/skema 1.6.0 → 1.9.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/LICENSE +0 -0
- package/README.md +1 -1
- package/dist/errors/exceptions/All.d.ts +74 -1
- package/dist/errors/exceptions/All.js +74 -1
- package/dist/errors/exceptions/BadRequest400.d.ts +232 -0
- package/dist/errors/exceptions/BadRequest400.js +311 -20
- package/dist/errors/exceptions/Flood420.d.ts +4 -0
- package/dist/errors/exceptions/Flood420.js +6 -1
- package/dist/errors/exceptions/Forbidden403.d.ts +20 -0
- package/dist/errors/exceptions/Forbidden403.js +27 -2
- package/dist/errors/exceptions/InternalServerError500.d.ts +4 -0
- package/dist/errors/exceptions/InternalServerError500.js +6 -1
- package/dist/errors/exceptions/NotAcceptable406.d.ts +28 -0
- package/dist/errors/exceptions/NotAcceptable406.js +37 -2
- package/dist/errors/exceptions/NotFound404.d.ts +4 -0
- package/dist/errors/exceptions/NotFound404.js +6 -1
- package/dist/raw/All.d.ts +79 -37
- package/dist/raw/All.js +79 -37
- package/dist/raw/Raw.d.ts +548 -20
- package/dist/raw/Raw.js +1966 -141
- package/package.json +1 -1
|
@@ -23,6 +23,10 @@ export declare class FloodWait extends Flood {
|
|
|
23
23
|
id: string;
|
|
24
24
|
message: string;
|
|
25
25
|
}
|
|
26
|
+
export declare class FrozenMethodInvalid extends Flood {
|
|
27
|
+
id: string;
|
|
28
|
+
message: string;
|
|
29
|
+
}
|
|
26
30
|
export declare class PremiumSubActiveUntil extends Flood {
|
|
27
31
|
id: string;
|
|
28
32
|
message: string;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.TakeoutInitDelay = exports.SlowmodeWait = exports.PremiumSubActiveUntil = exports.FloodWait = exports.FloodTestPhoneWait = exports.FloodPremiumWait = exports.AddressInvalid = exports.TwoFaConfirmWait = exports.Flood = void 0;
|
|
3
|
+
exports.TakeoutInitDelay = exports.SlowmodeWait = exports.PremiumSubActiveUntil = exports.FrozenMethodInvalid = exports.FloodWait = exports.FloodTestPhoneWait = exports.FloodPremiumWait = exports.AddressInvalid = exports.TwoFaConfirmWait = exports.Flood = void 0;
|
|
4
4
|
const RpcError_js_1 = require("@/errors/RpcError.js");
|
|
5
5
|
class Flood extends RpcError_js_1.RPCError {
|
|
6
6
|
code = 420;
|
|
@@ -32,6 +32,11 @@ class FloodWait extends Flood {
|
|
|
32
32
|
message = 'Please wait {value} seconds before repeating the action.';
|
|
33
33
|
}
|
|
34
34
|
exports.FloodWait = FloodWait;
|
|
35
|
+
class FrozenMethodInvalid extends Flood {
|
|
36
|
+
id = 'FROZEN_METHOD_INVALID';
|
|
37
|
+
message = 'The current account is [frozen](https://core.telegram.org/api/auth#frozen-accounts), and thus cannot execute the specified action.';
|
|
38
|
+
}
|
|
39
|
+
exports.FrozenMethodInvalid = FrozenMethodInvalid;
|
|
35
40
|
class PremiumSubActiveUntil extends Flood {
|
|
36
41
|
id = 'PREMIUM_SUB_ACTIVE_UNTIL_X';
|
|
37
42
|
message = 'You already have a premium subscription active until unixtime {value} .';
|
|
@@ -3,10 +3,22 @@ export declare class Forbidden extends RPCError {
|
|
|
3
3
|
code: number;
|
|
4
4
|
name: string;
|
|
5
5
|
}
|
|
6
|
+
export declare class AllowPaymentRequired extends Forbidden {
|
|
7
|
+
id: string;
|
|
8
|
+
message: string;
|
|
9
|
+
}
|
|
6
10
|
export declare class AnonymousReactionsDisabled extends Forbidden {
|
|
7
11
|
id: string;
|
|
8
12
|
message: string;
|
|
9
13
|
}
|
|
14
|
+
export declare class BotAccessForbidden extends Forbidden {
|
|
15
|
+
id: string;
|
|
16
|
+
message: string;
|
|
17
|
+
}
|
|
18
|
+
export declare class BotVerifierForbidden extends Forbidden {
|
|
19
|
+
id: string;
|
|
20
|
+
message: string;
|
|
21
|
+
}
|
|
10
22
|
export declare class BroadcastForbidden extends Forbidden {
|
|
11
23
|
id: string;
|
|
12
24
|
message: string;
|
|
@@ -87,6 +99,10 @@ export declare class ChatSendVoicesForbidden extends Forbidden {
|
|
|
87
99
|
id: string;
|
|
88
100
|
message: string;
|
|
89
101
|
}
|
|
102
|
+
export declare class ChatSendWebpageForbidden extends Forbidden {
|
|
103
|
+
id: string;
|
|
104
|
+
message: string;
|
|
105
|
+
}
|
|
90
106
|
export declare class ChatTypeInvalid extends Forbidden {
|
|
91
107
|
id: string;
|
|
92
108
|
message: string;
|
|
@@ -187,6 +203,10 @@ export declare class UserNotParticipant extends Forbidden {
|
|
|
187
203
|
id: string;
|
|
188
204
|
message: string;
|
|
189
205
|
}
|
|
206
|
+
export declare class UserPermissionDenied extends Forbidden {
|
|
207
|
+
id: string;
|
|
208
|
+
message: string;
|
|
209
|
+
}
|
|
190
210
|
export declare class UserPrivacyRestricted extends Forbidden {
|
|
191
211
|
id: string;
|
|
192
212
|
message: string;
|
|
@@ -1,18 +1,33 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.
|
|
4
|
-
exports.YourPrivacyRestricted = void 0;
|
|
3
|
+
exports.UserNotMutualContact = exports.UserIsBlocked = exports.UserInvalid = exports.UserDeleted = exports.UserChannelsTooMuch = exports.UserBotInvalid = exports.TakeoutRequired = exports.SensitiveChangeForbidden = exports.RightForbidden = exports.PublicChannelMissing = exports.PrivacyPremiumRequired = exports.PremiumAccountRequired = exports.PollVoteRequired = exports.PeerIdInvalid = exports.ParticipantJoinMissing = exports.NotEligible = exports.MessageDeleteForbidden = exports.MessageAuthorRequired = exports.InlineBotRequired = exports.GroupcallForbidden = exports.GroupcallAlreadyStarted = exports.EditBotInviteForbidden = exports.ChatWriteForbidden = exports.ChatTypeInvalid = exports.ChatSendWebpageForbidden = exports.ChatSendVoicesForbidden = exports.ChatSendVideosForbidden = exports.ChatSendStickersForbidden = exports.ChatSendRoundvideosForbidden = exports.ChatSendPollForbidden = exports.ChatSendPlainForbidden = exports.ChatSendPhotosForbidden = exports.ChatSendMediaForbidden = exports.ChatSendInlineForbidden = exports.ChatSendGifsForbidden = exports.ChatSendGameForbidden = exports.ChatSendDocsForbidden = exports.ChatSendAudiosForbidden = exports.ChatGuestSendForbidden = exports.ChatForbidden = exports.ChatAdminRequired = exports.ChatAdminInviteRequired = exports.ChatActionForbidden = exports.ChannelPublicGroupNa = exports.BroadcastForbidden = exports.BotVerifierForbidden = exports.BotAccessForbidden = exports.AnonymousReactionsDisabled = exports.AllowPaymentRequired = exports.Forbidden = void 0;
|
|
4
|
+
exports.YourPrivacyRestricted = exports.VoiceMessagesForbidden = exports.UserRestricted = exports.UserPrivacyRestricted = exports.UserPermissionDenied = exports.UserNotParticipant = void 0;
|
|
5
5
|
const RpcError_js_1 = require("@/errors/RpcError.js");
|
|
6
6
|
class Forbidden extends RpcError_js_1.RPCError {
|
|
7
7
|
code = 403;
|
|
8
8
|
name = 'FORBIDDEN';
|
|
9
9
|
}
|
|
10
10
|
exports.Forbidden = Forbidden;
|
|
11
|
+
class AllowPaymentRequired extends Forbidden {
|
|
12
|
+
id = 'ALLOW_PAYMENT_REQUIRED_X';
|
|
13
|
+
message = 'This peer charges {value} [Telegram Stars](https://core.telegram.org/api/stars) per message, but the `allow_paid_stars` was not set or its value is smaller than {value}.';
|
|
14
|
+
}
|
|
15
|
+
exports.AllowPaymentRequired = AllowPaymentRequired;
|
|
11
16
|
class AnonymousReactionsDisabled extends Forbidden {
|
|
12
17
|
id = 'ANONYMOUS_REACTIONS_DISABLED';
|
|
13
18
|
message = 'Sorry, anonymous administrators cannot leave reactions or participate in polls.';
|
|
14
19
|
}
|
|
15
20
|
exports.AnonymousReactionsDisabled = AnonymousReactionsDisabled;
|
|
21
|
+
class BotAccessForbidden extends Forbidden {
|
|
22
|
+
id = 'BOT_ACCESS_FORBIDDEN';
|
|
23
|
+
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.';
|
|
24
|
+
}
|
|
25
|
+
exports.BotAccessForbidden = BotAccessForbidden;
|
|
26
|
+
class BotVerifierForbidden extends Forbidden {
|
|
27
|
+
id = 'BOT_VERIFIER_FORBIDDEN';
|
|
28
|
+
message = 'This bot cannot assign [verification icons](https://core.telegram.org/api/bots/verification).';
|
|
29
|
+
}
|
|
30
|
+
exports.BotVerifierForbidden = BotVerifierForbidden;
|
|
16
31
|
class BroadcastForbidden extends Forbidden {
|
|
17
32
|
id = 'BROADCAST_FORBIDDEN';
|
|
18
33
|
message = 'Channel poll voters and reactions cannot be fetched to prevent deanonymization.';
|
|
@@ -113,6 +128,11 @@ class ChatSendVoicesForbidden extends Forbidden {
|
|
|
113
128
|
message = "You can't send voice recordings in this chat.";
|
|
114
129
|
}
|
|
115
130
|
exports.ChatSendVoicesForbidden = ChatSendVoicesForbidden;
|
|
131
|
+
class ChatSendWebpageForbidden extends Forbidden {
|
|
132
|
+
id = 'CHAT_SEND_WEBPAGE_FORBIDDEN';
|
|
133
|
+
message = "You can't send webpage previews to this chat.";
|
|
134
|
+
}
|
|
135
|
+
exports.ChatSendWebpageForbidden = ChatSendWebpageForbidden;
|
|
116
136
|
class ChatTypeInvalid extends Forbidden {
|
|
117
137
|
id = 'CHAT_TYPE_INVALID';
|
|
118
138
|
message = 'The specified user type is invalid.';
|
|
@@ -238,6 +258,11 @@ class UserNotParticipant extends Forbidden {
|
|
|
238
258
|
message = "You're not a member of this supergroup/channel.";
|
|
239
259
|
}
|
|
240
260
|
exports.UserNotParticipant = UserNotParticipant;
|
|
261
|
+
class UserPermissionDenied extends Forbidden {
|
|
262
|
+
id = 'USER_PERMISSION_DENIED';
|
|
263
|
+
message = "The user hasn't granted or has revoked the bot's access to change their emoji status using [bots.toggleUserEmojiStatusPermission](https://core.telegram.org/method/bots.toggleUserEmojiStatusPermission).";
|
|
264
|
+
}
|
|
265
|
+
exports.UserPermissionDenied = UserPermissionDenied;
|
|
241
266
|
class UserPrivacyRestricted extends Forbidden {
|
|
242
267
|
id = 'USER_PRIVACY_RESTRICTED';
|
|
243
268
|
message = "The user's privacy settings do not allow you to do this.";
|
|
@@ -199,6 +199,10 @@ export declare class TranslateReqFailed extends InternalServerError {
|
|
|
199
199
|
id: string;
|
|
200
200
|
message: string;
|
|
201
201
|
}
|
|
202
|
+
export declare class TranslationTimeout extends InternalServerError {
|
|
203
|
+
id: string;
|
|
204
|
+
message: string;
|
|
205
|
+
}
|
|
202
206
|
export declare class UnknownMethod extends InternalServerError {
|
|
203
207
|
id: string;
|
|
204
208
|
message: string;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.TranslateReqFailed = exports.StoreInvalidScalarType = exports.StorageCheckFailed = exports.SignInFailed = exports.SendMediaInvalid = exports.RpcMcgetFail = exports.RpcConnectFailed = exports.RpcCallFail = exports.RegIdGenerateFailed = exports.RandomIdDuplicate = exports.PtsChangeEmpty = exports.PostponedTimeout = exports.PhotoCreateFailed = exports.PersistentTimestampOutdated = exports.ParticipantCallFailed = exports.NoWorkersRunning = exports.NeedMemberInvalid = exports.NeedChatInvalid = exports.MtSendQueueTooLong = exports.MsgWaitFailed = exports.MsgRangeUnsync = exports.MsgidDecreaseRetry = exports.MemberOccupyUsernameFailed = exports.MemberOccupyPrimaryLocFailed = exports.MemberNoLocation = exports.MemberNotFound = exports.MemberFetchFailed = exports.MemberChatAddFailed = exports.InterdcCallRichError = exports.InterdcCallError = exports.ImageEngineDown = exports.HistoryGetFailed = exports.GroupedIdOccupyFailed = exports.GroupcallAddParticipantsFailed = exports.FolderDeacAutofixAll = exports.EncryptionOccupyFailed = exports.EncryptionOccupyAdminFailed = exports.ChpCallFail = exports.ChatOccupyUsernameFailed = exports.ChatOccupyLocFailed = exports.ChatInvalid = exports.ChatIdGenerateFailed = exports.CdnUploadTimeout = exports.CdnSaltsEmpty = exports.CallOccupyFailed = exports.AuthRestartX = exports.AuthRestart = exports.AuthKeyUnsynchronized = exports.ApiCallError = exports.InternalServerError = void 0;
|
|
4
|
-
exports.WpIdGenerateFailed = exports.WorkerBusyTooLongRetry = exports.VolumeLocNotFound = exports.UploadNoVolume = exports.UnknownMethod = void 0;
|
|
4
|
+
exports.WpIdGenerateFailed = exports.WorkerBusyTooLongRetry = exports.VolumeLocNotFound = exports.UploadNoVolume = exports.UnknownMethod = exports.TranslationTimeout = void 0;
|
|
5
5
|
const RpcError_js_1 = require("@/errors/RpcError.js");
|
|
6
6
|
class InternalServerError extends RpcError_js_1.RPCError {
|
|
7
7
|
code = 500;
|
|
@@ -253,6 +253,11 @@ class TranslateReqFailed extends InternalServerError {
|
|
|
253
253
|
message = 'Translation failed, please try again later.';
|
|
254
254
|
}
|
|
255
255
|
exports.TranslateReqFailed = TranslateReqFailed;
|
|
256
|
+
class TranslationTimeout extends InternalServerError {
|
|
257
|
+
id = 'TRANSLATION_TIMEOUT';
|
|
258
|
+
message = 'A timeout occurred while translating the specified text.';
|
|
259
|
+
}
|
|
260
|
+
exports.TranslationTimeout = TranslationTimeout;
|
|
256
261
|
class UnknownMethod extends InternalServerError {
|
|
257
262
|
id = 'UNKNOWN_METHOD';
|
|
258
263
|
message = 'The method you tried to call cannot be called on non-CDN DCs';
|
|
@@ -3,6 +3,14 @@ export declare class NotAcceptable extends RPCError {
|
|
|
3
3
|
code: number;
|
|
4
4
|
name: string;
|
|
5
5
|
}
|
|
6
|
+
export declare class AllowPaymentRequired extends NotAcceptable {
|
|
7
|
+
id: string;
|
|
8
|
+
message: string;
|
|
9
|
+
}
|
|
10
|
+
export declare class ApiGiftRestrictedUpdateApp extends NotAcceptable {
|
|
11
|
+
id: string;
|
|
12
|
+
message: string;
|
|
13
|
+
}
|
|
6
14
|
export declare class AuthKeyDuplicated extends NotAcceptable {
|
|
7
15
|
id: string;
|
|
8
16
|
message: string;
|
|
@@ -59,6 +67,10 @@ export declare class PaymentUnsupported extends NotAcceptable {
|
|
|
59
67
|
id: string;
|
|
60
68
|
message: string;
|
|
61
69
|
}
|
|
70
|
+
export declare class PeerIdInvalid extends NotAcceptable {
|
|
71
|
+
id: string;
|
|
72
|
+
message: string;
|
|
73
|
+
}
|
|
62
74
|
export declare class PhoneNumberInvalid extends NotAcceptable {
|
|
63
75
|
id: string;
|
|
64
76
|
message: string;
|
|
@@ -67,6 +79,10 @@ export declare class PhonePasswordFlood extends NotAcceptable {
|
|
|
67
79
|
id: string;
|
|
68
80
|
message: string;
|
|
69
81
|
}
|
|
82
|
+
export declare class PrecheckoutFailed extends NotAcceptable {
|
|
83
|
+
id: string;
|
|
84
|
+
message: string;
|
|
85
|
+
}
|
|
70
86
|
export declare class PremiumCurrentlyUnavailable extends NotAcceptable {
|
|
71
87
|
id: string;
|
|
72
88
|
message: string;
|
|
@@ -83,6 +99,14 @@ export declare class SendCodeUnavailable extends NotAcceptable {
|
|
|
83
99
|
id: string;
|
|
84
100
|
message: string;
|
|
85
101
|
}
|
|
102
|
+
export declare class StargiftExportInProgress extends NotAcceptable {
|
|
103
|
+
id: string;
|
|
104
|
+
message: string;
|
|
105
|
+
}
|
|
106
|
+
export declare class StarsFormAmountMismatch extends NotAcceptable {
|
|
107
|
+
id: string;
|
|
108
|
+
message: string;
|
|
109
|
+
}
|
|
86
110
|
export declare class StickersetInvalid extends NotAcceptable {
|
|
87
111
|
id: string;
|
|
88
112
|
message: string;
|
|
@@ -99,6 +123,10 @@ export declare class TopicDeleted extends NotAcceptable {
|
|
|
99
123
|
id: string;
|
|
100
124
|
message: string;
|
|
101
125
|
}
|
|
126
|
+
export declare class TranslationsDisabled extends NotAcceptable {
|
|
127
|
+
id: string;
|
|
128
|
+
message: string;
|
|
129
|
+
}
|
|
102
130
|
export declare class UpdateAppToLogin extends NotAcceptable {
|
|
103
131
|
id: string;
|
|
104
132
|
message: string;
|
|
@@ -1,12 +1,22 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.UserRestricted = exports.UserpicUploadRequired = exports.UserpicPrivacyRequired = exports.UpdateAppToLogin = exports.TopicDeleted = exports.TopicClosed = exports.StickersetOwnerAnonymous = exports.StickersetInvalid = exports.SendCodeUnavailable = exports.PrivacyPremiumRequired = exports.PreviousChatImportActiveWaitmin = exports.PremiumCurrentlyUnavailable = exports.PhonePasswordFlood = exports.PhoneNumberInvalid = exports.PaymentUnsupported = exports.InviteHashExpired = exports.GiftcodeNotAllowed = exports.FreshResetAuthorisationForbidden = exports.FreshChangePhoneForbidden = exports.FreshChangeAdminsForbidden = exports.FilerefUpgradeNeeded = exports.ChatForwardsRestricted = exports.ChannelTooLarge = exports.ChannelPrivate = exports.CallProtocolCompatLayerInvalid = exports.BusinessAddressActive = exports.BannedRightsInvalid = exports.AuthKeyDuplicated = exports.NotAcceptable = void 0;
|
|
3
|
+
exports.UserRestricted = exports.UserpicUploadRequired = exports.UserpicPrivacyRequired = exports.UpdateAppToLogin = exports.TranslationsDisabled = exports.TopicDeleted = exports.TopicClosed = exports.StickersetOwnerAnonymous = exports.StickersetInvalid = exports.StarsFormAmountMismatch = exports.StargiftExportInProgress = exports.SendCodeUnavailable = exports.PrivacyPremiumRequired = exports.PreviousChatImportActiveWaitmin = exports.PremiumCurrentlyUnavailable = exports.PrecheckoutFailed = exports.PhonePasswordFlood = exports.PhoneNumberInvalid = exports.PeerIdInvalid = exports.PaymentUnsupported = exports.InviteHashExpired = exports.GiftcodeNotAllowed = exports.FreshResetAuthorisationForbidden = exports.FreshChangePhoneForbidden = exports.FreshChangeAdminsForbidden = exports.FilerefUpgradeNeeded = exports.ChatForwardsRestricted = exports.ChannelTooLarge = exports.ChannelPrivate = exports.CallProtocolCompatLayerInvalid = exports.BusinessAddressActive = exports.BannedRightsInvalid = exports.AuthKeyDuplicated = exports.ApiGiftRestrictedUpdateApp = exports.AllowPaymentRequired = exports.NotAcceptable = void 0;
|
|
4
4
|
const RpcError_js_1 = require("@/errors/RpcError.js");
|
|
5
5
|
class NotAcceptable extends RpcError_js_1.RPCError {
|
|
6
6
|
code = 406;
|
|
7
7
|
name = 'NOT_ACCEPTABLE';
|
|
8
8
|
}
|
|
9
9
|
exports.NotAcceptable = NotAcceptable;
|
|
10
|
+
class AllowPaymentRequired extends NotAcceptable {
|
|
11
|
+
id = 'ALLOW_PAYMENT_REQUIRED';
|
|
12
|
+
message = 'This peer only accepts [paid messages »](https://core.telegram.org/api/paid-messages): this error is only emitted for older layers without paid messages support, so the client must be updated in order to use paid messages. .';
|
|
13
|
+
}
|
|
14
|
+
exports.AllowPaymentRequired = AllowPaymentRequired;
|
|
15
|
+
class ApiGiftRestrictedUpdateApp extends NotAcceptable {
|
|
16
|
+
id = 'API_GIFT_RESTRICTED_UPDATE_APP';
|
|
17
|
+
message = 'Please update the app to access the gift API.';
|
|
18
|
+
}
|
|
19
|
+
exports.ApiGiftRestrictedUpdateApp = ApiGiftRestrictedUpdateApp;
|
|
10
20
|
class AuthKeyDuplicated extends NotAcceptable {
|
|
11
21
|
id = 'AUTH_KEY_DUPLICATED';
|
|
12
22
|
message = 'Concurrent usage of the current session from multiple connections was detected, the current session was invalidated by the server for security reasons!';
|
|
@@ -44,7 +54,7 @@ class ChatForwardsRestricted extends NotAcceptable {
|
|
|
44
54
|
exports.ChatForwardsRestricted = ChatForwardsRestricted;
|
|
45
55
|
class FilerefUpgradeNeeded extends NotAcceptable {
|
|
46
56
|
id = 'FILEREF_UPGRADE_NEEDED';
|
|
47
|
-
message = 'The client has to be updated in order to support [file references](https://core.telegram.org/api/
|
|
57
|
+
message = 'The client has to be updated in order to support [file references](https://core.telegram.org/api/file-references).';
|
|
48
58
|
}
|
|
49
59
|
exports.FilerefUpgradeNeeded = FilerefUpgradeNeeded;
|
|
50
60
|
class FreshChangeAdminsForbidden extends NotAcceptable {
|
|
@@ -77,6 +87,11 @@ class PaymentUnsupported extends NotAcceptable {
|
|
|
77
87
|
message = 'A detailed description of the error will be received separately as described [here »](https://core.telegram.org/api/errors#406-not-acceptable).';
|
|
78
88
|
}
|
|
79
89
|
exports.PaymentUnsupported = PaymentUnsupported;
|
|
90
|
+
class PeerIdInvalid extends NotAcceptable {
|
|
91
|
+
id = 'PEER_ID_INVALID';
|
|
92
|
+
message = 'The provided peer id is invalid.';
|
|
93
|
+
}
|
|
94
|
+
exports.PeerIdInvalid = PeerIdInvalid;
|
|
80
95
|
class PhoneNumberInvalid extends NotAcceptable {
|
|
81
96
|
id = 'PHONE_NUMBER_INVALID';
|
|
82
97
|
message = 'The phone number is invalid.';
|
|
@@ -87,6 +102,11 @@ class PhonePasswordFlood extends NotAcceptable {
|
|
|
87
102
|
message = 'You have tried logging in too many times.';
|
|
88
103
|
}
|
|
89
104
|
exports.PhonePasswordFlood = PhonePasswordFlood;
|
|
105
|
+
class PrecheckoutFailed extends NotAcceptable {
|
|
106
|
+
id = 'PRECHECKOUT_FAILED';
|
|
107
|
+
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).';
|
|
108
|
+
}
|
|
109
|
+
exports.PrecheckoutFailed = PrecheckoutFailed;
|
|
90
110
|
class PremiumCurrentlyUnavailable extends NotAcceptable {
|
|
91
111
|
id = 'PREMIUM_CURRENTLY_UNAVAILABLE';
|
|
92
112
|
message = 'You cannot currently purchase a Premium subscription.';
|
|
@@ -107,6 +127,16 @@ class SendCodeUnavailable extends NotAcceptable {
|
|
|
107
127
|
message = 'Returned when all available options for this type of number were already used (e.g. flash-call, then SMS, then this error might be returned to trigger a second resend).';
|
|
108
128
|
}
|
|
109
129
|
exports.SendCodeUnavailable = SendCodeUnavailable;
|
|
130
|
+
class StargiftExportInProgress extends NotAcceptable {
|
|
131
|
+
id = 'STARGIFT_EXPORT_IN_PROGRESS';
|
|
132
|
+
message = 'A gift export is in progress, 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).';
|
|
133
|
+
}
|
|
134
|
+
exports.StargiftExportInProgress = StargiftExportInProgress;
|
|
135
|
+
class StarsFormAmountMismatch extends NotAcceptable {
|
|
136
|
+
id = 'STARS_FORM_AMOUNT_MISMATCH';
|
|
137
|
+
message = 'The form amount has changed, please fetch the new form using [payments.getPaymentForm](https://core.telegram.org/method/payments.getPaymentForm) and restart the process.';
|
|
138
|
+
}
|
|
139
|
+
exports.StarsFormAmountMismatch = StarsFormAmountMismatch;
|
|
110
140
|
class StickersetInvalid extends NotAcceptable {
|
|
111
141
|
id = 'STICKERSET_INVALID';
|
|
112
142
|
message = 'The provided sticker set is invalid.';
|
|
@@ -127,6 +157,11 @@ class TopicDeleted extends NotAcceptable {
|
|
|
127
157
|
message = 'The specified topic was deleted.';
|
|
128
158
|
}
|
|
129
159
|
exports.TopicDeleted = TopicDeleted;
|
|
160
|
+
class TranslationsDisabled extends NotAcceptable {
|
|
161
|
+
id = 'TRANSLATIONS_DISABLED';
|
|
162
|
+
message = 'Translations are unavailable, 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).';
|
|
163
|
+
}
|
|
164
|
+
exports.TranslationsDisabled = TranslationsDisabled;
|
|
130
165
|
class UpdateAppToLogin extends NotAcceptable {
|
|
131
166
|
id = 'UPDATE_APP_TO_LOGIN';
|
|
132
167
|
message = 'Please update your client to login.';
|
|
@@ -3,6 +3,10 @@ export declare class NotFound extends RPCError {
|
|
|
3
3
|
code: number;
|
|
4
4
|
name: string;
|
|
5
5
|
}
|
|
6
|
+
export declare class MethodInvalid extends NotFound {
|
|
7
|
+
id: string;
|
|
8
|
+
message: string;
|
|
9
|
+
}
|
|
6
10
|
export declare class PeerIdInvalid extends NotFound {
|
|
7
11
|
id: string;
|
|
8
12
|
message: string;
|
|
@@ -1,12 +1,17 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.PeerIdInvalid = exports.NotFound = void 0;
|
|
3
|
+
exports.PeerIdInvalid = exports.MethodInvalid = exports.NotFound = void 0;
|
|
4
4
|
const RpcError_js_1 = require("@/errors/RpcError.js");
|
|
5
5
|
class NotFound extends RpcError_js_1.RPCError {
|
|
6
6
|
code = 404;
|
|
7
7
|
name = 'NOT_FOUND';
|
|
8
8
|
}
|
|
9
9
|
exports.NotFound = NotFound;
|
|
10
|
+
class MethodInvalid extends NotFound {
|
|
11
|
+
id = 'METHOD_INVALID';
|
|
12
|
+
message = 'The specified method is invalid.';
|
|
13
|
+
}
|
|
14
|
+
exports.MethodInvalid = MethodInvalid;
|
|
10
15
|
class PeerIdInvalid extends NotFound {
|
|
11
16
|
id = 'PEER_ID_INVALID';
|
|
12
17
|
message = 'The provided peer id is invalid.';
|
package/dist/raw/All.d.ts
CHANGED
|
@@ -90,6 +90,7 @@ export declare const AllTLObject: {
|
|
|
90
90
|
3256584265: string;
|
|
91
91
|
3289396102: string;
|
|
92
92
|
2680512478: string;
|
|
93
|
+
4087948362: string;
|
|
93
94
|
480546647: string;
|
|
94
95
|
3184373440: string;
|
|
95
96
|
2303962423: string;
|
|
@@ -145,7 +146,7 @@ export declare const AllTLObject: {
|
|
|
145
146
|
935395612: string;
|
|
146
147
|
476978193: string;
|
|
147
148
|
2426849924: string;
|
|
148
|
-
|
|
149
|
+
2629079273: string;
|
|
149
150
|
2055212554: string;
|
|
150
151
|
1038967584: string;
|
|
151
152
|
1766936791: string;
|
|
@@ -159,7 +160,7 @@ export declare const AllTLObject: {
|
|
|
159
160
|
4138027219: string;
|
|
160
161
|
3108030054: string;
|
|
161
162
|
1272375192: string;
|
|
162
|
-
|
|
163
|
+
147581959: string;
|
|
163
164
|
1758159491: string;
|
|
164
165
|
2852600811: string;
|
|
165
166
|
3467263649: string;
|
|
@@ -212,8 +213,8 @@ export declare const AllTLObject: {
|
|
|
212
213
|
1102307842: string;
|
|
213
214
|
1171632161: string;
|
|
214
215
|
2953594786: string;
|
|
215
|
-
|
|
216
|
-
|
|
216
|
+
3928764883: string;
|
|
217
|
+
3871544610: string;
|
|
217
218
|
2887720909: string;
|
|
218
219
|
2226685304: string;
|
|
219
220
|
805187450: string;
|
|
@@ -224,6 +225,10 @@ export declare const AllTLObject: {
|
|
|
224
225
|
1777932024: string;
|
|
225
226
|
2829305497: string;
|
|
226
227
|
747579941: string;
|
|
228
|
+
2000845012: string;
|
|
229
|
+
1940760427: string;
|
|
230
|
+
2961100933: string;
|
|
231
|
+
3783807035: string;
|
|
227
232
|
3582593222: string;
|
|
228
233
|
1908216652: string;
|
|
229
234
|
590459437: string;
|
|
@@ -449,6 +454,8 @@ export declare const AllTLObject: {
|
|
|
449
454
|
1048963372: string;
|
|
450
455
|
1222788802: string;
|
|
451
456
|
3696816926: string;
|
|
457
|
+
4221326458: string;
|
|
458
|
+
2886149188: string;
|
|
452
459
|
2775329342: string;
|
|
453
460
|
1567990072: string;
|
|
454
461
|
16030880: string;
|
|
@@ -621,24 +628,24 @@ export declare const AllTLObject: {
|
|
|
621
628
|
3556320491: string;
|
|
622
629
|
3262826695: string;
|
|
623
630
|
1300890265: string;
|
|
624
|
-
|
|
625
|
-
|
|
626
|
-
|
|
627
|
-
|
|
628
|
-
|
|
629
|
-
|
|
630
|
-
|
|
631
|
-
|
|
632
|
-
|
|
633
|
-
|
|
634
|
-
|
|
635
|
-
|
|
636
|
-
|
|
637
|
-
|
|
638
|
-
|
|
639
|
-
|
|
640
|
-
|
|
641
|
-
|
|
631
|
+
2098662655: string;
|
|
632
|
+
3624674796: string;
|
|
633
|
+
3861629280: string;
|
|
634
|
+
1098841487: string;
|
|
635
|
+
2856384845: string;
|
|
636
|
+
2568198652: string;
|
|
637
|
+
2311426297: string;
|
|
638
|
+
1067792645: string;
|
|
639
|
+
4111468281: string;
|
|
640
|
+
1744911986: string;
|
|
641
|
+
2047989634: string;
|
|
642
|
+
2103314375: string;
|
|
643
|
+
3237829897: string;
|
|
644
|
+
3896947104: string;
|
|
645
|
+
3780920176: string;
|
|
646
|
+
1527715317: string;
|
|
647
|
+
45580630: string;
|
|
648
|
+
3167006480: string;
|
|
642
649
|
2002815875: string;
|
|
643
650
|
2688441221: string;
|
|
644
651
|
2259946248: string;
|
|
@@ -1053,8 +1060,8 @@ export declare const AllTLObject: {
|
|
|
1053
1060
|
4224893590: string;
|
|
1054
1061
|
3921323624: string;
|
|
1055
1062
|
3896830975: string;
|
|
1056
|
-
|
|
1057
|
-
|
|
1063
|
+
855293722: string;
|
|
1064
|
+
1648005024: string;
|
|
1058
1065
|
2849430303: string;
|
|
1059
1066
|
3216354699: string;
|
|
1060
1067
|
547062491: string;
|
|
@@ -1083,7 +1090,7 @@ export declare const AllTLObject: {
|
|
|
1083
1090
|
1355547603: string;
|
|
1084
1091
|
3480186296: string;
|
|
1085
1092
|
835375875: string;
|
|
1086
|
-
|
|
1093
|
+
29770178: string;
|
|
1087
1094
|
1218005070: string;
|
|
1088
1095
|
4117234314: string;
|
|
1089
1096
|
1042605427: string;
|
|
@@ -1460,8 +1467,8 @@ export declare const AllTLObject: {
|
|
|
1460
1467
|
1269016922: string;
|
|
1461
1468
|
2496562474: string;
|
|
1462
1469
|
1411605001: string;
|
|
1463
|
-
|
|
1464
|
-
|
|
1470
|
+
825922887: string;
|
|
1471
|
+
2247141837: string;
|
|
1465
1472
|
2743640936: string;
|
|
1466
1473
|
785918357: string;
|
|
1467
1474
|
2030298073: string;
|
|
@@ -1481,16 +1488,16 @@ export declare const AllTLObject: {
|
|
|
1481
1488
|
2194268816: string;
|
|
1482
1489
|
2966251031: string;
|
|
1483
1490
|
4181513308: string;
|
|
1484
|
-
|
|
1485
|
-
|
|
1486
|
-
|
|
1491
|
+
1448235490: string;
|
|
1492
|
+
1315997162: string;
|
|
1493
|
+
2670003428: string;
|
|
1487
1494
|
3770675820: string;
|
|
1488
1495
|
1038213101: string;
|
|
1489
1496
|
1658259128: string;
|
|
1490
1497
|
828000628: string;
|
|
1491
1498
|
1097619176: string;
|
|
1492
1499
|
2358937772: string;
|
|
1493
|
-
|
|
1500
|
+
1105150972: string;
|
|
1494
1501
|
2515765681: string;
|
|
1495
1502
|
1764202389: string;
|
|
1496
1503
|
4043418239: string;
|
|
@@ -1552,17 +1559,38 @@ export declare const AllTLObject: {
|
|
|
1552
1559
|
1897752877: string;
|
|
1553
1560
|
822231244: string;
|
|
1554
1561
|
4264769874: string;
|
|
1555
|
-
|
|
1556
|
-
|
|
1562
|
+
1998212710: string;
|
|
1563
|
+
2536352703: string;
|
|
1557
1564
|
787403204: string;
|
|
1558
|
-
|
|
1559
|
-
|
|
1565
|
+
1798960364: string;
|
|
1566
|
+
1118831432: string;
|
|
1560
1567
|
2103169520: string;
|
|
1561
1568
|
3541812317: string;
|
|
1562
1569
|
3677608656: string;
|
|
1563
|
-
|
|
1570
|
+
2935401404: string;
|
|
1564
1571
|
48327832: string;
|
|
1565
1572
|
2058715912: string;
|
|
1573
|
+
2556509887: string;
|
|
1574
|
+
4175473180: string;
|
|
1575
|
+
3781909729: string;
|
|
1576
|
+
3791878025: string;
|
|
1577
|
+
1046713180: string;
|
|
1578
|
+
3273638218: string;
|
|
1579
|
+
1009235855: string;
|
|
1580
|
+
1528613672: string;
|
|
1581
|
+
2952094616: string;
|
|
1582
|
+
984483112: string;
|
|
1583
|
+
178266597: string;
|
|
1584
|
+
1187439471: string;
|
|
1585
|
+
3660240455: string;
|
|
1586
|
+
1508266805: string;
|
|
1587
|
+
1155883043: string;
|
|
1588
|
+
910391095: string;
|
|
1589
|
+
3687736201: string;
|
|
1590
|
+
4035793259: string;
|
|
1591
|
+
2029777832: string;
|
|
1592
|
+
3472353192: string;
|
|
1593
|
+
1339896880: string;
|
|
1566
1594
|
3416209197: string;
|
|
1567
1595
|
1036301552: string;
|
|
1568
1596
|
3251461801: string;
|
|
@@ -1598,6 +1626,8 @@ export declare const AllTLObject: {
|
|
|
1598
1626
|
2123760019: string;
|
|
1599
1627
|
3416125430: string;
|
|
1600
1628
|
1457889180: string;
|
|
1629
|
+
1368051895: string;
|
|
1630
|
+
2555882759: string;
|
|
1601
1631
|
3968205178: string;
|
|
1602
1632
|
1779249670: string;
|
|
1603
1633
|
2227067795: string;
|
|
@@ -1717,6 +1747,10 @@ export declare const AllTLObject: {
|
|
|
1717
1747
|
2993107625: string;
|
|
1718
1748
|
3768410031: string;
|
|
1719
1749
|
3828148681: string;
|
|
1750
|
+
1117079528: string;
|
|
1751
|
+
1437867990: string;
|
|
1752
|
+
3927903314: string;
|
|
1753
|
+
4122302015: string;
|
|
1720
1754
|
227648840: string;
|
|
1721
1755
|
3054459160: string;
|
|
1722
1756
|
2429064373: string;
|
|
@@ -1763,7 +1797,7 @@ export declare const AllTLObject: {
|
|
|
1763
1797
|
1486110434: string;
|
|
1764
1798
|
1415369050: string;
|
|
1765
1799
|
53536639: string;
|
|
1766
|
-
|
|
1800
|
+
326126204: string;
|
|
1767
1801
|
3474297563: string;
|
|
1768
1802
|
4024018594: string;
|
|
1769
1803
|
4235767707: string;
|
|
@@ -1989,6 +2023,8 @@ export declare const AllTLObject: {
|
|
|
1989
2023
|
242762224: string;
|
|
1990
2024
|
798540757: string;
|
|
1991
2025
|
3531697936: string;
|
|
2026
|
+
4219374759: string;
|
|
2027
|
+
2638284002: string;
|
|
1992
2028
|
3990128682: string;
|
|
1993
2029
|
432207715: string;
|
|
1994
2030
|
51854712: string;
|
|
@@ -2089,6 +2125,7 @@ export declare const AllTLObject: {
|
|
|
2089
2125
|
3974275302: string;
|
|
2090
2126
|
576090389: string;
|
|
2091
2127
|
897842353: string;
|
|
2128
|
+
2684950703: string;
|
|
2092
2129
|
2854709741: string;
|
|
2093
2130
|
3860938573: string;
|
|
2094
2131
|
85399130: string;
|
|
@@ -2179,6 +2216,11 @@ export declare const AllTLObject: {
|
|
|
2179
2216
|
1553986774: string;
|
|
2180
2217
|
1805831148: string;
|
|
2181
2218
|
2781892941: string;
|
|
2219
|
+
3922622492: string;
|
|
2220
|
+
2411227969: string;
|
|
2221
|
+
1828948824: string;
|
|
2222
|
+
4245019904: string;
|
|
2223
|
+
2969135183: string;
|
|
2182
2224
|
2418125671: string;
|
|
2183
2225
|
4151709521: string;
|
|
2184
2226
|
4290172106: string;
|