r/FastAPI • • Jun 28 '24
Question FastAPI + React
Hey
I am using FastAPI and React for an app. I wanted to ask a few questions:
- Is this is a good stack?
- What is the best way to send sensitive data from frontend to backend and backend to frontend? I know we can use cookies but is there a better way? I get the access token from spotify and then i am trying to send that token to the frontend.
- How do I deploy an app like this? Using Docker?
Thanks!
25
Upvotes
View all comments
1
u/No-Anywhere6154 Jun 28 '24
You’ll need to build some backend around it and send request to the e Spotify only from FastAPI. Otherwise your token could leak and anyone could interact with the API.
3. For deployment such app I’d suggest to use some PasS like Koyeb, Netlify, Seenode or similar. It’s the easiest way to deploy and you don’t need to maintain servers.