Developer Tools: API

Application Programming Interface (API)

Tags

Tags are annotations applied to selected Bible verses. Tags belong to users. Individual tags retrieved via API will also include the verse references to which they refer.

List

GET /tags.xml

Returns all, site-wide tags.

Note: This request for all tags will not include their verse references.

Example:

Request
GET https://biblesearch.americanbible.org/tags.xml
Response
<?xml version="1.0" encoding="utf-8"?>
<tags>
  <tag id="1">
    <id>1</id>
    <name><![CDATA[locusts]]></name>
  </tag>
  <tag id="2">
    <id>2</id>
    <name><![CDATA[universe]]></name>
  </tag>
  <tag id="3">
    <id>3</id>
    <name><![CDATA[beginning]]></name>
  </tag>
  <tag id="4">
    <id>4</id>
    <name><![CDATA[the]]></name>
  </tag>
  <tag id="5">
    <id>5</id>
    <name><![CDATA[salt]]></name>
  </tag>
  <tag id="6">
    <id>6</id>
    <name><![CDATA[tale]]></name>
  </tag>
</tags>

GET /user/tags.xml

Returns a list of tags for your user.

Note: This request for all tags will not include their verse references.

Example:

Request
GET https://biblesearch.americanbible.org/user/tags.xml
Response
<?xml version="1.0" encoding="utf-8"?>
<tags>
  <tag id="257">
    <id>257</id>
    <name><![CDATA[son of god]]></name>
  </tag>
  <tag id="258">
    <id>258</id>
    <name><![CDATA[possessions]]></name>
  </tag>
</tags>

Show

GET /tags/#{tag_id}.xml

Returns the tag identified by the specified ID. Tag IDs are numbers and can be found by listing all tags or a listing a user's tags.

Example:

Request
GET https://biblesearch.americanbible.org/tags/258.xml
Response
<?xml version="1.0" encoding="utf-8"?>
<tags>
  <tag id="258">
    <id>258</id>
    <name><![CDATA[possessions]]></name>
    <references>
      <reference>
        <start>GNT:John.3.27</start>
        <end>GNT:John.3.27</end>
      </reference>
    </references>
  </tag>
</tags>

GET /tags/#{tag_name}.xml

For convenience, you may also retrieve tags by name. Make sure you properly URL encode the tag name.

Example:

Request
GET https://biblesearch.americanbible.org/tags/possessions.xml
Response
<?xml version="1.0" encoding="utf-8"?>
<tags>
  <tag id="258">
    <id>258</id>
    <name><![CDATA[possessions]]></name>
    <references>
      <reference>
        <start>GNT:John.3.27</start>
        <end>GNT:John.3.27</end>
      </reference>
    </references>
  </tag>
</tags>

Create

Create (POST) requests are not allowed for tag resources. To create a tag you must create a tagging resource.

Update

Update (PUT) requests are not allowed for tag resources. To edit a tag, you must make a request to its tagging resource.

Delete

Delete (DELETE) requests are not allowed for tag resources. To delete a tag, you must delete its corresponding tagging resource.