Term details

Provides detailed information about a given thesaurus term, which may be specified by its unique identifier or by the text of its descriptor. If a text is given as input and the text matches a USE-WITH term, the result will be an array describing the two descriptors to which the USE-WITH term applies.

Service URL https://apps.usgs.gov/thesaurus/term.php
thcode Thesaurus identifier; if not specified, the USGS Thesaurus will be used
code Unique identifier of the descriptor
text Text of the descriptor, if descriptors are distinct in the specified thesaurus
callback Name of a function in which to wrap the results, to support JSONP
Output A single object or an array of two objects containing the following members:
thcode Thesaurus identifier
term Single term object specifying the term, as follows:
code Unique identifier for this term
name Descriptor text for this term
parent Unique identifier of the parent of this term
scope Scope note for the term
uf Array of objects specifying USE-FOR and USE-WITH relationships:
name Text of the non-preferred term
usewith false for a simple non-preferred term, or a term object if the text is to be used for both the given descriptor and another descriptor together
bt Array of term objects specifying the broader terms, each the parent of the previous entry
nt Array of term objects specifying the narrower terms
rt Array of term objects specifying the related terms

Special cases

  1. If no parameters are given, the service returns an array of objects describing the thesauri that are available in the current database instance: https://apps.usgs.gov/thesaurus/term.php
  2. If a valid thesaurus code is given but neither a term code nor a descriptor is given, the root node of the thesaurus will be returned: https://apps.usgs.gov/thesaurus/term.php?thcode=2
  3. If a text given as input matches a USE-WITH term, an array of descriptors will be returned, each as described for a single term, above. https://apps.usgs.gov/thesaurus/term.php?thcode=2&text=oil%20spills
  4. If a pair of terms is given as input with " AND " between them, the two terms are matched separately and an array of descriptors will be returned, each as described for a single term, above. https://apps.usgs.gov/thesaurus/term.php?thcode=2&text=industrial%20pollution%20AND%20petroleum