|
API Description: Subjects Collection Specifics
The 'subjects' collection provides information about book subjects. To
retrieve corresponding books you can use 'subject_id' to search in the books collection.
The base URL for the subjects collection access is:
http://isbndb.com/api/subjects.xml
Arguments
Subjects collection supports the following indexes:
- name
- Performs a search on the subject name. For example:
/api/subjects.xml?access_key=Z&index1=name&value1=astronomy+teaching
The search follows the same rules and syntax as the
search on the website itself -- you can group words together using
double quotes, all non-ignored words must be present in the results.
- category_id
- Retrieving subjects listed in the given category by that category ID.
Example:
/api/subjects.xml?access_key=Z&index1=category_id&value1=science.biology.history
- subject_id
- Retrieving subject data by ISBNdb.com's subject ID. Returns at most
one match. Example:
/api/subjects.xml?access_key=Z&index1=subject_id&value1=molecular_biology
Results
By default, if no additional 'results' values specified, the book
subjects collection returns only a set of SubjectData/Name tag
pairs. For example:
/api/subjects.xml?access_key=Z&index1=name&value1=orthodontics+questions
<?xml version="1.0" encoding="UTF-8"?>
<ISBNdb server_time="2006-01-13T12:13:14">
<SubjectList total_results="2" page_size="10" page_number="1" shown_results="2">
<SubjectData subject_id="orthodontics_examinations_questions_etc" book_count="2"
marc_field="652" marc_indicator_1="" marc_indicator_2="">
<Name>Orthodontics -- Examinations, questions, etc</Name>
</SubjectData>
<SubjectData subject_id="orthodontics_diagnosis_examinations_questions_etc" book_count="3"
marc_field="650" marc_indicator_1="" marc_indicator_2="0">
<Name>Orthodontics -- Diagnosis -- Examinations, questions, etc</Name>
</SubjectData>
</SubjectList>
</ISBNdb>
In addition to common 'results' blocks the
book subjects collection adds some that are subjects specific. The
syntax remains the same -- comma separated values in the 'results'
argument.
- categories
- Shows a list of categories this subject is listed in. For example:
/api/subjects.xml?access_key=Z&results=categories&index1=subject_id&value1=love_poetry_english
<?xml version="1.0" encoding="UTF-8"?>
<ISBNdb server_time="2006-01-19T16:14:16">
<SubjectList total_results="1" page_size="10" page_number="1" shown_results="1">
<SubjectData subject_id="love_poetry_english" book_count="36" marc_field="650" marc_indicator_1="0" marc_indicator_2="">
<Name>Love poetry, English</Name>
<Categories>
<Category category_id="genres.poetry.love">Love</Category>
<Category category_id="society.interpersonal_relations.love.poetry">Poetry</Category>
</Categories>
</SubjectData>
</SubjectList>
</ISBNdb>
- structure
- Shows what the subject consists of. For example:
/api/subjects.xml?access_key=Z&results=structure&index1=subject_id&value1=artificial_intelligence_data_processing
<?xml version="1.0" encoding="UTF-8"?>
<ISBNdb server_time="2006-01-13T12:13:14">
<SubjectList total_results="1" page_size="10" page_number="1" shown_results="1">
<SubjectData subject_id="artificial_intelligence_data_processing" book_count="95"
marc_field="650" marc_indicator_1="0" marc_indicator_2="">
<Name>Artificial intelligence -- Data processing</Title>
<SubjectStructure>
<SubjectElement text="Artificial intelligence" type="Topical Term" marc_subfield="a"/>
<SubjectElement text="Data Processing" type="General" marc_subfield="x"/>
</SubjectStructure>
</SubjectData>
</SubjectList>
</ISBNdb>
Attributes in the SubjectData tag have the following meaning:
- marc_field - where available this represents the value corresponding to MARC standard.
See http://www.loc.gov/marc/bibliographic/ecbdhome.html
for details.
- marc_indicator_1 and marc_indicator_2 - two characters from this
MARC record's indicator columns, where available.
Attributes in the SubjectElement tag have the following meaning:
- text - literal text of the subject element. Typically, but not in
all cases, subject name is formed by combining texts of its elements
separated by double-dash.
- type - an ISBNdb.com specific type loosely based on the
MARC field and subfield information.
- marc_subfield - MARC subfield symbol, where available.
|