OpenAI API Setup
So, you just installed or upgraded Divi Form Builder to start utilizing the OpenAI GPT API features to serve your customers better.
Welcome to the future.
Before we do so, you need to setup your API keys details. This is done if 3 steps if you do not yet have an OpenAI API key, if you do, skip to Step 3.
The steps are:
- Obtaining your OpenAI API key
- Setting Monthly Usage limits for your API key with OpenAI
- Adding your API key to Divi Form Builder
Step 1 - Obtaining an OpenAI API key
- Go to OpenAI’s official platform website here.
- If you haven't already, create an account following the simple steps on the website. You can enter the email address and password linked to your OpenAI account to sign in or log in with an existing Google or Microsoft account.
- Once you’ve created an account or have logged into an existing account, you’ll see your name and your profile icon at the top-right corner of OpenAI’s platform homepage.
- To get an API Key, click on your name in the top-right corner to bring up a dropdown menu. Then, click the “View API keys” option.
- At this point, you’ll be on a page that has an option to “Create new secret key” near the center. If you do not have an API key, click this button to get one.
- Make sure to save the API key as soon as possible. Once the window showing it closes, you won’t be able to reopen it or view that API key again.
Step 2 - Setting Monthly Usage limits for your API key with OpenAI
- Log in to your OpenAI account here.
- Go to the Manage Account, you’ll see your name and your profile icon at the top-right corner of OpenAI’s platform homepage.
- On your account management page, click on Billing, and then Usage Limits.
- Look for the fields to set your hard and soft limits.
- Set a "Hard limit". This is the maximum usage threshold for each month. Once this limit is reached, subsequent requests will be rejected1.
- Set a "Soft limit". When your usage reaches this threshold each month, a notification email will be sent to you.
- Save your changes.
Step 3 - Adding your API key to Divi Form Builder
- Head over to the Divi Form Builder Settings > Form AI > OpenAI Settings.
- Paste your copied API key into the input.
- Select the OpenAI Model you have access to.
- Save the changes before testing the API key.
- Test your API key. This test will fail if either the API key is wrong, or the wrong model is selected.
NOTE: Not all API keys are created equal, if you did not waitlist yourself for the GPT 4 API, you might not have access to it, and be restricted to GPT 3.5.
You are now ready to start using the Divi Form Builder AI Field.