Difference between revisions of "API Overview"
m (moved API to API Overview: less vague name) |
|||
Line 20: | Line 20: | ||
Documentation here may currently include API features which are not fully implemented. Pages will generally indicate the implementation status of features (In order of least to most complete: Planned, Under Development, Partial Implementation, Completed, Mature) | Documentation here may currently include API features which are not fully implemented. Pages will generally indicate the implementation status of features (In order of least to most complete: Planned, Under Development, Partial Implementation, Completed, Mature) | ||
+ | |||
+ | |||
+ | In general, requests are answered with appropriate HTTP status codes. Responses may also include a 'message' and 'statusSubType' to further detail certain failures. A 'message' is a human-readable error message which can be used by a client as rudimentary output to display to a user. A 'statusSubType' is almost like an ENUM - so that programmatic decisions can be made by clients about what to do in certain situations. For example, a 403 may be because access is forbidden to an object based on permissions, because the account used for authentication is not active, or because the account used for auth is banned. The formermost is very straightforward so no 'message' and 'statusSubType' is included. The latter two would be sent with a 'message' and 'statusSubType'. The 'message' contents are not intended to be consumed programmatically and therefore are not documented in detail. The subStatusType values are further documented, see [[subStatusType]] | ||
+ | |||
To view a full list of API-related pages, see [[:Category:API]] | To view a full list of API-related pages, see [[:Category:API]] |
Revision as of 10:07, 10 March 2012
King Arthur's Gold has an API under development. This page and others on the kagwiki will serve as official documentation for how to use this API.
The API is planned to be 100% RESTful and uses JSON for all responses. HTTP request verbs and response codes are used appropriately and should be obeyed.
The API is/will be used for the following:
- Client authentication (both when the client opens and when joining a server)
- Server registration in the master list
- Client retrieval of the server list and server details
Future uses:
- 3rd party retrieval of forum and KAG account profile information (avatars, signatures, etc)
- Querying for KAG account status (gold/not activated/banned)
- Sekrit features to be determined/announced
Some of the features documented here are intended for internal use by components of KAG only. They may technically be usable by 3rd party applications and sites, however their use is discouraged for various reasons. Documented features which fall into this category will have warnings posted.
Documentation here may currently include API features which are not fully implemented. Pages will generally indicate the implementation status of features (In order of least to most complete: Planned, Under Development, Partial Implementation, Completed, Mature)
In general, requests are answered with appropriate HTTP status codes. Responses may also include a 'message' and 'statusSubType' to further detail certain failures. A 'message' is a human-readable error message which can be used by a client as rudimentary output to display to a user. A 'statusSubType' is almost like an ENUM - so that programmatic decisions can be made by clients about what to do in certain situations. For example, a 403 may be because access is forbidden to an object based on permissions, because the account used for authentication is not active, or because the account used for auth is banned. The formermost is very straightforward so no 'message' and 'statusSubType' is included. The latter two would be sent with a 'message' and 'statusSubType'. The 'message' contents are not intended to be consumed programmatically and therefore are not documented in detail. The subStatusType values are further documented, see subStatusType
To view a full list of API-related pages, see Category:API