From 5aa90788c2004fcb0cce8224d684e75e191df816 Mon Sep 17 00:00:00 2001 From: ikechan8370 Date: Wed, 15 May 2024 20:09:18 +0800 Subject: [PATCH] fix: add api3 timeout option --- utils/message.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/utils/message.js b/utils/message.js index 67ed425..1b8c457 100644 --- a/utils/message.js +++ b/utils/message.js @@ -66,7 +66,8 @@ export class OfficialChatGPTClient { referer: 'https://chat.openai.com/chat', library: 'chatgpt-plugin' }, - referrer: 'https://chat.openai.com/chat' + referrer: 'https://chat.openai.com/chat', + timeout: 10000 } logger.info('using api3 reverse proxy: ' + url) let requestLib = url.startsWith('https') ? https : http