API that creates customized images of Bible verses. Ideal for social media, presentations, and personal reflection.
To install this API, clone the repository and install the dependencies:
git clone https://github.com/your-username/bible-art-maker-api.git
cd bible-art-maker-api
pip install -r requirements.txt
To start the API server, run the following command:
uvicorn main:app --reload
or
python main.py
This will start the API on port 8777 or the configured IP and Port.
The following API endpoints are available:
GET /v1/bible/books
Return:
Returns a list of all books in the Bible.
["Gênesis", ..., "Apocalipse"]
POST /v1/bible/verse
Retrieves the text of a specific verse or range of verses from the Bible.
Available bible versions:
nvi
: Nova Versão Internacionalacf
: Almeida Corrigida Fielaa
: Almeida Atualizada
Args:
verse_request (VerseRequest)
: The request object containing the version, book, chapter, and verse range.
Return:
The response object containing the requested verse(s) text.
{
"version": "nvi",
"book": "João",
"chapter": 16,
"start_verse": 33,
"end_verse": 33,
"response": "Eu lhes disse essas coisas para que em mim vocês tenham paz. Neste mundo vocês terão aflições; contudo, tenham ânimo! Eu venci o mundo."
}
POST /v1/image/verse
Generates an image with the requested Bible verse.
Available bible versions:
nvi
: Nova Versão Internacionalacf
: Almeida Corrigida Fielaa
: Almeida Atualizada
Args:
verse_request (VerseRequest)
: The request object containing the version, book, chapter, verse range and mobile flag.
Return:
FileResponse
: The image file.
NVI:
ACF:
AA:
The API documentation is available at http://localhost:8777/docs
or http://localhost:8777/redoc
. You can use the documentation to explore the available endpoints and test them out.
This package is licensed under the GNU License. See the LICENSE file for details.
If you find a bug or have a feature request, please open an issue on the repository. If you would like to contribute code, please fork the repository and submit a pull request.
Before submitting a pull request, please make sure that your code adheres to the following guidelines:
- Follow the PEP 8 style guide.
- Write docstrings for all functions and classes.
- Write unit tests for all functions and classes.
- Make sure that all tests pass by running pytest.
- Keep the code simple and easy to understand.