Developer Tools: API

Application Programming Interface (API)

Passages

GET /passages.xml?q[]=#{passage_specifier_list}

GET /passages.xml?q[]=#{passage_specifier_list}&version=#{version_id_list}

Returns a structured response containing a collection of references to passages specified by the q[] querystring parameter. One or more Bible versions may be specified by the version parameter. Misspelled book names or abbreviations will be corrected if possible.

The passage specifier is in the form "Book+chapters:verses". Multiple specifiers can be included in a comma-separated list. Examples: "John+3", "John+3-5", "John+3:12", "John+3:12-15", "John+3,Luke+2".

The available version IDs can be listed with the versions endpoint. Multiple version IDs can be included in a comma-separated list. Examples: "KJV", "GNT,CEV".

It's important to note that the response only contains references to the passage(s), and a preview of the first three verses of the passage(s) themselves. To fetch the full Bible text of each passage you will need to issue another request to the URL of the passage/version combination you'd like.

Single passage, single version example:

Request
GET https://biblesearch.americanbible.org/passages.xml?q[]=john+3:1-5&version=KJV
Response
<?xml version="1.0" encoding="utf-8" ?>
<search>
  <result>
    <type>passages</type>
    <passages>
      <passage>
        <display>John 3:1-5</display>
        <version>KJV</version>
        <path>/chapters/KJV:John.3/verses.xml?start=1&end=5</path>
        <text_preview>
          <![CDATA[<span class="para"><span class="v43_3_1"><sup class="v43_3_1">1</sup>There was a man of the Pharisees, named Nicode'mus, a ruler of the Jews:</span></span> <span class="para"><span class="v43_3_2"><sup class="v43_3_2">2</sup>the same came to Jesus by night, and said unto him, Rabbi, we know that thou art a teacher come from God: for no man can do these miracles that thou doest, except God be with him.</span></span> <span class="para"><span class="v43_3_3"><sup class="v43_3_3">3</sup>Jesus answered and said unto him, Verily, verily, I say unto thee, Except a man be born again,* he cannot see the kingdom of God.</span></span> ]]>
        </text_preview>
        <chapter_id>KJV:John.3</chapter_id>
        <start_verse>1</start_verse>
        <end_verse>5</end_verse>
      </passage>
      </passages>
    </result>
</search>

Single passage, multiple versions example:

Request
GET https://biblesearch.americanbible.org/passages.xml?q[]=john+3:1-5&version=KJV,GNT
Response
<?xml version="1.0" encoding="utf-8"?>
<search>
  <result>
    <type>passages</type>
    <passages>
      <passage>
        <display>John 3:1-5</display>
        <version>KJV</version>
        <path>/chapters/KJV:John.3/verses.xml?start=1&end=5</path>
        <text_preview>
          <![CDATA[<span class="para"><span class="v43_3_1"><sup class="v43_3_1">1</sup>There was a man of the Pharisees, named Nicode'mus, a ruler of the Jews:</span></span> <span class="para"><span class="v43_3_2"><sup class="v43_3_2">2</sup>the same came to Jesus by night, and said unto him, Rabbi, we know that thou art a teacher come from God: for no man can do these miracles that thou doest, except God be with him.</span></span> <span class="para"><span class="v43_3_3"><sup class="v43_3_3">3</sup>Jesus answered and said unto him, Verily, verily, I say unto thee, Except a man be born again,* he cannot see the kingdom of God.</span></span> ]]>
        </text_preview>
        <chapter_id>KJV:John.3</chapter_id>
        <start_verse>1</start_verse>
        <end_verse>5</end_verse>
      </passage>
      <passage>
        <display>John 3:1-5</display>
        <version>GNT</version>
        <path>/chapters/GNT:John.3/verses.xml?start=1&end=5</path>
        <text_preview>
          <![CDATA[<span class="para"><span class="v43_3_1"><sup class="v43_3_1">1</sup>There was a Jewish leader named Nicodemus, who belonged to the party of the Pharisees.
          </span></span> <span class="para"><span class="v43_3_2"><sup class="v43_3_2">2</sup>One night he went to Jesus and said to him,  
          “Rabbi, we know that you are a teacher sent by God. No one could perform the miracles you are doing unless God were with him.”
          </span></span> <span class="para"><span class="v43_3_3"><sup class="v43_3_3">3</sup>Jesus answered,  
          “I am telling you the truth: no one can see the Kingdom of God without being born again.”
          </span></span> ]]>
        </text_preview>
        <chapter_id>GNT:John.3</chapter_id>
        <start_verse>1</start_verse>
        <end_verse>5</end_verse>
      </passage>
    </passages>
  </result>
</search>

Note that multiple versions are specified as a comma-separated list of version abbreviations.

If you aren't sure how many verses a chapter has, you can pass in the special '-ff' keyword as the end verse to a passage search. The response will fill in the final verse for you in the display, end_verse and path elements.

Example:

Request
GET https://biblesearch.americanbible.org/passages.xml?q[]=john+3:16-ff&version=KJV
Response
<?xml version="1.0" encoding="utf-8"?>
<search>
  <result>
    <type>passages</type>
    <passages>
      <passage>
        <display>John 3:16-36</display>
        <version>KJV</version>
        <path>/chapters/KJV:John.3/verses.xml?start=16&end=36</path>
        <text_preview>
          <![CDATA[<span class="para"><span class="v43_3_16"><sup class="v43_3_16">16</sup>For God so loved the world, that he gave his only begotten Son, that whosoever believeth in him should not perish, but have everlasting life.</span></span> <span class="para"><span class="v43_3_17"><sup class="v43_3_17">17</sup>For God sent not his Son into the world to condemn the world; but that the world through him might be saved.</span></span> <span class="para"><span class="v43_3_18"><sup class="v43_3_18">18</sup>He that believeth on him is not condemned: but he that believeth not is condemned already, because he hath not believed in the name of the only begotten Son of God.</span></span> ]]>
        </text_preview>
        <chapter_id>KJV:John.3</chapter_id>
        <start_verse>16</start_verse>
        <end_verse>36</end_verse>
      </passage>
    </passages>
  </result>
</search>