UNPKG

@delirius/welcard

Version:

WelCard is a lightweight and futuristic welcome card library designed for WhatsApp Bots.

89 lines (83 loc) 2 kB
/** * TikTok API error response structure. */ interface TikTokApiErrorResponse { /** Creator of the response */ creator: string; /** Status of the response (false in case of error) */ status: false; /** Error message */ msg: string; } /** * TikTok API success response structure. */ interface TikTokAuthor { /** Author's unique ID */ id: string; /** Author's TikTok username */ username: string; /** Author's display nickname */ nickname: string; /** URL to the author's avatar image */ avatar: string; } interface TikTokMusic { /** Music track ID */ id: string; /** Title of the music track */ title: string; /** URL to the music track */ play: string; /** Author of the music track */ author: string; } interface TikTokMeta { /** Video ID */ id: string; /** Video title */ title: string; /** Region code of the video */ region: string; /** URL to the high-definition video */ hd: string; /** Duration of the video in seconds */ duration: number; /** Number of plays/views */ play: number; /** Number of comments */ coment: number; /** Number of shares */ share: number; /** Number of likes */ like: number; /** Number of downloads */ download: number; /** Timestamp of when the video was published */ publish: number; /** URL to the video on TikTok */ url: string; /** Author details */ author: TikTokAuthor; /** Music details */ music: TikTokMusic; } interface TikTokApiSuccessResponse { /** Creator of the response */ creator: string; /** Status code of the response */ status: number; /** Array of video metadata */ meta: TikTokMeta[]; } /** * Union type for success and error responses. */ type TikTokApiResponse = TikTokApiSuccessResponse | TikTokApiErrorResponse; export { SswebResponse, LyricsSearchResponse, LyricsSearchError, LyricsSearchResult, TikTokApiResponse }