Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

180
Vistas
Why does my google OAuth2 refresh_token expire after a week?

I am currently creating a simple website using JS. In my application, I am using nodemailer as a tool so that individuals can contact me. The contact form goes directly to my email once the user submits the form.

I am using https//mail.google.com API with oAuth2 authentication (using refresh_token and accessToken). When I first began using oAuth2, it began working right away. However, “invalid_grant” has appeared in my console after submitting the form on the condition that the refresh_token I use have been living for a week. The token does work for the first 7 days but then expires by saying it’s an “invalid_grant” and that the “token has been revoked”.

How might I resolve this problem? (I’ll reply to any additional problems you have about this question)

about 4 years ago · Juan Pablo Isaza
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda