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

194
Vistas
Get request is not working with axios but working with postman

I've made a MongoDB GET request route named users/auth to create authentication by searching for the records provided in the request's body, inside the database. When I send the request via POSTMAN then it gives the expected response (eg: "true") enter image description here

But when I tried to send the same request inside my react-app with AXIOS it gives an unexpected response(eg: false) with status code: ok. I'm not sure of what wrong I'm doing.

//some valid objects which should return true
//but it return's false
users = {
"email": 'abc@gm.com',
"password": 'abcdef'
}

axios.get('http://localhost:5000/users/auth', users)
        .then(res => {
            console.log(res.data);
  //expected: true
  // actual result: false
        })
        .catch(error => console.log(error))

I've read this problem but It didn't fixed my problem.

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