-
Notifications
You must be signed in to change notification settings - Fork 1
REST API
Ben edited this page Feb 25, 2015
·
5 revisions
The REST API lets you push logs
to arewegood from anything that can make an HTTPS request.
- All API access is via the
https://api.arewegood.io
url. - All requests must be authenticated with either
?access_token=...
in the request query string, or set theAuthentication
header toBearer ...
where...
is the api key of the repository you are logging data for (retrieved from arewegood ui). - All requests must also set the
Content-Type
header toapplication/json
.
Pushes logs for the repository represented by the api key (defined via authenticate reference above).
Content:
{
logs: [
{type:"", data: ...},
....
]
}
type: a string that represents the type of log message that is being sent. Supported types are info, error, debug, trace (each represents a level of logging).
data: any arbitrary content of a log message.
Response:
A successful response will contain no body and a status code of 200
. Failure will yield a different status code, and an optional json response containing an {error:""}
message.