Vibe Affirmations API
🆓 Try Demo Mode - No Auth RequiredTest the API instantly without any authentication:
# Get a sample affirmation - any vibe!
curl "https://vibe-affirmations.p.rapidapi.com/demo/affirmation?vibe=cosmic"
# Browse all 9 vibes with examples
curl "https://vibe-affirmations.p.rapidapi.com/demo/vibes"
Once you're ready for production, choose your plan:
curl -X GET "https://vibe-affirmations.p.rapidapi.com/affirmation/daily?vibe=hype" \
-H "X-RapidAPI-Key: YOUR_API_KEY" \
-H "X-RapidAPI-Host: vibe-affirmations.p.rapidapi.com"
Response:
{
"vibe": "hype",
"affirmation": "Let's go! You're crushing it!",
"source": "cached-daily-drop"
}
Use the code examples below to integrate into your application.
const axios = require('axios');
async function getDailyAffirmation(vibe = 'hype') {
try {
const response = await axios.get(
`https://vibe-affirmations.p.rapidapi.com/affirmation/daily?vibe=${vibe}`,
{
headers: {
'X-RapidAPI-Key': process.env.RAPIDAPI_KEY,
'X-RapidAPI-Host': 'vibe-affirmations.p.rapidapi.com'
}
}
);
console.log(response.data.affirmation);
return response.data;
} catch (error) {
console.error('Error fetching affirmation:', error);
}
}
// Usage
getDailyAffirmation('stoic');
import requests
import os
def get_daily_affirmation(vibe='hype'):
url = "https://vibe-affirmations.p.rapidapi.com/affirmation/daily"
headers = {
"X-RapidAPI-Key": os.getenv('RAPIDAPI_KEY'),
"X-RapidAPI-Host": "vibe-affirmations.p.rapidapi.com"
}
params = {"vibe": vibe}
response = requests.get(url, headers=headers, params=params)
if response.status_code == 200:
data = response.json()
print(data['affirmation'])
return data
else:
print(f"Error: {response.status_code}")
return None
# Usage
get_daily_affirmation('zen')
import { useState, useEffect } from 'react';
export default function AffirmationWidget({ vibe = 'hype' }) {
const [affirmation, setAffirmation] = useState(null);
const [loading, setLoading] = useState(true);
useEffect(() => {
async function fetchAffirmation() {
try {
const response = await fetch(
`/api/affirmation?vibe=${vibe}`
);
const data = await response.json();
setAffirmation(data.affirmation);
} catch (error) {
console.error('Error:', error);
} finally {
setLoading(false);
}
}
fetchAffirmation();
}, [vibe]);
if (loading) return Loading...;
return (
{affirmation}
{vibe}
);
}
| Endpoint | Auth Required | Description |
|---|---|---|
GET /demo/affirmation |
❌ No | Try any vibe without authentication (100/day) |
GET /demo/vibes |
❌ No | List all vibes with examples |
GET /affirmation/daily |
✅ Yes | Cached affirmation (<10ms) |
GET /affirmation/random |
✅ Yes | Random affirmation from vibe |
GET /affirmation/bulk |
✅ Yes | Get 10 affirmations at once |
POST /affirmation/live |
✅ Yes + OpenAI Key | Custom AI-generated affirmations |
GET /vibes |
✅ Yes | List accessible vibes for your tier |
Marcus Aurelius wisdom for philosophical strength
"The obstacle is the way."
High-energy motivation to get pumped
"Let's go! You're crushing it!"
Tough love with playful sass
"At least you tried."
Mindfulness and inner peace
"Breathe in peace, breathe out tension."
Unapologetic confidence and boss energy
"They doubted you. Prove them wrong."
Intellectual curiosity and wisdom
"Knowledge is the investment that pays the best interest."
Universal perspective and existential awe
"You are stardust with consciousness."
Compassionate validation and support
"Your feelings are valid."
Military precision and discipline
"Drop and give me 20 reasons you'll succeed!"
# .env file
RAPIDAPI_KEY=your_rapidapi_key_here
RAPIDAPI_HOST=vibe-affirmations.p.rapidapi.com