How do I reference an .env secret is server.js?

I made an environment called TOKEN, and a secret inside it called TOKEN.
How do I put that in my server.js? I’ve been reading tons of stuff on google without making it work nor getting what I need to do.

1 Like

I also tried making a .env file and using process.env.TOKEN its not working

1 Like