Open AI API - Did something recently change?

There is no problem in my application at the moment, but sometimes there may be api-related errors. It may be a temporary issue
 
Since it's works for others, try refreshing or clear your cache and then retry..
 
Thanks for verifying. First I tested in my cefsharp app but it returns "Network response was not ok". Well this is just a BS message so I pasted it in the browser console. 429 To many request. I'm running in an about blank chrome browser and I use this code. Can you guys check if it works for you, please. I promise nothing malicious in the code. ChatGPT generated this for me (Bless ChatGPT).

JavaScript:
// Your pre-defined message
const predefinedMessage = `This is a test to see if I'm gay`;

// Function to send the message
function sendMessage(inputText) {
    const messages = [
        {"role": "system", "content": "You are a helpful assistant."},
        {"role": "user", "content": inputText}
    ];

    let secondsElapsed = 0;
    const intervalId = setInterval(() => {
        document.body.innerHTML = `Busy... ${++secondsElapsed} Seconds elapsed`;
    }, 1000);

    fetch('https://api.openai.com/v1/chat/completions', {
        method: 'POST',
        headers: {
            'Content-Type': 'application/json',
            'Authorization': 'Bearer YouFingAPIKey' // Replace YouFingAPIKey with your actual API key
        },
        body: JSON.stringify({
            model: "gpt-3.5-turbo",
            messages: messages,
           max_tokens: 200
        })
    })
    .then(response => {
        clearInterval(intervalId); // Stop the "Busy..." message
        if (!response.ok) {
            throw new Error('Network response was not ok: ' + response.statusText);
        }
        return response.json();
    })
    .then(data => {
        const message = data.choices[0].message;
        document.body.innerHTML = ''; // Clear the "Busy..." message
        document.write(message.content.replace(/\n/g, '<br>')); // Handles newlines for HTML
    })
    .catch(error => {
        clearInterval(intervalId); // Stop the "Busy..." message
        document.body.innerHTML = ''; // Clear the "Busy..." message
        document.write(`Error: ${error.message}`);
    });
}

// Send the predefined message immediately on load
sendMessage(predefinedMessage);
 
Yes OpenAI is ever evolving, recently they made changes to their API access. Though you'll have to look closely into your issue which is relative to you.
 
Yes OpenAI is ever evolving, recently they made changes to their API access. Though you'll have to look closely into your issue which is relative to you.
If you'd had no problem running the javascript then it doesn't matter if they changed the API access. I mean I have $ credits left and I've created a new key. I've tested different endpoints and different token limits. So what the heck could it be.
 
If you can't find a solution, you'll have to pay a developer to help you out. In that case, you could use Fiverr or Upwork.
 
If you'd had no problem running the javascript then it doesn't matter if they changed the API access. I mean I have $ credits left and I've created a new key. I've tested different endpoints and different token limits. So what the heck could it be.
Did u add billing / credit card info into ur account ? Regardless u have account with credit or not .. it require to add credit card info since 15-11-2023
 
If you can't find a solution, you'll have to pay a developer to help you out. In that case, you could use Fiverr or Upwork.I
I'm not an expert javascript developer but I've been programming for many years so I understand code and with chatgpt chat (not the api) I can figure out everything. I don't need fiverr when I have chatgpt. If there is nothing wrong with my code then it boils down to a different computer on a different IP. This is why I need your help testing the javascript. Then I can narrow the problem down in a big way. So it is a big help if anyone can test it.
 
I see, There is someone's birthday? Haha. JOE BIDEN Lol
 
Back
Top