Support

Home Forums Event Espresso Premium App endpoint error

App endpoint error

Posted: April 5, 2017 at 9:13 pm

Viewing 4 reply threads


Giant Dwarf

April 5, 2017 at 9:13 pm

Hi there, we’ve been trying to login to the EE app, but haven’t had any luck, as we keep getting the message “Connection error, unable to load data” on login.

I’ve run through the checklist of troubleshooting potential app problems with no luck. We’ve got the latest version of the app and have updated EE within the last two months.

I tried install wp-rest-api-log to see what was going wrong but got no log results. Instead I had a peek at the apache access log and noticed that the app is attempting to connect to the wrong URL. Rather than sending GET requests to /wp-json/ee/v4.8.36/events which serves a json file, the app seems to be dropping the “wp-json” part from the requests and is instead trying to make requests like “GET /ee/v4.8.36/events”, which are returning 404 messages.

Any ideas how we can fix this? The site in question is GiantDwarf.com.au (json endpoint http://giantdwarf.com.au/wp-json).


Josh

  • Support Staff

April 6, 2017 at 12:09 pm

Hi there,

May I ask what makes you think the app is dropping the /wp-json/ part of the URL in the request? Are you sure that something else isn’t stripping that part?


Giant Dwarf

April 6, 2017 at 6:28 pm

It’s entirely possible I guess but I just hit the wall of not knowing how the app works behind the scenes which makes it difficult to reverse engineer the issue.

Basically I got as far as making a login attempt in the app and then checking in the apache log what URL was requested in order to try and check that the json on the site is working. That’s when I saw that the requests hitting the site were for /ee/… instead of for /wp-json/ee/…

It’s possible the site itself is telling the app that this is the URL to query, but without knowing how the app finds the json endpoint in the first place I can’t say whether that’s the case.


Giant Dwarf

April 6, 2017 at 7:00 pm

Oh and also if I’ve misunderstood the question and you’re asking how I know it’s specifically the app making those requests, I can see the username listed in the logs, so if I try to login as FooBar I will get

162.158.178.xx – FooBar [07/Apr/2017:10:39:11 +1000] “HEAD / HTTP/1.1” 301 509 “-” “okhttp/3.2.0”
162.158.178.xx – – [07/Apr/2017:10:39:13 +1000] “HEAD / HTTP/1.1” 200 507 “-” “okhttp/3.2.0”
162.158.178.xx – FooBar [07/Apr/2017:10:39:14 +1000] “GET /ee/v4.8.36/site_info HTTP/1.1” 404 33414 “-” “okhttp/3.2.0”

Followed by a number of other 404’d requests that attempt to probe upcoming event details.


Josh

  • Support Staff

April 6, 2017 at 8:15 pm

Hi there,

The logs indicate that the GET request to /ee/v4.8.36/site_info was OK, and that log item doesn’t include wp-json in the URL either.

This may be an issue with your site’s permalinks whre another plugin has added its own rewrite rules that’s affecting the requests from the app.

Can you make a backup of the .htaccess file, then set an .htaccess file with only the standard WP rewrite rules to see if that makes a difference?

Viewing 4 reply threads

The support post ‘App endpoint error’ is closed to new replies.

Have a question about this support post? Create a new support post in our support forums and include a link to this existing support post so we can help you.

Event Espresso