Spaces:
Runtime error
Runtime error
### login | |
POST http://127.0.0.1:8080/chatgpt/login | |
Content-Type: application/json | |
{ | |
"username": "{{username}}", | |
"password": "{{password}}" | |
} | |
### get conversations | |
GET http://127.0.0.1:8080/chatgpt/conversations | |
Authorization: Bearer {{accessToken}} | |
### create conversation | |
POST http://127.0.0.1:8080/chatgpt/conversation | |
Authorization: Bearer {{accessToken}} | |
Content-Type: application/json | |
Accept: text/event-stream | |
{ | |
"action": "next", | |
"messages": [ | |
{ | |
"id": "{{$random.uuid}}", | |
"author": { | |
"role": "user" | |
}, | |
"content": { | |
"content_type": "text", | |
"parts": [ | |
"hello" | |
] | |
}, | |
"metadata": {} | |
} | |
], | |
"model": "gpt-4", | |
"timezone_offset_min": -480, | |
"history_and_training_disabled": false | |
} | |
> {% | |
response.body.onEachLine((data) => { | |
client.log(data.toString()); | |
}) | |
%} | |
### get models | |
GET http://127.0.0.1:8080/chatgpt/models | |
Authorization: Bearer {{accessToken}} | |
### check account | |
GET http://127.0.0.1:8080/chatgpt/accounts/check | |
Authorization: Bearer {{accessToken}} | |