import { AxiosInstance, AxiosRequestConfig } from "axios"; import { TiktokShopApp } from "../interfaces"; export default class TiktokNewEraService { static readonly TIKTOK_API_ENDPOINT: string; static readonly SIGN_EXCLUDE_KEYS: string[]; static readonly CURRENT_TIKTOK_API_VERSION = "202309"; private app; private tiktokShopAxiosInstance; constructor({ app }: { app: TiktokShopApp; }); private handleTiktokResponse; getTiktokShopAxiosInstance(): AxiosInstance; getCurrentTimestamp(): number; getRequestParams(params?: Record): { app_key: string; shop_cipher: string; timestamp: number; }; buildParamsWithSign(endpoint: string, requestOption: AxiosRequestConfig): AxiosRequestConfig; buildCompletedRequestData(requestOption: AxiosRequestConfig): { url?: string | undefined; method?: ((string & {}) | import("axios").Method) | undefined; baseURL?: string | undefined; allowAbsoluteUrls?: boolean | undefined; transformRequest?: import("axios").AxiosRequestTransformer | import("axios").AxiosRequestTransformer[] | undefined; transformResponse?: import("axios").AxiosResponseTransformer | import("axios").AxiosResponseTransformer[] | undefined; headers?: import("axios").AxiosHeaders | (Partial & Partial<{ delete: import("axios").AxiosHeaders; get: import("axios").AxiosHeaders; head: import("axios").AxiosHeaders; post: import("axios").AxiosHeaders; put: import("axios").AxiosHeaders; patch: import("axios").AxiosHeaders; options: import("axios").AxiosHeaders; purge: import("axios").AxiosHeaders; link: import("axios").AxiosHeaders; unlink: import("axios").AxiosHeaders; query: import("axios").AxiosHeaders; } & { common: import("axios").AxiosHeaders; }>) | undefined; params?: any; paramsSerializer?: import("axios").ParamsSerializerOptions | import("axios").CustomParamsSerializer | undefined; data?: any; timeout?: number | undefined; timeoutErrorMessage?: string | undefined; withCredentials?: boolean | undefined; adapter?: (import("axios").AxiosAdapter | ((string & {}) | "xhr" | "http" | "fetch")) | (import("axios").AxiosAdapter | ((string & {}) | "xhr" | "http" | "fetch"))[] | undefined; auth?: import("axios").AxiosBasicCredentials | undefined; responseType?: import("axios").ResponseType | undefined; responseEncoding?: ((string & {}) | import("axios").responseEncoding) | undefined; xsrfCookieName?: string | undefined; xsrfHeaderName?: string | undefined; onUploadProgress?: ((progressEvent: import("axios").AxiosProgressEvent) => void) | undefined; onDownloadProgress?: ((progressEvent: import("axios").AxiosProgressEvent) => void) | undefined; maxContentLength?: number | undefined; validateStatus?: ((status: number) => boolean) | null | undefined; maxBodyLength?: number | undefined; maxRedirects?: number | undefined; maxRate?: number | [number, number] | undefined; beforeRedirect?: ((options: Record, responseDetails: { headers: Record; statusCode: import("axios").HttpStatusCode; }, requestDetails: { headers: Record; url: string; method: string; }) => void) | undefined; socketPath?: string | null | undefined; allowedSocketPaths?: string | string[] | null | undefined; transport?: any; httpAgent?: any; httpsAgent?: any; proxy?: false | import("axios").AxiosProxyConfig | undefined; cancelToken?: import("axios").CancelToken | undefined; decompress?: boolean | undefined; transitional?: import("axios").TransitionalOptions | undefined; signal?: import("axios").GenericAbortSignal | undefined; insecureHTTPParser?: boolean | undefined; env?: { FormData?: (new (...args: any[]) => object) | undefined; fetch?: ((input: string | URL | Request, init?: RequestInit | undefined) => Promise) | undefined; Request?: (new (input: string | URL | Request, init?: RequestInit | undefined) => Request) | undefined; Response?: (new (body?: string | ArrayBuffer | ArrayBufferView | Blob | FormData | URLSearchParams | null | undefined, init?: ResponseInit | undefined) => Response) | undefined; } | undefined; formSerializer?: import("axios").FormSerializerOptions | undefined; family?: import("axios").AddressFamily; lookup?: ((hostname: string, options: object, cb: (err: Error | null, address: import("axios").LookupAddress | import("axios").LookupAddress[], family?: import("axios").AddressFamily) => void) => void) | undefined; withXSRFToken?: boolean | ((config: import("axios").InternalAxiosRequestConfig) => boolean | undefined) | undefined; parseReviver?: ((this: any, key: string, value: any, context?: { source?: string | undefined; } | undefined) => any) | undefined; fetchOptions?: Record | undefined; httpVersion?: 2 | 1 | undefined; http2Options?: (Record & { sessionTimeout?: number | undefined; }) | undefined; formDataHeaderPolicy?: "legacy" | "content-only" | undefined; redact?: string[] | undefined; sensitiveHeaders?: string[] | undefined; }; execute(requestOption: AxiosRequestConfig): Promise>; /** * Note: prefix and suffix must start with '/' */ static buildRequestUrl(prefix: string, suffix: string, version?: string): string; static generateSign: (endpoint: string, requestOption: AxiosRequestConfig, app_secret: string) => string; } /** * Interfaces definition */ export interface TiktokResponse { code: number; message: string; request_id: string; data: T; }