maierfelix / POGOserver

Pokemon GO server emulator
GNU General Public License v3.0
460 stars 198 forks source link

Adding PokeStops and Spawnpoints - manually due to API trouble #311

Open ghost opened 7 years ago

ghost commented 7 years ago

With API being somewhat unwilling to work (using the pre-setup version and the api script found here)..

What fields would a Pokestop need? A Spawnpoint? Where would I need to enter them? I basically want to input the data which usually comes from api manually.

Alternatively an idea how to get the api working.. It says "Connecting.." for a long while, server prints "Unknown request url: https://127.0.0.1:3000/api".. API is enabled in Server's cfg.

chaze117 commented 7 years ago

You executed the "npm run api" command? And it's address https://127.0.0.1:3000

ghost commented 7 years ago

Added the command, thanks for the tip :) Error; Connection refused..

EDIT: it asked for localhost for some reason.. when using only localhost it at least gives me the login screen again, but it still keeps "Connecting" indefinitely. Also, server's still printing "Unknown request url" with the same URL..

chaze117 commented 7 years ago

Sorry my bad it's not 127.0.0.1:3000, the correct address is 127.0.0.1:9000 but you need edit the cfg.js if you run other webserver on your computer. From this: API_ALLOWED_HOSTS: ["localhost", "127.0.0.1"],

to this API_ALLOWED_HOSTS: ["localhost", "127.0.0.1", "127.0.0.1:9000"],

If you don't run any other webserver on your computer just leave the cjg.js and connect to 127.0.0.1 or localhost

ghost commented 7 years ago

Ooookay, so it stopped giving "Unknown Request URL" and it doesn't refuse connection.. But it still can't connect.