greenfield-hippos / backend

0 stars 1 forks source link

feat: add endpoint for calling openai API #10

Closed vicentbe10 closed 1 month ago

vicentbe10 commented 1 month ago

First PR to merge so not sure I did it correctly or if I am messing with the branches.

About the PR itself.

How I tested? I used Postman to create a post request with a "message" in the body. You can also do a quick test with curl

curl -X POST http://localhost:5000/api/chat \
     -H "Content-Type: application/json" \
     -d '{"message": "Can you explain what a promise is in JavaScript?"}'