API
Use our API to search the Bible or fetch verses from the free external bible-api.com (no key required).
Base URL: http://localhost/api
For JSON listing of endpoints: http://localhost/api
Endpoints
| Method | Description | Example URL |
|---|---|---|
| GET | Returns all endpoints and base URL as JSON. | http://localhost/api |
| GET | Search verses in your database by text. | http://localhost/api/bible/search?q=beginning&lang=en&limit=20 |
| GET | Fetch verse(s) from bible-api.com (free, no key). Params: reference (required), translation (optional). | http://localhost/api/bible/external?reference=john%203:16&translation=kjv |
| GET | Get a random verse from bible-api.com. Params: translation, book (OT/NT or book IDs). | http://localhost/api/bible/external/random?translation=web&book=NT |
| GET | path= (translations), path=web (books), path=web/JHN (chapters), path=web/JHN/3 (verses). | http://localhost/api/bible/external/data?path=web |
External Bible API (bible-api.com)
We integrate with bible-api.com: free, no API key, CORS enabled. Use the /api/bible/external and /api/bible/external/random and /api/bible/external/data endpoints above. Translations: web, kjv, asv, bbe, darby, and more.