curl "http://example.com/api/kittens"
-H "Authorization: meowmeowmeow"
The above command returns JSON structured like this:
[
{
"id": 1,
"name": "Fluffums",
"breed": "calico",
"fluffiness": 6,
"cuteness": 7
},
{
"id": 2,
"name": "Isis",
"breed": "unknown",
"fluffiness": 5,
"cuteness": 10
}
]
This endpoint retrieves all kittens
GET http://example.com/kittens
Parameter | Default | Description |
---|---|---|
include_cats |
false |
If set to true , the result will also include cats. |
available |
true |
If set to false , the result will include kittens that have already been adopted. |
curl "http://example.com/api/kittens/3"
-H "Authorization: meowmeowmeow"
The above command returns JSON structured like this:
{
"id": 2,
"name": "Isis",
"breed": "unknown",
"fluffiness": 5,
"cuteness": 10
}
This endpoint retrieves a specific kitten.
GET http://example.com/kittens/<ID>
Parameter | Description |
---|---|
ID |
The ID of the cat to retrieve. |