mirror of
https://github.com/FranP-code/Baileys.git
synced 2025-10-13 00:32:22 +00:00
add media cache option
This commit is contained in:
@@ -135,6 +135,8 @@ export type WAMediaUploadFunction = (readStream: ReadStream, opts: { fileEncSha2
|
||||
export type MediaGenerationOptions = {
|
||||
logger?: Logger
|
||||
upload: WAMediaUploadFunction
|
||||
/** cache media so it does not have to be uploaded again */
|
||||
mediaCache?: (url: string) => Promise<WAGenericMediaMessage> | WAGenericMediaMessage
|
||||
}
|
||||
export type MessageContentGenerationOptions = MediaGenerationOptions & {
|
||||
getUrlInfo?: (text: string) => Promise<WAUrlInfo>
|
||||
|
||||
Reference in New Issue
Block a user