API Documentation
Authentication
Most APIs in Hound require authentication. There are two main ways to authenticate with Hound:
- Auth Tokens
- API Keys
Some routes, such as deleting a user and resetting another user's password can only be done by the admin.
Auth Token
Auth tokens are used by Hound's official clients. If you would like to plan on making a Hound client, you should use this method.
Set these headers before calling the /login endpoint
X-Client-Id: A unique identifier for your appX-Client-Platform: The platform of your app, supported values includeios-mobile,ios-tv(Apple TV),android-mobile,android-tv,web. You can use a custom Client Platform if you wishX-Device-Id: A UUIDv4 unique identifier for the device. This should be generated by the client during first run, and persisted
Request
POST /api/v1/auth/login
{
"username": "username",
"password": "password"
}Response
{
"data": {
"username": "john_doe",
"display_name": "John Doe",
"token": "abcdef...",
"role": "admin"
},
"status": "success"
}For browsers, a cookie will be set in the token field with the value of the token. For other clients, attach the token in the header Authorization with the value Bearer <token>.
API Key
For standalone tools and webhooks, an API Key might be more suitable. Each user can create an API Key to allow other applications to access and modify their data.
To obtain an API Key, access the web portal: Click your name on the top-right corner -> My Account -> API Keys -> Add API Key
You should create a separate API Key for each application, so you can revoke them as necessary.
WARNING
In Hound Beta, API Keys have full access to that user. Do not share your API Keys to untrusted applications.
Once you have an API Key, attach the header X-Api-Key with this API Key as the value.