hello. i'm trying to send a request with nodejs server and it gives me connect etimedout 10.10.34.36:443 error. if i send the request from fron-end it works fine.
my code:
const fetch = require("node-fetch");
module.exports = {
async home() {
try {
const response = await fetch(
"https://api.themoviedb.org/3/tv/popular?api_key=********&language=en-US&page=1"
);
const responseData = await response.json();
console.log(responseData);
} catch (error) {
throw new Error(error);
}
}
};
Не можеш да нађеш филм или серију? Пријави се да додаш.
Желите ли да оцените или додате ову ставку у листу?
Нисте члан?
Одговор од Travis Bell
дана 02. фебруар 2021. у 10:54 AM
Hi @mohammad-tn,
10.10.34.36
is a private IP (an IP address on your LAN). We can't help with that. If you're seeing an error connecting to the public service let us know.