pokemongo-webspoof icon indicating copy to clipboard operation
pokemongo-webspoof copied to clipboard

Request_Denied when clicking on location

Open maxpac opened this issue 6 years ago • 37 comments

Hi,

Facing this issue when I'm not able to click on a location to spoof (see photo)

image

Anyone facing the same issue?

maxpac avatar Dec 04 '18 12:12 maxpac

this might occur when the MAP API or Location API reached the cota limit. You have to add your own MAPs API key

fritzggerard avatar Dec 04 '18 12:12 fritzggerard

how do i do that?

maxpac avatar Dec 04 '18 12:12 maxpac

Having the same issue.

akattamis avatar Dec 04 '18 14:12 akattamis

Can be solved by using your own Maps API key, although this requires to setup a Google Cloud Platform project. After setting up the project, you can obtain the key here https://console.cloud.google.com/google/maps-apis/ Next clone the webspoof repository by following steps from Readme section "Develop", open src/config/api.js and replace the api key there. After that, you can run (npm run dev) or build (npm run build) the app for use with your own api key. (This should prevent the issue further, unless you manage to reach the api free quotas)

MattyTesar avatar Dec 04 '18 22:12 MattyTesar

Matty, can you dumb it down. I downloaded the nodejs but then what?

molonlabe88 avatar Dec 05 '18 03:12 molonlabe88

For obtaining the api key, please follow this https://developers.google.com/maps/documentation/javascript/get-api-key . You will be asked to create or link a billing account though, which requires you enter your credit card information. But if you'll be using this only for the webspoof app, no excessive use, you won't be billed anything. (To be sure you can setup a budget of $0 to be notified in case of any charge) (Make sure that you enable Maps JavaScript API and Directions API - check here https://console.cloud.google.com/google/maps-apis/overview)

For the next steps, open terminal.app on your mac, check you have NodeJS installed (eg. by running npm -v. If you get "command not found", install nodejs from here https://nodejs.org/en/ ), then go to the folder where you want to clone this repository (by typing cd 'path_to_folder'), run git clone https://github.com/iam4x/pokemongo-webspoof.git, cd pokemongo-webspoof and npm install Then proceed to replace the api key in path_to_folder/pokemongo-webspoof/src/config/api.js and save the file. Then enter npm run build in terminal, and after it finishes, you can find freshly built pokemongo-webspoof.app in pokemongo-webspoof-darwin-x64 folder.

Is that understandable, or are you having trouble with any specific step/s?

MattyTesar avatar Dec 05 '18 08:12 MattyTesar

Hi, unfortunately Request denied even after replacing with own key. Any suggestions?

CavemanGer avatar Dec 05 '18 09:12 CavemanGer

Did you build the app after saving the changes and run the new version? Also, make sure you have Maps JavaScript or Embed API key with unrestricted use (you can check here https://console.cloud.google.com/google/maps-apis/overview - open the desired api detail from 'Enabled APIs' and then look to 'Credentials' section)

MattyTesar avatar Dec 05 '18 09:12 MattyTesar

For some reason the api key was not activated. Resolved this, now it works. Thanks a lot Matty!

CavemanGer avatar Dec 05 '18 09:12 CavemanGer

Thanks a lot Matty for your Help. After replacing the API Key and build the app the error Google Maps API error 400 has gone. But "Request Denied" is still their. Which API ´s has to be activated? Thank´s

Blistex1899 avatar Dec 05 '18 11:12 Blistex1899

Direction API has also be activated, after that it works fine.

Thanks

Blistex1899 avatar Dec 05 '18 11:12 Blistex1899

Direction API has also be activated, after that it works fine.

You're right, Directions API is quite essential for the autopilot feature. Thanks for pointing that out 👍

MattyTesar avatar Dec 05 '18 11:12 MattyTesar

I get error messages after these steps: cd pokemongo-webspoof && npm install npm run build

macbook-air:~ User$ CD pokemongo-webspoof macbook-air:~ User$ CD pokemongo-webspoof && npm install npm WARN saveError ENOENT: no such file or directory, open '/Users/xyz/package.json' npm WARN enoent ENOENT: no such file or directory, open '/Users/xyz/package.json' npm WARN xyz No description npm WARN xyz No repository field. npm WARN xyz No README data npm WARN xyz No license field.

if i understand the errormessage right its because the package.json file cant be found, but when i look in the pokemongo-webspoof folder its inside. so i copied the file in the root directory (user).. after this the installation "worked" but still with warnings..

After this i searched for the pokemongo-webspoof-darwin-x64, but i cant find it. i can find a node_modules but no pokemongo.webspoof in it..

isnt it possible to change the API Key in an existing Pokemon Webspoof APP? There should be an api.js file too..

sorry for this nooby questions but im new in MAC..

megusta63 avatar Dec 05 '18 12:12 megusta63

@megusta63 these npm install warnings aren't really important, if you see node_modules in your pokemongo-webspoof folder then the installation probably worked. Did you run npm run build after that, and if so, do you get any errors there? (make sure you run this from inside the pokemongo-webspoof folder)

MattyTesar avatar Dec 05 '18 13:12 MattyTesar

i'm getting npm command not found. Sorry, i'm bad at codings and commands

maxpac avatar Dec 05 '18 13:12 maxpac

@maxpac have you installed NodeJS? You can try using absolute path to the command, which should be /usr/local/bin/npm If you're still getting "command not found" or "No such file or directory", try installing node with the package from https://nodejs.org/en/

MattyTesar avatar Dec 05 '18 13:12 MattyTesar

sorry, forgot i had to install node.js. so i have followed all the steps, ensured my api has no restrictions but i'm still getting Request Denied,

I've also ensured both Map Javascript API and Directions API are enabled.

maxpac avatar Dec 05 '18 14:12 maxpac

@MattyTesar worked! thanks, i run from the root directory first because of this it doesnt worked

megusta63 avatar Dec 05 '18 14:12 megusta63

@megusta63 Thanks for bringing this up. No wonder i couldn't get through.

However, after "cd pokemongo-webspoof and npm install", i'm getting ACTION Regenerating Makefile. What's this?

maxpac avatar Dec 05 '18 15:12 maxpac

@maxpac can you try removing node_modules folder and package.lock file and running npm install again (from inside pokemongo-webspoof folder). Also make sure you have nodejs version 6+ ( run node -v )

MattyTesar avatar Dec 05 '18 15:12 MattyTesar

@MattyTesar ok i'm able to to pass npm install. The problem right now is npm run build. I'm getting this error Failed at the [email protected] build script. Any idea?

The first error code line was ELIFECYCLE

maxpac avatar Dec 05 '18 15:12 maxpac

IT FINALLY WORKED! Had to run npm run build first, change the API key in api.js, run npm run build again. Not sure why an additional steps but it works at least.

Thanks again everyone! Especially @MattyTesar

maxpac avatar Dec 05 '18 15:12 maxpac

Sorry to trouble again. I'm able to build, run without issues, able to teleport but my character doesn't respond to my movements at all. I'm getting this error.

image

maxpac avatar Dec 05 '18 15:12 maxpac

Check Readme section Known issues https://github.com/iam4x/pokemongo-webspoof/blob/c820192db572c3829add43d34e00adc156c7e6de/README.md#known-issues

MattyTesar avatar Dec 05 '18 15:12 MattyTesar

Cause one of the troubleshooting was to delete the app and reinstall it. So does that mean i have do npm run build after deleting again?

maxpac avatar Dec 05 '18 15:12 maxpac

That shouldn't be necessary, unless you build the app with a different version number. You just need to add your build of pokemongo-webspoof.app to the accessibility apps in System Preferences > Security & Privacy > Privacy tab > Accessibility and check the checkbox next to it. Or bypass this altogether by opening Script Editor.app and running the following code (if you do this, don't use "Auto update Xcode location" in the spoof app)

repeat
	tell application "System Events" to tell process "Xcode"
		click menu item "pokemonLocation" of menu 1 of menu item "Simulate Location" of menu 1 of menu bar item "Debug" of menu bar 1
	end tell
	delay 0.5
end repeat

MattyTesar avatar Dec 05 '18 16:12 MattyTesar

Hi there, I'm sorry to ask but is there any free of cost solution to get Webspoof to work again like before? Thank you

berrymetal avatar Dec 05 '18 17:12 berrymetal

You mean without the need to setup billing account? Because even with it, it's basically free of cost, unless you're planning on making more than about 1300 directions requests (autopilot target updates) per day. https://cloud.google.com/maps-platform/pricing/sheet/

MattyTesar avatar Dec 05 '18 18:12 MattyTesar

I enabled Maps API and now maps load without the watermark but I am still getting the "request denied"

Well, it was loading fine. Now its back to the "development purposes only"

now i'm getting over_query_limit

molonlabe88 avatar Dec 06 '18 00:12 molonlabe88

You mean without the need to setup billing account? Because even with it, it's basically free of cost, unless you're planning on making more than about 1300 directions requests (autopilot target updates) per day. https://cloud.google.com/maps-platform/pricing/sheet/

or what about a way that would let us update the API without as many steps. I think i've almost got this time, but I don't follow what to do if i have to reinstall web spoof. I'd even donate a few bucks to someone who made it easier.

molonlabe88 avatar Dec 06 '18 00:12 molonlabe88