Documentation Index Fetch the complete documentation index at: https://rocks.docs.rive.wtf/llms.txt
Use this file to discover all available pages before exploring further.
API Key Authentication
All endpoints require a Bearer token. Send your API key in the Authorization header on every request.
Getting Your API Key
DM southctrl
DM southctrl on Discord to apply for a key
Wait for Review
Keys are approved manually
Receive Your Key
If approved, you will receive your key in Discord DMs
Store Securely
Store your key safely, preferably in environment variables
Every key is assigned to one IP . Do not share or reuse your key across different IPs.
Include this header in every request:
Authorization: Bearer YOUR_API_KEY
Example Requests
cURL
JavaScript
Python
Node.js (axios)
curl -X GET "https://rocks.rive.wtf/api/bible/random?translation=web" \
-H "Authorization: Bearer YOUR_API_KEY"
Using Environment Variables
Do not hardcode your API key. Use environment variables whenever possible.
Node.js
Python
Discord.js Bot
// .env file
ROCKS_API_KEY = your_api_key_here
// In your code
require ( 'dotenv' ). config ();
const API_KEY = process . env . ROCKS_API_KEY ;
const response = await fetch ( 'https://rocks.rive.wtf/api/endpoint' , {
headers: {
'Authorization' : `Bearer ${ API_KEY } `
}
});
# .env file
ROCKS_API_KEY = your_api_key_here
# In your code
import os
from dotenv import load_dotenv
load_dotenv()
API_KEY = os.getenv( 'ROCKS_API_KEY' )
headers = { 'Authorization' : f 'Bearer { API_KEY } ' }
response = requests.get( 'https://rocks.rive.wtf/api/endpoint' , headers = headers)
// config.json (DO NOT commit to git)
{
"token" : "your_discord_bot_token" ,
"rocksApiKey" : "your_api_key_here"
}
// In your bot
const config = require ( './config.json' );
const response = await fetch ( 'https://rocks.rive.wtf/api/endpoint' , {
headers: {
'Authorization' : `Bearer ${ config . rocksApiKey } `
}
});
Rules and Best Practices
Environment Variables Store your key in environment variables, not in source code
Gitignore Files Add .env and other secret files to .gitignore
One Key, One IP Each key is tied to one IP
Need Help? DM southctrl on Discord if you need help with your key
Every key is assigned to one IP
You must DM southctrl on Discord to apply for a key
Never post your key in GitHub, Discord servers, or public code
If your key is exposed, DM southctrl immediately
Rate Limiting
The API uses rate limits to keep usage fair:
Standard: 100 requests per minute
Burst: 10 requests per second
If you need higher limits, DM southctrl on Discord with your use case.
Use exponential backoff if you receive 429: async function makeRequestWithRetry ( url , retries = 3 ) {
for ( let i = 0 ; i < retries ; i ++ ) {
const response = await fetch ( url , {
headers: { 'Authorization' : `Bearer ${ API_KEY } ` }
});
if ( response . status !== 429 ) {
return response . json ();
}
// Wait before retrying (exponential backoff)
await new Promise ( resolve => setTimeout ( resolve , 1000 * Math . pow ( 2 , i )));
}
throw new Error ( 'Rate limit exceeded' );
}
Error Responses
If authentication fails, you may receive:
Status Code Description Solution 401 Missing or invalid API key Check your key and header format 403 API key doesn’t have permission DM southctrl if you need access 429 Rate limit exceeded Wait and try again later 500 Server error Try again later or ask for support
Example Error Response
{
"success" : false ,
"error" : {
"code" : 401 ,
"message" : "Invalid or missing API key" ,
"details" : "Please provide a valid API key in the Authorization header"
}
}
Test Your Key
Use this request to check whether your key works:
curl -X GET "https://rocks.rive.wtf/api/bible/random?translation=web" \
-H "Authorization: Bearer YOUR_API_KEY" \
-w "\nStatus: %{http_code}\n"
Need Help?
Contact Support Discord: southctrlDM for key applications, authentication help, or compromised keys.
Treat your API key like a password.