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

326
Vistas
Node: Cannot acces to an endpoint

I have no idea about what is happend. I've developed a server who serves information through an API REST. I have defined several endpoints which works without any problem but the end points defined today doesn't work anyone of them.

The code of my router.js is:

import express from "express";
import {Result} from "../com/result";
import config from "../config";
import {getData, getPhotoFromGIATAServer} from "../com/functions";
import {XMLParser} from "fast-xml-parser";
import fs from "fs";

const router = express.Router();

router.post("/api", async (req, res) => {

});

router.post("/api/destinations", async (req, res) => {

});

router.post("/api/country", async (req, res) => {

});

router.post("/api/media", async (req, res) => {

});

router.post("/api/factsheet", async (req, res) => {

});

router.post("/api/texts", async (req, res) => {

});

router.post("/api/update", async (req, res) => {

});

router.post("/api/photo", async (req, res) => {

});

router.post("/api/update/photos", async (req, res) => {
   //Doesn't work
});

router.post("/api/update/texts", async (req, res) => {
    //Doesn't work
});

router.post("/api/update/factsheets", async (req, res) => {
    //Doesn't work
});

module.exports.Router = router;

All the endpoints works fine except the last three ones. When I make a call to one of them I receive a 404 error.

As you can see, the domain and por in both cases are equals but one of them works and the other one not.

enter image description here

enter image description here

enter image description here

enter image description here

I don't understand anything. What is happend? What am I doing wrong?

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