This backend server handles Google OAuth 2.0 token exchange and refresh for integrations.
-
Install dependencies:
npm install
-
Copy
.env.exampleto.envand fill in your values. -
Start the server:
npm run dev
GET /auth/oauth2callback?code=...exchanges the Google authorization code for tokens.GET /auth/get-access-tokenreturns a valid access token, refreshing it when needed.GET /auth/refresh-tokenmanually refreshes the stored access token.