项目作者: MatthiasELISEE

项目描述 :
Open-source MIT-licensed offline bible api to get passages from references in 36+ languages
高级语言: Python
项目地址: git://github.com/MatthiasELISEE/free_python_bible_api.git
创建时间: 2018-08-23T08:40:20Z
项目社区:https://github.com/MatthiasELISEE/free_python_bible_api

开源协议:MIT License

下载


free_python_bible_api

Quickstart

You need an OSIS xml bible to proceed.

You can find them here : https://github.com/bzerangue/osis-bibles

Before getting verses you need to set the Bible file.

  1. import free_bible_api
  2. free_bible_api.set_bible("kjv.xml")

Getting verses in natural language

There are 2 different ways to get verses :

  1. # Get verses from reference in French or English (they must be separated by semi-colons)
  2. print(free_bible_api.text_from_references("Am 3:4-6; jude 4,6; Gen7.8"))
  3. # The Bible can be in whatever language you want, but the reference must be in French or English.
  4. # Get verse from OSIS id :
  5. print(free_bible_api.text_from_osisID("Gen.5.4"))

You can also just translate a reference in French or English to an clean OSIS id.

  1. # Reference to OSIS ID translator
  2. print(free_bible_api.osisID_from_reference("Genesis 5: 4"))
  3. # prints :
  4. # Gen.5.4

Use it as much as you want, and please report bugs.

1 Corinthians 10:31 Whether therefore ye eat, or drink, or whatsoever ye do, do all to the glory of God.