Awesome
meowfacts
Description:
A simple api that returns a random fact about cats on a GET request
Example Usage
curl https://meowfacts.herokuapp.com/
Response
{
"data": [
"0": "Mother cats teach their kittens to use the litter box."
]
}
Advanced Usage
You can request more than one fact at a time by using the GET param count
curl https://meowfacts.herokuapp.com/?count=3
Response
{
"data": [
"0": "Mother cats teach their kittens to use the litter box.",
"1": "A cat can sprint at about thirty-one miles per hour.",
"2": "The worlds richest cat is worth $13 million after his human passed away and left her fortune to him."
]
}
You can request a specific fact if you know the ID / order it is buy passing the GET param id
curl https://meowfacts.herokuapp.com/?id=3
Response
{
"data": [
"0": "Mother cats teach their kittens to use the litter box."
]
}
Language Support
You can request the response in different languages by using the GET param lang
curl https://meowfacts.herokuapp.com/?lang=ukr
Response
{
"data": [
"0": "Найбагатший у світі кіт коштує 13 мільйонів доларів після того, як його людина померла і залишила йому свій стан"
]
}
Supported Languages
The supported languages are listed below, you can use any of the lang Values
in the first column as a lang
param.
"?lang=esp" and "?lang=esp-mx" will both return spanish for your response, and simply using the ISO-639-1
code will default to esp-mx for simplicity.
LANG Variable | ISO 639-1 | Language Name | Localization (country) |
---|---|---|---|
eng-us | eng | English | USA |
ces-cz or cze-cz | cze (B) ces (T) | Czech | CZ |
ger-de | ger | German | DE |
ben-in | ben | Bengali | IN |
esp-es | esp | Spanish | ES |
esp-mx | esp | Spanish (default) | MX |
rus-ru | rus | Russian | RUS |
por-br | por | Portuguese | BR |
tl-fil | fil | Filipino | PH |
ukr-ua | ukr | Ukrainian | UA |
urd-ur | urd | Urdu | UR |
ita-it | ita | Italian | IT |
zho-tw | zho | Chinese | TW (Taiwan) |
kor-ko | kor | Korean | KO |
Documentation
<div align="center"> <p> <a href="https://app.swaggerhub.com/apis-docs/wh-iterabb-it/meowfacts/1.0.0"> <img width="200" height="72" src="https://raw.githubusercontent.com/swagger-api/swagger.io/wordpress/images/assets/SW-logo-clr.png" /> </a> </p> <p> <a href="https://rapidapi.com/wh-iterabb-it-wh-iterabb-it-default/api/meowfacts/"> <img width="200" height="52" src="https://rapidapi.com/static-assets/default/dark-logo-78e48dc1-ca3f-4d67-a6f5-74032f439c8b.svg" /> </a> </p> <p> <a href="https://meow-facts.netlify.app/"> <img width="200" height="52" src="https://img.shields.io/badge/Community_Documentation-FFFFFF.svg?logo=bookstack&logoColor=blue&style=for-the-badge" /> </a> </p> </div>Local Development
Installation
npm install
Basic usage
npm run start