UNPKG

polyv-live-cli

Version:

CLI tool for managing PolyV live streaming services.

68 lines 3.13 kB
import { BaseHandler } from './base.handler'; import { DocumentServiceConfig, DocumentListOptions, DocumentUploadOptions, DocumentDeleteOptions, DocumentStatusOptions, DocumentDisplayItem } from '../types/document'; import { AuthConfig } from '../types/auth'; export interface IDocumentService { getDocumentList(options: DocumentListOptions): Promise<{ contents: DocumentDisplayItem[]; pageNumber: number; pageSize: number; totalItems: number; totalPages: number; }>; uploadDocument(channelId: string, options: { url: string; type?: 'common' | 'animate'; docName?: string; callbackUrl?: string; }): Promise<{ fileId: string; status: string; type: string; }>; deleteDocument(channelId: string, fileId: string, type: 'old' | 'new'): Promise<boolean>; getDocumentStatus(channelId: string, fileId: string): Promise<{ fileId: string; convertStatus: string; type: string; totalPage: number; imageCount: number; htmlUrl?: string; }[]>; updateTeacherDocRelation(teacherId: string, fileIds: string, operation: 1 | 2): Promise<boolean>; getChannelMultimediaResourceList(channelId: string, options?: any): Promise<any>; getChannelMultimediaResourceDetail(channelId: string, options?: any): Promise<any>; linkChannelMultimediaResource(channelId: string, vids: string): Promise<boolean>; unlinkChannelMultimediaResource(channelId: string, vids: string): Promise<boolean>; getUserMultimediaResourceDetail(vids: string): Promise<any>; deleteUserMultimediaResource(vids: string): Promise<boolean>; } export declare class DocumentHandler extends BaseHandler { private readonly documentService; constructor(authConfig: AuthConfig, serviceConfig: DocumentServiceConfig, documentService?: IDocumentService); listDocuments(options: DocumentListOptions): Promise<void>; uploadDocument(options: DocumentUploadOptions): Promise<void>; deleteDocument(options: DocumentDeleteOptions): Promise<void>; getDocumentStatus(options: DocumentStatusOptions): Promise<void>; updateTeacherDocRelation(options: any): Promise<void>; listChannelMultimediaResourceVids(options: any): Promise<void>; listChannelMultimediaResourceDetails(options: any): Promise<void>; linkChannelMultimediaResource(options: any): Promise<void>; unlinkChannelMultimediaResource(options: any): Promise<void>; getUserMultimediaResourceDetail(options: any): Promise<void>; deleteUserMultimediaResource(options: any): Promise<void>; private displayDocumentList; private normalizeStringList; private paginationOptions; private displayResult; private displayDocumentTable; private displayUploadResult; private displayUploadResultTable; private displayDeleteResult; private displayDeleteResultTable; private displayStatusResult; private displayStatusTable; private translateStatus; private translateConvertStatus; private formatTimestamp; } //# sourceMappingURL=document.handler.d.ts.map