Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

5
  • 1
    You can make the fetch request to the backend, and the backend uses fetch to access FastAPI. Commented Apr 25 at 18:37
  • That would be like Widget - > PHP (because the website uses that) -> FastAPI ? And then the same but backwards. Am I right? Commented Apr 25 at 18:59
  • 1
    Yes, that's right... Widget connects to PHP, PHP requests data from FastAPI, forwards data back to widget. It's mostly used when the frontend consumes an API endpoint and you don't want to expose the API to the world. Commented Apr 25 at 19:36
  • So the website backend and the FastAPI backend are on two different machines? And you've said that you already tested serving the FastAPI application over HTTP with a self-signed certificate. What exactly prevents you from getting a free and trusted certificate from a CA like Let's Encrypt? You can install and run ACME clients like certbot without sudo or root privileges. Commented Apr 25 at 22:35
  • I didn't know about ACME clients like certbot tbh, I'm kinda new with all of this stuff but thank you anyway, I'll look it up!! Commented Apr 28 at 15:28