-
Notifications
You must be signed in to change notification settings - Fork 3
The Web API is a new REST based interface to key parts of the TeamHaven Server business layer. It is available under the /api URL of a TeamHaven server, and it is available via HTTPS at https://www.teamhaven.com/api.
Authorisation is done using the standard HTTP Authorization header. There are two authorisation schemes, both of which use the same basic format for a set of TeamHaven credentials:
username/account:password
Typically, authorisation should be performed with HTTP Basic authorisation, using Base64 encoded TeamHaven credentials.
Authorization: Basic c3RvbnkvdGVzdDp0ZXJyaWVy
However, for debugging purposes, it is also possible to provide unencoded credentials using "TeamHaven" as the authentication scheme name rather than "Basic".
Authorization: TeamHaven username/account:password
In addition, a standard TeamHaven authentication cookie can also be used, so that if web pages on the TeamHaven website wish to use the WebAPI, they may do so without having to provide any authorisation information, as their requests will already contain the required cookie. This means it is possible to log into the TeamHaven website and review the output of any GET requests via a web browser, provided it can request and display XML or JSON output.
Request content must be UTF-8 encoded and presented as text/json or application/json.
Content-Type: application/json; charset=UTF-8
- 2xx
- Success
- 4xx
-
Something was wrong with your request. Check the
Messageproperty of the response for more information about what was wrong. - 5xx
- An exception prevented the server from processing your request, contact support@teamhaven.com for assistance.
The API HTTP redirection where appropriate. Clients should assume that any request may result in a redirection. Receiving an HTTP redirection is not an error and clients should follow that redirect. Redirect responses will have a Location header field which contains the URI of the resource to which the client should repeat the requests.