chore: pass axios options to downloading remote media

This commit is contained in:
Adhiraj Singh
2023-02-18 13:03:47 +05:30
parent f013b61e35
commit ca24608dc8
5 changed files with 24 additions and 7 deletions

View File

@@ -1,3 +1,4 @@
import { AxiosRequestConfig } from 'axios'
import type NodeCache from 'node-cache'
import type { Logger } from 'pino'
import type { Readable } from 'stream'
@@ -204,6 +205,8 @@ export type MediaGenerationOptions = {
mediaCache?: NodeCache
mediaUploadTimeoutMs?: number
options?: AxiosRequestConfig
}
export type MessageContentGenerationOptions = MediaGenerationOptions & {
getUrlInfo?: (text: string) => Promise<WAUrlInfo | undefined>