getSpellingSuggestions
- Information returned
- Strings similar to a specified string
- Service domain
- https://rxnav.nlm.nih.gov
- HTTP request
- GETÂ /REST/spellingsuggestions.xml?name=value
Description
Get spelling suggestions for a given term (the name parameter). The suggestions are RxNorm terms contained in the current version, listed in decreasing order of closeness to the original phrase.
Scope
Active: concepts in the current RxNorm data set that have an atom with SAB=RXNORM and SUPPRESS=N
Parameters
| Parameter | Location | Use | Description | Default |
|---|---|---|---|---|
| format | Path | Optional | Notation for results One of:
| .xml |
| name | Query | Required | Possibly misspelled term |
All query parameters are case-insensitive.
Output structure
Results are available as either XML or JSON.
The XML result has the root element rxnormdata. It is described in the XML Schema for the RxNorm API; the relevant element structure is summarized below. Elements that would be empty might be left out.
The JSON result is an object {...}, analogous to the content of the XML rxnormdata. Fields that might occur multiple times in the XML are expressed as an array. Fields that would be empty might be null or left out. Numbers are expressed as strings.
Both XML and JSON results follow the same outline:
- rxnormdata
- Root element in XML, or anonymous object in JSON
- suggestionGroup
- name
- Misspelled term
- suggestionList
- suggestion (array)
- RxNorm term
Example: Terms like "ambienn"
XML: https://rxnav.nlm.nih.gov/REST/spellingsuggestions?name=ambienn
JSON: https://rxnav.nlm.nih.gov/REST/spellingsuggestions.json?name=ambienn
An XML result is shown below.
<rxnormdata>
<suggestionGroup>
<name>ambienn</name>
<suggestionList>
<suggestion>Ambien</suggestion>
<suggestion>amber</suggestion>
<suggestion>Ammens</suggestion>
<suggestion>Amrinon</suggestion>
<suggestion>aspirin</suggestion>
<suggestion>amrinone</suggestion>
<suggestion>apigenin</suggestion>
<suggestion>arbutin</suggestion>
<suggestion>algin</suggestion>
<suggestion>alizan</suggestion>
</suggestionList>
</suggestionGroup>
</rxnormdata>