itd-api 0.14.5 → 0.14.6
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/events/index.cjs +2 -2
- package/dist/events/index.d.cts +2 -2
- package/dist/events/index.d.ts +2 -2
- package/dist/events/index.js +2 -2
- package/dist/index.cjs +32 -8
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +16 -35
- package/dist/index.d.ts +16 -35
- package/dist/index.js +32 -8
- package/dist/index.js.map +1 -1
- package/dist/rest/index.cjs +2 -2
- package/dist/rest/index.d.cts +2 -2
- package/dist/rest/index.d.ts +2 -2
- package/dist/rest/index.js +2 -2
- package/dist/shared/{events-CMhrmHei.d.cts → events-BsmLCdog.d.cts} +1 -1
- package/dist/shared/{events-Cupq8UXH.d.ts → events-By7baZfE.d.ts} +1 -1
- package/dist/shared/{events-C3Wup3mC.cjs → events-DFQSN5H6.cjs} +2 -2
- package/dist/shared/{events-C3Wup3mC.cjs.map → events-DFQSN5H6.cjs.map} +1 -1
- package/dist/shared/{events-BbpL69OD.js → events-DorlX-Xd.js} +2 -2
- package/dist/shared/{events-BbpL69OD.js.map → events-DorlX-Xd.js.map} +1 -1
- package/dist/shared/{render-ByW1tXn-.d.cts → render-CZoSZHnh.d.cts} +92 -53
- package/dist/shared/{render-BXeYbuuY.cjs → render-CklT-3gT.cjs} +2 -2
- package/dist/shared/render-CklT-3gT.cjs.map +1 -0
- package/dist/shared/{render-C706i1rL.js → render-DBt-OBbC.js} +2 -2
- package/dist/shared/render-DBt-OBbC.js.map +1 -0
- package/dist/shared/{render-B3nhAeaQ.d.ts → render-DOxbtUga.d.ts} +92 -53
- package/dist/shared/{url-Duzw4X6d.cjs → url-CStw2h1g.cjs} +12 -2
- package/dist/shared/url-CStw2h1g.cjs.map +1 -0
- package/dist/shared/{url-CZpgaPdI.js → url-DTDqkKpf.js} +12 -2
- package/dist/shared/url-DTDqkKpf.js.map +1 -0
- package/dist/shared/{url-DHWmfmrE.d.cts → url-Ls6HGxZl.d.cts} +11 -1
- package/dist/shared/{url-D4bo3tpX.d.ts → url-U1Q7c-SD.d.ts} +11 -1
- package/package.json +1 -1
- package/dist/shared/render-BXeYbuuY.cjs.map +0 -1
- package/dist/shared/render-C706i1rL.js.map +0 -1
- package/dist/shared/url-CZpgaPdI.js.map +0 -1
- package/dist/shared/url-Duzw4X6d.cjs.map +0 -1
package/dist/index.d.cts
CHANGED
|
@@ -3,9 +3,9 @@
|
|
|
3
3
|
*
|
|
4
4
|
* @packageDocumentation
|
|
5
5
|
*/
|
|
6
|
-
import { $ as RateLimitBucketContext, $t as ItdValidationError, A as ClientConnection, An as LikesVisibility, At as BUCKET_LIMITS, B as DEFAULT_BASE_URL, Bn as ViewReason, Bt as ItdError, C as SubscriptionState, Cn as CommentSort, Ct as ItdOperationDefinition, D as Emitter, Dn as InteractionType, Dt as operationBucket, E as UsernameAvailability, En as IncidentKind, Et as isBuiltInOperationId, Fn as ReportReason, Ft as ItdApiErrorInit, Gt as ItdForbiddenError, H as LIBRARY_VERSION, Hn as WallAccess, Ht as ItdFieldErrors, I as HttpClient, In as ReportTargetType, It as ItdApiErrorKind, J as RetrySafety, Jt as ItdPhoneVerificationError, K as OperationMetadata, Kt as ItdNetworkError, Ln as ServiceState, Lt as ItdAuthError, M as AuthProvider, Mn as MessageAccess, Mt as RateLimitBucket, Nn as NotificationType, Nt as ItdAbortError, O as Listener, On as ItdErrorCode, Ot as operationMethod, Pn as QrLocationPrecision, Pt as ItdApiError, Q as PaginationOptions, Qt as ItdTimeoutError, R as RateLimitBucketState, Rn as SpanType, Rt as ItdConfigError, S as PublicProfile, Sn as CaptchaType, St as CustomOperationId, T as UserSummary, Tn as FeedTab, Tt as OperationId, U as FeatureOperationId, Ut as ItdFileError, V as STATUS_SERVICE, Vn as ViewSource, Vt as ItdErrorKind, W as OperationAnnotations, Wt as ItdFileErrorReason, X as ErrorContextHook, Xt as ItdServerError, Y as ClientHooks, Yt as ItdRateLimitError, Z as OperationRequestOptions, Zt as ItdStateError, _ as MyProfile, _n as UserRef, _t as LogLevel, a as NotificationEvent, an as isItdError, at as RequestOptions, b as PrivacySettings, bn as CaptchaChoice, bt as systemClock, c as NotificationSettings, cn as isItdNotFoundError, ct as RetryDecisionContext, d as AuthUser, dn as isItdServerError, dt as QueryParams, en as RateLimitErrorScope, et as RateLimitBucketOverride, f as Author, fn as isItdStateError, ft as QueryValue, g as MessageAllowlistUser, gn as UserId, gt as createUuidV4, h as MessageAllowlistMembership, hn as Span, ht as RuntimeMode, i as formatNotificationText, in as isItdConflictError, it as RequestExtensions, j as AuthIdentity, jn as Loose, jt as DEFAULT_RATE_LIMIT_BUCKET, k as Unsubscribe, kn as LastSeenUnit, kt as operationRetrySafety, l as Actor, ln as isItdPhoneVerificationError, lt as RetryOptions, m as LastSeen, mn as IsoDate, mt as RateLimitPacing, n as canonicalNotificationType, nn as isItdApiError, nt as RawRequestOptions, o as normalizeNotification, on as isItdFileError, ot as ResponseContext, p as FollowResult, pn as isItdValidationError, pt as ServiceDefinition, q as OperationMethod, qt as ItdNotFoundError, r as isKnownNotificationType, rn as isItdAuthError, rt as RequestContext, s as Notification, sn as isItdForbiddenError, st as RetryContext, t as resolveNotificationUrl, tn as TimeoutBudget, tt as RateLimitOptions, u as AuthState, un as isItdRateLimitError, ut as RuntimeOptions, v as Pin, vn as AccessType, vt as Logger, w as UserBase, wn as EventChannelStatus, wt as OPERATIONS, x as Profile, xn as CaptchaField, xt as BuiltInOperationId, y as PinsResult, yn as AttachmentType, yt as ItdClock, z as CookieJar, zn as UsernameUnavailableReason, zt as ItdConflictError } from "./shared/url-
|
|
7
|
-
import { $ as InternationalSubscriptionCheckoutMode, $i as
|
|
8
|
-
import { $ as EventTransportFrame, A as EventSequentializer, B as NotificationOfType, C as EventSession, D as EventMiddlewareObject, E as EventMiddleware, F as NotificationEventContext, G as UnknownNotificationUpdate, H as NotificationUpdateOfType, I as NotificationEventFilter, J as NotificationEventsMap, K as UnreadCountUpdate, L as NotificationEventOfType, M as runEventMiddleware, N as EventContext, O as EventNext, P as NotificationContext, Q as EventTransportContext, R as NotificationEventSelector, S as EventEnqueueOptions, T as EventHandler, U as NotificationUpdateOrigin, V as NotificationUpdate, W as NotificationUpdateType, X as NotificationEventsTransport, Y as NotificationEventsOptions, Z as EventTransport, _ as WebSocketTransportOptions, a as EventMiddlewareGroup, b as EventChannelEvents, c as EventRouteSelector, d as NotificationEventsClientOptions, et as UnauthorizedStreamError, f as createNotificationEventsClient, g as WebSocketTransport, h as WebSocketOpenFailureClassifier, i as EventFilter, j as EventTypeGuard, k as EventPredicate, l as EventRouter, m as WebSocketLike, n as EventErrorBoundary, o as EventMiddlewareLike, p as WebSocketImplementationOptions, q as NotificationEvents, r as EventErrorContext, s as EventRouteTable, t as EventComposer, tt as ReconnectOptions, u as NotificationEventsClient, v as EventChannel, w as EventSyncReason, x as EventChannelOptions, y as EventChannelDeps, z as NotificationEventsUpdate } from "./shared/events-
|
|
6
|
+
import { $ as RateLimitBucketContext, $t as ItdValidationError, A as ClientConnection, An as LikesVisibility, At as BUCKET_LIMITS, B as DEFAULT_BASE_URL, Bn as ViewReason, Bt as ItdError, C as SubscriptionState, Cn as CommentSort, Ct as ItdOperationDefinition, D as Emitter, Dn as InteractionType, Dt as operationBucket, E as UsernameAvailability, En as IncidentKind, Et as isBuiltInOperationId, Fn as ReportReason, Ft as ItdApiErrorInit, Gt as ItdForbiddenError, H as LIBRARY_VERSION, Hn as WallAccess, Ht as ItdFieldErrors, I as HttpClient, In as ReportTargetType, It as ItdApiErrorKind, J as RetrySafety, Jt as ItdPhoneVerificationError, K as OperationMetadata, Kt as ItdNetworkError, Ln as ServiceState, Lt as ItdAuthError, M as AuthProvider, Mn as MessageAccess, Mt as RateLimitBucket, Nn as NotificationType, Nt as ItdAbortError, O as Listener, On as ItdErrorCode, Ot as operationMethod, Pn as QrLocationPrecision, Pt as ItdApiError, Q as PaginationOptions, Qt as ItdTimeoutError, R as RateLimitBucketState, Rn as SpanType, Rt as ItdConfigError, S as PublicProfile, Sn as CaptchaType, St as CustomOperationId, T as UserSummary, Tn as FeedTab, Tt as OperationId, U as FeatureOperationId, Ut as ItdFileError, V as STATUS_SERVICE, Vn as ViewSource, Vt as ItdErrorKind, W as OperationAnnotations, Wt as ItdFileErrorReason, X as ErrorContextHook, Xt as ItdServerError, Y as ClientHooks, Yt as ItdRateLimitError, Z as OperationRequestOptions, Zt as ItdStateError, _ as MyProfile, _n as UserRef, _t as LogLevel, a as NotificationEvent, an as isItdError, at as RequestOptions, b as PrivacySettings, bn as CaptchaChoice, bt as systemClock, c as NotificationSettings, cn as isItdNotFoundError, ct as RetryDecisionContext, d as AuthUser, dn as isItdServerError, dt as QueryParams, en as RateLimitErrorScope, et as RateLimitBucketOverride, f as Author, fn as isItdStateError, ft as QueryValue, g as MessageAllowlistUser, gn as UserId, gt as createUuidV4, h as MessageAllowlistMembership, hn as Span, ht as RuntimeMode, i as formatNotificationText, in as isItdConflictError, it as RequestExtensions, j as AuthIdentity, jn as Loose, jt as DEFAULT_RATE_LIMIT_BUCKET, k as Unsubscribe, kn as LastSeenUnit, kt as operationRetrySafety, l as Actor, ln as isItdPhoneVerificationError, lt as RetryOptions, m as LastSeen, mn as IsoDate, mt as RateLimitPacing, n as canonicalNotificationType, nn as isItdApiError, nt as RawRequestOptions, o as normalizeNotification, on as isItdFileError, ot as ResponseContext, p as FollowResult, pn as isItdValidationError, pt as ServiceDefinition, q as OperationMethod, qt as ItdNotFoundError, r as isKnownNotificationType, rn as isItdAuthError, rt as RequestContext, s as Notification, sn as isItdForbiddenError, st as RetryContext, t as resolveNotificationUrl, tn as TimeoutBudget, tt as RateLimitOptions, u as AuthState, un as isItdRateLimitError, ut as RuntimeOptions, v as Pin, vn as AccessType, vt as Logger, w as UserBase, wn as EventChannelStatus, wt as OPERATIONS, x as Profile, xn as CaptchaField, xt as BuiltInOperationId, y as PinsResult, yn as AttachmentType, yt as ItdClock, z as CookieJar, zn as UsernameUnavailableReason, zt as ItdConflictError } from "./shared/url-Ls6HGxZl.cjs";
|
|
7
|
+
import { $ as InternationalSubscriptionCheckoutMode, $i as ResolveFileContext, $n as Poll, $r as CreateCommentInput, $t as ReportsResource, A as UsersResource, Ai as ChatReadCursor, An as Report, Ar as Page, At as ShopDeliveryDestination, B as ViewTracker, Bi as ChatUploadOptions, Bn as BannerDrawingPoint, Br as MessageMarkupBuilder, Bt as ShopOrderSummary, C as fromStream, Ci as ChatMessageReactions, Cn as StatusDay, Cr as NotificationsResource, Ct as ShopConsent, D as UpdatePrivacyInput, Di as ChatReactionCatalog, Dn as ChangelogEntry, Dr as ForwardChatMessagesInput, Dt as ShopDeliveryCalculation, E as MessageAllowlistParams, Ei as ChatReaction, En as AnnouncementButton, Er as ChatsResource, Et as ShopCreatedOrder, F as TelemetryBatchOptions, Fi as ChatTextEntity, Fn as FilesResource, Fr as mapPage, Ft as ShopOrderBase, G as SubscriptionCheckoutReleaseInput, Gi as FeatureInstallation, Gn as Attachment, Gr as MarkupBuilder, Gt as ShopProductColor, H as ViewTrackerOptions, Hi as ClientFeature, Hn as UploadedBannerDrawing, Hr as MessageMarkupInput, Ht as ShopPayment, I as TelemetryClock, Ii as ChatUnreadState, In as UploadOptions, Ir as MessageBuilder, It as ShopOrderDelivery, J as SubscriptionPayOptions, Ji as ManagedClientResource, Jn as CommentUpdateResult, Jr as MarkupSpan, Jt as ShopRecipient, K as SubscriptionCheckoutTerms, Ki as FeatureOperationDefinition, Kn as Comment, Kr as MarkupContent, Kt as ShopProductSpec, L as TelemetryOptions, Li as ChatUpdate, Ln as UploadedFile, Lr as MessageInput, Lt as ShopOrderItem, M as InteractionEntry, Mi as ChatReply, Mn as LegalResource, Mr as PaginationMode, Mt as ShopOrder, N as PhotoOpenInput, Ni as ChatSentMessage, Nn as HashtagPostsParams, Nr as Paginator, Nt as ShopOrderAccessSession, O as UpdateProfileInput, Oi as ChatReactionCount, On as Clan, Or as SetChatReactionsInput, Ot as ShopDeliveryCity, P as TelemetryBatch, Pi as ChatSummary, Pn as HashtagsResource, Pr as PaginatorOptions, Pt as ShopOrderAccessVerification, Q as InternationalSubscriptionCheckout, Qi as PreparedStreamSource, Qn as PinPostResult, Qr as ChatMessageContent, Qt as SearchResult, R as TelemetryResource, Ri as ChatUpdateType, Rn as BannerDrawing, Rr as message, Rt as ShopOrderItemInput, S as VideoMimeType, Si as ChatMessage, Sn as ServiceStatus, Sr as NotificationListParams, St as CreateShopOrderInput, T as VerificationResource, Ti as ChatPreview, Tn as Announcement, Tr as ChatListParams, Tt as ShopConsentKind, U as SubscriptionBindCardOptions, Ui as FeatureBucketDefinition, Un as CommentsResource, Ur as messageMarkup, Ut as ShopProduct, V as ViewTrackerInput, Vi as ChatUploadedFile, Vn as BannerDrawingTool, Vr as MessageMarkupContent, Vt as ShopOrderSupport, W as SubscriptionCheckoutInput, Wi as FeatureContext, Wn as RepliesParams, Wr as AutoSpansOptions, Wt as ShopProductCategory, X as SubscriptionResource, Xi as PreparedBufferSource, Xn as LikeResult, Xr as autoSpans, Xt as ShopSizeChartRow, Y as SubscriptionPaymentInput, Yi as FileResolver, Yn as Hashtag, Yr as TextMarkup, Yt as ShopSizeChart, Z as InternationalSubscriptionCapability, Zi as PreparedFileSource, Zn as OriginalPost, Zr as markup, Zt as SearchResource, _ as AllowedMimeType, _i as ChatHistoryPage, _n as parseMarkdown, _r as LegalDocumentSummary, _t as ShopDeliveryResource, a as ShopFeatureOptions, aa as ClientPlugin, ai as BuilderInput, an as PostsResource, ar as PostUpdateResult, at as SubscriptionCheckoutState, b as ImageMimeType, bi as ChatMediaItem, bn as PlatformVersions, br as QrLoginTarget, bt as ShopProductsResource, c as ShopOrderAccessStorage, ca as OperationTransformer, ci as ChatActionType, cn as PostBuilder, cr as CommentInput, ct as SubscriptionGift, d as statusDays, di as ChatDeletedMessages, dn as post, dr as ConsentContext, dt as SubscriptionPaymentProvider, ea as ResolveFileOptions, ei as CreatePollInput, en as ReportBuilder, er as PollOption, et as InternationalSubscriptionOffer, f as isMyProfile, fi as ChatDirectResult, fn as PollBuilder, fr as ConsentDocument, ft as SubscriptionQuote, g as AUDIO_MIME_TYPES, gi as ChatForwardedMessages, gn as parseHtml, gr as LegalDocumentScope, gt as ShopConsentsResource, h as ALLOWED_MIME_TYPES, hi as ChatFirstMessage, hn as ParseMarkupOptions, hr as LegalDocumentBlockType, ht as PayShopOrderOptions, i as ShopFeatureApi, ia as AttemptNext, ii as UpdatePostInput, in as FeedParams, ir as PostStats, it as SubscriptionCheckoutKind, j as DwellEntry, ji as ChatReadResult, jn as VerificationStatus, jr as PageState, jt as ShopDeliveryPoint, k as UserListParams, ki as ChatReactionType, kn as Portal, kr as BaseResource, kt as ShopDeliveryCountry, l as ShopOrderAccessStorageAdapterOptions, la as PluginApi, li as ChatAttachment, ln as PostInput, lr as comment, lt as SubscriptionOffer, m as utcStampToIso, mi as ChatFileLink, mn as poll, mr as LegalDocumentBlock, mt as CreateShopOrderOptions, n as SpanRenderFormat, na as AttemptExtensions, ni as CreateReportInput, nn as report, nr as PostBase, nt as PaymentMethodType, o as createShopFeature, oa as OperationExtensions, oi as ItdBuilder, on as UserPostsParams, or as UpdateResultBase, ot as SubscriptionCheckoutStatus, p as toDate, pi as ChatEditedMessage, pn as PollInput, pr as LegalDocument, pt as SubscriptionRenewalAgreement, q as SubscriptionGiftInput, qi as FeatureRequestOptions, qn as CommentReplyTo, qr as MarkupInput, qt as ShopProductStatus, r as renderSpans, ra as AttemptInterceptor, ri as SendChatMessageInput, rn as CommentsParams, rr as PostCounters, rt as Subscription, s as MemoryShopOrderAccessStorage, sa as OperationTransformContext, si as isBuilder, sn as CreatePostInput, sr as CommentBuilder, st as SubscriptionCheckoutSubject, t as RenderSpansOptions, ta as AttemptContext, ti as CreatePostData, tn as ReportInput, tr as Post, tt as PaymentMethod, u as createShopOrderAccessStorage, ua as PluginTeardown, ui as ChatChange, un as PostUpdateInput, ur as AccountLifecycleResource, ut as SubscriptionPayment, v as AudioMimeType, vi as ChatListPage, vn as PlatformClientVersion, vr as LegalDocumentVersion, vt as ShopOrderRequestOptions, w as fromUrl, wi as ChatPresence, wn as StatusIncidentLine, wr as UpdateNotificationSettingsInput, wt as ShopConsentContext, x as VIDEO_MIME_TYPES, xi as ChatMediaPage, xn as PlatformStatus, xr as Session, xt as ShopResource, y as IMAGE_MIME_TYPES, yi as ChatMediaCategory, yn as PlatformResource, yr as TermsAcceptance, yt as ShopOrdersResource, z as VideoProgressInput, zi as ChatUpdatesPage, zn as BannerDrawingOperation, zr as MessageMarkup, zt as ShopOrderStatus } from "./shared/render-CZoSZHnh.cjs";
|
|
8
|
+
import { $ as EventTransportFrame, A as EventSequentializer, B as NotificationOfType, C as EventSession, D as EventMiddlewareObject, E as EventMiddleware, F as NotificationEventContext, G as UnknownNotificationUpdate, H as NotificationUpdateOfType, I as NotificationEventFilter, J as NotificationEventsMap, K as UnreadCountUpdate, L as NotificationEventOfType, M as runEventMiddleware, N as EventContext, O as EventNext, P as NotificationContext, Q as EventTransportContext, R as NotificationEventSelector, S as EventEnqueueOptions, T as EventHandler, U as NotificationUpdateOrigin, V as NotificationUpdate, W as NotificationUpdateType, X as NotificationEventsTransport, Y as NotificationEventsOptions, Z as EventTransport, _ as WebSocketTransportOptions, a as EventMiddlewareGroup, b as EventChannelEvents, c as EventRouteSelector, d as NotificationEventsClientOptions, et as UnauthorizedStreamError, f as createNotificationEventsClient, g as WebSocketTransport, h as WebSocketOpenFailureClassifier, i as EventFilter, j as EventTypeGuard, k as EventPredicate, l as EventRouter, m as WebSocketLike, n as EventErrorBoundary, o as EventMiddlewareLike, p as WebSocketImplementationOptions, q as NotificationEvents, r as EventErrorContext, s as EventRouteTable, t as EventComposer, tt as ReconnectOptions, u as NotificationEventsClient, v as EventChannel, w as EventSyncReason, x as EventChannelOptions, y as EventChannelDeps, z as NotificationEventsUpdate } from "./shared/events-BsmLCdog.cjs";
|
|
9
9
|
import { a as createTokenStorage, i as TokenStorageAdapterOptions, n as MemoryTokenStorage, r as TokenStorage, t as ItdSession } from "./shared/storage-FtS4NIC7.cjs";
|
|
10
10
|
import { a as scopedTokenStorage, i as createMultiTokenStorage, n as MultiTokenStorage, r as MultiTokenStorageAdapterOptions, t as MemoryMultiTokenStorage } from "./shared/multi-storage-OGWNMK3x.cjs";
|
|
11
11
|
import { a as FileStreamOptions, c as LazyFile, d as UrlFileOptions, i as FileStreamContent, l as StreamFile, n as FileContext, o as FileTransferMode, r as FileInput, s as FromStreamOptions, t as FileContent, u as UrlFile } from "./shared/contracts-DEbkC0cB.cjs";
|
|
@@ -318,50 +318,23 @@ interface PhoneRegion {
|
|
|
318
318
|
example: string;
|
|
319
319
|
/** Способы подтверждения, доступные в регионе. */
|
|
320
320
|
methods: PhoneVerificationMethod[];
|
|
321
|
+
/** Код может прийти в сообщении ИТД. */
|
|
322
|
+
message?: boolean;
|
|
321
323
|
}
|
|
322
324
|
/** Серверный список регионов, доступных для телефонного входа. */
|
|
323
325
|
interface PhoneConfig {
|
|
324
326
|
regions: PhoneRegion[];
|
|
325
327
|
defaultRegion: string;
|
|
326
328
|
}
|
|
327
|
-
/** Редакция документа, включённая в контекст согласия. */
|
|
328
|
-
interface ConsentDocument {
|
|
329
|
-
scope: string;
|
|
330
|
-
slug: string;
|
|
331
|
-
version: string;
|
|
332
|
-
contentSha256: string;
|
|
333
|
-
url: string;
|
|
334
|
-
}
|
|
335
329
|
/** Текст и редакции документов, с которыми пользователь соглашается при входе. */
|
|
336
|
-
interface PhoneConsent {
|
|
337
|
-
/** Версия протокола из consent(); передаётся серверу вместе с contextToken. */
|
|
338
|
-
protocolVersion: number;
|
|
339
|
-
/** Подписанный контекст; в start() передаётся без изменения. */
|
|
340
|
-
contextToken: string;
|
|
341
|
-
id: string;
|
|
342
|
-
/** Время выдачи контекста, Unix-время в миллисекундах. */
|
|
343
|
-
issuedAt: number;
|
|
344
|
-
/** Срок действия контекста, Unix-время в миллисекундах. */
|
|
345
|
-
expiresAt: number;
|
|
346
|
-
bundle: {
|
|
347
|
-
id: string;
|
|
348
|
-
flow: typeof PHONE_CONSENT_FLOW;
|
|
349
|
-
documents: ConsentDocument[];
|
|
350
|
-
actions: Record<string, string>;
|
|
351
|
-
actionVersion: string;
|
|
352
|
-
submitLabel: string;
|
|
353
|
-
text: {
|
|
354
|
-
text: string;
|
|
355
|
-
document?: string;
|
|
356
|
-
}[];
|
|
357
|
-
};
|
|
358
|
-
}
|
|
330
|
+
interface PhoneConsent extends ConsentContext<typeof PHONE_CONSENT_FLOW> {}
|
|
359
331
|
/** Серверные каналы доставки кода. */
|
|
360
332
|
export declare const PhoneDeliveryChannel: Readonly<{
|
|
361
333
|
readonly MissedCall: "missed_call";
|
|
362
334
|
readonly VoiceCall: "voice_call";
|
|
363
335
|
readonly Sms: "sms";
|
|
364
336
|
readonly Push: "push";
|
|
337
|
+
readonly Message: "message";
|
|
365
338
|
}>;
|
|
366
339
|
export type PhoneDeliveryChannel = Loose<(typeof PhoneDeliveryChannel)[keyof typeof PhoneDeliveryChannel]>;
|
|
367
340
|
/** Подтверждение входящим кодом либо исходящим звонком пользователя. */
|
|
@@ -904,6 +877,14 @@ declare class AccountResource extends AccountLifecycleResource {
|
|
|
904
877
|
* ```
|
|
905
878
|
*/
|
|
906
879
|
getInfo(options?: RequestOptions): Promise<AccountInfo>;
|
|
880
|
+
/** Возвращает текущую редакцию условий и контекст, если аккаунту требуется согласие. */
|
|
881
|
+
termsAcceptance(options?: RequestOptions): Promise<TermsAcceptance>;
|
|
882
|
+
/**
|
|
883
|
+
* Записывает согласие текущего аккаунта с редакцией условий.
|
|
884
|
+
*
|
|
885
|
+
* @param contextToken токен из контекста согласия, полученного через {@link termsAcceptance}
|
|
886
|
+
*/
|
|
887
|
+
acceptTerms(contextToken: string, options?: RequestOptions): Promise<void>;
|
|
907
888
|
}
|
|
908
889
|
/** Данные запуска телефонного входа после принятия документов пользователем. */
|
|
909
890
|
interface PhoneLoginInput {
|
|
@@ -1817,4 +1798,4 @@ export declare class ItdAccounts {
|
|
|
1817
1798
|
* То же, что `new ItdAccounts(options)`, — для тех, кому привычнее фабрика.
|
|
1818
1799
|
*/
|
|
1819
1800
|
export declare function createAccounts(options?: ItdAccountsOptions): ItdAccounts;
|
|
1820
|
-
export { ALLOWED_MIME_TYPES, AUDIO_MIME_TYPES, AccessType, type AccountChangesResource, type AccountEmailResource, type AccountEvents, type AccountFeature, type AccountInfo, type AccountLifecycleResource, type AccountPasswordResource, type AccountPhoneResource, type AccountPhoneStartInput, type AccountResource, type Actor, type AddAccountOptions, type AllowedMimeType, type Announcement, type AnnouncementButton, type Attachment, AttachmentType, type AttemptContext, type AttemptExtensions, type AttemptInterceptor, type AttemptNext, type AudioMimeType, type AuthEvents, type AuthIdentity, type AuthInput, type AuthProvider, type AuthResource, type AuthState, type AuthUser, type Author, type AutoSpansOptions, BUCKET_LIMITS, type BannerDrawing, type BannerDrawingOperation, type BannerDrawingPoint, BannerDrawingTool, type BuilderInput, type BuiltInOperationId, CaptchaChoice, CaptchaField, type CaptchaPage, type CaptchaProvider, type CaptchaSolveContext, type CaptchaSolver, type CaptchaSolverInput, type CaptchaToken, CaptchaType, type ChangelogEntry, ChatActionType, type ChatAttachment, type ChatChange, type ChatDeletedMessages, type ChatDirectResult, type ChatEditedMessage, type ChatEventContext, type ChatEventMap, type ChatEventsOptions, type ChatFileLink, type ChatFirstMessage, type ChatForwardedMessages, type ChatHistoryPage, type ChatListPage, type ChatListParams, ChatMediaCategory, type ChatMediaItem, type ChatMediaPage, type ChatMessage, type ChatMessageContent, type ChatMessageReactions, type ChatPresence, type ChatPreview, type ChatReaction, type ChatReactionCatalog, type ChatReactionCount, ChatReactionType, type ChatReadCursor, type ChatReadResult, type ChatReply, type ChatSentMessage, type ChatSummary, type ChatTextEntity, type ChatUnreadState, type ChatUpdate, ChatUpdateType, type ChatUpdatesPage, type ChatUploadOptions, type ChatUploadedFile, type ChatsApi, ChatsResource, type Clan, type ClientConnection, type ClientFeature, type ClientHooks, type ClientPlugin, type Comment, type CommentBuilder, type CommentInput, type CommentReplyTo, CommentSort, type CommentUpdateResult, type CommentsParams, type CommentsResource, type ConsentDocument, type ContactActionResult, type ContactChange, type ContactChangeConfirmation, type ContactChangeSchedule, type ContactProofDelivery, type CreateCommentInput, type CreatePollInput, type CreatePostData, type CreatePostInput, type CreateReportInput, type CreateShopOrderInput, type CreateShopOrderOptions, type Credentials, type CredentialsAuth, type CredentialsWithCaptcha, type CustomOperationId, DEFAULT_BASE_URL, DEFAULT_RATE_LIMIT_BUCKET, type DwellEntry, type EnumerableKeyValueStore, type ErrorContextHook, EventChannel, type EventChannelDeps, type EventChannelEvents, type EventChannelOptions, EventChannelStatus, EventComposer, type EventContext, type EventEnqueueOptions, type EventErrorBoundary, type EventErrorContext, type EventFilter, type EventHandler, type EventMiddleware, type EventMiddlewareGroup, type EventMiddlewareLike, type EventMiddlewareObject, type EventNext, type EventPredicate, type EventRouteSelector, type EventRouteTable, EventRouter, type EventSequentializer, type EventSession, type EventSyncReason, type EventTransport, type EventTransportContext, type EventTransportFrame, type EventTypeGuard, type FeatureBucketDefinition, type FeatureContext, type FeatureInstallation, type FeatureOperationDefinition, type FeatureOperationId, type FeatureRequestOptions, type FeedParams, FeedTab, type FileContent, type FileContext, type FileInput, type FileResolver, type FileStreamContent, type FileStreamOptions, FileTransferMode, type FilesResource, type FollowResult, type ForgotPasswordInput, type ForwardChatMessagesInput, type FromStreamOptions, type Hashtag, type HashtagPostsParams, type HashtagsResource, IMAGE_MIME_TYPES, type ImageMimeType, IncidentKind, type InteractionEntry, InteractionType, type InternationalSubscriptionCapability, type InternationalSubscriptionCheckout, InternationalSubscriptionCheckoutMode, type InternationalSubscriptionOffer, type IsoDate, ItdAbortError, type ItdAccountsOptions, ItdApiError, type ItdApiErrorInit, ItdApiErrorKind, ItdAuthError, type ItdBuilder, type ItdClientOptions, type ItdClock, ItdConfigError, ItdConflictError, ItdError, ItdErrorCode, ItdErrorKind, type ItdFieldErrors, ItdFileError, ItdFileErrorReason, ItdForbiddenError, ItdNetworkError, ItdNotFoundError, ItdPhoneVerificationError, ItdRateLimitError, ItdServerError, type ItdSession, ItdStateError, ItdTimeoutError, ItdValidationError, type KeyValueCodec, type KeyValueStore, type KeyValueStoreKeys, type KeyValueStoreResult, LIBRARY_VERSION, type LastSeen, LastSeenUnit, type LazyFile, type LegalDocument, type LegalDocumentBlock, LegalDocumentBlockType, LegalDocumentScope, type LegalDocumentSummary, type LegalDocumentVersion, type LegalResource, type LikeResult, LikesVisibility, type Listener, LogLevel, type Logger, type Loose, type ManagedClientResource, type MarkupBuilder, type MarkupContent, type MarkupInput, type MarkupSpan, MemoryKeyValueStore, MemoryMultiTokenStorage, MemoryShopOrderAccessStorage, MemoryTokenStorage, MessageAccess, type MessageAllowlistMembership, type MessageAllowlistParams, type MessageAllowlistUser, type MessageBuilder, type MessageInput, type MessageMarkup, type MessageMarkupBuilder, type MessageMarkupContent, type MessageMarkupInput, type MultiTokenStorage, type MultiTokenStorageAdapterOptions, type MyProfile, type Notification, type NotificationContext, type NotificationEvent, type NotificationEventContext, type NotificationEventFilter, type NotificationEventOfType, type NotificationEventSelector, NotificationEvents, NotificationEventsClient, type NotificationEventsClientOptions, type NotificationEventsMap, type NotificationEventsOptions, NotificationEventsTransport, type NotificationEventsUpdate, type NotificationListParams, type NotificationOfType, type NotificationSettings, NotificationType, type NotificationUpdate, type NotificationUpdateOfType, NotificationUpdateOrigin, NotificationUpdateType, type NotificationsApi, type NotificationsResource, OPERATIONS, type OperationAnnotations, type ItdOperationDefinition as OperationDefinition, type OperationExtensions, type OperationId, type OperationMetadata, OperationMethod, type OperationRequestOptions, type OperationTransformContext, type OperationTransformer, type OriginalPost, type Page, type PageState, PaginationMode, type PaginationOptions, Paginator, type PaginatorOptions, type ParseMarkupOptions, type PayShopOrderOptions, type PaymentMethod, PaymentMethodType, type PendingContactChange, type PhoneAuthResource, type PhoneConfig, type PhoneConsent, type PhoneDelivery, type PhoneFlowInput, type PhoneFlowResume, type PhoneFlowStart, type PhoneLoginInput, type PhoneLoginResult, type PhoneRegion, type PhoneReverseOptions, type PhoneReverseStatus, type PhotoOpenInput, type Pin, type PinPostResult, type PinsResult, type PlatformClientVersion, type PlatformResource, type PlatformStatus, type PlatformVersions, type PluginApi, type PluginTeardown, type Poll, type PollBuilder, type PollInput, type PollOption, type Portal, type Post, type PostBase, type PostBuilder, type PostCounters, type PostInput, type PostStats, type PostUpdateInput, type PostUpdateResult, type PostsResource, type PreparedBufferSource, type PreparedFileSource, type PreparedStreamSource, type PrivacySettings, type Profile, type PublicProfile, QrLocationPrecision, type QrLoginClaim, type QrLoginClaimInput, type QrLoginSecrets, type QrLoginStart, type QrLoginStreamEvent, type QrLoginStreamInput, type QrLoginStreamListener, type QrLoginStreamOptions, type QrLoginTarget, type QueryParams, type QueryValue, type RateLimitBucket, type RateLimitBucketContext, type RateLimitBucketOverride, type RateLimitBucketState, RateLimitErrorScope, type RateLimitOptions, RateLimitPacing, type RawRequestOptions, type ReconnectOptions, type RecordKeyValueStoreSource, type RemoveAccountOptions, type RenderSpansOptions, type RepliesParams, type Report, type ReportBuilder, type ReportInput, ReportReason, ReportTargetType, type ReportsResource, type RequestContext, type RequestExtensions, type RequestOptions, type ResetPasswordInput, type ResolveFileContext, type ResolveFileOptions, type ResponseContext, type RetryContext, type RetryDecisionContext, type RetryOptions, RetrySafety, RuntimeMode, type RuntimeOptions, STATUS_SERVICE, type SearchResource, type SearchResult, type SendChatMessageInput, type ServiceDefinition, ServiceState, type ServiceStatus, type Session, type SessionOptions, type SetChatReactionsInput, type ShopConsent, type ShopConsentContext, ShopConsentKind, type ShopConsentsResource, type ShopCreatedOrder, type ShopDeliveryCalculation, type ShopDeliveryCity, type ShopDeliveryCountry, type ShopDeliveryDestination, type ShopDeliveryPoint, type ShopDeliveryResource, type ShopFeatureApi, type ShopFeatureOptions, type ShopOrder, type ShopOrderAccessSession, type ShopOrderAccessStorage, type ShopOrderAccessStorageAdapterOptions, type ShopOrderAccessVerification, type ShopOrderBase, type ShopOrderDelivery, type ShopOrderItem, type ShopOrderItemInput, type ShopOrderRequestOptions, ShopOrderStatus, type ShopOrderSummary, type ShopOrderSupport, type ShopOrdersResource, type ShopPayment, type ShopProduct, ShopProductCategory, type ShopProductColor, type ShopProductSpec, ShopProductStatus, type ShopProductsResource, type ShopRecipient, type ShopResource, type ShopSizeChart, type ShopSizeChartRow, type SignInResult, type Span, SpanRenderFormat, SpanType, type StatusDay, type StatusIncidentLine, type StreamFile, type Subscription, type SubscriptionBindCardOptions, type SubscriptionCheckoutInput, SubscriptionCheckoutKind, type SubscriptionCheckoutReleaseInput, type SubscriptionCheckoutState, SubscriptionCheckoutStatus, type SubscriptionCheckoutSubject, type SubscriptionCheckoutTerms, type SubscriptionGift, type SubscriptionGiftInput, type SubscriptionOffer, type SubscriptionPayOptions, type SubscriptionPayment, type SubscriptionPaymentInput, SubscriptionPaymentProvider, type SubscriptionQuote, type SubscriptionRenewalAgreement, type SubscriptionResource, type SubscriptionState, type TelemetryBatch, type TelemetryBatchOptions, type TelemetryClock, type TelemetryOptions, type TelemetryResource, type TextMarkup, TimeoutBudget, type TokenStorage, type TokenStorageAdapterOptions, UnauthorizedStreamError, type UnknownNotificationUpdate, type UnreadCountUpdate, type Unsubscribe, type UpdateNotificationSettingsInput, type UpdatePostInput, type UpdatePrivacyInput, type UpdateProfileInput, type UpdateResultBase, type UploadOptions, type UploadedBannerDrawing, type UploadedFile, type UrlFile, type UrlFileOptions, type UserBase, type UserId, type UserListParams, type UserPostsParams, type UserRef, type UserSummary, type UsernameAvailability, UsernameUnavailableReason, type UsersResource, VIDEO_MIME_TYPES, type VerificationResource, type VerificationStatus, type VideoMimeType, type VideoProgressInput, ViewReason, ViewSource, type ViewTracker, type ViewTrackerInput, type ViewTrackerOptions, WallAccess, type WebSocketImplementationOptions, type WebSocketLike, type WebSocketOpenFailureClassifier, WebSocketTransport, type WebSocketTransportOptions, autoSpans, canonicalNotificationType, comment, createKeyValueStore, createMultiTokenStorage, createNotificationEventsClient, createRecordKeyValueStore, createShopFeature, createShopOrderAccessStorage, createTokenStorage, createUuidV4, formatNotificationText, fromStream, fromUrl, isBuilder, isBuiltInOperationId, isEnumerableKeyValueStore, isItdApiError, isItdAuthError, isItdConflictError, isItdError, isItdFileError, isItdForbiddenError, isItdNotFoundError, isItdPhoneVerificationError, isItdRateLimitError, isItdServerError, isItdStateError, isItdValidationError, isKnownNotificationType, isMyProfile, mapPage, markup, message, messageMarkup, normalizeNotification, operationBucket, operationMethod, operationRetrySafety, parseHtml, parseMarkdown, poll, post, renderSpans, report, resolveNotificationUrl, runEventMiddleware, scopedTokenStorage, statusDays, systemClock, toDate, utcStampToIso, withCodec, withNamespace };
|
|
1801
|
+
export { ALLOWED_MIME_TYPES, AUDIO_MIME_TYPES, AccessType, type AccountChangesResource, type AccountEmailResource, type AccountEvents, type AccountFeature, type AccountInfo, type AccountLifecycleResource, type AccountPasswordResource, type AccountPhoneResource, type AccountPhoneStartInput, type AccountResource, type Actor, type AddAccountOptions, type AllowedMimeType, type Announcement, type AnnouncementButton, type Attachment, AttachmentType, type AttemptContext, type AttemptExtensions, type AttemptInterceptor, type AttemptNext, type AudioMimeType, type AuthEvents, type AuthIdentity, type AuthInput, type AuthProvider, type AuthResource, type AuthState, type AuthUser, type Author, type AutoSpansOptions, BUCKET_LIMITS, type BannerDrawing, type BannerDrawingOperation, type BannerDrawingPoint, BannerDrawingTool, type BuilderInput, type BuiltInOperationId, CaptchaChoice, CaptchaField, type CaptchaPage, type CaptchaProvider, type CaptchaSolveContext, type CaptchaSolver, type CaptchaSolverInput, type CaptchaToken, CaptchaType, type ChangelogEntry, ChatActionType, type ChatAttachment, type ChatChange, type ChatDeletedMessages, type ChatDirectResult, type ChatEditedMessage, type ChatEventContext, type ChatEventMap, type ChatEventsOptions, type ChatFileLink, type ChatFirstMessage, type ChatForwardedMessages, type ChatHistoryPage, type ChatListPage, type ChatListParams, ChatMediaCategory, type ChatMediaItem, type ChatMediaPage, type ChatMessage, type ChatMessageContent, type ChatMessageReactions, type ChatPresence, type ChatPreview, type ChatReaction, type ChatReactionCatalog, type ChatReactionCount, ChatReactionType, type ChatReadCursor, type ChatReadResult, type ChatReply, type ChatSentMessage, type ChatSummary, type ChatTextEntity, type ChatUnreadState, type ChatUpdate, ChatUpdateType, type ChatUpdatesPage, type ChatUploadOptions, type ChatUploadedFile, type ChatsApi, ChatsResource, type Clan, type ClientConnection, type ClientFeature, type ClientHooks, type ClientPlugin, type Comment, type CommentBuilder, type CommentInput, type CommentReplyTo, CommentSort, type CommentUpdateResult, type CommentsParams, type CommentsResource, type ConsentContext, type ConsentDocument, type ContactActionResult, type ContactChange, type ContactChangeConfirmation, type ContactChangeSchedule, type ContactProofDelivery, type CreateCommentInput, type CreatePollInput, type CreatePostData, type CreatePostInput, type CreateReportInput, type CreateShopOrderInput, type CreateShopOrderOptions, type Credentials, type CredentialsAuth, type CredentialsWithCaptcha, type CustomOperationId, DEFAULT_BASE_URL, DEFAULT_RATE_LIMIT_BUCKET, type DwellEntry, type EnumerableKeyValueStore, type ErrorContextHook, EventChannel, type EventChannelDeps, type EventChannelEvents, type EventChannelOptions, EventChannelStatus, EventComposer, type EventContext, type EventEnqueueOptions, type EventErrorBoundary, type EventErrorContext, type EventFilter, type EventHandler, type EventMiddleware, type EventMiddlewareGroup, type EventMiddlewareLike, type EventMiddlewareObject, type EventNext, type EventPredicate, type EventRouteSelector, type EventRouteTable, EventRouter, type EventSequentializer, type EventSession, type EventSyncReason, type EventTransport, type EventTransportContext, type EventTransportFrame, type EventTypeGuard, type FeatureBucketDefinition, type FeatureContext, type FeatureInstallation, type FeatureOperationDefinition, type FeatureOperationId, type FeatureRequestOptions, type FeedParams, FeedTab, type FileContent, type FileContext, type FileInput, type FileResolver, type FileStreamContent, type FileStreamOptions, FileTransferMode, type FilesResource, type FollowResult, type ForgotPasswordInput, type ForwardChatMessagesInput, type FromStreamOptions, type Hashtag, type HashtagPostsParams, type HashtagsResource, IMAGE_MIME_TYPES, type ImageMimeType, IncidentKind, type InteractionEntry, InteractionType, type InternationalSubscriptionCapability, type InternationalSubscriptionCheckout, InternationalSubscriptionCheckoutMode, type InternationalSubscriptionOffer, type IsoDate, ItdAbortError, type ItdAccountsOptions, ItdApiError, type ItdApiErrorInit, ItdApiErrorKind, ItdAuthError, type ItdBuilder, type ItdClientOptions, type ItdClock, ItdConfigError, ItdConflictError, ItdError, ItdErrorCode, ItdErrorKind, type ItdFieldErrors, ItdFileError, ItdFileErrorReason, ItdForbiddenError, ItdNetworkError, ItdNotFoundError, ItdPhoneVerificationError, ItdRateLimitError, ItdServerError, type ItdSession, ItdStateError, ItdTimeoutError, ItdValidationError, type KeyValueCodec, type KeyValueStore, type KeyValueStoreKeys, type KeyValueStoreResult, LIBRARY_VERSION, type LastSeen, LastSeenUnit, type LazyFile, type LegalDocument, type LegalDocumentBlock, LegalDocumentBlockType, LegalDocumentScope, type LegalDocumentSummary, type LegalDocumentVersion, type LegalResource, type LikeResult, LikesVisibility, type Listener, LogLevel, type Logger, type Loose, type ManagedClientResource, type MarkupBuilder, type MarkupContent, type MarkupInput, type MarkupSpan, MemoryKeyValueStore, MemoryMultiTokenStorage, MemoryShopOrderAccessStorage, MemoryTokenStorage, MessageAccess, type MessageAllowlistMembership, type MessageAllowlistParams, type MessageAllowlistUser, type MessageBuilder, type MessageInput, type MessageMarkup, type MessageMarkupBuilder, type MessageMarkupContent, type MessageMarkupInput, type MultiTokenStorage, type MultiTokenStorageAdapterOptions, type MyProfile, type Notification, type NotificationContext, type NotificationEvent, type NotificationEventContext, type NotificationEventFilter, type NotificationEventOfType, type NotificationEventSelector, NotificationEvents, NotificationEventsClient, type NotificationEventsClientOptions, type NotificationEventsMap, type NotificationEventsOptions, NotificationEventsTransport, type NotificationEventsUpdate, type NotificationListParams, type NotificationOfType, type NotificationSettings, NotificationType, type NotificationUpdate, type NotificationUpdateOfType, NotificationUpdateOrigin, NotificationUpdateType, type NotificationsApi, type NotificationsResource, OPERATIONS, type OperationAnnotations, type ItdOperationDefinition as OperationDefinition, type OperationExtensions, type OperationId, type OperationMetadata, OperationMethod, type OperationRequestOptions, type OperationTransformContext, type OperationTransformer, type OriginalPost, type Page, type PageState, PaginationMode, type PaginationOptions, Paginator, type PaginatorOptions, type ParseMarkupOptions, type PayShopOrderOptions, type PaymentMethod, PaymentMethodType, type PendingContactChange, type PhoneAuthResource, type PhoneConfig, type PhoneConsent, type PhoneDelivery, type PhoneFlowInput, type PhoneFlowResume, type PhoneFlowStart, type PhoneLoginInput, type PhoneLoginResult, type PhoneRegion, type PhoneReverseOptions, type PhoneReverseStatus, type PhotoOpenInput, type Pin, type PinPostResult, type PinsResult, type PlatformClientVersion, type PlatformResource, type PlatformStatus, type PlatformVersions, type PluginApi, type PluginTeardown, type Poll, type PollBuilder, type PollInput, type PollOption, type Portal, type Post, type PostBase, type PostBuilder, type PostCounters, type PostInput, type PostStats, type PostUpdateInput, type PostUpdateResult, type PostsResource, type PreparedBufferSource, type PreparedFileSource, type PreparedStreamSource, type PrivacySettings, type Profile, type PublicProfile, QrLocationPrecision, type QrLoginClaim, type QrLoginClaimInput, type QrLoginSecrets, type QrLoginStart, type QrLoginStreamEvent, type QrLoginStreamInput, type QrLoginStreamListener, type QrLoginStreamOptions, type QrLoginTarget, type QueryParams, type QueryValue, type RateLimitBucket, type RateLimitBucketContext, type RateLimitBucketOverride, type RateLimitBucketState, RateLimitErrorScope, type RateLimitOptions, RateLimitPacing, type RawRequestOptions, type ReconnectOptions, type RecordKeyValueStoreSource, type RemoveAccountOptions, type RenderSpansOptions, type RepliesParams, type Report, type ReportBuilder, type ReportInput, ReportReason, ReportTargetType, type ReportsResource, type RequestContext, type RequestExtensions, type RequestOptions, type ResetPasswordInput, type ResolveFileContext, type ResolveFileOptions, type ResponseContext, type RetryContext, type RetryDecisionContext, type RetryOptions, RetrySafety, RuntimeMode, type RuntimeOptions, STATUS_SERVICE, type SearchResource, type SearchResult, type SendChatMessageInput, type ServiceDefinition, ServiceState, type ServiceStatus, type Session, type SessionOptions, type SetChatReactionsInput, type ShopConsent, type ShopConsentContext, ShopConsentKind, type ShopConsentsResource, type ShopCreatedOrder, type ShopDeliveryCalculation, type ShopDeliveryCity, type ShopDeliveryCountry, type ShopDeliveryDestination, type ShopDeliveryPoint, type ShopDeliveryResource, type ShopFeatureApi, type ShopFeatureOptions, type ShopOrder, type ShopOrderAccessSession, type ShopOrderAccessStorage, type ShopOrderAccessStorageAdapterOptions, type ShopOrderAccessVerification, type ShopOrderBase, type ShopOrderDelivery, type ShopOrderItem, type ShopOrderItemInput, type ShopOrderRequestOptions, ShopOrderStatus, type ShopOrderSummary, type ShopOrderSupport, type ShopOrdersResource, type ShopPayment, type ShopProduct, ShopProductCategory, type ShopProductColor, type ShopProductSpec, ShopProductStatus, type ShopProductsResource, type ShopRecipient, type ShopResource, type ShopSizeChart, type ShopSizeChartRow, type SignInResult, type Span, SpanRenderFormat, SpanType, type StatusDay, type StatusIncidentLine, type StreamFile, type Subscription, type SubscriptionBindCardOptions, type SubscriptionCheckoutInput, SubscriptionCheckoutKind, type SubscriptionCheckoutReleaseInput, type SubscriptionCheckoutState, SubscriptionCheckoutStatus, type SubscriptionCheckoutSubject, type SubscriptionCheckoutTerms, type SubscriptionGift, type SubscriptionGiftInput, type SubscriptionOffer, type SubscriptionPayOptions, type SubscriptionPayment, type SubscriptionPaymentInput, SubscriptionPaymentProvider, type SubscriptionQuote, type SubscriptionRenewalAgreement, type SubscriptionResource, type SubscriptionState, type TelemetryBatch, type TelemetryBatchOptions, type TelemetryClock, type TelemetryOptions, type TelemetryResource, type TermsAcceptance, type TextMarkup, TimeoutBudget, type TokenStorage, type TokenStorageAdapterOptions, UnauthorizedStreamError, type UnknownNotificationUpdate, type UnreadCountUpdate, type Unsubscribe, type UpdateNotificationSettingsInput, type UpdatePostInput, type UpdatePrivacyInput, type UpdateProfileInput, type UpdateResultBase, type UploadOptions, type UploadedBannerDrawing, type UploadedFile, type UrlFile, type UrlFileOptions, type UserBase, type UserId, type UserListParams, type UserPostsParams, type UserRef, type UserSummary, type UsernameAvailability, UsernameUnavailableReason, type UsersResource, VIDEO_MIME_TYPES, type VerificationResource, type VerificationStatus, type VideoMimeType, type VideoProgressInput, ViewReason, ViewSource, type ViewTracker, type ViewTrackerInput, type ViewTrackerOptions, WallAccess, type WebSocketImplementationOptions, type WebSocketLike, type WebSocketOpenFailureClassifier, WebSocketTransport, type WebSocketTransportOptions, autoSpans, canonicalNotificationType, comment, createKeyValueStore, createMultiTokenStorage, createNotificationEventsClient, createRecordKeyValueStore, createShopFeature, createShopOrderAccessStorage, createTokenStorage, createUuidV4, formatNotificationText, fromStream, fromUrl, isBuilder, isBuiltInOperationId, isEnumerableKeyValueStore, isItdApiError, isItdAuthError, isItdConflictError, isItdError, isItdFileError, isItdForbiddenError, isItdNotFoundError, isItdPhoneVerificationError, isItdRateLimitError, isItdServerError, isItdStateError, isItdValidationError, isKnownNotificationType, isMyProfile, mapPage, markup, message, messageMarkup, normalizeNotification, operationBucket, operationMethod, operationRetrySafety, parseHtml, parseMarkdown, poll, post, renderSpans, report, resolveNotificationUrl, runEventMiddleware, scopedTokenStorage, statusDays, systemClock, toDate, utcStampToIso, withCodec, withNamespace };
|
package/dist/index.d.ts
CHANGED
|
@@ -3,9 +3,9 @@
|
|
|
3
3
|
*
|
|
4
4
|
* @packageDocumentation
|
|
5
5
|
*/
|
|
6
|
-
import { $ as RequestContext, $t as isItdAuthError, A as ClientConnection, An as QrLocationPrecision, At as ItdApiError, B as OperationAnnotations, Bt as ItdFileErrorReason, C as SubscriptionState, Cn as InteractionType, Ct as operationBucket, D as Emitter, Dn as Loose, Dt as DEFAULT_RATE_LIMIT_BUCKET, E as UsernameAvailability, En as LikesVisibility, Et as BUCKET_LIMITS, Fn as UsernameUnavailableReason, Ft as ItdConflictError, G as ClientHooks, Gt as ItdRateLimitError, H as OperationMetadata, Ht as ItdNetworkError, I as DEFAULT_BASE_URL, In as ViewReason, It as ItdError, J as PaginationOptions, Jt as ItdTimeoutError, K as ErrorContextHook, Kt as ItdServerError, L as STATUS_SERVICE, Ln as ViewSource, Lt as ItdErrorKind, M as AuthProvider, Mn as ReportTargetType, Mt as ItdApiErrorKind, Nn as ServiceState, Nt as ItdAuthError, O as Listener, On as MessageAccess, Ot as RateLimitBucket, Pn as SpanType, Pt as ItdConfigError, Q as RawRequestOptions, Qt as isItdApiError, R as LIBRARY_VERSION, Rn as WallAccess, Rt as ItdFieldErrors, S as PublicProfile, Sn as IncidentKind, St as isBuiltInOperationId, T as UserSummary, Tn as LastSeenUnit, Tt as operationRetrySafety, U as OperationMethod, Ut as ItdNotFoundError, Vt as ItdForbiddenError, W as RetrySafety, Wt as ItdPhoneVerificationError, X as RateLimitBucketOverride, Xt as RateLimitErrorScope, Y as RateLimitBucketContext, Yt as ItdValidationError, Z as RateLimitOptions, Zt as TimeoutBudget, _ as MyProfile, _n as CaptchaField, _t as BuiltInOperationId, a as NotificationEvent, an as isItdPhoneVerificationError, at as RetryOptions, b as PrivacySettings, bn as EventChannelStatus, bt as OPERATIONS, c as NotificationSettings, cn as isItdStateError, ct as QueryValue, d as AuthUser, dn as Span, dt as RuntimeMode, en as isItdConflictError, et as RequestExtensions, f as Author, fn as UserId, ft as createUuidV4, g as MessageAllowlistUser, gn as CaptchaChoice, gt as systemClock, h as MessageAllowlistMembership, hn as AttachmentType, ht as ItdClock, i as formatNotificationText, in as isItdNotFoundError, it as RetryDecisionContext, j as AuthIdentity, jn as ReportReason, jt as ItdApiErrorInit, k as Unsubscribe, kn as NotificationType, kt as ItdAbortError, l as Actor, ln as isItdValidationError, lt as ServiceDefinition, m as LastSeen, mn as AccessType, mt as Logger, n as canonicalNotificationType, nn as isItdFileError, nt as ResponseContext, o as normalizeNotification, on as isItdRateLimitError, ot as RuntimeOptions, p as FollowResult, pn as UserRef, pt as LogLevel, q as OperationRequestOptions, qt as ItdStateError, r as isKnownNotificationType, rn as isItdForbiddenError, rt as RetryContext, s as Notification, sn as isItdServerError, st as QueryParams, t as resolveNotificationUrl, tn as isItdError, tt as RequestOptions, u as AuthState, un as IsoDate, ut as RateLimitPacing, v as Pin, vn as CaptchaType, vt as CustomOperationId, w as UserBase, wn as ItdErrorCode, wt as operationMethod, x as Profile, xn as FeedTab, xt as OperationId, y as PinsResult, yn as CommentSort, yt as ItdOperationDefinition, z as FeatureOperationId, zt as ItdFileError } from "./shared/url-
|
|
7
|
-
import { $ as InternationalSubscriptionCheckoutMode, $i as
|
|
8
|
-
import { $ as EventTransportContext, A as EventHandler, B as NotificationEventContext, C as EventChannelDeps, D as EventSession, E as EventEnqueueOptions, F as EventSequentializer, G as NotificationOfType, H as NotificationEventOfType, I as EventTypeGuard, J as NotificationUpdateOrigin, K as NotificationUpdate, L as runEventMiddleware, M as EventMiddlewareObject, N as EventNext, O as EventSyncReason, P as EventPredicate, Q as EventTransport, R as EventContext, S as EventChannel, T as EventChannelOptions, U as NotificationEventSelector, V as NotificationEventFilter, W as NotificationEventsUpdate, X as UnknownNotificationUpdate, Y as NotificationUpdateType, Z as UnreadCountUpdate, _ as createNotificationEventsClient, a as WebSocketTransportOptions, b as NotificationEventsOptions, c as EventErrorContext, d as EventMiddlewareLike, et as EventTransportFrame, f as EventRouteTable, g as NotificationEventsClientOptions, h as NotificationEventsClient, i as WebSocketTransport, j as EventMiddleware, k as ReconnectOptions, l as EventFilter, m as EventRouter, n as WebSocketLike, o as EventComposer, p as EventRouteSelector, q as NotificationUpdateOfType, r as WebSocketOpenFailureClassifier, s as EventErrorBoundary, t as WebSocketImplementationOptions, tt as UnauthorizedStreamError, u as EventMiddlewareGroup, v as NotificationEvents, w as EventChannelEvents, x as NotificationEventsTransport, y as NotificationEventsMap, z as NotificationContext } from "./shared/events-
|
|
6
|
+
import { $ as RequestContext, $t as isItdAuthError, A as ClientConnection, An as QrLocationPrecision, At as ItdApiError, B as OperationAnnotations, Bt as ItdFileErrorReason, C as SubscriptionState, Cn as InteractionType, Ct as operationBucket, D as Emitter, Dn as Loose, Dt as DEFAULT_RATE_LIMIT_BUCKET, E as UsernameAvailability, En as LikesVisibility, Et as BUCKET_LIMITS, Fn as UsernameUnavailableReason, Ft as ItdConflictError, G as ClientHooks, Gt as ItdRateLimitError, H as OperationMetadata, Ht as ItdNetworkError, I as DEFAULT_BASE_URL, In as ViewReason, It as ItdError, J as PaginationOptions, Jt as ItdTimeoutError, K as ErrorContextHook, Kt as ItdServerError, L as STATUS_SERVICE, Ln as ViewSource, Lt as ItdErrorKind, M as AuthProvider, Mn as ReportTargetType, Mt as ItdApiErrorKind, Nn as ServiceState, Nt as ItdAuthError, O as Listener, On as MessageAccess, Ot as RateLimitBucket, Pn as SpanType, Pt as ItdConfigError, Q as RawRequestOptions, Qt as isItdApiError, R as LIBRARY_VERSION, Rn as WallAccess, Rt as ItdFieldErrors, S as PublicProfile, Sn as IncidentKind, St as isBuiltInOperationId, T as UserSummary, Tn as LastSeenUnit, Tt as operationRetrySafety, U as OperationMethod, Ut as ItdNotFoundError, Vt as ItdForbiddenError, W as RetrySafety, Wt as ItdPhoneVerificationError, X as RateLimitBucketOverride, Xt as RateLimitErrorScope, Y as RateLimitBucketContext, Yt as ItdValidationError, Z as RateLimitOptions, Zt as TimeoutBudget, _ as MyProfile, _n as CaptchaField, _t as BuiltInOperationId, a as NotificationEvent, an as isItdPhoneVerificationError, at as RetryOptions, b as PrivacySettings, bn as EventChannelStatus, bt as OPERATIONS, c as NotificationSettings, cn as isItdStateError, ct as QueryValue, d as AuthUser, dn as Span, dt as RuntimeMode, en as isItdConflictError, et as RequestExtensions, f as Author, fn as UserId, ft as createUuidV4, g as MessageAllowlistUser, gn as CaptchaChoice, gt as systemClock, h as MessageAllowlistMembership, hn as AttachmentType, ht as ItdClock, i as formatNotificationText, in as isItdNotFoundError, it as RetryDecisionContext, j as AuthIdentity, jn as ReportReason, jt as ItdApiErrorInit, k as Unsubscribe, kn as NotificationType, kt as ItdAbortError, l as Actor, ln as isItdValidationError, lt as ServiceDefinition, m as LastSeen, mn as AccessType, mt as Logger, n as canonicalNotificationType, nn as isItdFileError, nt as ResponseContext, o as normalizeNotification, on as isItdRateLimitError, ot as RuntimeOptions, p as FollowResult, pn as UserRef, pt as LogLevel, q as OperationRequestOptions, qt as ItdStateError, r as isKnownNotificationType, rn as isItdForbiddenError, rt as RetryContext, s as Notification, sn as isItdServerError, st as QueryParams, t as resolveNotificationUrl, tn as isItdError, tt as RequestOptions, u as AuthState, un as IsoDate, ut as RateLimitPacing, v as Pin, vn as CaptchaType, vt as CustomOperationId, w as UserBase, wn as ItdErrorCode, wt as operationMethod, x as Profile, xn as FeedTab, xt as OperationId, y as PinsResult, yn as CommentSort, yt as ItdOperationDefinition, z as FeatureOperationId, zt as ItdFileError } from "./shared/url-U1Q7c-SD.js";
|
|
7
|
+
import { $ as InternationalSubscriptionCheckoutMode, $i as ResolveFileContext, $n as Poll, $r as CreateCommentInput, $t as ReportsResource, A as UsersResource, Ai as ChatReadCursor, An as Report, Ar as Page, At as ShopDeliveryDestination, B as ViewTracker, Bi as ChatUploadOptions, Bn as BannerDrawingPoint, Br as MessageMarkupBuilder, Bt as ShopOrderSummary, C as fromStream, Ci as ChatMessageReactions, Cn as StatusDay, Cr as NotificationsResource, Ct as ShopConsent, D as UpdatePrivacyInput, Di as ChatReactionCatalog, Dn as ChangelogEntry, Dr as ForwardChatMessagesInput, Dt as ShopDeliveryCalculation, E as MessageAllowlistParams, Ei as ChatReaction, En as AnnouncementButton, Er as ChatsResource, Et as ShopCreatedOrder, F as TelemetryBatchOptions, Fi as ChatTextEntity, Fn as FilesResource, Fr as mapPage, Ft as ShopOrderBase, G as SubscriptionCheckoutReleaseInput, Gi as FeatureInstallation, Gn as Attachment, Gr as MarkupBuilder, Gt as ShopProductColor, H as ViewTrackerOptions, Hi as ClientFeature, Hn as UploadedBannerDrawing, Hr as MessageMarkupInput, Ht as ShopPayment, I as TelemetryClock, Ii as ChatUnreadState, In as UploadOptions, Ir as MessageBuilder, It as ShopOrderDelivery, J as SubscriptionPayOptions, Ji as ManagedClientResource, Jn as CommentUpdateResult, Jr as MarkupSpan, Jt as ShopRecipient, K as SubscriptionCheckoutTerms, Ki as FeatureOperationDefinition, Kn as Comment, Kr as MarkupContent, Kt as ShopProductSpec, L as TelemetryOptions, Li as ChatUpdate, Ln as UploadedFile, Lr as MessageInput, Lt as ShopOrderItem, M as InteractionEntry, Mi as ChatReply, Mn as LegalResource, Mr as PaginationMode, Mt as ShopOrder, N as PhotoOpenInput, Ni as ChatSentMessage, Nn as HashtagPostsParams, Nr as Paginator, Nt as ShopOrderAccessSession, O as UpdateProfileInput, Oi as ChatReactionCount, On as Clan, Or as SetChatReactionsInput, Ot as ShopDeliveryCity, P as TelemetryBatch, Pi as ChatSummary, Pn as HashtagsResource, Pr as PaginatorOptions, Pt as ShopOrderAccessVerification, Q as InternationalSubscriptionCheckout, Qi as PreparedStreamSource, Qn as PinPostResult, Qr as ChatMessageContent, Qt as SearchResult, R as TelemetryResource, Ri as ChatUpdateType, Rn as BannerDrawing, Rr as message, Rt as ShopOrderItemInput, S as VideoMimeType, Si as ChatMessage, Sn as ServiceStatus, Sr as NotificationListParams, St as CreateShopOrderInput, T as VerificationResource, Ti as ChatPreview, Tn as Announcement, Tr as ChatListParams, Tt as ShopConsentKind, U as SubscriptionBindCardOptions, Ui as FeatureBucketDefinition, Un as CommentsResource, Ur as messageMarkup, Ut as ShopProduct, V as ViewTrackerInput, Vi as ChatUploadedFile, Vn as BannerDrawingTool, Vr as MessageMarkupContent, Vt as ShopOrderSupport, W as SubscriptionCheckoutInput, Wi as FeatureContext, Wn as RepliesParams, Wr as AutoSpansOptions, Wt as ShopProductCategory, X as SubscriptionResource, Xi as PreparedBufferSource, Xn as LikeResult, Xr as autoSpans, Xt as ShopSizeChartRow, Y as SubscriptionPaymentInput, Yi as FileResolver, Yn as Hashtag, Yr as TextMarkup, Yt as ShopSizeChart, Z as InternationalSubscriptionCapability, Zi as PreparedFileSource, Zn as OriginalPost, Zr as markup, Zt as SearchResource, _ as AllowedMimeType, _i as ChatHistoryPage, _n as parseMarkdown, _r as LegalDocumentSummary, _t as ShopDeliveryResource, a as ShopFeatureOptions, aa as ClientPlugin, ai as BuilderInput, an as PostsResource, ar as PostUpdateResult, at as SubscriptionCheckoutState, b as ImageMimeType, bi as ChatMediaItem, bn as PlatformVersions, br as QrLoginTarget, bt as ShopProductsResource, c as ShopOrderAccessStorage, ca as OperationTransformer, ci as ChatActionType, cn as PostBuilder, cr as CommentInput, ct as SubscriptionGift, d as statusDays, da as HttpClient, di as ChatDeletedMessages, dn as post, dr as ConsentContext, dt as SubscriptionPaymentProvider, ea as ResolveFileOptions, ei as CreatePollInput, en as ReportBuilder, er as PollOption, et as InternationalSubscriptionOffer, f as isMyProfile, fa as RateLimitBucketState, fi as ChatDirectResult, fn as PollBuilder, fr as ConsentDocument, ft as SubscriptionQuote, g as AUDIO_MIME_TYPES, gi as ChatForwardedMessages, gn as parseHtml, gr as LegalDocumentScope, gt as ShopConsentsResource, h as ALLOWED_MIME_TYPES, hi as ChatFirstMessage, hn as ParseMarkupOptions, hr as LegalDocumentBlockType, ht as PayShopOrderOptions, i as ShopFeatureApi, ia as AttemptNext, ii as UpdatePostInput, in as FeedParams, ir as PostStats, it as SubscriptionCheckoutKind, j as DwellEntry, ji as ChatReadResult, jn as VerificationStatus, jr as PageState, jt as ShopDeliveryPoint, k as UserListParams, ki as ChatReactionType, kn as Portal, kr as BaseResource, kt as ShopDeliveryCountry, l as ShopOrderAccessStorageAdapterOptions, la as PluginApi, li as ChatAttachment, ln as PostInput, lr as comment, lt as SubscriptionOffer, m as utcStampToIso, mi as ChatFileLink, mn as poll, mr as LegalDocumentBlock, mt as CreateShopOrderOptions, n as SpanRenderFormat, na as AttemptExtensions, ni as CreateReportInput, nn as report, nr as PostBase, nt as PaymentMethodType, o as createShopFeature, oa as OperationExtensions, oi as ItdBuilder, on as UserPostsParams, or as UpdateResultBase, ot as SubscriptionCheckoutStatus, p as toDate, pa as CookieJar, pi as ChatEditedMessage, pn as PollInput, pr as LegalDocument, pt as SubscriptionRenewalAgreement, q as SubscriptionGiftInput, qi as FeatureRequestOptions, qn as CommentReplyTo, qr as MarkupInput, qt as ShopProductStatus, r as renderSpans, ra as AttemptInterceptor, ri as SendChatMessageInput, rn as CommentsParams, rr as PostCounters, rt as Subscription, s as MemoryShopOrderAccessStorage, sa as OperationTransformContext, si as isBuilder, sn as CreatePostInput, sr as CommentBuilder, st as SubscriptionCheckoutSubject, t as RenderSpansOptions, ta as AttemptContext, ti as CreatePostData, tn as ReportInput, tr as Post, tt as PaymentMethod, u as createShopOrderAccessStorage, ua as PluginTeardown, ui as ChatChange, un as PostUpdateInput, ur as AccountLifecycleResource, ut as SubscriptionPayment, v as AudioMimeType, vi as ChatListPage, vn as PlatformClientVersion, vr as LegalDocumentVersion, vt as ShopOrderRequestOptions, w as fromUrl, wi as ChatPresence, wn as StatusIncidentLine, wr as UpdateNotificationSettingsInput, wt as ShopConsentContext, x as VIDEO_MIME_TYPES, xi as ChatMediaPage, xn as PlatformStatus, xr as Session, xt as ShopResource, y as IMAGE_MIME_TYPES, yi as ChatMediaCategory, yn as PlatformResource, yr as TermsAcceptance, yt as ShopOrdersResource, z as VideoProgressInput, zi as ChatUpdatesPage, zn as BannerDrawingOperation, zr as MessageMarkup, zt as ShopOrderStatus } from "./shared/render-DOxbtUga.js";
|
|
8
|
+
import { $ as EventTransportContext, A as EventHandler, B as NotificationEventContext, C as EventChannelDeps, D as EventSession, E as EventEnqueueOptions, F as EventSequentializer, G as NotificationOfType, H as NotificationEventOfType, I as EventTypeGuard, J as NotificationUpdateOrigin, K as NotificationUpdate, L as runEventMiddleware, M as EventMiddlewareObject, N as EventNext, O as EventSyncReason, P as EventPredicate, Q as EventTransport, R as EventContext, S as EventChannel, T as EventChannelOptions, U as NotificationEventSelector, V as NotificationEventFilter, W as NotificationEventsUpdate, X as UnknownNotificationUpdate, Y as NotificationUpdateType, Z as UnreadCountUpdate, _ as createNotificationEventsClient, a as WebSocketTransportOptions, b as NotificationEventsOptions, c as EventErrorContext, d as EventMiddlewareLike, et as EventTransportFrame, f as EventRouteTable, g as NotificationEventsClientOptions, h as NotificationEventsClient, i as WebSocketTransport, j as EventMiddleware, k as ReconnectOptions, l as EventFilter, m as EventRouter, n as WebSocketLike, o as EventComposer, p as EventRouteSelector, q as NotificationUpdateOfType, r as WebSocketOpenFailureClassifier, s as EventErrorBoundary, t as WebSocketImplementationOptions, tt as UnauthorizedStreamError, u as EventMiddlewareGroup, v as NotificationEvents, w as EventChannelEvents, x as NotificationEventsTransport, y as NotificationEventsMap, z as NotificationContext } from "./shared/events-By7baZfE.js";
|
|
9
9
|
import { a as createTokenStorage, i as TokenStorageAdapterOptions, n as MemoryTokenStorage, r as TokenStorage, t as ItdSession } from "./shared/storage-C_ZujAZt.js";
|
|
10
10
|
import { a as scopedTokenStorage, i as createMultiTokenStorage, n as MultiTokenStorage, r as MultiTokenStorageAdapterOptions, t as MemoryMultiTokenStorage } from "./shared/multi-storage-DQiERirK.js";
|
|
11
11
|
import { a as FileStreamOptions, c as LazyFile, d as UrlFileOptions, i as FileStreamContent, l as StreamFile, n as FileContext, o as FileTransferMode, r as FileInput, s as FromStreamOptions, t as FileContent, u as UrlFile } from "./shared/contracts-pxnDIsQP.js";
|
|
@@ -318,50 +318,23 @@ interface PhoneRegion {
|
|
|
318
318
|
example: string;
|
|
319
319
|
/** Способы подтверждения, доступные в регионе. */
|
|
320
320
|
methods: PhoneVerificationMethod[];
|
|
321
|
+
/** Код может прийти в сообщении ИТД. */
|
|
322
|
+
message?: boolean;
|
|
321
323
|
}
|
|
322
324
|
/** Серверный список регионов, доступных для телефонного входа. */
|
|
323
325
|
interface PhoneConfig {
|
|
324
326
|
regions: PhoneRegion[];
|
|
325
327
|
defaultRegion: string;
|
|
326
328
|
}
|
|
327
|
-
/** Редакция документа, включённая в контекст согласия. */
|
|
328
|
-
interface ConsentDocument {
|
|
329
|
-
scope: string;
|
|
330
|
-
slug: string;
|
|
331
|
-
version: string;
|
|
332
|
-
contentSha256: string;
|
|
333
|
-
url: string;
|
|
334
|
-
}
|
|
335
329
|
/** Текст и редакции документов, с которыми пользователь соглашается при входе. */
|
|
336
|
-
interface PhoneConsent {
|
|
337
|
-
/** Версия протокола из consent(); передаётся серверу вместе с contextToken. */
|
|
338
|
-
protocolVersion: number;
|
|
339
|
-
/** Подписанный контекст; в start() передаётся без изменения. */
|
|
340
|
-
contextToken: string;
|
|
341
|
-
id: string;
|
|
342
|
-
/** Время выдачи контекста, Unix-время в миллисекундах. */
|
|
343
|
-
issuedAt: number;
|
|
344
|
-
/** Срок действия контекста, Unix-время в миллисекундах. */
|
|
345
|
-
expiresAt: number;
|
|
346
|
-
bundle: {
|
|
347
|
-
id: string;
|
|
348
|
-
flow: typeof PHONE_CONSENT_FLOW;
|
|
349
|
-
documents: ConsentDocument[];
|
|
350
|
-
actions: Record<string, string>;
|
|
351
|
-
actionVersion: string;
|
|
352
|
-
submitLabel: string;
|
|
353
|
-
text: {
|
|
354
|
-
text: string;
|
|
355
|
-
document?: string;
|
|
356
|
-
}[];
|
|
357
|
-
};
|
|
358
|
-
}
|
|
330
|
+
interface PhoneConsent extends ConsentContext<typeof PHONE_CONSENT_FLOW> {}
|
|
359
331
|
/** Серверные каналы доставки кода. */
|
|
360
332
|
export declare const PhoneDeliveryChannel: Readonly<{
|
|
361
333
|
readonly MissedCall: "missed_call";
|
|
362
334
|
readonly VoiceCall: "voice_call";
|
|
363
335
|
readonly Sms: "sms";
|
|
364
336
|
readonly Push: "push";
|
|
337
|
+
readonly Message: "message";
|
|
365
338
|
}>;
|
|
366
339
|
export type PhoneDeliveryChannel = Loose<(typeof PhoneDeliveryChannel)[keyof typeof PhoneDeliveryChannel]>;
|
|
367
340
|
/** Подтверждение входящим кодом либо исходящим звонком пользователя. */
|
|
@@ -904,6 +877,14 @@ declare class AccountResource extends AccountLifecycleResource {
|
|
|
904
877
|
* ```
|
|
905
878
|
*/
|
|
906
879
|
getInfo(options?: RequestOptions): Promise<AccountInfo>;
|
|
880
|
+
/** Возвращает текущую редакцию условий и контекст, если аккаунту требуется согласие. */
|
|
881
|
+
termsAcceptance(options?: RequestOptions): Promise<TermsAcceptance>;
|
|
882
|
+
/**
|
|
883
|
+
* Записывает согласие текущего аккаунта с редакцией условий.
|
|
884
|
+
*
|
|
885
|
+
* @param contextToken токен из контекста согласия, полученного через {@link termsAcceptance}
|
|
886
|
+
*/
|
|
887
|
+
acceptTerms(contextToken: string, options?: RequestOptions): Promise<void>;
|
|
907
888
|
}
|
|
908
889
|
/** Данные запуска телефонного входа после принятия документов пользователем. */
|
|
909
890
|
interface PhoneLoginInput {
|
|
@@ -1817,4 +1798,4 @@ export declare class ItdAccounts {
|
|
|
1817
1798
|
* То же, что `new ItdAccounts(options)`, — для тех, кому привычнее фабрика.
|
|
1818
1799
|
*/
|
|
1819
1800
|
export declare function createAccounts(options?: ItdAccountsOptions): ItdAccounts;
|
|
1820
|
-
export { ALLOWED_MIME_TYPES, AUDIO_MIME_TYPES, AccessType, type AccountChangesResource, type AccountEmailResource, type AccountEvents, type AccountFeature, type AccountInfo, type AccountLifecycleResource, type AccountPasswordResource, type AccountPhoneResource, type AccountPhoneStartInput, type AccountResource, type Actor, type AddAccountOptions, type AllowedMimeType, type Announcement, type AnnouncementButton, type Attachment, AttachmentType, type AttemptContext, type AttemptExtensions, type AttemptInterceptor, type AttemptNext, type AudioMimeType, type AuthEvents, type AuthIdentity, type AuthInput, type AuthProvider, type AuthResource, type AuthState, type AuthUser, type Author, type AutoSpansOptions, BUCKET_LIMITS, type BannerDrawing, type BannerDrawingOperation, type BannerDrawingPoint, BannerDrawingTool, type BuilderInput, type BuiltInOperationId, CaptchaChoice, CaptchaField, type CaptchaPage, type CaptchaProvider, type CaptchaSolveContext, type CaptchaSolver, type CaptchaSolverInput, type CaptchaToken, CaptchaType, type ChangelogEntry, ChatActionType, type ChatAttachment, type ChatChange, type ChatDeletedMessages, type ChatDirectResult, type ChatEditedMessage, type ChatEventContext, type ChatEventMap, type ChatEventsOptions, type ChatFileLink, type ChatFirstMessage, type ChatForwardedMessages, type ChatHistoryPage, type ChatListPage, type ChatListParams, ChatMediaCategory, type ChatMediaItem, type ChatMediaPage, type ChatMessage, type ChatMessageContent, type ChatMessageReactions, type ChatPresence, type ChatPreview, type ChatReaction, type ChatReactionCatalog, type ChatReactionCount, ChatReactionType, type ChatReadCursor, type ChatReadResult, type ChatReply, type ChatSentMessage, type ChatSummary, type ChatTextEntity, type ChatUnreadState, type ChatUpdate, ChatUpdateType, type ChatUpdatesPage, type ChatUploadOptions, type ChatUploadedFile, type ChatsApi, ChatsResource, type Clan, type ClientConnection, type ClientFeature, type ClientHooks, type ClientPlugin, type Comment, type CommentBuilder, type CommentInput, type CommentReplyTo, CommentSort, type CommentUpdateResult, type CommentsParams, type CommentsResource, type ConsentDocument, type ContactActionResult, type ContactChange, type ContactChangeConfirmation, type ContactChangeSchedule, type ContactProofDelivery, type CreateCommentInput, type CreatePollInput, type CreatePostData, type CreatePostInput, type CreateReportInput, type CreateShopOrderInput, type CreateShopOrderOptions, type Credentials, type CredentialsAuth, type CredentialsWithCaptcha, type CustomOperationId, DEFAULT_BASE_URL, DEFAULT_RATE_LIMIT_BUCKET, type DwellEntry, type EnumerableKeyValueStore, type ErrorContextHook, EventChannel, type EventChannelDeps, type EventChannelEvents, type EventChannelOptions, EventChannelStatus, EventComposer, type EventContext, type EventEnqueueOptions, type EventErrorBoundary, type EventErrorContext, type EventFilter, type EventHandler, type EventMiddleware, type EventMiddlewareGroup, type EventMiddlewareLike, type EventMiddlewareObject, type EventNext, type EventPredicate, type EventRouteSelector, type EventRouteTable, EventRouter, type EventSequentializer, type EventSession, type EventSyncReason, type EventTransport, type EventTransportContext, type EventTransportFrame, type EventTypeGuard, type FeatureBucketDefinition, type FeatureContext, type FeatureInstallation, type FeatureOperationDefinition, type FeatureOperationId, type FeatureRequestOptions, type FeedParams, FeedTab, type FileContent, type FileContext, type FileInput, type FileResolver, type FileStreamContent, type FileStreamOptions, FileTransferMode, type FilesResource, type FollowResult, type ForgotPasswordInput, type ForwardChatMessagesInput, type FromStreamOptions, type Hashtag, type HashtagPostsParams, type HashtagsResource, IMAGE_MIME_TYPES, type ImageMimeType, IncidentKind, type InteractionEntry, InteractionType, type InternationalSubscriptionCapability, type InternationalSubscriptionCheckout, InternationalSubscriptionCheckoutMode, type InternationalSubscriptionOffer, type IsoDate, ItdAbortError, type ItdAccountsOptions, ItdApiError, type ItdApiErrorInit, ItdApiErrorKind, ItdAuthError, type ItdBuilder, type ItdClientOptions, type ItdClock, ItdConfigError, ItdConflictError, ItdError, ItdErrorCode, ItdErrorKind, type ItdFieldErrors, ItdFileError, ItdFileErrorReason, ItdForbiddenError, ItdNetworkError, ItdNotFoundError, ItdPhoneVerificationError, ItdRateLimitError, ItdServerError, type ItdSession, ItdStateError, ItdTimeoutError, ItdValidationError, type KeyValueCodec, type KeyValueStore, type KeyValueStoreKeys, type KeyValueStoreResult, LIBRARY_VERSION, type LastSeen, LastSeenUnit, type LazyFile, type LegalDocument, type LegalDocumentBlock, LegalDocumentBlockType, LegalDocumentScope, type LegalDocumentSummary, type LegalDocumentVersion, type LegalResource, type LikeResult, LikesVisibility, type Listener, LogLevel, type Logger, type Loose, type ManagedClientResource, type MarkupBuilder, type MarkupContent, type MarkupInput, type MarkupSpan, MemoryKeyValueStore, MemoryMultiTokenStorage, MemoryShopOrderAccessStorage, MemoryTokenStorage, MessageAccess, type MessageAllowlistMembership, type MessageAllowlistParams, type MessageAllowlistUser, type MessageBuilder, type MessageInput, type MessageMarkup, type MessageMarkupBuilder, type MessageMarkupContent, type MessageMarkupInput, type MultiTokenStorage, type MultiTokenStorageAdapterOptions, type MyProfile, type Notification, type NotificationContext, type NotificationEvent, type NotificationEventContext, type NotificationEventFilter, type NotificationEventOfType, type NotificationEventSelector, NotificationEvents, NotificationEventsClient, type NotificationEventsClientOptions, type NotificationEventsMap, type NotificationEventsOptions, NotificationEventsTransport, type NotificationEventsUpdate, type NotificationListParams, type NotificationOfType, type NotificationSettings, NotificationType, type NotificationUpdate, type NotificationUpdateOfType, NotificationUpdateOrigin, NotificationUpdateType, type NotificationsApi, type NotificationsResource, OPERATIONS, type OperationAnnotations, type ItdOperationDefinition as OperationDefinition, type OperationExtensions, type OperationId, type OperationMetadata, OperationMethod, type OperationRequestOptions, type OperationTransformContext, type OperationTransformer, type OriginalPost, type Page, type PageState, PaginationMode, type PaginationOptions, Paginator, type PaginatorOptions, type ParseMarkupOptions, type PayShopOrderOptions, type PaymentMethod, PaymentMethodType, type PendingContactChange, type PhoneAuthResource, type PhoneConfig, type PhoneConsent, type PhoneDelivery, type PhoneFlowInput, type PhoneFlowResume, type PhoneFlowStart, type PhoneLoginInput, type PhoneLoginResult, type PhoneRegion, type PhoneReverseOptions, type PhoneReverseStatus, type PhotoOpenInput, type Pin, type PinPostResult, type PinsResult, type PlatformClientVersion, type PlatformResource, type PlatformStatus, type PlatformVersions, type PluginApi, type PluginTeardown, type Poll, type PollBuilder, type PollInput, type PollOption, type Portal, type Post, type PostBase, type PostBuilder, type PostCounters, type PostInput, type PostStats, type PostUpdateInput, type PostUpdateResult, type PostsResource, type PreparedBufferSource, type PreparedFileSource, type PreparedStreamSource, type PrivacySettings, type Profile, type PublicProfile, QrLocationPrecision, type QrLoginClaim, type QrLoginClaimInput, type QrLoginSecrets, type QrLoginStart, type QrLoginStreamEvent, type QrLoginStreamInput, type QrLoginStreamListener, type QrLoginStreamOptions, type QrLoginTarget, type QueryParams, type QueryValue, type RateLimitBucket, type RateLimitBucketContext, type RateLimitBucketOverride, type RateLimitBucketState, RateLimitErrorScope, type RateLimitOptions, RateLimitPacing, type RawRequestOptions, type ReconnectOptions, type RecordKeyValueStoreSource, type RemoveAccountOptions, type RenderSpansOptions, type RepliesParams, type Report, type ReportBuilder, type ReportInput, ReportReason, ReportTargetType, type ReportsResource, type RequestContext, type RequestExtensions, type RequestOptions, type ResetPasswordInput, type ResolveFileContext, type ResolveFileOptions, type ResponseContext, type RetryContext, type RetryDecisionContext, type RetryOptions, RetrySafety, RuntimeMode, type RuntimeOptions, STATUS_SERVICE, type SearchResource, type SearchResult, type SendChatMessageInput, type ServiceDefinition, ServiceState, type ServiceStatus, type Session, type SessionOptions, type SetChatReactionsInput, type ShopConsent, type ShopConsentContext, ShopConsentKind, type ShopConsentsResource, type ShopCreatedOrder, type ShopDeliveryCalculation, type ShopDeliveryCity, type ShopDeliveryCountry, type ShopDeliveryDestination, type ShopDeliveryPoint, type ShopDeliveryResource, type ShopFeatureApi, type ShopFeatureOptions, type ShopOrder, type ShopOrderAccessSession, type ShopOrderAccessStorage, type ShopOrderAccessStorageAdapterOptions, type ShopOrderAccessVerification, type ShopOrderBase, type ShopOrderDelivery, type ShopOrderItem, type ShopOrderItemInput, type ShopOrderRequestOptions, ShopOrderStatus, type ShopOrderSummary, type ShopOrderSupport, type ShopOrdersResource, type ShopPayment, type ShopProduct, ShopProductCategory, type ShopProductColor, type ShopProductSpec, ShopProductStatus, type ShopProductsResource, type ShopRecipient, type ShopResource, type ShopSizeChart, type ShopSizeChartRow, type SignInResult, type Span, SpanRenderFormat, SpanType, type StatusDay, type StatusIncidentLine, type StreamFile, type Subscription, type SubscriptionBindCardOptions, type SubscriptionCheckoutInput, SubscriptionCheckoutKind, type SubscriptionCheckoutReleaseInput, type SubscriptionCheckoutState, SubscriptionCheckoutStatus, type SubscriptionCheckoutSubject, type SubscriptionCheckoutTerms, type SubscriptionGift, type SubscriptionGiftInput, type SubscriptionOffer, type SubscriptionPayOptions, type SubscriptionPayment, type SubscriptionPaymentInput, SubscriptionPaymentProvider, type SubscriptionQuote, type SubscriptionRenewalAgreement, type SubscriptionResource, type SubscriptionState, type TelemetryBatch, type TelemetryBatchOptions, type TelemetryClock, type TelemetryOptions, type TelemetryResource, type TextMarkup, TimeoutBudget, type TokenStorage, type TokenStorageAdapterOptions, UnauthorizedStreamError, type UnknownNotificationUpdate, type UnreadCountUpdate, type Unsubscribe, type UpdateNotificationSettingsInput, type UpdatePostInput, type UpdatePrivacyInput, type UpdateProfileInput, type UpdateResultBase, type UploadOptions, type UploadedBannerDrawing, type UploadedFile, type UrlFile, type UrlFileOptions, type UserBase, type UserId, type UserListParams, type UserPostsParams, type UserRef, type UserSummary, type UsernameAvailability, UsernameUnavailableReason, type UsersResource, VIDEO_MIME_TYPES, type VerificationResource, type VerificationStatus, type VideoMimeType, type VideoProgressInput, ViewReason, ViewSource, type ViewTracker, type ViewTrackerInput, type ViewTrackerOptions, WallAccess, type WebSocketImplementationOptions, type WebSocketLike, type WebSocketOpenFailureClassifier, WebSocketTransport, type WebSocketTransportOptions, autoSpans, canonicalNotificationType, comment, createKeyValueStore, createMultiTokenStorage, createNotificationEventsClient, createRecordKeyValueStore, createShopFeature, createShopOrderAccessStorage, createTokenStorage, createUuidV4, formatNotificationText, fromStream, fromUrl, isBuilder, isBuiltInOperationId, isEnumerableKeyValueStore, isItdApiError, isItdAuthError, isItdConflictError, isItdError, isItdFileError, isItdForbiddenError, isItdNotFoundError, isItdPhoneVerificationError, isItdRateLimitError, isItdServerError, isItdStateError, isItdValidationError, isKnownNotificationType, isMyProfile, mapPage, markup, message, messageMarkup, normalizeNotification, operationBucket, operationMethod, operationRetrySafety, parseHtml, parseMarkdown, poll, post, renderSpans, report, resolveNotificationUrl, runEventMiddleware, scopedTokenStorage, statusDays, systemClock, toDate, utcStampToIso, withCodec, withNamespace };
|
|
1801
|
+
export { ALLOWED_MIME_TYPES, AUDIO_MIME_TYPES, AccessType, type AccountChangesResource, type AccountEmailResource, type AccountEvents, type AccountFeature, type AccountInfo, type AccountLifecycleResource, type AccountPasswordResource, type AccountPhoneResource, type AccountPhoneStartInput, type AccountResource, type Actor, type AddAccountOptions, type AllowedMimeType, type Announcement, type AnnouncementButton, type Attachment, AttachmentType, type AttemptContext, type AttemptExtensions, type AttemptInterceptor, type AttemptNext, type AudioMimeType, type AuthEvents, type AuthIdentity, type AuthInput, type AuthProvider, type AuthResource, type AuthState, type AuthUser, type Author, type AutoSpansOptions, BUCKET_LIMITS, type BannerDrawing, type BannerDrawingOperation, type BannerDrawingPoint, BannerDrawingTool, type BuilderInput, type BuiltInOperationId, CaptchaChoice, CaptchaField, type CaptchaPage, type CaptchaProvider, type CaptchaSolveContext, type CaptchaSolver, type CaptchaSolverInput, type CaptchaToken, CaptchaType, type ChangelogEntry, ChatActionType, type ChatAttachment, type ChatChange, type ChatDeletedMessages, type ChatDirectResult, type ChatEditedMessage, type ChatEventContext, type ChatEventMap, type ChatEventsOptions, type ChatFileLink, type ChatFirstMessage, type ChatForwardedMessages, type ChatHistoryPage, type ChatListPage, type ChatListParams, ChatMediaCategory, type ChatMediaItem, type ChatMediaPage, type ChatMessage, type ChatMessageContent, type ChatMessageReactions, type ChatPresence, type ChatPreview, type ChatReaction, type ChatReactionCatalog, type ChatReactionCount, ChatReactionType, type ChatReadCursor, type ChatReadResult, type ChatReply, type ChatSentMessage, type ChatSummary, type ChatTextEntity, type ChatUnreadState, type ChatUpdate, ChatUpdateType, type ChatUpdatesPage, type ChatUploadOptions, type ChatUploadedFile, type ChatsApi, ChatsResource, type Clan, type ClientConnection, type ClientFeature, type ClientHooks, type ClientPlugin, type Comment, type CommentBuilder, type CommentInput, type CommentReplyTo, CommentSort, type CommentUpdateResult, type CommentsParams, type CommentsResource, type ConsentContext, type ConsentDocument, type ContactActionResult, type ContactChange, type ContactChangeConfirmation, type ContactChangeSchedule, type ContactProofDelivery, type CreateCommentInput, type CreatePollInput, type CreatePostData, type CreatePostInput, type CreateReportInput, type CreateShopOrderInput, type CreateShopOrderOptions, type Credentials, type CredentialsAuth, type CredentialsWithCaptcha, type CustomOperationId, DEFAULT_BASE_URL, DEFAULT_RATE_LIMIT_BUCKET, type DwellEntry, type EnumerableKeyValueStore, type ErrorContextHook, EventChannel, type EventChannelDeps, type EventChannelEvents, type EventChannelOptions, EventChannelStatus, EventComposer, type EventContext, type EventEnqueueOptions, type EventErrorBoundary, type EventErrorContext, type EventFilter, type EventHandler, type EventMiddleware, type EventMiddlewareGroup, type EventMiddlewareLike, type EventMiddlewareObject, type EventNext, type EventPredicate, type EventRouteSelector, type EventRouteTable, EventRouter, type EventSequentializer, type EventSession, type EventSyncReason, type EventTransport, type EventTransportContext, type EventTransportFrame, type EventTypeGuard, type FeatureBucketDefinition, type FeatureContext, type FeatureInstallation, type FeatureOperationDefinition, type FeatureOperationId, type FeatureRequestOptions, type FeedParams, FeedTab, type FileContent, type FileContext, type FileInput, type FileResolver, type FileStreamContent, type FileStreamOptions, FileTransferMode, type FilesResource, type FollowResult, type ForgotPasswordInput, type ForwardChatMessagesInput, type FromStreamOptions, type Hashtag, type HashtagPostsParams, type HashtagsResource, IMAGE_MIME_TYPES, type ImageMimeType, IncidentKind, type InteractionEntry, InteractionType, type InternationalSubscriptionCapability, type InternationalSubscriptionCheckout, InternationalSubscriptionCheckoutMode, type InternationalSubscriptionOffer, type IsoDate, ItdAbortError, type ItdAccountsOptions, ItdApiError, type ItdApiErrorInit, ItdApiErrorKind, ItdAuthError, type ItdBuilder, type ItdClientOptions, type ItdClock, ItdConfigError, ItdConflictError, ItdError, ItdErrorCode, ItdErrorKind, type ItdFieldErrors, ItdFileError, ItdFileErrorReason, ItdForbiddenError, ItdNetworkError, ItdNotFoundError, ItdPhoneVerificationError, ItdRateLimitError, ItdServerError, type ItdSession, ItdStateError, ItdTimeoutError, ItdValidationError, type KeyValueCodec, type KeyValueStore, type KeyValueStoreKeys, type KeyValueStoreResult, LIBRARY_VERSION, type LastSeen, LastSeenUnit, type LazyFile, type LegalDocument, type LegalDocumentBlock, LegalDocumentBlockType, LegalDocumentScope, type LegalDocumentSummary, type LegalDocumentVersion, type LegalResource, type LikeResult, LikesVisibility, type Listener, LogLevel, type Logger, type Loose, type ManagedClientResource, type MarkupBuilder, type MarkupContent, type MarkupInput, type MarkupSpan, MemoryKeyValueStore, MemoryMultiTokenStorage, MemoryShopOrderAccessStorage, MemoryTokenStorage, MessageAccess, type MessageAllowlistMembership, type MessageAllowlistParams, type MessageAllowlistUser, type MessageBuilder, type MessageInput, type MessageMarkup, type MessageMarkupBuilder, type MessageMarkupContent, type MessageMarkupInput, type MultiTokenStorage, type MultiTokenStorageAdapterOptions, type MyProfile, type Notification, type NotificationContext, type NotificationEvent, type NotificationEventContext, type NotificationEventFilter, type NotificationEventOfType, type NotificationEventSelector, NotificationEvents, NotificationEventsClient, type NotificationEventsClientOptions, type NotificationEventsMap, type NotificationEventsOptions, NotificationEventsTransport, type NotificationEventsUpdate, type NotificationListParams, type NotificationOfType, type NotificationSettings, NotificationType, type NotificationUpdate, type NotificationUpdateOfType, NotificationUpdateOrigin, NotificationUpdateType, type NotificationsApi, type NotificationsResource, OPERATIONS, type OperationAnnotations, type ItdOperationDefinition as OperationDefinition, type OperationExtensions, type OperationId, type OperationMetadata, OperationMethod, type OperationRequestOptions, type OperationTransformContext, type OperationTransformer, type OriginalPost, type Page, type PageState, PaginationMode, type PaginationOptions, Paginator, type PaginatorOptions, type ParseMarkupOptions, type PayShopOrderOptions, type PaymentMethod, PaymentMethodType, type PendingContactChange, type PhoneAuthResource, type PhoneConfig, type PhoneConsent, type PhoneDelivery, type PhoneFlowInput, type PhoneFlowResume, type PhoneFlowStart, type PhoneLoginInput, type PhoneLoginResult, type PhoneRegion, type PhoneReverseOptions, type PhoneReverseStatus, type PhotoOpenInput, type Pin, type PinPostResult, type PinsResult, type PlatformClientVersion, type PlatformResource, type PlatformStatus, type PlatformVersions, type PluginApi, type PluginTeardown, type Poll, type PollBuilder, type PollInput, type PollOption, type Portal, type Post, type PostBase, type PostBuilder, type PostCounters, type PostInput, type PostStats, type PostUpdateInput, type PostUpdateResult, type PostsResource, type PreparedBufferSource, type PreparedFileSource, type PreparedStreamSource, type PrivacySettings, type Profile, type PublicProfile, QrLocationPrecision, type QrLoginClaim, type QrLoginClaimInput, type QrLoginSecrets, type QrLoginStart, type QrLoginStreamEvent, type QrLoginStreamInput, type QrLoginStreamListener, type QrLoginStreamOptions, type QrLoginTarget, type QueryParams, type QueryValue, type RateLimitBucket, type RateLimitBucketContext, type RateLimitBucketOverride, type RateLimitBucketState, RateLimitErrorScope, type RateLimitOptions, RateLimitPacing, type RawRequestOptions, type ReconnectOptions, type RecordKeyValueStoreSource, type RemoveAccountOptions, type RenderSpansOptions, type RepliesParams, type Report, type ReportBuilder, type ReportInput, ReportReason, ReportTargetType, type ReportsResource, type RequestContext, type RequestExtensions, type RequestOptions, type ResetPasswordInput, type ResolveFileContext, type ResolveFileOptions, type ResponseContext, type RetryContext, type RetryDecisionContext, type RetryOptions, RetrySafety, RuntimeMode, type RuntimeOptions, STATUS_SERVICE, type SearchResource, type SearchResult, type SendChatMessageInput, type ServiceDefinition, ServiceState, type ServiceStatus, type Session, type SessionOptions, type SetChatReactionsInput, type ShopConsent, type ShopConsentContext, ShopConsentKind, type ShopConsentsResource, type ShopCreatedOrder, type ShopDeliveryCalculation, type ShopDeliveryCity, type ShopDeliveryCountry, type ShopDeliveryDestination, type ShopDeliveryPoint, type ShopDeliveryResource, type ShopFeatureApi, type ShopFeatureOptions, type ShopOrder, type ShopOrderAccessSession, type ShopOrderAccessStorage, type ShopOrderAccessStorageAdapterOptions, type ShopOrderAccessVerification, type ShopOrderBase, type ShopOrderDelivery, type ShopOrderItem, type ShopOrderItemInput, type ShopOrderRequestOptions, ShopOrderStatus, type ShopOrderSummary, type ShopOrderSupport, type ShopOrdersResource, type ShopPayment, type ShopProduct, ShopProductCategory, type ShopProductColor, type ShopProductSpec, ShopProductStatus, type ShopProductsResource, type ShopRecipient, type ShopResource, type ShopSizeChart, type ShopSizeChartRow, type SignInResult, type Span, SpanRenderFormat, SpanType, type StatusDay, type StatusIncidentLine, type StreamFile, type Subscription, type SubscriptionBindCardOptions, type SubscriptionCheckoutInput, SubscriptionCheckoutKind, type SubscriptionCheckoutReleaseInput, type SubscriptionCheckoutState, SubscriptionCheckoutStatus, type SubscriptionCheckoutSubject, type SubscriptionCheckoutTerms, type SubscriptionGift, type SubscriptionGiftInput, type SubscriptionOffer, type SubscriptionPayOptions, type SubscriptionPayment, type SubscriptionPaymentInput, SubscriptionPaymentProvider, type SubscriptionQuote, type SubscriptionRenewalAgreement, type SubscriptionResource, type SubscriptionState, type TelemetryBatch, type TelemetryBatchOptions, type TelemetryClock, type TelemetryOptions, type TelemetryResource, type TermsAcceptance, type TextMarkup, TimeoutBudget, type TokenStorage, type TokenStorageAdapterOptions, UnauthorizedStreamError, type UnknownNotificationUpdate, type UnreadCountUpdate, type Unsubscribe, type UpdateNotificationSettingsInput, type UpdatePostInput, type UpdatePrivacyInput, type UpdateProfileInput, type UpdateResultBase, type UploadOptions, type UploadedBannerDrawing, type UploadedFile, type UrlFile, type UrlFileOptions, type UserBase, type UserId, type UserListParams, type UserPostsParams, type UserRef, type UserSummary, type UsernameAvailability, UsernameUnavailableReason, type UsersResource, VIDEO_MIME_TYPES, type VerificationResource, type VerificationStatus, type VideoMimeType, type VideoProgressInput, ViewReason, ViewSource, type ViewTracker, type ViewTrackerInput, type ViewTrackerOptions, WallAccess, type WebSocketImplementationOptions, type WebSocketLike, type WebSocketOpenFailureClassifier, WebSocketTransport, type WebSocketTransportOptions, autoSpans, canonicalNotificationType, comment, createKeyValueStore, createMultiTokenStorage, createNotificationEventsClient, createRecordKeyValueStore, createShopFeature, createShopOrderAccessStorage, createTokenStorage, createUuidV4, formatNotificationText, fromStream, fromUrl, isBuilder, isBuiltInOperationId, isEnumerableKeyValueStore, isItdApiError, isItdAuthError, isItdConflictError, isItdError, isItdFileError, isItdForbiddenError, isItdNotFoundError, isItdPhoneVerificationError, isItdRateLimitError, isItdServerError, isItdStateError, isItdValidationError, isKnownNotificationType, isMyProfile, mapPage, markup, message, messageMarkup, normalizeNotification, operationBucket, operationMethod, operationRetrySafety, parseHtml, parseMarkdown, poll, post, renderSpans, report, resolveNotificationUrl, runEventMiddleware, scopedTokenStorage, statusDays, systemClock, toDate, utcStampToIso, withCodec, withNamespace };
|
package/dist/index.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { A as isItdFileError, C as ItdValidationError, D as isItdAuthError, E as isItdApiError, F as isItdServerError, I as isItdStateError, L as isItdValidationError, M as isItdNotFoundError, N as isItdPhoneVerificationError, O as isItdConflictError, P as isItdRateLimitError, S as ItdTimeoutError, T as TimeoutBudget, _ as ItdNotFoundError, a as ItdAbortError, b as ItdServerError, c as ItdAuthError, d as ItdError, f as ItdErrorKind, g as ItdNetworkError, h as ItdForbiddenError, i as requireOptionalBoolean, j as isItdForbiddenError, k as isItdError, l as ItdConfigError, m as ItdFileErrorReason, n as isRecord, o as ItdApiError, p as ItdFileError, s as ItdApiErrorKind, t as isObjectLike, u as ItdConflictError, v as ItdPhoneVerificationError, w as RateLimitErrorScope, x as ItdStateError, y as ItdRateLimitError } from "./shared/validate-CCgIq5u0.js";
|
|
2
|
-
import { $ as ChatReactionType, A as AccountLifecycleResource, B as AUDIO_MIME_TYPES, C as poll, D as LegalDocumentScope, E as LegalDocumentBlockType, F as BaseResource, G as autoSpans, H as VIDEO_MIME_TYPES, I as PaginationMode, J as normalizeChatUpdate, K as markup, L as Paginator, M as createFeatureHost, N as ExtensibleOperationCatalog, O as comment, P as ChatsResource, Q as ChatMediaCategory, R as mapPage, S as post, T as parseMarkdown, U as message, V as IMAGE_MIME_TYPES, W as messageMarkup, X as utcStampToIso, Y as toDate, Z as ChatActionType, _ as PaymentMethodType, a as createShopOrderAccessStorage, b as SubscriptionPaymentProvider, c as ShopOrderStatus, d as isMyProfile, et as ChatUpdateType, f as BannerDrawingTool, g as InternationalSubscriptionCheckoutMode, h as createResources, i as MemoryShopOrderAccessStorage, j as NotificationsResource, k as createStatusFeature, l as ShopProductCategory, m as fromUrl, n as renderSpans, o as statusDays, p as fromStream, q as isBuilder, r as createShopFeature, s as ShopConsentKind, t as SpanRenderFormat, u as ShopProductStatus, v as SubscriptionCheckoutKind, w as parseHtml, x as report, y as SubscriptionCheckoutStatus, z as ALLOWED_MIME_TYPES } from "./shared/render-
|
|
3
|
-
import { _ as Emitter, a as EVENT_OPERATIONS, c as resolveNotificationEventsOptions, d as NotificationUpdateType, f as createParser, g as runEventMiddleware, h as UnauthorizedStreamError, i as createNotificationEventsClient, l as setNotificationEventsConnectGuard, m as EventChannel, n as EventRouter, o as NotificationEvents, p as WebSocketTransport, r as NotificationEventsClient, s as NotificationEventsTransport, t as EventComposer, u as NotificationUpdateOrigin, v as reportListenerError } from "./shared/events-
|
|
4
|
-
import { $ as CaptchaField, B as BUCKET_LIMITS, C as setQueuedAuthPreparation, D as pickArray, E as installAsyncDisposeFallback, F as defineBuiltInOperation, H as OperationMethod, I as isBuiltInOperationId, J as requestAbortError, L as operationBucket, M as passthroughOperation, N as voidOperation, P as OPERATIONS, Q as CaptchaChoice, R as operationMethod, T as readTokenMetadata, U as RetrySafety, V as DEFAULT_RATE_LIMIT_BUCKET, X as AccessType, Z as AttachmentType, _ as STATUS_SERVICE, _t as ViewReason, at as InteractionType, b as RateLimitPacing, c as ITD_CATALOG, ct as LikesVisibility, dt as QrLocationPrecision, et as CaptchaType, f as RequestQueuePool, ft as ReportReason, gt as UsernameUnavailableReason, h as DEFAULT_BASE_URL, ht as SpanType, it as IncidentKind, j as pickString, l as createClientRuntime, lt as MessageAccess, m as orderPluginDefinitions, mt as ServiceState, n as formatNotificationText, nt as EventChannelStatus, o as canonicalNotificationType, ot as ItdErrorCode, p as assertPluginRemovable, pt as ReportTargetType, q as createRequestAbortScope, r as normalizeNotification, rt as FeedTab, s as isKnownNotificationType, st as LastSeenUnit, t as resolveNotificationUrl, tt as CommentSort, u as createApiError, ut as NotificationType, v as resolveRateLimit, vt as ViewSource, xt as systemClock, y as LIBRARY_VERSION, yt as WallAccess, z as operationRetrySafety } from "./shared/url-
|
|
2
|
+
import { $ as ChatReactionType, A as AccountLifecycleResource, B as AUDIO_MIME_TYPES, C as poll, D as LegalDocumentScope, E as LegalDocumentBlockType, F as BaseResource, G as autoSpans, H as VIDEO_MIME_TYPES, I as PaginationMode, J as normalizeChatUpdate, K as markup, L as Paginator, M as createFeatureHost, N as ExtensibleOperationCatalog, O as comment, P as ChatsResource, Q as ChatMediaCategory, R as mapPage, S as post, T as parseMarkdown, U as message, V as IMAGE_MIME_TYPES, W as messageMarkup, X as utcStampToIso, Y as toDate, Z as ChatActionType, _ as PaymentMethodType, a as createShopOrderAccessStorage, b as SubscriptionPaymentProvider, c as ShopOrderStatus, d as isMyProfile, et as ChatUpdateType, f as BannerDrawingTool, g as InternationalSubscriptionCheckoutMode, h as createResources, i as MemoryShopOrderAccessStorage, j as NotificationsResource, k as createStatusFeature, l as ShopProductCategory, m as fromUrl, n as renderSpans, o as statusDays, p as fromStream, q as isBuilder, r as createShopFeature, s as ShopConsentKind, t as SpanRenderFormat, u as ShopProductStatus, v as SubscriptionCheckoutKind, w as parseHtml, x as report, y as SubscriptionCheckoutStatus, z as ALLOWED_MIME_TYPES } from "./shared/render-DBt-OBbC.js";
|
|
3
|
+
import { _ as Emitter, a as EVENT_OPERATIONS, c as resolveNotificationEventsOptions, d as NotificationUpdateType, f as createParser, g as runEventMiddleware, h as UnauthorizedStreamError, i as createNotificationEventsClient, l as setNotificationEventsConnectGuard, m as EventChannel, n as EventRouter, o as NotificationEvents, p as WebSocketTransport, r as NotificationEventsClient, s as NotificationEventsTransport, t as EventComposer, u as NotificationUpdateOrigin, v as reportListenerError } from "./shared/events-DorlX-Xd.js";
|
|
4
|
+
import { $ as CaptchaField, B as BUCKET_LIMITS, C as setQueuedAuthPreparation, D as pickArray, E as installAsyncDisposeFallback, F as defineBuiltInOperation, H as OperationMethod, I as isBuiltInOperationId, J as requestAbortError, L as operationBucket, M as passthroughOperation, N as voidOperation, P as OPERATIONS, Q as CaptchaChoice, R as operationMethod, T as readTokenMetadata, U as RetrySafety, V as DEFAULT_RATE_LIMIT_BUCKET, X as AccessType, Z as AttachmentType, _ as STATUS_SERVICE, _t as ViewReason, at as InteractionType, b as RateLimitPacing, c as ITD_CATALOG, ct as LikesVisibility, dt as QrLocationPrecision, et as CaptchaType, f as RequestQueuePool, ft as ReportReason, gt as UsernameUnavailableReason, h as DEFAULT_BASE_URL, ht as SpanType, it as IncidentKind, j as pickString, l as createClientRuntime, lt as MessageAccess, m as orderPluginDefinitions, mt as ServiceState, n as formatNotificationText, nt as EventChannelStatus, o as canonicalNotificationType, ot as ItdErrorCode, p as assertPluginRemovable, pt as ReportTargetType, q as createRequestAbortScope, r as normalizeNotification, rt as FeedTab, s as isKnownNotificationType, st as LastSeenUnit, t as resolveNotificationUrl, tt as CommentSort, u as createApiError, ut as NotificationType, v as resolveRateLimit, vt as ViewSource, xt as systemClock, y as LIBRARY_VERSION, yt as WallAccess, z as operationRetrySafety } from "./shared/url-DTDqkKpf.js";
|
|
5
5
|
import { D as fallbackLogger, E as LogLevel, a as isSerializedCookieEntry, i as REFRESH_COOKIE_PATH, k as resolveLogger, n as CookieJar, r as REFRESH_COOKIE, s as encodePathSegment, u as joinUrl, v as RuntimeMode, y as createUuidV4 } from "./shared/cookies-mDZE19_j.js";
|
|
6
6
|
import { n as copySession, r as createTokenStorage, t as MemoryTokenStorage } from "./shared/storage-ChR4KC8V.js";
|
|
7
7
|
import { a as scopedTokenStorage, i as isRestorableSession, n as controlledTokenStorage, r as createMultiTokenStorage, t as MemoryMultiTokenStorage } from "./shared/multi-storage-CLPyg8_T.js";
|
|
@@ -193,6 +193,8 @@ function createNotificationsApi(http, createEvents) {
|
|
|
193
193
|
}
|
|
194
194
|
// src/operations/account.ts
|
|
195
195
|
const ACCOUNT_GET_INFO = passthroughOperation("account.getInfo");
|
|
196
|
+
const ACCOUNT_TERMS_ACCEPTANCE = passthroughOperation("account.termsAcceptance");
|
|
197
|
+
const ACCOUNT_ACCEPT_TERMS = voidOperation("account.acceptTerms");
|
|
196
198
|
const ACCOUNT_PASSWORD_SET = voidOperation("account.password.set");
|
|
197
199
|
const ACCOUNT_PASSWORD_CHANGE = voidOperation("account.password.change");
|
|
198
200
|
// src/operations/account/changes.ts
|
|
@@ -275,7 +277,8 @@ const PhoneDeliveryChannel = Object.freeze({
|
|
|
275
277
|
MissedCall: "missed_call",
|
|
276
278
|
VoiceCall: "voice_call",
|
|
277
279
|
Sms: "sms",
|
|
278
|
-
Push: "push"
|
|
280
|
+
Push: "push",
|
|
281
|
+
Message: "message"
|
|
279
282
|
});
|
|
280
283
|
/** Подтверждение входящим кодом либо исходящим звонком пользователя. */
|
|
281
284
|
const PhoneVerificationMethod = Object.freeze({
|
|
@@ -354,7 +357,7 @@ var AccountEmailResource = class extends BaseResource {
|
|
|
354
357
|
}
|
|
355
358
|
/** Повторно отправляет код на тот же адрес. Передайте `flowToken` из первого запроса. */
|
|
356
359
|
resendOtp(input, options = {}) {
|
|
357
|
-
return requestAccount(this.http, ACCOUNT_EMAIL_RESEND_OTP, "/resend-otp", input, options);
|
|
360
|
+
return requestAccount(this.http, ACCOUNT_EMAIL_RESEND_OTP, "/email/resend-otp", input, options);
|
|
358
361
|
}
|
|
359
362
|
};
|
|
360
363
|
// src/resources/account/password.ts
|
|
@@ -580,6 +583,21 @@ var AccountResource = class extends AccountLifecycleResource {
|
|
|
580
583
|
getInfo(options = {}) {
|
|
581
584
|
return requestAccount(this.http, ACCOUNT_GET_INFO, "/methods", void 0, options);
|
|
582
585
|
}
|
|
586
|
+
/** Возвращает текущую редакцию условий и контекст, если аккаунту требуется согласие. */
|
|
587
|
+
termsAcceptance(options = {}) {
|
|
588
|
+
return requestAccount(this.http, ACCOUNT_TERMS_ACCEPTANCE, "/terms-acceptance", void 0, options);
|
|
589
|
+
}
|
|
590
|
+
/**
|
|
591
|
+
* Записывает согласие текущего аккаунта с редакцией условий.
|
|
592
|
+
*
|
|
593
|
+
* @param contextToken токен из контекста согласия, полученного через {@link termsAcceptance}
|
|
594
|
+
*/
|
|
595
|
+
acceptTerms(contextToken, options = {}) {
|
|
596
|
+
return requestAccount(this.http, ACCOUNT_ACCEPT_TERMS, "/terms-acceptance", {
|
|
597
|
+
accepted: true,
|
|
598
|
+
contextToken
|
|
599
|
+
}, options);
|
|
600
|
+
}
|
|
583
601
|
};
|
|
584
602
|
// src/operations/auth.ts
|
|
585
603
|
/** Чем закончился запрос входа. */
|
|
@@ -813,7 +831,7 @@ const AUTH_PATHS = {
|
|
|
813
831
|
signUp: "/api/v1/auth/sign-up",
|
|
814
832
|
signIn: "/api/v1/auth/sign-in",
|
|
815
833
|
verifyOtp: "/api/v1/auth/verify-otp",
|
|
816
|
-
resendOtp: "/api/v1/auth/resend-otp",
|
|
834
|
+
resendOtp: "/api/v1/auth/email/resend-otp",
|
|
817
835
|
refresh: "/api/v1/auth/refresh",
|
|
818
836
|
logout: "/api/v1/auth/logout",
|
|
819
837
|
forgotPassword: "/api/v1/auth/forgot-password",
|
|
@@ -1775,7 +1793,13 @@ var PhoneAuthResource = class extends BaseResource {
|
|
|
1775
1793
|
}
|
|
1776
1794
|
/** Разрешённые регионы, примеры номеров и доступные способы подтверждения. */
|
|
1777
1795
|
config(options = {}) {
|
|
1778
|
-
return this.#request(AUTH_PHONE_CONFIG, "/phone/config", void 0,
|
|
1796
|
+
return this.#request(AUTH_PHONE_CONFIG, "/phone/config", void 0, {
|
|
1797
|
+
...options,
|
|
1798
|
+
headers: {
|
|
1799
|
+
...options.headers,
|
|
1800
|
+
"X-ITD-Phone-Message": "1"
|
|
1801
|
+
}
|
|
1802
|
+
});
|
|
1779
1803
|
}
|
|
1780
1804
|
/**
|
|
1781
1805
|
* Загружает контекст phone_entry вместе с текстом и редакциями документов.
|
|
@@ -1809,7 +1833,7 @@ var PhoneAuthResource = class extends BaseResource {
|
|
|
1809
1833
|
...options,
|
|
1810
1834
|
headers: {
|
|
1811
1835
|
...options.headers,
|
|
1812
|
-
...input.method === PhoneVerificationMethod.Reverse ? { "X-ITD-Phone-Method": PhoneVerificationMethod.Reverse } : {}
|
|
1836
|
+
...input.method === PhoneVerificationMethod.Reverse ? { "X-ITD-Phone-Method": PhoneVerificationMethod.Reverse } : { "X-ITD-Phone-Message": "1" }
|
|
1813
1837
|
}
|
|
1814
1838
|
});
|
|
1815
1839
|
}
|