API that has been working for weeks, has stop working

I’m calling the API from my c# script using Http client.
This has been working for weeks. Today I tried to send a petition and the API response doesn’t make any sense.

I’m trying on playgrond with exact same parameters and model and receiving the correct answer in matter of 1-2 seconds. From the API, it takes 10+ seconds and the response is completely different (and wrong).

The latency issue has been there since day one, but those wrong api responses not. What is going on?

I’m using temperature 0. In case is relevant, I have tried a bunch of different models (gpt-4.1-nano, gpt-4.0-mini, gpt-4)

You can try using curl, to see if the problem is with the request itself or something specific to your code.

Example using a windows prompt:

set OPENAI_API_KEY=YOUR-API-KEY
curl https://api.openai.com/v1/responses -H "Content-Type: application/json" -H "Authorization: Bearer %OPENAI_API_KEY%" -d "{\"model\":\"gpt-4o\",\"input\":[{\"role\":\"user\",\"content\":[{\"type\":\"input_text\",\"text\":\"hi\"}]}],\"text\":{\"format\":{\"type\":\"text\"}},\"reasoning\":{},\"tools\":[],\"temperature\":1,\"max_output_tokens\":2048,\"top_p\":1,\"store\":true}"

Just tried curl, I’m doing it in two steps.

  1. curl https://api.openai.com/v1/files to upload my file (takes about 1 second).
  2. curl https://api.openai.com/v1/responses to upload prompt to extract information from the previous uploaded file using its Id (takes about 8 seconds).

Seems it’s a little bit faster than Http client, nevertheless, way slower than playground and responses are still different.

Is the response accurate with curl?

You need to consider that the playground is calling the api from a “closer” distance than between you and the api endpoint.