polyv-live-api-sdk 1.0.5 → 1.0.9
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/README.md +186 -0
- package/dist/index.cjs +71 -0
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +64 -1
- package/dist/index.js +71 -0
- package/dist/index.js.map +1 -1
- package/dist/services/channel.service.d.ts +40 -1
- package/dist/services/channel.service.d.ts.map +1 -1
- package/dist/services/live-interaction.service.d.ts.map +1 -1
- package/dist/types/channel.d.ts +24 -0
- package/dist/types/channel.d.ts.map +1 -1
- package/dist/types/index.d.ts +1 -1
- package/dist/types/index.d.ts.map +1 -1
- package/package.json +2 -1
package/dist/index.d.cts
CHANGED
|
@@ -2485,6 +2485,30 @@ interface DeleteChannelProductParams {
|
|
|
2485
2485
|
/** Product ID - REQUIRED */
|
|
2486
2486
|
productId: number;
|
|
2487
2487
|
}
|
|
2488
|
+
/**
|
|
2489
|
+
* Update Channel Product Enabled Request
|
|
2490
|
+
*
|
|
2491
|
+
* Parameters for toggling the channel product library on/off.
|
|
2492
|
+
*/
|
|
2493
|
+
interface UpdateChannelProductEnabledParams {
|
|
2494
|
+
/** Channel ID - REQUIRED */
|
|
2495
|
+
channelId: string;
|
|
2496
|
+
/** Product library enabled status: Y = on, N = off - REQUIRED */
|
|
2497
|
+
enabled: YNFlag$1;
|
|
2498
|
+
}
|
|
2499
|
+
/**
|
|
2500
|
+
* Update Channel Config Params
|
|
2501
|
+
*
|
|
2502
|
+
* Parameters for updating channel configuration via /v3/channel/config/update.
|
|
2503
|
+
*/
|
|
2504
|
+
interface UpdateChannelConfigParams {
|
|
2505
|
+
/** Channel ID - REQUIRED */
|
|
2506
|
+
channelId: string;
|
|
2507
|
+
/** Config key name (e.g. 'couponEnabled', 'productEnabled') - REQUIRED */
|
|
2508
|
+
key: string;
|
|
2509
|
+
/** Config value (e.g. 'Y' or 'N') - REQUIRED */
|
|
2510
|
+
value: string;
|
|
2511
|
+
}
|
|
2488
2512
|
/**
|
|
2489
2513
|
* List Channel Products Request
|
|
2490
2514
|
*
|
|
@@ -12712,6 +12736,45 @@ declare class ChannelService {
|
|
|
12712
12736
|
* ```
|
|
12713
12737
|
*/
|
|
12714
12738
|
deleteChannelProduct(params: DeleteChannelProductParams): Promise<boolean>;
|
|
12739
|
+
/**
|
|
12740
|
+
* Update channel product library enabled status
|
|
12741
|
+
*
|
|
12742
|
+
* Toggles the channel product library on or off.
|
|
12743
|
+
* All params (channelId, enabled, appId, timestamp) participate in signature.
|
|
12744
|
+
*
|
|
12745
|
+
* @param params - Parameters including channelId and enabled (Y/N)
|
|
12746
|
+
* @returns true if update was successful
|
|
12747
|
+
* @throws PolyVValidationError if required parameters are missing
|
|
12748
|
+
*
|
|
12749
|
+
* @example
|
|
12750
|
+
* ```typescript
|
|
12751
|
+
* await channelService.updateChannelProductEnabled({
|
|
12752
|
+
* channelId: 'ch123456',
|
|
12753
|
+
* enabled: 'Y',
|
|
12754
|
+
* });
|
|
12755
|
+
* ```
|
|
12756
|
+
*/
|
|
12757
|
+
updateChannelProductEnabled(params: UpdateChannelProductEnabledParams): Promise<boolean>;
|
|
12758
|
+
/**
|
|
12759
|
+
* Update channel configuration
|
|
12760
|
+
*
|
|
12761
|
+
* Updates a channel config key-value pair via /v3/channel/config/update.
|
|
12762
|
+
* Common keys include: couponEnabled, productEnabled, etc.
|
|
12763
|
+
*
|
|
12764
|
+
* @param params - Parameters including channelId, key, and value
|
|
12765
|
+
* @returns true if update was successful
|
|
12766
|
+
* @throws PolyVValidationError if required parameters are missing
|
|
12767
|
+
*
|
|
12768
|
+
* @example
|
|
12769
|
+
* ```typescript
|
|
12770
|
+
* await channelService.updateChannelConfig({
|
|
12771
|
+
* channelId: 'ch123456',
|
|
12772
|
+
* key: 'couponEnabled',
|
|
12773
|
+
* value: 'Y',
|
|
12774
|
+
* });
|
|
12775
|
+
* ```
|
|
12776
|
+
*/
|
|
12777
|
+
updateChannelConfig(params: UpdateChannelConfigParams): Promise<boolean>;
|
|
12715
12778
|
}
|
|
12716
12779
|
|
|
12717
12780
|
/**
|
|
@@ -20501,4 +20564,4 @@ declare function getErrorCodeCategory(code: number): string;
|
|
|
20501
20564
|
*/
|
|
20502
20565
|
declare const VERSION = "1.0.0";
|
|
20503
20566
|
|
|
20504
|
-
export { type AccountViewerSettings, type AddAccountParams, type AddBadwordsParams, type AddBadwordsResponse, type AddBannedIpParams, type AddBannedIpResponse, type AddChannelLabelRefsParams, type AddChannelProductParams, type AddChannelProductResponse, type AddCustomFieldParams, type AddCustomFieldResponse, type AddCustomFieldValueParams, type AddInviteSaleParams, type AddInviteSaleResponse, type AddRobotModel, type AddViewerLabelParams, type AddWhiteListParams, type AllocateLogType, type AllocateOrigin, type AllocationLogItem, type AnchorDetail, type AnchorItem, type AnchorRelationItem, type AntiRecordModelType, type AntiRecordSettingsParams, type AntiRecordSettingsResponse, type AntiRecordShowMode, type AntiRecordType, type ApiErrorDetail, type ApiErrorResponse, type ApiResponse, type ApiResponseStatus, type ApiSuccessResponse, type ApiVersion, type ArrayElement, type AudioModerationRecordItem, type AudioModerationSetting, type AudioModerationSettings, type AudioModerationStrategy, type AuthConfig, type AuthSetting$1 as AuthSetting, type AuthType, type BaseCallbackPayload, type BasicCreateChannelParams, type BatchCheckinItem, type BatchCheckinParams, type BatchCreateChannelsParams, type BatchCreateChannelsResponse, type BatchCreatePopularizationParams, type BatchCreateVideoProducesItem, type BatchCreateVideoProducesParams, type BatchCreateVideoProducesResponse, type BatchDeleteRobotsParams, type BatchPublishSubtitleParams, type BatchSaveRobotsParams, type BatchSaveRobotsResponse, type BatchUpdateOrderStatusParams, type BillUseDetailItem, type BillingDailyItem, type BlacklistAddParams, type BlacklistDeleteParams, type BlacklistItem, type BlacklistPageParams, type BroadcastType, type BrowsersSummary, type BrowsersSummaryParams, type Bulletin, type CallbackOriginType, type CallbackPayload, type CallbackSettings, type CancelCardPushParams, type CardPushItem, type Category, type ChannelBasicInfo, type ChannelBasicListItem, type ChannelDetail$2 as ChannelDetail, type ChannelDetailListItem, type ChannelDetailParams, type ChannelDetailResponse, type ChannelIdParam, type ChannelModel, type ChannelScene$1 as ChannelScene, ChannelService, type ChannelSimpleListItem, type ChannelStreamType, type ChannelsParams, type ChannelsResponse, type ChatHistoryPageResponse, type ChatMessage, type ChildAccount, type ChildAccountRole, type ChildAccountStatus, type CleanNoticesParams, type ContentGroupItem, type ContentGroupType, type ContentGroupTypeExtended, type Coupon, type CouponRule, type CouponViewer, type CreateAnchorParams, type CreateCardPushParams, type CreateCardPushResponse, type CreateCategoryParams, type CreateCategoryResponse, type CreateChannelParams, type CreateChannelRequest, type CreateChannelResponse, type CreateChildAccountParams, type CreateCouponParams, type CreateDistributeBatchParams, type CreateGroupUserParams, type CreateGroupUserResponse, type CreateLabelParams, type CreateLabelResponse, type CreateLotteryActivityParams, type CreateLotteryActivityResponse, type CreateMrChannelParams, type CreateMrChannelResponse, type CreateOrganizationParams, type CreateOrganizationResponse, type CreateProductParams, type CreateProductResponse, type CreateProductTagParams$1 as CreateProductTagParams, type CreateProductTagResponse$1 as CreateProductTagResponse, type CreateRoleParams, type CreateSessionParams, type CreateSessionResponse, type CreateTaskRewardParams, type CreateTaskRewardResponse, type CreateViewerLabelParams, type CreateViewerLabelResponse, type CreateViewerNameGroupParams, type CreateViewerRecordParams, type CreateWaitLotteryParams, type CreateWaitLotteryResponse, type CryptoSource, type CustomField, type DailyViewStatistics, type DecorateSettings, type DeepPartial, type DeleteAccountsParams, type DeleteCardPushParams, type DeleteCategoryParams, type DeleteCategoryResponse, type DeleteChannelBannedParams, type DeleteChannelBannedResponse, type DeleteChannelProductParams, type DeleteChildAccountsParams, type DeleteCouponsBatchParams, type DeleteDistributeBatchParams, type DeleteLabelParams, type DeleteLotteryActivityParams, type DeleteMaterialsParams, type DeleteMaterialsResult, type DeleteOrganizationParams, type DeleteProductParams, type DeleteProductTagParams$1 as DeleteProductTagParams, type DeleteSessionParams, type DeleteTaskRewardParams, type DeleteUserBadwordParams, type DeleteUserBadwordResponse, type DeleteVideoProduceParams, type DeleteViewerLabelParams, type DeleteViewerLabelRefParams, type DeleteViewerRecordParams, type DeleteWhiteListParams, type DigitalHuman, type DigitalHumanInfo, type DigitalHumanOrganization, type DirectAuthViewerParams, type DiskVideoScriptDeleteParams, type DiskVideoScriptInfo, type DiskVideoScriptQueryParams, type DiskVideoScriptUploadParams, type DiskVideoScriptUploadResponse, type DistributeItem, type DistributeListResponse, type DistributeStatistic, type DocConvertStatusItem, type DocConvertType, type DocListResponse, type DocModel, type DocStatus, type DocType, type DonateSettings, type DonateTemplate, type DoubleTeacherType, ERROR_CATEGORIES, ERROR_MESSAGES, type EnvironmentInfo, type ErrorCategory, type ErrorCategoryName, ExportSessionStatsParams, ExportSessionStatsResponse, type ExternalViewerItem, type FollowViewer, type ForbidChannelKickUsersBody, type ForbidChannelKickUsersParams, type ForbidChannelKickUsersResponse, type ForbidChannelUnkickUsersBody, type ForbidChannelUnkickUsersParams, type ForbidChannelUnkickUsersResponse, type ForbidKickUsersBody, type ForbidKickUsersGlobalResponse, type ForbidKickUsersResponse, type ForbidUnkickUsersGlobalResponse, type ForbidUser, type FullReduceRule, type GeoSummary, type GeoSummaryParams, type GetAccountViewerParams, type GetBillUseDetailListParams, type GetBillUseDetailListResponse, type GetByRoleParams, type GetBySaleParams, type GetCardPushParams, type GetCategoryListResponse, type GetChannelBannedListParams, type GetChannelBannedListResponse, type GetChannelBannedUserListParams, type GetChannelBannedUserListResponse, type GetChannelKickedUserListParams, type GetChannelKickedUserListResponse, type GetChildAccountParams, type GetDailyViewStatisticsParams, type GetDailyViewStatisticsResponse, type GetDecorateParams, type GetDistributeStatisticParams, type GetDocListRequest, type GetDonateParams, type GetForbidUserListParams, type GetForbidUserListResponse, type GetIncomeDetailParams, type GetIncomeDetailResponse, type GetInviteRankParams, type GetInviteStatsParams, type GetLiveSessionParams, type GetLotteryActivityParams, type GetMicDurationParams, type GetProductOrderParams, type GetProductSettingParams, type GetProductTagParams, type GetRelevanceParams, type GetRobotSettingParams, type GetRobotStatsParams, type GetRoleResponse, type GetSessionParams, type GetSessionStatsSummaryListParams, type GetSessionStatsSummaryListResponse, type GetShareParams, type GetSimpleChannelListParams, type GetSimpleChannelListResponse, type GetSubtitleParams, type GetTaskRewardParams, type GetTaskRewardStatsParams, type GetUserDurationsParams, type GetUserDurationsResponse, type GetUserInfoResponse, type GetVideoProduceParams, type GetVideoProducePptParams, type GetViewerDetailParams, type GetViewerRecordParams, type GetViewerUnionDetailParams, GetViewlogParams, GetViewlogResponse, type GetWatchConditionParams, type GetWatchLogDetailParams, type GetWatchLogListParams, type GetWatchLogListResponse, type GetWhiteListParams, type GetWhiteListResponse, type GiftItem, type GiftPageParams, type GlobalFooterSettings, type GlobalSwitchSettings, type GroupAddParams, type GroupAllocateLogContent, type GroupDeleteParams, type GroupInfo, type GroupListParams, type GroupPaginatedResponse, type GroupPaginationParams, type GroupResponse, type GroupUpdateParams, type GroupUserPackage, type GroupViewerAddParams, type GroupViewerDeleteParams, type GroupViewerInfo, type GroupViewerListParams, type HeadAdvertParams, type HeadAdvertType, HttpMethod, type IllegalNotifySettings, type ImageFrequency, type ImportExternalViewerParams, type InfoField$1 as InfoField, type InfoFieldType, type InteractionCallbackPayload, type InteractionEventDeleteParams, type InteractionEventSaveParams, type InteractionType, type InviteRankItem, type InviteSale, type InviteStats, type InviterCreateParams, type JsonArray, type JsonObject, type JsonValue, type KickedUser, type Label, type LanguageInfo, type LikeItem, type LikePageParams, type ListAllocateLogParams, type ListAllocateLogResponse, type ListAllocationLogsParams, type ListAllocationLogsResponse, type ListAnchorRelationsParams, type ListAnchorsParams, type ListAnchorsResponse, type ListAudioModerationRecordsParams, type ListAudioModerationRecordsResponse, type ListBillingDailyParams, type ListBillingDailyResponse, type ListBulletinsParams, type ListBulletinsResponse, type ListChannelBasicParams, type ListChildAccountsParams, type ListChildAccountsResponse, type ListContentGroupsParams, type ListCustomFieldsResponse, type ListDigitalHumansParams, type ListDigitalHumansResponse, type ListDistributeParams, type ListFollowViewersParams, type ListFollowViewersResponse, type ListGroupUserPackagesParams, type ListGroupUserPackagesResponse, type ListInviteSalesResponse, type ListLabelsResponse, type ListLotteryActivitiesParams, type ListMaterialCategoriesParams, type ListMaterialCategoriesResponse, type ListMaterialsParams, type ListMaterialsResponse, type ListOrganizationsParams, type ListOrganizationsResponse, type ListProductOrdersParams, type ListProductOrdersResponse, type ListProductTagsParams, type ListProductTagsResponse, type ListProductsParams, type ListProductsResponse, type ListQaParams, type ListQaResponse, type ListRobotsParams, type ListRobotsResponse, type ListRolesParams, type ListRolesResponse, type ListSessionsParams, type ListSessionsResponse, type ListVideoModerationResultsParams, type ListVideoModerationResultsResponse, type ListVideoProducePptsParams, type ListVideoProducePptsResponse, type ListVideoProducesParams, type ListVideoProducesResponse, type ListViewerLabelsResponse, type ListViewerRecordsParams, type ListViewerRecordsResponse, type LiveSessionInfo, type LiveStatusCallbackPayload, type LiveStatusItem, type LiveStatusType, type LiveSummary, type LiveSummaryParams, type LogoParams, type LogoPosition, type LotteryActivity, type LotteryListParams, type LotteryStatistics, MAX_DATE_RANGE_DAYS, type MarqueeTemplate, type MarqueeUrlParams, type Material, type MaterialCategory, type MaterialExtData, type MaterialInfo, type MaterialPaginatedResponse, type MaterialPaginationParams, type MemberStatusCallbackPayload, type MemberStatusType, type MicDurationParams, type MicDurationResponse$1 as MicDurationResponse, type ModerationLabel, type ModerationResultType, type MonitorStreamInfo, type MrConcurrencyDetailResponse, type Mutable, type NewScene, type NonNullable, type OptionalKeys, type Organization, type PageMRecordParams, type PageMRecordResponse, type PageSetting, type PaginatedForbidUserData, type PaginationOptions, type PaginationResponse, type PauseRobotParams, type Permission, type PlaybackCallbackPayload, type PlaybackItem, type PlaybackListParams, type PlaybackListResponse, type PlaybackSetting, type PlaybackVideoInfo, PolyVAPIError, type PolyVAPIErrorOptions, type PolyVAPIErrorResponse, PolyVClient, type PolyVClientConfig, PolyVError, PolyVErrorCode, type PolyVErrorOptions, PolyVValidationError, type PopularizationInfo, type PopularizationItem, type PopularizationListParams, PptStatus, type Primitive, type PrivacyParam, type Product, type ProductLinkType, type ProductOrder, type ProductPriceType, type ProductSetting, type ProductStatsItem, type ProductStatsPageParams, type ProductStatus, type ProductTag$1 as ProductTag, type ProductType, type PushCardParams, type PvShowEnableSettings, type Qa, type QaAnswer, type QueryPlaybackVideoInfoParams, type QueryWinnerViewerParams, type ReceiveListParams, type ReceiveListResponse, type RecordCallbackPayload, type RecordedFileItem, type RemoveInviteSaleParams, type RequestOptions, type RequireKeys, type ResolvedClientConfig, type Robot, type RobotSetting, type RobotStats, type Role, type RoleConfig, type RoleConfigTemplate, type RoleDetail, type RolePermission, type SaveRobotItem, type SearchCouponViewersParams, type SearchCouponViewersResponse, type SearchCouponsParams, type SearchCouponsResponse, type SendAdminMsgResponse, type SendCustomMessageEncodeParams, type SendCustomMessageParams, type SendSmsParams, type SessionInfo, type SessionRelevanceInfo, type SessionStatsSummary, type SetAuthTypeParams, type SetConcurrencesParams, type SetFlowParams, type SetLiveDurationsParams, type SetOrganizationsItem, type SetOrganizationsParams, type SetPlaybackCallbackParams, type SetPlaybackCallbackResponse, type SetPullBitrateParams, type SetRecordCallbackParams, type SetRecordCallbackResponse, type SetSpaceParams, type SetStreamCallbackParams, type SetStreamCallbackResponse, type SetUserChildrenLoginTokenParams, type SetUserChildrenLoginTokenResponse, type SetUserLoginTokenParams, type SetUserLoginTokenResponse, type SetWatchConditionParams, type SexType, type ShareSettings, type SignParams, type SignatureConfig, type SignatureInput, SignatureMethod, type SignatureOutput, type SignatureResult, type SortChannelProductParams, type SortOptions, type SsoConfigParams, type SsoConfigResponse, type SsoLoginParams, type SsoLoginResponse, type StatisticsCallbackPayload, type StopAdvertParams, type StopTaskRewardParams, type SubAuthType, type SubmitAcceptInfoParams, type SubtitleInfo$1 as SubtitleInfo, type SwitchGetResponse, type SwitchUpdateParams, type SwitchUpdateResponse, type TaskReward, type TaskRewardPageParams, type TaskRewardStats, type TaskRewardViewerDetail, type Template, type TtsVoice, type TtsVoiceInfo, TtsVoiceTag, type UnconditionalRule, type UpdateAccountParams, type UpdateAccountViewerParams, type UpdateAnchorParams, type UpdateAnchorStatusParams, type UpdateAudioModerationSettingParams, type UpdateAudioModerationSettingsParams, type UpdateAuthParams, type UpdateBannedUserParams, type UpdateBannedUserResponse, type UpdateBannedViewerParams, type UpdateBannedViewerResponse, type UpdateByRoleParams, type UpdateCallbackParams, type UpdateCardPushParams, type UpdateCategoryNameParams, type UpdateCategoryNameResponse, type UpdateCategoryRankParams, type UpdateCategoryRankResponse, type UpdateChannelParams, type UpdateChannelProductParams, type UpdateChannelRequest, type UpdateChannelSubtitleParams, type UpdateChannelTemplateParams, type UpdateChatEnabledParams, type UpdateChildAccountParams, type UpdateCouponParams, type UpdateCouponsStatusBatchParams, type UpdateDecorateParams, type UpdateDistributeBatchParams, type UpdateDonateParams, type UpdateDonateTemplateParams, type UpdateGlobalFooterParams, type UpdateGlobalSwitchParams, type UpdateGroupUserPackageParams, type UpdateInviteSaleParams, type UpdateLabelParams, type UpdateLotteryActivityParams, type UpdateMarqueeTemplateParams, type UpdateMasterSwitchParams, type UpdatePageSettingParams, type UpdatePlaybackSettingParams, type UpdateProductParams, type UpdateProductSettingParams, type UpdateProductTagParams$1 as UpdateProductTagParams, type UpdatePvShowEnableParams, type UpdateRobotSettingParams, type UpdateRoleConfigTemplateParams, type UpdateRoleParams, type UpdateSessionParams, type UpdateShareParams, type UpdateSkinParams, type UpdateSubtitleParams, type UpdateSwitchParams, type UpdateTaskRewardParams, type UpdateVideoModerationSettingParams, type UpdateVideoModerationSettingsParams, type UpdateViewerLabelParams, type UpdateViewerRecordParams, type UpdateWhiteListParams, type UploadDocRequest, type UploadDocResponse, type UploadOptions, type UploadProgress, type UploadVideoProducePptParams, type UploadVideoProducePptResponse, type UserChannelBasicListParams, type UserChannelBasicListResponse, type CreateProductTagParams as UserCreateProductTagParams, type CreateProductTagResponse as UserCreateProductTagResponse, type DeleteProductTagParams as UserDeleteProductTagParams, type MicDurationResponse as UserMicDurationResponse, type UserPaginatedResponse, type UserPaginationParams, type UserPlaybackListParams, type UserPlaybackListResponse, type ProductTag as UserProductTag, type UpdateProductTagParams as UserUpdateProductTagParams, type ChannelDetail as V4ChannelDetail, type SubtitleInfo as V4ChannelSubtitleInfo, type V4PaginatedResponse, type V4PaginationParams, VERSION, type ValidationConstraints, type VersionConfig, type VideoModerationResultItem, type VideoModerationSetting, type VideoModerationSettings, type VideoModerationStrategy, type VideoProducePpt, VideoProduceStatus, type VideoProduceTask, type ViewerLabel, type ViewerLogoutParams, type ViewerLotteryWinParams, type ViewerLotteryWinResponse, type ViewerRecord, type ViewerSource, ViewlogItem, type WatchConditionResponse, type WatchFeedbackItem, type WatchFeedbackListParams, type WatchFeedbackListResponse, type WatchLogDetailResponse, type WatchLogItem, type WatchType, type WatermarkFontSize, type AuthSetting as WebAuthSetting, type InfoField as WebInfoField, type WeixinBookingStats, type WeixinBookingStatsParams, type WhiteListItem, type WinnerViewerInfo, type YNEnabled, type YNFlag$1 as YNFlag, type cleanChatParams, collectAll, createSignature, type delChatParams, generateSignature, generateTimestamp, getEnvironmentInfo, getErrorCodeCategory, getErrorMessage, getErrorMessageByCode, type getHistoryPageParams, isBrowser, isNode, isPolyVAPIError, isPolyVError, isPolyVErrorCode, isPolyVValidationError, isStartDateBeforeEndDate, isValidDateFormat, isWebWorker, paginate, type sendAdminMsgParams, sortParams, validateDateRange };
|
|
20567
|
+
export { type AccountViewerSettings, type AddAccountParams, type AddBadwordsParams, type AddBadwordsResponse, type AddBannedIpParams, type AddBannedIpResponse, type AddChannelLabelRefsParams, type AddChannelProductParams, type AddChannelProductResponse, type AddCustomFieldParams, type AddCustomFieldResponse, type AddCustomFieldValueParams, type AddInviteSaleParams, type AddInviteSaleResponse, type AddRobotModel, type AddViewerLabelParams, type AddWhiteListParams, type AllocateLogType, type AllocateOrigin, type AllocationLogItem, type AnchorDetail, type AnchorItem, type AnchorRelationItem, type AntiRecordModelType, type AntiRecordSettingsParams, type AntiRecordSettingsResponse, type AntiRecordShowMode, type AntiRecordType, type ApiErrorDetail, type ApiErrorResponse, type ApiResponse, type ApiResponseStatus, type ApiSuccessResponse, type ApiVersion, type ArrayElement, type AudioModerationRecordItem, type AudioModerationSetting, type AudioModerationSettings, type AudioModerationStrategy, type AuthConfig, type AuthSetting$1 as AuthSetting, type AuthType, type BaseCallbackPayload, type BasicCreateChannelParams, type BatchCheckinItem, type BatchCheckinParams, type BatchCreateChannelsParams, type BatchCreateChannelsResponse, type BatchCreatePopularizationParams, type BatchCreateVideoProducesItem, type BatchCreateVideoProducesParams, type BatchCreateVideoProducesResponse, type BatchDeleteRobotsParams, type BatchPublishSubtitleParams, type BatchSaveRobotsParams, type BatchSaveRobotsResponse, type BatchUpdateOrderStatusParams, type BillUseDetailItem, type BillingDailyItem, type BlacklistAddParams, type BlacklistDeleteParams, type BlacklistItem, type BlacklistPageParams, type BroadcastType, type BrowsersSummary, type BrowsersSummaryParams, type Bulletin, type CallbackOriginType, type CallbackPayload, type CallbackSettings, type CancelCardPushParams, type CardPushItem, type Category, type ChannelBasicInfo, type ChannelBasicListItem, type ChannelDetail$2 as ChannelDetail, type ChannelDetailListItem, type ChannelDetailParams, type ChannelDetailResponse, type ChannelIdParam, type ChannelModel, type ChannelScene$1 as ChannelScene, ChannelService, type ChannelSimpleListItem, type ChannelStreamType, type ChannelsParams, type ChannelsResponse, type ChatHistoryPageResponse, type ChatMessage, type ChildAccount, type ChildAccountRole, type ChildAccountStatus, type CleanNoticesParams, type ContentGroupItem, type ContentGroupType, type ContentGroupTypeExtended, type Coupon, type CouponRule, type CouponViewer, type CreateAnchorParams, type CreateCardPushParams, type CreateCardPushResponse, type CreateCategoryParams, type CreateCategoryResponse, type CreateChannelParams, type CreateChannelRequest, type CreateChannelResponse, type CreateChildAccountParams, type CreateCouponParams, type CreateDistributeBatchParams, type CreateGroupUserParams, type CreateGroupUserResponse, type CreateLabelParams, type CreateLabelResponse, type CreateLotteryActivityParams, type CreateLotteryActivityResponse, type CreateMrChannelParams, type CreateMrChannelResponse, type CreateOrganizationParams, type CreateOrganizationResponse, type CreateProductParams, type CreateProductResponse, type CreateProductTagParams$1 as CreateProductTagParams, type CreateProductTagResponse$1 as CreateProductTagResponse, type CreateRoleParams, type CreateSessionParams, type CreateSessionResponse, type CreateTaskRewardParams, type CreateTaskRewardResponse, type CreateViewerLabelParams, type CreateViewerLabelResponse, type CreateViewerNameGroupParams, type CreateViewerRecordParams, type CreateWaitLotteryParams, type CreateWaitLotteryResponse, type CryptoSource, type CustomField, type DailyViewStatistics, type DecorateSettings, type DeepPartial, type DeleteAccountsParams, type DeleteCardPushParams, type DeleteCategoryParams, type DeleteCategoryResponse, type DeleteChannelBannedParams, type DeleteChannelBannedResponse, type DeleteChannelProductParams, type DeleteChildAccountsParams, type DeleteCouponsBatchParams, type DeleteDistributeBatchParams, type DeleteLabelParams, type DeleteLotteryActivityParams, type DeleteMaterialsParams, type DeleteMaterialsResult, type DeleteOrganizationParams, type DeleteProductParams, type DeleteProductTagParams$1 as DeleteProductTagParams, type DeleteSessionParams, type DeleteTaskRewardParams, type DeleteUserBadwordParams, type DeleteUserBadwordResponse, type DeleteVideoProduceParams, type DeleteViewerLabelParams, type DeleteViewerLabelRefParams, type DeleteViewerRecordParams, type DeleteWhiteListParams, type DigitalHuman, type DigitalHumanInfo, type DigitalHumanOrganization, type DirectAuthViewerParams, type DiskVideoScriptDeleteParams, type DiskVideoScriptInfo, type DiskVideoScriptQueryParams, type DiskVideoScriptUploadParams, type DiskVideoScriptUploadResponse, type DistributeItem, type DistributeListResponse, type DistributeStatistic, type DocConvertStatusItem, type DocConvertType, type DocListResponse, type DocModel, type DocStatus, type DocType, type DonateSettings, type DonateTemplate, type DoubleTeacherType, ERROR_CATEGORIES, ERROR_MESSAGES, type EnvironmentInfo, type ErrorCategory, type ErrorCategoryName, ExportSessionStatsParams, ExportSessionStatsResponse, type ExternalViewerItem, type FollowViewer, type ForbidChannelKickUsersBody, type ForbidChannelKickUsersParams, type ForbidChannelKickUsersResponse, type ForbidChannelUnkickUsersBody, type ForbidChannelUnkickUsersParams, type ForbidChannelUnkickUsersResponse, type ForbidKickUsersBody, type ForbidKickUsersGlobalResponse, type ForbidKickUsersResponse, type ForbidUnkickUsersGlobalResponse, type ForbidUser, type FullReduceRule, type GeoSummary, type GeoSummaryParams, type GetAccountViewerParams, type GetBillUseDetailListParams, type GetBillUseDetailListResponse, type GetByRoleParams, type GetBySaleParams, type GetCardPushParams, type GetCategoryListResponse, type GetChannelBannedListParams, type GetChannelBannedListResponse, type GetChannelBannedUserListParams, type GetChannelBannedUserListResponse, type GetChannelKickedUserListParams, type GetChannelKickedUserListResponse, type GetChildAccountParams, type GetDailyViewStatisticsParams, type GetDailyViewStatisticsResponse, type GetDecorateParams, type GetDistributeStatisticParams, type GetDocListRequest, type GetDonateParams, type GetForbidUserListParams, type GetForbidUserListResponse, type GetIncomeDetailParams, type GetIncomeDetailResponse, type GetInviteRankParams, type GetInviteStatsParams, type GetLiveSessionParams, type GetLotteryActivityParams, type GetMicDurationParams, type GetProductOrderParams, type GetProductSettingParams, type GetProductTagParams, type GetRelevanceParams, type GetRobotSettingParams, type GetRobotStatsParams, type GetRoleResponse, type GetSessionParams, type GetSessionStatsSummaryListParams, type GetSessionStatsSummaryListResponse, type GetShareParams, type GetSimpleChannelListParams, type GetSimpleChannelListResponse, type GetSubtitleParams, type GetTaskRewardParams, type GetTaskRewardStatsParams, type GetUserDurationsParams, type GetUserDurationsResponse, type GetUserInfoResponse, type GetVideoProduceParams, type GetVideoProducePptParams, type GetViewerDetailParams, type GetViewerRecordParams, type GetViewerUnionDetailParams, GetViewlogParams, GetViewlogResponse, type GetWatchConditionParams, type GetWatchLogDetailParams, type GetWatchLogListParams, type GetWatchLogListResponse, type GetWhiteListParams, type GetWhiteListResponse, type GiftItem, type GiftPageParams, type GlobalFooterSettings, type GlobalSwitchSettings, type GroupAddParams, type GroupAllocateLogContent, type GroupDeleteParams, type GroupInfo, type GroupListParams, type GroupPaginatedResponse, type GroupPaginationParams, type GroupResponse, type GroupUpdateParams, type GroupUserPackage, type GroupViewerAddParams, type GroupViewerDeleteParams, type GroupViewerInfo, type GroupViewerListParams, type HeadAdvertParams, type HeadAdvertType, HttpMethod, type IllegalNotifySettings, type ImageFrequency, type ImportExternalViewerParams, type InfoField$1 as InfoField, type InfoFieldType, type InteractionCallbackPayload, type InteractionEventDeleteParams, type InteractionEventSaveParams, type InteractionType, type InviteRankItem, type InviteSale, type InviteStats, type InviterCreateParams, type JsonArray, type JsonObject, type JsonValue, type KickedUser, type Label, type LanguageInfo, type LikeItem, type LikePageParams, type ListAllocateLogParams, type ListAllocateLogResponse, type ListAllocationLogsParams, type ListAllocationLogsResponse, type ListAnchorRelationsParams, type ListAnchorsParams, type ListAnchorsResponse, type ListAudioModerationRecordsParams, type ListAudioModerationRecordsResponse, type ListBillingDailyParams, type ListBillingDailyResponse, type ListBulletinsParams, type ListBulletinsResponse, type ListChannelBasicParams, type ListChildAccountsParams, type ListChildAccountsResponse, type ListContentGroupsParams, type ListCustomFieldsResponse, type ListDigitalHumansParams, type ListDigitalHumansResponse, type ListDistributeParams, type ListFollowViewersParams, type ListFollowViewersResponse, type ListGroupUserPackagesParams, type ListGroupUserPackagesResponse, type ListInviteSalesResponse, type ListLabelsResponse, type ListLotteryActivitiesParams, type ListMaterialCategoriesParams, type ListMaterialCategoriesResponse, type ListMaterialsParams, type ListMaterialsResponse, type ListOrganizationsParams, type ListOrganizationsResponse, type ListProductOrdersParams, type ListProductOrdersResponse, type ListProductTagsParams, type ListProductTagsResponse, type ListProductsParams, type ListProductsResponse, type ListQaParams, type ListQaResponse, type ListRobotsParams, type ListRobotsResponse, type ListRolesParams, type ListRolesResponse, type ListSessionsParams, type ListSessionsResponse, type ListVideoModerationResultsParams, type ListVideoModerationResultsResponse, type ListVideoProducePptsParams, type ListVideoProducePptsResponse, type ListVideoProducesParams, type ListVideoProducesResponse, type ListViewerLabelsResponse, type ListViewerRecordsParams, type ListViewerRecordsResponse, type LiveSessionInfo, type LiveStatusCallbackPayload, type LiveStatusItem, type LiveStatusType, type LiveSummary, type LiveSummaryParams, type LogoParams, type LogoPosition, type LotteryActivity, type LotteryListParams, type LotteryStatistics, MAX_DATE_RANGE_DAYS, type MarqueeTemplate, type MarqueeUrlParams, type Material, type MaterialCategory, type MaterialExtData, type MaterialInfo, type MaterialPaginatedResponse, type MaterialPaginationParams, type MemberStatusCallbackPayload, type MemberStatusType, type MicDurationParams, type MicDurationResponse$1 as MicDurationResponse, type ModerationLabel, type ModerationResultType, type MonitorStreamInfo, type MrConcurrencyDetailResponse, type Mutable, type NewScene, type NonNullable, type OptionalKeys, type Organization, type PageMRecordParams, type PageMRecordResponse, type PageSetting, type PaginatedForbidUserData, type PaginationOptions, type PaginationResponse, type PauseRobotParams, type Permission, type PlaybackCallbackPayload, type PlaybackItem, type PlaybackListParams, type PlaybackListResponse, type PlaybackSetting, type PlaybackVideoInfo, PolyVAPIError, type PolyVAPIErrorOptions, type PolyVAPIErrorResponse, PolyVClient, type PolyVClientConfig, PolyVError, PolyVErrorCode, type PolyVErrorOptions, PolyVValidationError, type PopularizationInfo, type PopularizationItem, type PopularizationListParams, PptStatus, type Primitive, type PrivacyParam, type Product, type ProductLinkType, type ProductOrder, type ProductPriceType, type ProductSetting, type ProductStatsItem, type ProductStatsPageParams, type ProductStatus, type ProductTag$1 as ProductTag, type ProductType, type PushCardParams, type PvShowEnableSettings, type Qa, type QaAnswer, type QueryPlaybackVideoInfoParams, type QueryWinnerViewerParams, type ReceiveListParams, type ReceiveListResponse, type RecordCallbackPayload, type RecordedFileItem, type RemoveInviteSaleParams, type RequestOptions, type RequireKeys, type ResolvedClientConfig, type Robot, type RobotSetting, type RobotStats, type Role, type RoleConfig, type RoleConfigTemplate, type RoleDetail, type RolePermission, type SaveRobotItem, type SearchCouponViewersParams, type SearchCouponViewersResponse, type SearchCouponsParams, type SearchCouponsResponse, type SendAdminMsgResponse, type SendCustomMessageEncodeParams, type SendCustomMessageParams, type SendSmsParams, type SessionInfo, type SessionRelevanceInfo, type SessionStatsSummary, type SetAuthTypeParams, type SetConcurrencesParams, type SetFlowParams, type SetLiveDurationsParams, type SetOrganizationsItem, type SetOrganizationsParams, type SetPlaybackCallbackParams, type SetPlaybackCallbackResponse, type SetPullBitrateParams, type SetRecordCallbackParams, type SetRecordCallbackResponse, type SetSpaceParams, type SetStreamCallbackParams, type SetStreamCallbackResponse, type SetUserChildrenLoginTokenParams, type SetUserChildrenLoginTokenResponse, type SetUserLoginTokenParams, type SetUserLoginTokenResponse, type SetWatchConditionParams, type SexType, type ShareSettings, type SignParams, type SignatureConfig, type SignatureInput, SignatureMethod, type SignatureOutput, type SignatureResult, type SortChannelProductParams, type SortOptions, type SsoConfigParams, type SsoConfigResponse, type SsoLoginParams, type SsoLoginResponse, type StatisticsCallbackPayload, type StopAdvertParams, type StopTaskRewardParams, type SubAuthType, type SubmitAcceptInfoParams, type SubtitleInfo$1 as SubtitleInfo, type SwitchGetResponse, type SwitchUpdateParams, type SwitchUpdateResponse, type TaskReward, type TaskRewardPageParams, type TaskRewardStats, type TaskRewardViewerDetail, type Template, type TtsVoice, type TtsVoiceInfo, TtsVoiceTag, type UnconditionalRule, type UpdateAccountParams, type UpdateAccountViewerParams, type UpdateAnchorParams, type UpdateAnchorStatusParams, type UpdateAudioModerationSettingParams, type UpdateAudioModerationSettingsParams, type UpdateAuthParams, type UpdateBannedUserParams, type UpdateBannedUserResponse, type UpdateBannedViewerParams, type UpdateBannedViewerResponse, type UpdateByRoleParams, type UpdateCallbackParams, type UpdateCardPushParams, type UpdateCategoryNameParams, type UpdateCategoryNameResponse, type UpdateCategoryRankParams, type UpdateCategoryRankResponse, type UpdateChannelConfigParams, type UpdateChannelParams, type UpdateChannelProductEnabledParams, type UpdateChannelProductParams, type UpdateChannelRequest, type UpdateChannelSubtitleParams, type UpdateChannelTemplateParams, type UpdateChatEnabledParams, type UpdateChildAccountParams, type UpdateCouponParams, type UpdateCouponsStatusBatchParams, type UpdateDecorateParams, type UpdateDistributeBatchParams, type UpdateDonateParams, type UpdateDonateTemplateParams, type UpdateGlobalFooterParams, type UpdateGlobalSwitchParams, type UpdateGroupUserPackageParams, type UpdateInviteSaleParams, type UpdateLabelParams, type UpdateLotteryActivityParams, type UpdateMarqueeTemplateParams, type UpdateMasterSwitchParams, type UpdatePageSettingParams, type UpdatePlaybackSettingParams, type UpdateProductParams, type UpdateProductSettingParams, type UpdateProductTagParams$1 as UpdateProductTagParams, type UpdatePvShowEnableParams, type UpdateRobotSettingParams, type UpdateRoleConfigTemplateParams, type UpdateRoleParams, type UpdateSessionParams, type UpdateShareParams, type UpdateSkinParams, type UpdateSubtitleParams, type UpdateSwitchParams, type UpdateTaskRewardParams, type UpdateVideoModerationSettingParams, type UpdateVideoModerationSettingsParams, type UpdateViewerLabelParams, type UpdateViewerRecordParams, type UpdateWhiteListParams, type UploadDocRequest, type UploadDocResponse, type UploadOptions, type UploadProgress, type UploadVideoProducePptParams, type UploadVideoProducePptResponse, type UserChannelBasicListParams, type UserChannelBasicListResponse, type CreateProductTagParams as UserCreateProductTagParams, type CreateProductTagResponse as UserCreateProductTagResponse, type DeleteProductTagParams as UserDeleteProductTagParams, type MicDurationResponse as UserMicDurationResponse, type UserPaginatedResponse, type UserPaginationParams, type UserPlaybackListParams, type UserPlaybackListResponse, type ProductTag as UserProductTag, type UpdateProductTagParams as UserUpdateProductTagParams, type ChannelDetail as V4ChannelDetail, type SubtitleInfo as V4ChannelSubtitleInfo, type V4PaginatedResponse, type V4PaginationParams, VERSION, type ValidationConstraints, type VersionConfig, type VideoModerationResultItem, type VideoModerationSetting, type VideoModerationSettings, type VideoModerationStrategy, type VideoProducePpt, VideoProduceStatus, type VideoProduceTask, type ViewerLabel, type ViewerLogoutParams, type ViewerLotteryWinParams, type ViewerLotteryWinResponse, type ViewerRecord, type ViewerSource, ViewlogItem, type WatchConditionResponse, type WatchFeedbackItem, type WatchFeedbackListParams, type WatchFeedbackListResponse, type WatchLogDetailResponse, type WatchLogItem, type WatchType, type WatermarkFontSize, type AuthSetting as WebAuthSetting, type InfoField as WebInfoField, type WeixinBookingStats, type WeixinBookingStatsParams, type WhiteListItem, type WinnerViewerInfo, type YNEnabled, type YNFlag$1 as YNFlag, type cleanChatParams, collectAll, createSignature, type delChatParams, generateSignature, generateTimestamp, getEnvironmentInfo, getErrorCodeCategory, getErrorMessage, getErrorMessageByCode, type getHistoryPageParams, isBrowser, isNode, isPolyVAPIError, isPolyVError, isPolyVErrorCode, isPolyVValidationError, isStartDateBeforeEndDate, isValidDateFormat, isWebWorker, paginate, type sendAdminMsgParams, sortParams, validateDateRange };
|
package/dist/index.js
CHANGED
|
@@ -4349,6 +4349,74 @@ var ChannelService = class {
|
|
|
4349
4349
|
);
|
|
4350
4350
|
return response;
|
|
4351
4351
|
}
|
|
4352
|
+
/**
|
|
4353
|
+
* Update channel product library enabled status
|
|
4354
|
+
*
|
|
4355
|
+
* Toggles the channel product library on or off.
|
|
4356
|
+
* All params (channelId, enabled, appId, timestamp) participate in signature.
|
|
4357
|
+
*
|
|
4358
|
+
* @param params - Parameters including channelId and enabled (Y/N)
|
|
4359
|
+
* @returns true if update was successful
|
|
4360
|
+
* @throws PolyVValidationError if required parameters are missing
|
|
4361
|
+
*
|
|
4362
|
+
* @example
|
|
4363
|
+
* ```typescript
|
|
4364
|
+
* await channelService.updateChannelProductEnabled({
|
|
4365
|
+
* channelId: 'ch123456',
|
|
4366
|
+
* enabled: 'Y',
|
|
4367
|
+
* });
|
|
4368
|
+
* ```
|
|
4369
|
+
*/
|
|
4370
|
+
async updateChannelProductEnabled(params) {
|
|
4371
|
+
if (!params.channelId || params.channelId.trim() === "") {
|
|
4372
|
+
throw PolyVValidationError.required("channelId");
|
|
4373
|
+
}
|
|
4374
|
+
if (!params.enabled || params.enabled !== "Y" && params.enabled !== "N") {
|
|
4375
|
+
throw PolyVValidationError.required("enabled");
|
|
4376
|
+
}
|
|
4377
|
+
const response = await this.client.httpClient.post(
|
|
4378
|
+
"/live/v3/channel/product/update-enabled",
|
|
4379
|
+
null,
|
|
4380
|
+
{ params: { channelId: params.channelId, enabled: params.enabled } }
|
|
4381
|
+
);
|
|
4382
|
+
return response;
|
|
4383
|
+
}
|
|
4384
|
+
/**
|
|
4385
|
+
* Update channel configuration
|
|
4386
|
+
*
|
|
4387
|
+
* Updates a channel config key-value pair via /v3/channel/config/update.
|
|
4388
|
+
* Common keys include: couponEnabled, productEnabled, etc.
|
|
4389
|
+
*
|
|
4390
|
+
* @param params - Parameters including channelId, key, and value
|
|
4391
|
+
* @returns true if update was successful
|
|
4392
|
+
* @throws PolyVValidationError if required parameters are missing
|
|
4393
|
+
*
|
|
4394
|
+
* @example
|
|
4395
|
+
* ```typescript
|
|
4396
|
+
* await channelService.updateChannelConfig({
|
|
4397
|
+
* channelId: 'ch123456',
|
|
4398
|
+
* key: 'couponEnabled',
|
|
4399
|
+
* value: 'Y',
|
|
4400
|
+
* });
|
|
4401
|
+
* ```
|
|
4402
|
+
*/
|
|
4403
|
+
async updateChannelConfig(params) {
|
|
4404
|
+
if (!params.channelId || params.channelId.trim() === "") {
|
|
4405
|
+
throw PolyVValidationError.required("channelId");
|
|
4406
|
+
}
|
|
4407
|
+
if (!params.key || params.key.trim() === "") {
|
|
4408
|
+
throw PolyVValidationError.required("key");
|
|
4409
|
+
}
|
|
4410
|
+
if (!params.value || params.value.trim() === "") {
|
|
4411
|
+
throw PolyVValidationError.required("value");
|
|
4412
|
+
}
|
|
4413
|
+
const response = await this.client.httpClient.post(
|
|
4414
|
+
"/live/v3/channel/config/update",
|
|
4415
|
+
null,
|
|
4416
|
+
{ params: { channelId: params.channelId, key: params.key, value: params.value } }
|
|
4417
|
+
);
|
|
4418
|
+
return response;
|
|
4419
|
+
}
|
|
4352
4420
|
};
|
|
4353
4421
|
|
|
4354
4422
|
// src/services/chat.service.ts
|
|
@@ -5285,6 +5353,9 @@ var LiveInteractionService = class {
|
|
|
5285
5353
|
* ```
|
|
5286
5354
|
*/
|
|
5287
5355
|
async getCheckinList(params) {
|
|
5356
|
+
if (!params.channelId) {
|
|
5357
|
+
throw new Error("channelId is required");
|
|
5358
|
+
}
|
|
5288
5359
|
const response = await this.client.httpClient.get(
|
|
5289
5360
|
"/live/v2/chat/getCheckinList",
|
|
5290
5361
|
{ params }
|