I have tried to create a new thread with curl. But I get a error and I cannot understand what is wrong. I am using curl in windows 10.
curl -H “Content-Type: application/json” -H “Authorization: Bearer myAPIkey” -H “OpenAI-Beta :assistants=v1” -d’{“messages”:[{“role”:“user”,“content”:“Who am I”}]}’
The endpoint address is edited away because links are not allowed.
Error message:
{
“error”: {
“message”: “1 validation error for Request\nbody → 0\n Expecting value: line 1 column 1 (char 0) (type=value_error.jsondecode; msg=Expecting value; doc=‘{messages:[{role:user,content:Who am I}]}’; pos=0; lineno=1; colno=1)”,
“type”: “invalid_request_error”,
“param”: null,
“code”: null
}
}
So what am I doing wrong?