pop2api / test.py
8e
init
2a81db1
raw
history blame contribute delete
439 Bytes
import requests
url = "http://127.0.0.1:3000/v1/chat/completions"
headers = {
"Authorization": "Bearer none",
"Content-Type": "application/json"
}
data = {
"model": "gpt-4o",
"messages": [
{
"role": "user",
"content": "收到请回复yessss"
}
],
"stream": False
}
response = requests.get(url, headers=headers, json=data)
print(response.status_code)
print(response.json())