I am sorry if this question has been asked before; I haven’t been able to find it. I have a paid ChatGPT Plus account, and I created a GPT model with FAQs from my company. It works perfectly, but I don’t know exactly if I can access that model through PHP and if I need to pay for API usage.
Thanks, and excuse my newbie question. I tried many things and nothing works so far.
Hi @pedroalcanta69, and welcome to the community!
GPTs are not accessible via API. But the API “equivalent” is the Assistants API.
https://platform.openai.com/docs/assistants/overview?context=with-streaming
This API is still in Beta and has some quirks, but it is working much better today than a couple months back.
So, in very short, this is what you need to do:
- Go to the OpenAI Playground | https://platform.openai.com/assistants
- Create a new assistant, upload the docs you need, give it the instructions (system message) you want.
- Now you can use that assistant as if it was a custom GPT through the assistant API. You just need the assistantId. Follow the OpenAI guide and you’ll be up and running in no time.
Best of luck!
1 Like