I’m trying to set up the GPT-3 API on Bubble, but keep getting an empty text response in return to my calls.
I’ve added my key to the header and the content-type is set to application/json. I’m passing the following sample JSON (from the docs) via a POST to https://api.openai.com/v1/completions
{
"model": "text-davinci-003",
"prompt": "Say this is a test",
"max_tokens": 7,
"temperature": 0,
"top_p": 1,
"n": 1,
"stream": false,
"logprobs": null,
"stop": "\n"
}
but when I initialize the call this is the response I get with a blank text response
Returned Values:
{
"id": "cmpl-6......YXhL4y",
"object": "text_completion",
"created": 1673992522,
"model": "text-davinci-003",
"choices": [
{
"text": "",
"index": 0,
"logprobs": null,
"finish_reason": "stop"
}
],
"usage": {
"prompt_tokens": 5,
"total_tokens": 5
}
}
Does anyone have any suggestions? I’ve tried reaching out to OpenAI support but I guess they are super backed up.