Introduction
Welcome to the Kittn API! You can use our API to access Kittn API endpoints, which can get information on various cats, kittens, and breeds in our database.
We have language bindings in Shell, Ruby, and Python! You can view code examples in the dark area to the right, and you can switch the programming language of the examples with the tabs in the top right.
Authentication
To authorize, use this code:
require 'kittn'
api = Kittn::APIClient.authorize!('meowmeowmeow')
import kittn
api = kittn.authorize('meowmeowmeow')
# With shell, you can just pass the correct header with each request
curl "api_endpoint_here"
-H "Authorization: meowmeowmeow"
Errors
The Kittn API uses the following error codes:
Error Code | Meaning |
---|---|
400 | Bad Request -- Your request sucks |
401 | Unauthorized -- Your API key is wrong |
403 | Forbidden -- The kitten requested is hidden for administrators only |
404 | Not Found -- The specified kitten could not be found |
405 | Method Not Allowed -- You tried to access a kitten with an invalid method |
406 | Not Acceptable -- You requested a format that isn't json |
410 | Gone -- The kitten requested has been removed from our servers |
418 | I'm a teapot |
429 | Too Many Requests -- You're requesting too many kittens! Slow down! |
500 | Internal Server Error -- We had a problem with our server. Try again later. |
503 | Service Unavailable -- We're temporarially offline for maintanance. Please try again later. |