"n" : "1"
- 1 in strings maybe that's an issue,
missing."n": "1" "model": "text-davinci-003",
Unexpected end of JSON input
β― curl --location 'http://api.portkey.ai/v1/proxy/completions' \ --header 'x-portkey-api-key: <PORTKEY_API_KEY>' \ --header 'x-portkey-mode: proxy openai' \ --header 'Authorization: Bearer <OPENAI_API_KEY>' \ --header 'Content-Type: application/json' \ --data '{ "n": "1", "model": "text-davinci-003", "prompt": "Top 20 tallest buildings in the world" }' # Response {"ok":false,"message":"Unexpected end of JSON input"}
proxy/chat/completions
and passed body similar to open ai
docs. It didn't work.curl --location --request POST 'http://api.portkey.ai/v1/proxy/chat/completions' \ --header 'x-portkey-api-key: xxxxx=' \ --header 'x-portkey-mode: proxy openai' \ --header 'Authorization: sk-xxxxx' \ --header 'Content-Type: application/json' \ --data-raw '{ "model": "gpt-3.5-turbo", "messages": [ { "role": "system", "content": "You are a helpful assistant." }, { "role": "user", "content": "Hello!" } ] }'