API talk:Main
Backstory And Stories[edit]
I will be, when time permits and they become active, documenting the new story APIs: API:2/backstory/answers, API:2/backstory/questions, API:2/stories, and API:2/stories/seasons. I doesn't seem fitting to me that these should be placed under "Mechanics" or "Misc." I feel we should create a new category; "Story". Anyone else have any input on this? Bandlero (talk) 09:53, 29 July 2016 (UTC)
- Created the new "Story" category and have added the documentation from the APIs to it. Bandlero (talk) 06:00, 4 August 2016 (UTC)
IDs by Type?[edit]
Please tell me there is a way to get a list of all exotic armors data ids w/o going through every page of the wiki 1 at a time? --Reanne (talk) 00:03, 14 February 2016 (UTC)
- See API:2/items - it can be used to fetch a list of items and information on items. --Nightlark (talk) 10:25, 15 February 2016 (UTC)
API's?[edit]
As a grammar Nazi, I think it should be APIs. I know the Society for Excessive Use of Apostrophes has a large following but… ArenaNet use a mixture of with and without apostrophe which shows they have been infiltrated too. --Claret (talk) 02:12, 10 August 2013 (UTC)
- You’re absolutely right. Wonder why I haven’t noticed that… Anyway, fixed! :) poke | talk 02:20, 10 August 2013 (UTC)
- Actually, that's an accepted usage to form plurals of acronyms. It may not be common usage, but it's not wrong. —Dr Ishmael 02:26, 10 August 2013 (UTC)
- Yes, I am aware but even if it's not wrong, it looks bad. Sorry, that's my opinion and that of a lot of old fuddy-duddies and not so old ones. It offends my eyes. NATO conventionally should not use an apostrophe but N.A.T.O.'s is apparently correct. If you read the reference you gave, it's most often used to disambiguate. Still, I won't change people's articles, I just suggest they might consider it. I mean I have to read the weird words like "upon" and "gotten" - that's painful enough. <- humo(u)r. --Claret (talk) 02:35, 10 August 2013 (UTC)
Open[edit]
Okay, the API namespace is officially open now. Note that the namespace itself is locked by default. If you are interested in working on improving the documentation, please see Guild Wars 2 Wiki:Requests for API editorship on how to get access. The talk pages however are not locked, so feel free to leave suggestions even if you do not have direct access.
Also this is obviously just the start. The main goal was to transfer the available documentation from the forums here in a working format. From here on we’ll work on improving the documentation so that it becomes clear to understand and easy to navigate. Many of the articles can benefit from interlinking and I plan to create articles on some API related topics too. For example API:Maps is going to be an article—or “guide” if you like—on how to use the map APIs with the tile service to create full maps; with examples and detailed information. Feel free to help me with that, or if you have a topic you could write something about, just start it. Apart from the fact that the namespace is locked down to a subset of editors, it should still be a wiki where everyone can live out their own ideas. Just stay focused on the main goal to document the API and always keep in mind that this is the official documentation now, so keep it correct ;)
Finally, some words on the article organization: I’ve prefixed all API version 1 endpoints with a “1/” so that it’s clear that they are part of the version 1. This also prevents any conflicts with later versions and also keeps the root of the namespace clean for general purpose articles. So API:Maps won’t conflict with the endpoint documentation API:1/maps. Also the name of those endpoint articles is equivalent to the actual endpoint except for the leading v
(which would have looked very odd in the URL because of the wiki’s auto-capitalization). poke | talk 02:17, 10 August 2013 (UTC)
- Thanks for the set up, it definitely looks more organized now. —Captain Combat 03:17, 10 August 2013 (UTC)
Translation[edit]
After this discussion i've decided to keep the translation in the user namespace for now. I'd like to keep it 1:1 with the original, but others don't like it that way... So any suggestions for a way to go? --Smiley™ de: user | talk 03:20, 10 August 2013 (UTC)
- To be honest, I don’t really understand their problems. I mean sure, I can understand that they don’t want a good editor to “waste” that amount of time on something maybe nobody will be interested in. But then again, it’s not as if you will be doing other things more likely just because they told you not to do this. Editing is very often inspired by the own interests in something, so if you are interested in doing it, then you should (and usually will) just do it anyway. Doing it in your user namespace instead of the main namespace is now somewhat stupid if you think about it: You’re doing it like you originally planned (making you spend the time anyway), and the main namespace does not get any benefits from it…
- Maybe you could just create those detail pages as subpages of the original article, but keep the original article as it is and just link the individual endpoints to their detail pages. So those who are not satisfied with the short description on the one article can go to the details page and get everything else.
- Creating some categorized subpages (events, wvw, maps etc.) would be fine too. For the world_names issue, you could probably create a new category for “localized constants” or something.
- Btw. because it came up a few times in that discussion: The layout of the documentation is very much designed to be flexible for the future. While now all requests are boring GET requests with a JSON response and no authorization, all that will change in the future. Authorization via OAuth has already been announced and then POST requests will start to pop up for different requests. Rate limits are just as likely (the original infobox had both authorization and rate limit information, but I decided to keep it out for now). So while it may seem overblown for the moment, it offers a lot of flexibility and possibilities for what’s coming.
- And I think you should consider that on the German wiki as well. It does fit on a single article now (in a more or less readable way); but the API is only at its beginning. poke | talk 11:40, 10 August 2013 (UTC)
- It's not that i wanted to keep the translation in the user namespace forever - just until that discussion is done. I intended to move it then to subpages of the API article to match the structure of the original because i know about the points you made regarding flexibility (because i made them too in that discussion). See, the point of "wasting" an editors time is invalid anyway since i don't play much GW2 and i just try to help the wiki i the way i can - which is mostly programming/webapp related - so i don't understand the point of this whole discussion too and thats why i asked for suggestions (which would possibly also help french and spanish translators if there are any). --Smiley™ de: user | talk 18:38, 10 August 2013 (UTC)
Typo[edit]
This page looks like it's locked to developers only so just wanted to post a small typo that I found. "Returns a commonly requested assets." should probably read "Returns commonly requested assets." Just a friendly FYI. :-)
- Fixed. —Dr Ishmael 22:16, 14 September 2013 (UTC)
(Reset indent) New typo, Under "Guild Authenticated" section, "guild/:id/upgraes" is supposed to be "guild/:id/upgrades". DreamPhreak (talk) 12:58, 22 June 2016 (UTC)
Trading post ?[edit]
Any info about an API to retrieve information about the sell products ? How does a site like gw2spidy.com acces these information ? --Dcool (talk) 22:19, 1 December 2013 (UTC)
- The trading post API has not been officially released. Spidy and others have reverse-engineered the website that is accessed by the in-game interface. —Dr Ishmael 22:39, 1 December 2013 (UTC)
- You can find information about the Trading Post API in this thread.--Relyk ~ talk < 22:42, 1 December 2013 (UTC)
Class Diagrams[edit]
I think it would be a good idea to draw a class diagram for each endpoint instead of just listing the possible return values.
Examples:
What do you think? Good idea, or too much effort?
~Steven (talk) 09:26, 27 April 2014 (UTC)
- Too difficult to maintain specialty images - not everyone knows how to generate diagrams like that. (I don't.) But anyone can edit text. —Dr Ishmael 13:47, 27 April 2014 (UTC)
Adding Interwiki Links[edit]
Hey, I know you can request the ability to edit the api-pages but I don't really need it (except for one thing which won't change very often): The interwiki-links. The wiki already has the links to the english api-v2 so someone would just need to go through the pages (which exist) and copy the infos to the english wiki pages, shouldn't be too much work. That's why I'm not applying for editing the api-pages: until they don't bring out another apis, there won't be much for me to edit here. --Cloned (talk) 08:46, 9 September 2014 (UTC)
- Don't worry about the API pages at all, i have an eye on that all the time ;) --Smiley™ de: user | talk 09:44, 9 September 2014 (UTC)
Where to get it?[edit]
Where does one go to download/install the API? Daddicus (talk) 18:43, 4 October 2014
- The API is just a set of HTTP endpoints you can access with your browser or some other software. So there is not really something you can download or install. However, there are quite a few libraries for various programming languages that you can use to get a higher level access to the API. poke | talk 18:49, 4 October 2014 (UTC)
Adding Transactions[edit]
Just a note to add transactions to the list here: http://wiki.guildwars2.com/wiki/API:Main#Trading_post
Link to add:http://wiki.guildwars2.com/wiki/API:2/commerce/transactions
Recipe/Item numbers[edit]
I see that the API-calls for items and recipes go by an ID-number. Is there any way of translating a Name to a Number? Or anyway of easily finding out what number you want? In order to not have to iterate over all the items in order to find the one you're interested in. Winterbay (talk) 16:32, 17 May 2015 (UTC)
- Nope, the id is the unique identifier. Some items and/or recipes may have the same name.--Relyk ~ talk < 20:07, 17 May 2015 (UTC)
Version 2 endpoints[edit]
The information under Version 2 endpoints is not up to date anymore. If you go to the link https://wiki.guildwars2.com/wiki/API:2 you see more APIv2 endpoints listed than under that heading. I wanted to edit this, but i noticed the edit functionality on this page is limited. Could someone else update the page? Or give me the rights to edit it. Thanks. Jurrit (talk) 10:07, 29 May 2015 (UTC)
- Specifically /v2/account and /v2/characters is missing. Also under Changelog Jurrit (talk) 10:16, 29 May 2015 (UTC)
- See Guild Wars 2 Wiki:Requests for API editorship —Dr Ishmael 12:22, 29 May 2015 (UTC)
Version 1?[edit]
At the very first lane of the page it says the current version is the Version 1. Aren't we already using the Version 2? - Saelyth / Aens Windstorm Talk 21:42, 5 June 2015 (UTC)
- Since /v2 is still a work in progress, i'd consider /v1 as current version at this point. --Smiley™ de: user | talk 22:18, 5 June 2015 (UTC)
- I'd say the "current" version depends on which endpoint or set of endpoints you're working with. If you're working with items/trading post/skins/etc. then v2 is definitely the current version, since it has a lot of features that v1 doesn't. Realistically, the only time that v1 would be the current version is if a v2 version of that endpoint doesn't exist. —Dr Ishmael 01:56, 6 June 2015 (UTC)
Account/Recipes[edit]
As far as I can see there is no way to determine if any account characters (and which characters, if any) have a recipe unlocked. This would be quite useful. Any idea if that planned for the next API release? Separ (talk) 15:37, 9 January 2016 (UTC)
- This totally is in the API, and evidently I completely forgot about it. It's under
/v2/characters
if you have theinventories
permission. Just added that to the page; sorry about that! Eearslya (talk) 17:28, 9 January 2016 (UTC)- A character query for one of my characters (mesmer with Artificer, Tailor, Scribe) returns a recipe string (...,10153,10159,10170,10237,....) that includes 10170. When I attempt to get info on only that recipe (Query string: "v2/recipes?ids=" & "10170"), I get: {"text":"all ids provided are invalid"} when that number is combined with others I get the other recipe's info but nothing for that. These are all of the recipe ids (Query string: "v2/recipes") that do not show any details when the values is queried: 10104, 10165, 10170, 10418, 10424, 10864, 10879, 11300, 11758, 11760, 11765, 11770, 11774, 11780. Could there be similar problems in other tables? Separ (talk) 20:11, 26 January 2016 (UTC)
- Not everything in the game is on the API. Fountain Torch#recipe1 -86.131.74.25 22:49, 26 January 2016 (UTC)
- Understood, but the /characters part of the API returns a recipe code that the /recipes part of the API does not see as valid. Separ (talk) 22:56, 26 January 2016 (UTC)
- Recipe 10170 works fine for me--Relyk ~ talk < 03:33, 27 January 2016 (UTC)
- Understood, but the /characters part of the API returns a recipe code that the /recipes part of the API does not see as valid. Separ (talk) 22:56, 26 January 2016 (UTC)
- Not everything in the game is on the API. Fountain Torch#recipe1 -86.131.74.25 22:49, 26 January 2016 (UTC)
Is API v1 fully obsolete?[edit]
Are there any data in the endpoints of the v1 API which can't be accessed via v2? Except event details because it's still available. But all of the others, like items, seem to be covered from v2, right? Nokomis (talk) 22:32, 20 April 2018 (UTC)
- v1/event_details (and therefore v1/maps) are the obvious ones that I know aren't obsolete (you need v1/maps to get proper event positions).
- I have a suspicion that the guild endpoint for v1 might also contain information that's hard to get from v2, but I don't have any familiarity with the guild endpoints. -Chieftain Alex 13:44, 21 April 2018 (UTC)
Chinese server[edit]
I can't edit the article. Could someone please add the following information to the notes:
- The Chinese version of Guild Wars 2 does not have a public API of its own.
- All fan-made Chinese applications and webpages rely on API data from the global server in English.
- As a result, items unique to the Chinese server (that are not implemented on the global server) are not available on API-based Chinese websites.--LilianaM (talk) 14:06, 25 July 2021 (UTC)
Consistency of type naming[edit]
Type naming across different pages is not consistent. E.g. in some pages it's `int` yet in others `number` might be used. I think it would be better to have consistent naming. And personally I think using more granular (`int`/`decimal` instead of `number`) naming should be preferred. Gosferano (talk) 22:43, 29 September 2022 (UTC)
Wizard vault endpoint[edit]
Can we get API:2/wizardsvault added to the list, it seems to be missing --Dak393 (talk) 11:15, 24 August 2024 (UTC)