nisabmohd / ChatGPT

I've developed a ChatGPT clone using Next.js 14, Shadcn-UI, Prisma ORM, and integrated it with the OpenAI API. It offers a user-friendly conversational AI experience.
Apache License 2.0
306 stars 123 forks source link

Quick question, why do you need nodejs and a database? #5

Closed ncesar closed 1 year ago

ncesar commented 1 year ago

Couldn't you just use the frontend to fetch api calls to OpenAI?

Are you using database and node just to have user login/signup or is there something else I didnt saw on the code?

Thanks and good job!

nisabmohd commented 1 year ago

The OpenAi docs recommend to use it with Node for security reasons. And I have uses api key authentication in Node beacuse you have to be authorised inorder to make request.

ncesar commented 1 year ago

makes totally sense, thank you and nice job here!