Showing Posts For lynnae.4095:
That’s all UTC
(and have some extra words so the forums let me post. Hi Mom!)
hmm, here’s the list of times I’ve gotten a response since Saturday morning (hourly checks):
everything fine through 05:09 then nothing. Then sporadic successes:
2017/03/18 23:09:15
2017/03/19 06:09:15
2017/03/19 08:09:15
2017/03/19 10:09:15
2017/03/19 19:14:31 (new server, new time, one day I’ll fix that, but probably not)
I can’t see from here if those all correlate, with that much green I feel unlucky about the big break in hits today
(edited by lynnae.4095)
The trading post prices endpoint is up and down, can we PM here? I can send you the times logs of when I’ve been able to get trading post data:
https://api.guildwars2.com/v2/commerce/prices
and the associated:
https://api.guildwars2.com/v2/commerce/prices?ids=
Most recently about 30 min ago 19:14 UTC
I’m checking the data that’s been returned now, take me a couple of minutes as today I’ve been moving databases.
Data looks legit from a cursory inspection, as in it hasn’t been the same record being returned each time
(edited by lynnae.4095)
looks like, at least certain, endpoints have been up and down today. How big is the fire? ie would you appreciate it if people held off work on new features today that would hit the endpoints that seem to be up (or were up last time my services ran)
Everyone loves javascript!
(crickets…)
Okay, well, some people do, so I’ve heard, once.
On offer today is a wrapper for the v2 API, available at:
https://github.com/dyanarose/gw2Api.js
or via:
bower install dlr.gw2Api
A playground/test platform which will generate example wrapper code for you and make calls to the API is available at: http://dyanarose.github.io/gw2Api.js
And because wiki’s are wicked: https://github.com/dyanarose/gw2Api.js/wiki
Almost all errors are mine
New javascript implementation of all v2 api endpoints. v0.1 at the present.
- Project Name : gw2Api.js
- Implementation Language: javascript
- Project Administrator: lynnae.4095
- Url to the project: https://github.com/dyanarose/gw2Api.js
- Bower: bower install dlr.gw2Api
:) thanks. I’m aware.
ta folks.
Since sending the preflight request is not something you can control when you set the Authorization header in javascript, I’ll try appending it to the query string as indicated.
ta for the tip, think this was the post that shows the query string key https://forum-en.gw2archive.eu/forum/community/api/Cross-Origin-v2-transactions
and the original dev post response that preflight requests are not supported and listing the query string workaround:
https://forum-en.gw2archive.eu/forum/community/api/Launching-v2-commerce-transactions/first#post5077482
(edited by lynnae.4095)
using javascript XMLHttpRequest and setting the Authorization header via xhr.setRequestHeader(‘Authorization’,’Bearer ’ + token);
causes a preflight request to be sent because Authorization is considered to be a custom header.
Unfortunately the preflight request doesn’t look to be handled and Chrome reports:
XMLHttpRequest cannot load https://api.guildwars2.com/v2/account. No ‘Access-Control-Allow-Origin’ header is present on the requested resource.
Is this to be expected, and XMLHttpRequest can’t be used to access the protected resources, or do I have the wrong end of the stick for setting the bearer token? Or have the CORS headers gone walkabout?
(edited by lynnae.4095)
going through the endpoint pages, it’s not as clear as it could be which query params each endpoint accepts.
Though many endpoints do have a “params” section, there isn’t a standard for which params are included.
For example:
https://wiki.guildwars2.com/wiki/API:2/colors only lists the “lang” param specifically, though id and ids are mentioned buried in the text.
Is there an objection to cleaning up the pages, so that the front page for API:2 lists all the common params (which look to be page and page_size) and then each endpoint page lists the params it accepts, along with whether the param is Required or Optional (and possibly mutually exclusive)
i’m more concerned about the fact that authorization (log in with gw2) is impossible.
Authentication is not possible right now. Delegated authorization is.
I think what you’re looking for is OpenIdConnect, which uses JWT tokens to build authentication using the OAuth specifications.