Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 2 additions & 14 deletions WebChatGPT/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,21 +13,9 @@


headers = request_headers = {
"Accept": "text/event-stream",
"Accept-Encoding": "gzip, deflate",
"Accept-Language": "en-US,en;q=0.5",
# "Alt-Used": "chat.openai.com",
"Authorization": f"Bearer %(value)s",
"Connection": "keep-alive",
"Content-Type": "application/json",
"Host": "chat.openai.com",
"Origin": "https://chat.openai.com",
"Referer": "https://chat.openai.com/",
"Sec-Fetch-Dest": "empty",
"Sec-Fetch-Mode": "cors",
"Sec-Fetch-Site": "same-origin",
"User-Agent": "Mozilla/5.0 (X11; Linux x86_64; rv:124.0) Gecko/20100101 Firefox/124.0",
"OAI-Language": locale.getlocale()[0].replace("_", "-"),
"User-Agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/120.0.0.0 Safari/537.36",
'Accept': 'application/json, text/plain, */*'
}

response_example = {
Expand Down