# Clinical Tables — Zapi reference > NLM Clinical Table Search Service — 22 keyless code systems including LOINC, ICD-10-CM, ICD-11, RxTerms, HPO, HCPCS, NPI, UCUM and genomics tables. **Base URL:** `https://api.zpi.web.id` **Auth:** Send `x-api-key: YOUR_KEY` header on every request. Get a free key at https://zpi.web.id/dashboard/keys. **Response envelope:** `{ content, message, errors }` **Rate limit:** 60 req/min on free tier. **Related:** - Detail page: https://zpi.web.id/api/health/clinical-tables - Endpoint catalog: https://zpi.web.id/category/health - Concise index: https://zpi.web.id/llms.txt - Full reference: https://zpi.web.id/llms-full.txt --- ## Clinical Tables **Category:** health · **Slug:** `clinical-tables` **Detail page:** https://zpi.web.id/api/health/clinical-tables NLM Clinical Table Search Service — 22 keyless code systems including LOINC, ICD-10-CM, ICD-11, RxTerms, HPO, HCPCS, NPI, UCUM and genomics tables. **Tags:** loinc, icd10, icd11, rxterms, nlm, terminology, medical-codes ### Answer List LOINC answer list for one question code — clinicaltables.nlm.nih.gov, direct JSON. Sits outside the /api//v3/search grammar: its own path, one code in, - **Method:** `GET` - **Endpoint:** `https://api.zpi.web.id/v1/health:clinical-tables/answer-list` - **Cache TTL:** 300s **Parameters:** | Name | Type | Location | Required | Description | |------|------|----------|----------|-------------| | `loincNum` | string | query | yes | LOINC code of the question whose answer list to return | **cURL:** ```bash curl "https://api.zpi.web.id/v1/health:clinical-tables/answer-list?loincNum=45592-3" \ -H "x-api-key: YOUR_API_KEY" ``` **JavaScript / TypeScript:** ```javascript const res = await fetch("https://api.zpi.web.id/v1/health:clinical-tables/answer-list?loincNum=45592-3", { headers: { "x-api-key": process.env.ZAPI_KEY } }); const data = await res.json(); ``` **Python:** ```python import requests r = requests.get("https://api.zpi.web.id/v1/health:clinical-tables/answer-list?loincNum=45592-3", headers={"x-api-key": "YOUR_API_KEY"}) data = r.json() ``` **Example response:** ```json { "count": 7, "items": [ { "code": "LA12637-7", "text": "Independent - no help or staff oversight at any time", "sequence": 1 }, { "code": "LA12638-5", "text": "Supervision - oversight, encouragement or cueing", "sequence": 2 }, { "code": "LA12639-3", "text": "Limited assistance - resident highly involved in activity; staff provide guided maneuvering of limbs or other non-weight-bearing assistance", "sequence": 3 }, { "code": "LA12640-1", "text": "Extensive assistance - resident involved in activity, staff provide weight-bearing support", "sequence": 4 }, { "code": "LA12641-9", "text": "Total dependence - full staff performance every time during entire 7-day period", "sequence": 5 }, { "code": "LA12642-7", "text": "Activity occurred only once or twice - activity did occur but only once or twice", "sequence": 6 }, { "code": "LA18614-0", "text": "Activity did not occur - activity did not occur or family and/or non-facility staff provided care 100% of the time for that activity over the entire 7-day period", "sequence": 7 } ], "loincNum": "45592-3", "provider": "clinical-tables" } ``` --- ### Conditions Problem-list conditions — clinicaltables.nlm.nih.gov `conditions`, direct JSON, no key. The service answers with a positional array [total, codes, extra, displayRows] - **Method:** `GET` - **Endpoint:** `https://api.zpi.web.id/v1/health:clinical-tables/conditions` - **Cache TTL:** 300s **Parameters:** | Name | Type | Location | Required | Description | |------|------|----------|----------|-------------| | `terms` | string | query | yes | Search text. Several partial words are combined with an implicit AND | | `page` | number | query | no | Page number. Default 1 | | `limit` | number | query | no | Items per page. Default 10, max 500. Page times limit may not exceed 7500 | | `fields` | string | query | no | Comma-separated fields returned as display strings. Allowed: primary_name, consumer_name, key_id, icd10cm_codes, icd10cm, term_icd9_code, term_icd9_text, word_synonyms, synonyms, info_link_data. | | `extraFields` | string | query | no | Comma-separated fields returned with their native types, so objects and arrays stay structured. Accepts field:alias. Allowed: primary_name, consumer_name, key_id, icd10cm_codes, icd10cm, term_icd9_code, term_icd9_text, word_synonyms, synonyms, info_link_data. | | `searchFields` | string | query | no | Comma-separated fields the search text is matched against. Allowed: primary_name, consumer_name, key_id, icd10cm_codes, icd10cm, term_icd9_code, term_icd9_text, word_synonyms, synonyms, info_link_data. | | `codeField` | string | query | no | The single field to report as each item's code. Allowed: primary_name, consumer_name, key_id, icd10cm_codes, icd10cm, term_icd9_code, term_icd9_text, word_synonyms, synonyms, info_link_data. | | `filter` | string | query | no | Elasticsearch query-string filter applied on top of the search text. It is not wildcarded automatically | **cURL:** ```bash curl "https://api.zpi.web.id/v1/health:clinical-tables/conditions?terms=asthma&page=1&limit=10&fields=primary_name%2Cconsumer_name%2Ckey_id&extraFields=synonyms%2Cword_synonyms&searchFields=primary_name%2Cconsumer_name%2Ckey_id&codeField=key_id&filter=primary_name%3Aasthma*" \ -H "x-api-key: YOUR_API_KEY" ``` **JavaScript / TypeScript:** ```javascript const res = await fetch("https://api.zpi.web.id/v1/health:clinical-tables/conditions?terms=asthma&page=1&limit=10&fields=primary_name%2Cconsumer_name%2Ckey_id&extraFields=synonyms%2Cword_synonyms&searchFields=primary_name%2Cconsumer_name%2Ckey_id&codeField=key_id&filter=primary_name%3Aasthma*", { headers: { "x-api-key": process.env.ZAPI_KEY } }); const data = await res.json(); ``` **Python:** ```python import requests r = requests.get("https://api.zpi.web.id/v1/health:clinical-tables/conditions?terms=asthma&page=1&limit=10&fields=primary_name%2Cconsumer_name%2Ckey_id&extraFields=synonyms%2Cword_synonyms&searchFields=primary_name%2Cconsumer_name%2Ckey_id&codeField=key_id&filter=primary_name%3Aasthma*", headers={"x-api-key": "YOUR_API_KEY"}) data = r.json() ``` **Example response:** ```json { "page": 1, "count": 3, "items": [ { "code": "366", "keyId": "366", "primaryName": "Asthma", "consumerName": "Asthma" }, { "code": "30572", "keyId": "30572", "synonyms": [ "asthma mild persistent" ], "primaryName": "Asthma - mild persistent", "consumerName": "Asthma - mild persistent" }, { "code": "30573", "keyId": "30573", "synonyms": [ "asthma moderate persistent" ], "primaryName": "Asthma - moderate persistent", "consumerName": "Asthma - moderate persistent" } ], "limit": 3, "terms": "asthma", "total": 5, "hasMore": true, "nextPage": 2, "provider": "clinical-tables" } ``` --- ### Cosmic COSMIC structural variants — clinicaltables.nlm.nih.gov `cosmic_struct`, direct JSON. The service answers with a positional array [total, codes, extra, displayRows] - **Method:** `GET` - **Endpoint:** `https://api.zpi.web.id/v1/health:clinical-tables/cosmic` - **Cache TTL:** 300s **Parameters:** | Name | Type | Location | Required | Description | |------|------|----------|----------|-------------| | `terms` | string | query | yes | Search text. Several partial words are combined with an implicit AND | | `page` | number | query | no | Page number. Default 1 | | `limit` | number | query | no | Items per page. Default 10, max 500. Page times limit may not exceed 7500 | | `fields` | string | query | no | Comma-separated fields returned as display strings. Allowed: BreakPointOrder, ChromFrom, ChromTo, Description, ID_STUDY, LocationFromMax, LocationFromMin, LocationToMax, LocationToMin, MutationID, MutationType, NonTemplatedInsSeq, PrimaryHistology, PrimarySite, Site, StrandFrom, StrandTo, GRChVer, COSMIC_STRUCTURAL_ID, COSMIC_PHENOTYPE_ID, COSMIC_STUDY_ID. | | `extraFields` | string | query | no | Comma-separated fields returned with their native types, so objects and arrays stay structured. Accepts field:alias. Allowed: BreakPointOrder, ChromFrom, ChromTo, Description, ID_STUDY, LocationFromMax, LocationFromMin, LocationToMax, LocationToMin, MutationID, MutationType, NonTemplatedInsSeq, PrimaryHistology, PrimarySite, Site, StrandFrom, StrandTo, GRChVer, COSMIC_STRUCTURAL_ID, COSMIC_PHENOTYPE_ID, COSMIC_STUDY_ID. | | `searchFields` | string | query | no | Comma-separated fields the search text is matched against. Allowed: BreakPointOrder, ChromFrom, ChromTo, Description, ID_STUDY, LocationFromMax, LocationFromMin, LocationToMax, LocationToMin, MutationID, MutationType, NonTemplatedInsSeq, PrimaryHistology, PrimarySite, Site, StrandFrom, StrandTo, GRChVer, COSMIC_STRUCTURAL_ID, COSMIC_PHENOTYPE_ID, COSMIC_STUDY_ID. | | `codeField` | string | query | no | The single field to report as each item's code. Allowed: BreakPointOrder, ChromFrom, ChromTo, Description, ID_STUDY, LocationFromMax, LocationFromMin, LocationToMax, LocationToMin, MutationID, MutationType, NonTemplatedInsSeq, PrimaryHistology, PrimarySite, Site, StrandFrom, StrandTo, GRChVer, COSMIC_STRUCTURAL_ID, COSMIC_PHENOTYPE_ID, COSMIC_STUDY_ID. | | `filter` | string | query | no | Elasticsearch query-string filter applied on top of the search text. It is not wildcarded automatically | | `genomeBuild` | enum(37|38) | query | no | GRCh human genome build the coordinates refer to. Default 37 | **cURL:** ```bash curl "https://api.zpi.web.id/v1/health:clinical-tables/cosmic?terms=deletion&page=1&limit=10&fields=MutationID%2CMutationType%2CDescription&extraFields=ChromFrom%2CChromTo&searchFields=MutationID%2CMutationType%2CDescription&codeField=MutationID&filter=MutationType%3Adeletion&genomeBuild=38" \ -H "x-api-key: YOUR_API_KEY" ``` **JavaScript / TypeScript:** ```javascript const res = await fetch("https://api.zpi.web.id/v1/health:clinical-tables/cosmic?terms=deletion&page=1&limit=10&fields=MutationID%2CMutationType%2CDescription&extraFields=ChromFrom%2CChromTo&searchFields=MutationID%2CMutationType%2CDescription&codeField=MutationID&filter=MutationType%3Adeletion&genomeBuild=38", { headers: { "x-api-key": process.env.ZAPI_KEY } }); const data = await res.json(); ``` **Python:** ```python import requests r = requests.get("https://api.zpi.web.id/v1/health:clinical-tables/cosmic?terms=deletion&page=1&limit=10&fields=MutationID%2CMutationType%2CDescription&extraFields=ChromFrom%2CChromTo&searchFields=MutationID%2CMutationType%2CDescription&codeField=MutationID&filter=MutationType%3Adeletion&genomeBuild=38", headers={"x-api-key": "YOUR_API_KEY"}) data = r.json() ``` **Example response:** ```json { "page": 1, "count": 3, "items": [ { "code": "119626", "chromTo": "7", "chromFrom": "7", "mutationID": "119626", "description": "chr7:g.(145808590_145808610)_(145874585_145874605)del", "mutationType": "intrachromosomal deletion" }, { "code": "119635", "chromTo": "18", "chromFrom": "18", "mutationID": "119635", "description": "chr18:g.(50962789_50962809)_(51078735_51078755)del", "mutationType": "intrachromosomal deletion" }, { "code": "119648", "chromTo": "13", "chromFrom": "13", "mutationID": "119648", "description": "chr13:g.(23495219_23495239)_(23495527_23495547)del", "mutationType": "intrachromosomal deletion" } ], "limit": 3, "terms": "deletion", "total": 49355, "hasMore": true, "nextPage": 2, "provider": "clinical-tables" } ``` --- ### Cytogenetic Locations Cytogenetic band locations — clinicaltables.nlm.nih.gov `cytogenetic_locs`, direct JSON, no key. The service answers with a positional array [total, codes, extra, displayRows] - **Method:** `GET` - **Endpoint:** `https://api.zpi.web.id/v1/health:clinical-tables/cytogenetic-locations` - **Cache TTL:** 300s **Parameters:** | Name | Type | Location | Required | Description | |------|------|----------|----------|-------------| | `terms` | string | query | yes | Search text. Several partial words are combined with an implicit AND | | `page` | number | query | no | Page number. Default 1 | | `limit` | number | query | no | Items per page. Default 10, max 500. Page times limit may not exceed 7500 | | `fields` | string | query | no | Comma-separated fields returned as display strings. Allowed: chromosome, arm, band, iscn_start, iscn_stop, stain, cytogenetic. | | `extraFields` | string | query | no | Comma-separated fields returned with their native types, so objects and arrays stay structured. Accepts field:alias. Allowed: chromosome, arm, band, iscn_start, iscn_stop, stain, cytogenetic. | | `searchFields` | string | query | no | Comma-separated fields the search text is matched against. Allowed: chromosome, arm, band, iscn_start, iscn_stop, stain, cytogenetic. | | `codeField` | string | query | no | The single field to report as each item's code. Allowed: chromosome, arm, band, iscn_start, iscn_stop, stain, cytogenetic. | | `filter` | string | query | no | Elasticsearch query-string filter applied on top of the search text. It is not wildcarded automatically | **cURL:** ```bash curl "https://api.zpi.web.id/v1/health:clinical-tables/cytogenetic-locations?terms=7q31&page=1&limit=10&fields=cytogenetic%2Cchromosome%2Carm&extraFields=cytogenetic%2Cchromosome&searchFields=cytogenetic%2Cchromosome%2Carm&codeField=cytogenetic&filter=chromosome%3A7" \ -H "x-api-key: YOUR_API_KEY" ``` **JavaScript / TypeScript:** ```javascript const res = await fetch("https://api.zpi.web.id/v1/health:clinical-tables/cytogenetic-locations?terms=7q31&page=1&limit=10&fields=cytogenetic%2Cchromosome%2Carm&extraFields=cytogenetic%2Cchromosome&searchFields=cytogenetic%2Cchromosome%2Carm&codeField=cytogenetic&filter=chromosome%3A7", { headers: { "x-api-key": process.env.ZAPI_KEY } }); const data = await res.json(); ``` **Python:** ```python import requests r = requests.get("https://api.zpi.web.id/v1/health:clinical-tables/cytogenetic-locations?terms=7q31&page=1&limit=10&fields=cytogenetic%2Cchromosome%2Carm&extraFields=cytogenetic%2Cchromosome&searchFields=cytogenetic%2Cchromosome%2Carm&codeField=cytogenetic&filter=chromosome%3A7", headers={"x-api-key": "YOUR_API_KEY"}) data = r.json() ``` **Example response:** ```json { "page": 1, "count": 3, "items": [ { "arm": "q", "code": "7q31.1", "chromosome": "7", "cytogenetic": "7q31.1" }, { "arm": "q", "code": "7q31.31", "chromosome": "7", "cytogenetic": "7q31.31" }, { "arm": "q", "code": "7q31.33", "chromosome": "7", "cytogenetic": "7q31.33" } ], "limit": 3, "terms": "7q31", "total": 5, "hasMore": true, "nextPage": 2, "provider": "clinical-tables" } ``` --- ### Dbvar dbVar structural variants — clinicaltables.nlm.nih.gov `dbvar`, direct JSON, no key. The service answers with a positional array [total, codes, extra, displayRows] - **Method:** `GET` - **Endpoint:** `https://api.zpi.web.id/v1/health:clinical-tables/dbvar` - **Cache TTL:** 300s **Parameters:** | Name | Type | Location | Required | Description | |------|------|----------|----------|-------------| | `terms` | string | query | yes | Search text. Several partial words are combined with an implicit AND | | `page` | number | query | no | Page number. Default 1 | | `limit` | number | query | no | Items per page. Default 10, max 500. Page times limit may not exceed 7500 | | `fields` | string | query | no | Comma-separated fields returned as display strings. Allowed: Alias, ciend, cipos, clinical_int, copy_number, Dbxref, End_range, FeatureEnd, FeatureStart, gender, ID, Name, parent, phenotype, sampleset_name, sampleset_type, SeqID, Start_range, Type, var_origin, Zygosity. | | `extraFields` | string | query | no | Comma-separated fields returned with their native types, so objects and arrays stay structured. Accepts field:alias. Allowed: Alias, ciend, cipos, clinical_int, copy_number, Dbxref, End_range, FeatureEnd, FeatureStart, gender, ID, Name, parent, phenotype, sampleset_name, sampleset_type, SeqID, Start_range, Type, var_origin, Zygosity. | | `searchFields` | string | query | no | Comma-separated fields the search text is matched against. Allowed: Alias, ciend, cipos, clinical_int, copy_number, Dbxref, End_range, FeatureEnd, FeatureStart, gender, ID, Name, parent, phenotype, sampleset_name, sampleset_type, SeqID, Start_range, Type, var_origin, Zygosity. | | `codeField` | string | query | no | The single field to report as each item's code. Allowed: Alias, ciend, cipos, clinical_int, copy_number, Dbxref, End_range, FeatureEnd, FeatureStart, gender, ID, Name, parent, phenotype, sampleset_name, sampleset_type, SeqID, Start_range, Type, var_origin, Zygosity. | | `filter` | string | query | no | Elasticsearch query-string filter applied on top of the search text. It is not wildcarded automatically | **cURL:** ```bash curl "https://api.zpi.web.id/v1/health:clinical-tables/dbvar?terms=nsv&page=1&limit=10&fields=Name%2CType%2CID&extraFields=Alias%2CDbxref&searchFields=Name%2CType%2CID&codeField=Name&filter=var_origin%3Agermline" \ -H "x-api-key: YOUR_API_KEY" ``` **JavaScript / TypeScript:** ```javascript const res = await fetch("https://api.zpi.web.id/v1/health:clinical-tables/dbvar?terms=nsv&page=1&limit=10&fields=Name%2CType%2CID&extraFields=Alias%2CDbxref&searchFields=Name%2CType%2CID&codeField=Name&filter=var_origin%3Agermline", { headers: { "x-api-key": process.env.ZAPI_KEY } }); const data = await res.json(); ``` **Python:** ```python import requests r = requests.get("https://api.zpi.web.id/v1/health:clinical-tables/dbvar?terms=nsv&page=1&limit=10&fields=Name%2CType%2CID&extraFields=Alias%2CDbxref&searchFields=Name%2CType%2CID&codeField=Name&filter=var_origin%3Agermline", headers={"x-api-key": "YOUR_API_KEY"}) data = r.json() ``` **Example response:** ```json { "page": 1, "count": 3, "items": [ { "id": "7945772", "code": "nsv7447629", "name": "nsv7447629", "type": "copy_number_variation", "alias": "3___122567173_122571435___GRCh37_copy_number_variation_from_gain_or_loss", "dbxref": "URL:www.ncbi.nlm.nih.gov/dbvar/variants/nsv7447629" }, { "id": "7945768", "code": "nsv7447625", "name": "nsv7447625", "type": "copy_number_variation", "alias": "2___241740907_241778621___GRCh37_copy_number_variation_from_gain_or_loss", "dbxref": "URL:www.ncbi.nlm.nih.gov/dbvar/variants/nsv7447625" }, { "id": "7945758", "code": "nsv7447615", "name": "nsv7447615", "type": "copy_number_variation", "alias": "3___46130509_46180416___GRCh37_copy_number_variation_from_gain_or_loss", "dbxref": "URL:www.ncbi.nlm.nih.gov/dbvar/variants/nsv7447615" } ], "limit": 3, "terms": "nsv", "total": 10000, "hasMore": true, "nextPage": 2, "provider": "clinical-tables" } ``` --- ### Disease Names Disease names from MedGen — clinicaltables.nlm.nih.gov `disease_names`, direct JSON, no key. The service answers with a positional array [total, codes, extra, displayRows] - **Method:** `GET` - **Endpoint:** `https://api.zpi.web.id/v1/health:clinical-tables/disease-names` - **Cache TTL:** 300s **Parameters:** | Name | Type | Location | Required | Description | |------|------|----------|----------|-------------| | `terms` | string | query | yes | Search text. Several partial words are combined with an implicit AND | | `page` | number | query | no | Page number. Default 1 | | `limit` | number | query | no | Items per page. Default 10, max 500. Page times limit may not exceed 7500 | | `fields` | string | query | no | Comma-separated fields returned as display strings. Allowed: DiseaseName, ConceptID. | | `extraFields` | string | query | no | Comma-separated fields returned with their native types, so objects and arrays stay structured. Accepts field:alias. Allowed: DiseaseName, ConceptID. | | `searchFields` | string | query | no | Comma-separated fields the search text is matched against. Allowed: DiseaseName, ConceptID. | | `codeField` | string | query | no | The single field to report as each item's code. Allowed: DiseaseName, ConceptID. | | `filter` | string | query | no | Elasticsearch query-string filter applied on top of the search text. It is not wildcarded automatically | **cURL:** ```bash curl "https://api.zpi.web.id/v1/health:clinical-tables/disease-names?terms=marfan&page=1&limit=10&fields=DiseaseName%2CConceptID&extraFields=DiseaseName%2CConceptID&searchFields=DiseaseName%2CConceptID&codeField=ConceptID&filter=DiseaseName%3Amarfan*" \ -H "x-api-key: YOUR_API_KEY" ``` **JavaScript / TypeScript:** ```javascript const res = await fetch("https://api.zpi.web.id/v1/health:clinical-tables/disease-names?terms=marfan&page=1&limit=10&fields=DiseaseName%2CConceptID&extraFields=DiseaseName%2CConceptID&searchFields=DiseaseName%2CConceptID&codeField=ConceptID&filter=DiseaseName%3Amarfan*", { headers: { "x-api-key": process.env.ZAPI_KEY } }); const data = await res.json(); ``` **Python:** ```python import requests r = requests.get("https://api.zpi.web.id/v1/health:clinical-tables/disease-names?terms=marfan&page=1&limit=10&fields=DiseaseName%2CConceptID&extraFields=DiseaseName%2CConceptID&searchFields=DiseaseName%2CConceptID&codeField=ConceptID&filter=DiseaseName%3Amarfan*", headers={"x-api-key": "YOUR_API_KEY"}) data = r.json() ``` **Example response:** ```json { "page": 1, "count": 3, "items": [ { "code": "C5681015", "conceptID": "C5681015", "diseaseName": "Marfan and Marfan-related disorder" }, { "code": "C0024796", "conceptID": "C0024796", "diseaseName": "Marfan syndrome" }, { "code": "C4016055", "conceptID": "C4016055", "diseaseName": "Marfan syndrome, atypical" } ], "limit": 3, "terms": "marfan", "total": 19, "hasMore": true, "nextPage": 2, "provider": "clinical-tables" } ``` --- ### Drug Ingredients Drug ingredient names — clinicaltables.nlm.nih.gov `drug_ingredients`, direct JSON, no key. The service answers with a positional array [total, codes, extra, displayRows] - **Method:** `GET` - **Endpoint:** `https://api.zpi.web.id/v1/health:clinical-tables/drug-ingredients` - **Cache TTL:** 300s **Parameters:** | Name | Type | Location | Required | Description | |------|------|----------|----------|-------------| | `terms` | string | query | yes | Search text. Several partial words are combined with an implicit AND | | `page` | number | query | no | Page number. Default 1 | | `limit` | number | query | no | Items per page. Default 10, max 500. Page times limit may not exceed 7500 | | `fields` | string | query | no | Comma-separated fields returned as display strings. Allowed: code, name. | | `extraFields` | string | query | no | Comma-separated fields returned with their native types, so objects and arrays stay structured. Accepts field:alias. Allowed: code, name. | | `searchFields` | string | query | no | Comma-separated fields the search text is matched against. Allowed: code, name. | | `codeField` | string | query | no | The single field to report as each item's code. Allowed: code, name. | | `filter` | string | query | no | Elasticsearch query-string filter applied on top of the search text. It is not wildcarded automatically | **cURL:** ```bash curl "https://api.zpi.web.id/v1/health:clinical-tables/drug-ingredients?terms=aspirin&page=1&limit=10&fields=code%2Cname&extraFields=code%2Cname&searchFields=code%2Cname&codeField=code&filter=name%3Aaspirin*" \ -H "x-api-key: YOUR_API_KEY" ``` **JavaScript / TypeScript:** ```javascript const res = await fetch("https://api.zpi.web.id/v1/health:clinical-tables/drug-ingredients?terms=aspirin&page=1&limit=10&fields=code%2Cname&extraFields=code%2Cname&searchFields=code%2Cname&codeField=code&filter=name%3Aaspirin*", { headers: { "x-api-key": process.env.ZAPI_KEY } }); const data = await res.json(); ``` **Python:** ```python import requests r = requests.get("https://api.zpi.web.id/v1/health:clinical-tables/drug-ingredients?terms=aspirin&page=1&limit=10&fields=code%2Cname&extraFields=code%2Cname&searchFields=code%2Cname&codeField=code&filter=name%3Aaspirin*", headers={"x-api-key": "YOUR_API_KEY"}) data = r.json() ``` **Example response:** ```json { "page": 1, "count": 1, "items": [ { "code": "1191", "name": "aspirin" } ], "limit": 3, "terms": "aspirin", "total": 1, "hasMore": false, "nextPage": null, "provider": "clinical-tables" } ``` --- ### Drugs RxTerms drug names — clinicaltables.nlm.nih.gov `rxterms`, direct JSON, no key. The service answers with a positional array [total, codes, extra, displayRows] - **Method:** `GET` - **Endpoint:** `https://api.zpi.web.id/v1/health:clinical-tables/drugs` - **Cache TTL:** 300s **Parameters:** | Name | Type | Location | Required | Description | |------|------|----------|----------|-------------| | `terms` | string | query | yes | Search text. Several partial words are combined with an implicit AND | | `page` | number | query | no | Page number. Default 1 | | `limit` | number | query | no | Items per page. Default 10, max 500. Page times limit may not exceed 7500 | | `fields` | string | query | no | Comma-separated fields returned as display strings. Allowed: DISPLAY_NAME, STRENGTHS_AND_FORMS, RXCUIS, SXDG_RXCUI, DISPLAY_NAME_SYNONYM. | | `extraFields` | string | query | no | Comma-separated fields returned with their native types, so objects and arrays stay structured. Accepts field:alias. Allowed: DISPLAY_NAME, STRENGTHS_AND_FORMS, RXCUIS, SXDG_RXCUI, DISPLAY_NAME_SYNONYM. | | `searchFields` | string | query | no | Comma-separated fields the search text is matched against. Allowed: DISPLAY_NAME, STRENGTHS_AND_FORMS, RXCUIS, SXDG_RXCUI, DISPLAY_NAME_SYNONYM. | | `codeField` | string | query | no | The single field to report as each item's code. Allowed: DISPLAY_NAME, STRENGTHS_AND_FORMS, RXCUIS, SXDG_RXCUI, DISPLAY_NAME_SYNONYM. | | `filter` | string | query | no | Elasticsearch query-string filter applied on top of the search text. It is not wildcarded automatically | **cURL:** ```bash curl "https://api.zpi.web.id/v1/health:clinical-tables/drugs?terms=aspirin&page=1&limit=10&fields=DISPLAY_NAME%2CSXDG_RXCUI&extraFields=STRENGTHS_AND_FORMS%2CRXCUIS&searchFields=DISPLAY_NAME%2CSXDG_RXCUI&codeField=DISPLAY_NAME&filter=DISPLAY_NAME%3Aaspirin*" \ -H "x-api-key: YOUR_API_KEY" ``` **JavaScript / TypeScript:** ```javascript const res = await fetch("https://api.zpi.web.id/v1/health:clinical-tables/drugs?terms=aspirin&page=1&limit=10&fields=DISPLAY_NAME%2CSXDG_RXCUI&extraFields=STRENGTHS_AND_FORMS%2CRXCUIS&searchFields=DISPLAY_NAME%2CSXDG_RXCUI&codeField=DISPLAY_NAME&filter=DISPLAY_NAME%3Aaspirin*", { headers: { "x-api-key": process.env.ZAPI_KEY } }); const data = await res.json(); ``` **Python:** ```python import requests r = requests.get("https://api.zpi.web.id/v1/health:clinical-tables/drugs?terms=aspirin&page=1&limit=10&fields=DISPLAY_NAME%2CSXDG_RXCUI&extraFields=STRENGTHS_AND_FORMS%2CRXCUIS&searchFields=DISPLAY_NAME%2CSXDG_RXCUI&codeField=DISPLAY_NAME&filter=DISPLAY_NAME%3Aaspirin*", headers={"x-api-key": "YOUR_API_KEY"}) data = r.json() ``` **Example response:** ```json { "page": 1, "count": 3, "items": [ { "code": "Aspirin (Oral Pill)", "rxcuis": [ "252857", "308416", "243670", "198466", "198467", "212033", "308409", "198471" ], "sxdgRxcui": "1154070", "displayName": "Aspirin (Oral Pill)", "strengthsAndForms": [ " 81 mg Cap", " 81 mg DR Tab", " 81 mg Tab", "325 mg Cap", "325 mg DR Tab", "325 mg Tab", "500 mg DR Tab", "500 mg Tab" ] }, { "code": "Aspirin (Chewable)", "rxcuis": [ "318272" ], "sxdgRxcui": "1294937", "displayName": "Aspirin (Chewable)", "strengthsAndForms": [ "81 mg Tab" ] }, { "code": "Aspirin/oxyCODONE (Oral Pill)", "rxcuis": [ "637540", "848768" ], "sxdgRxcui": "1153750", "displayName": "Aspirin/oxyCODONE (Oral Pill)", "strengthsAndForms": [ "325-4.5-0.38 mg Tab", "325-4.84 mg Tab" ] } ], "limit": 3, "terms": "aspirin", "total": 15, "hasMore": true, "nextPage": 2, "provider": "clinical-tables" } ``` --- ### Form Definition Renderable LOINC panel definition — clinicaltables.nlm.nih.gov, direct JSON. The one rich payload in this source: a nested question tree with units, answer - **Method:** `GET` - **Endpoint:** `https://api.zpi.web.id/v1/health:clinical-tables/form-definition` - **Cache TTL:** 300s **Parameters:** | Name | Type | Location | Required | Description | |------|------|----------|----------|-------------| | `loincNum` | string | query | yes | LOINC code of the panel or form whose definition to return | **cURL:** ```bash curl "https://api.zpi.web.id/v1/health:clinical-tables/form-definition?loincNum=34565-2" \ -H "x-api-key: YOUR_API_KEY" ``` **JavaScript / TypeScript:** ```javascript const res = await fetch("https://api.zpi.web.id/v1/health:clinical-tables/form-definition?loincNum=34565-2", { headers: { "x-api-key": process.env.ZAPI_KEY } }); const data = await res.json(); ``` **Python:** ```python import requests r = requests.get("https://api.zpi.web.id/v1/health:clinical-tables/form-definition?loincNum=34565-2", headers={"x-api-key": "YOUR_API_KEY"}) data = r.json() ``` **Example response:** ```json { "code": "34565-2", "name": "Vital signs, weight and height panel", "items": [ { "items": [ { "units": [ { "code": "{beats}/min", "name": "{beats}/min", "system": "http://unitsofmeasure.org", "isDefault": false }, { "code": "{counts}/min", "name": "{counts}/min", "system": "http://unitsofmeasure.org", "isDefault": false } ], "linkId": "/34566-0/8867-4", "dataType": "REAL", "isHeader": false, "question": "Heart rate", "questionCode": "8867-4", "questionCodeSystem": "http://loinc.org" }, { "units": [ { "code": "{breaths}/min", "name": "{breaths}/min", "system": "http://unitsofmeasure.org", "isDefault": false }, { "code": "{counts}/min", "name": "{counts}/min", "system": "http://unitsofmeasure.org", "isDefault": false } ], "linkId": "/34566-0/9279-1", "dataType": "REAL", "isHeader": false, "question": "Resp rate", "questionCode": "9279-1", "questionCodeSystem": "http://loinc.org" }, { "items": [ { "units": [ { "code": "mm[Hg]", "name": "mm[Hg]", "system": "http://unitsofmeasure.org", "isDefault": false } ], "linkId": "/34566-0/35094-2/8480-6", "dataType": "REAL", "isHeader": false, "question": "BP sys", "questionCode": "8480-6", "questionCodeSystem": "http://loinc.org" }, { "units": [ { "code": "mm[Hg]", "name": "mm[Hg]", "system": "http://unitsofmeasure.org", "isDefault": false } ], "linkId": "/34566-0/35094-2/8462-4", "dataType": "REAL", "isHeader": false, "question": "BP dias", "questionCode": "8462-4", "questionCodeSystem": "http://loinc.org" }, { "units": [ { "code": "mm[Hg]", "name": "mm[Hg]", "system": "http://unitsofmeasure.org", "isDefault": false } ], "linkId": "/34566-0/35094-2/8478-0", "dataType": "REAL", "isHeader": false, "question": "BP mean", "questionCode": "8478-0", "questionCodeSystem": "http://loinc.org" }, { "linkId": "/34566-0/35094-2/8357-6", "answers": [ { "code": "LA24013-7", "text": "Auscultation - automatic", "system": "http://loinc.org" }, { "code": "LA24012-9", "text": "Auscultation - manual", "system": "http://loinc.org" }, { "code": "LA24014-5", "text": "Oscillometry", "system": "http://loinc.org" }, { "code": "LA24016-0", "text": "Continuous noninvasive arterial pressure (CNAP)", "system": "http://loinc.org" }, { "code": "LA24015-2", "text": "Invasive (intravascular transducer)", "system": "http://loinc.org" }, { "code": "LA25780-0", "text": "Arterial line", "label": "3308001", "system": "http://loinc.org" }, { "code": "LA19771-7", "text": "Doppler", "label": "3308003", "system": "http://loinc.org" }, { "code": "LA25782-6", "text": "Cuff-manual palpated only", "label": "3308009", "system": "http://loinc.org" } ], "dataType": "CNE", "isHeader": false, "question": "BP method", "questionCode": "8357-6", "questionCodeSystem": "http://loinc.org" }, { "units": [ { "code": "cm", "name": "cm", "system": "http://unitsofmeasure.org", "isDefault": false } ], "linkId": "/34566-0/35094-2/8358-4", "answers": [ { "code": "LA11162-7", "text": "Adult standard", "system": "http://loinc.org" }, { "code": "LA11163-5", "text": "Adult large", "system": "http://loinc.org" }, { "code": "LA11164-3", "text": "Thigh extra large", "system": "http://loinc.org" } ], "dataType": "CNE", "isHeader": false, "question": "BP device Cuff size", "questionCode": "8358-4", "questionCodeSystem": "http://loinc.org" }, { "linkId": "/34566-0/35094-2/8359-2", "dataType": "ST", "isHeader": false, "question": "Periph a measurement site", "questionCode": "8359-2", "questionCodeSystem": "http://loinc.org" }, { "linkId": "/34566-0/35094-2/9856-6", "dataType": "ST", "isHeader": false, "question": "BP device Inventory #", "questionCode": "9856-6", "questionCodeSystem": "http://loinc.org" }, { "linkId": "/34566-0/35094-2/9857-4", "dataType": "ST", "isHeader": false, "question": "BP device Model #", "questionCode": "9857-4", "questionCodeSystem": "http://loinc.org" } ], "linkId": "/34566-0/35094-2", "dataType": "SECTION", "isHeader": true, "question": "BP Pnl", "questionCode": "35094-2", "questionCodeSystem": "http://loinc.org" }, { "items": [ { "units": [ { "code": "Cel", "name": "Cel", "system": "http://unitsofmeasure.org", "isDefault": false } ], "linkId": "/34566-0/35095-9/8310-5", "dataType": "REAL", "isHeader": false, "question": "Body temperature", "questionCode": "8310-5", "questionCodeSystem": "http://loinc.org" }, { "linkId": "/34566-0/35095-9/8326-1", "answers": [ { "code": "LA24040-0", "text": "Digital thermometer", "system": "http://loinc.org" }, { "code": "LA24043-4", "text": "Liquid-crystal temperature-sensitive strip", "system": "http://loinc.org" }, { "code": "LA24038-4", "text": "Mercury thermometer", "system": "http://loinc.org" }, { "code": "LA24037-6", "text": "Non-contact infrared thermometer (NCIT)", "system": "http://loinc.org" }, { "code": "LA24042-6", "text": "Temporal artery infrared thermometer", "system": "http://loinc.org" }, { "code": "LA24039-2", "text": "Thermal scanner camera", "system": "http://loinc.org" }, { "code": "LA24041-8", "text": "Tympanic infrared thermometer", "system": "http://loinc.org" } ], "dataType": "CNE", "isHeader": false, "question": "Bdy Temp Device Class", "questionCode": "8326-1", "questionCodeSystem": "http://loinc.org" }, { "linkId": "/34566-0/35095-9/8327-9", "answers": [ { "code": "LA9370-3", "text": "Axillary", "system": "http://loinc.org" }, { "code": "LA9367-9", "text": "Oral", "system": "http://loinc.org" }, { "code": "LA21929-7", "text": "Ear", "system": "http://loinc.org" }, { "code": "LA9368-7", "text": "Tympanic membrane", "system": "http://loinc.org" }, { "code": "LA21928-9", "text": "Temporal artery (forehead)", "system": "http://loinc.org" }, { "code": "LA9369-5", "text": "Rectal", "system": "http://loinc.org" }, { "code": "LA9371-1", "text": "Urinary bladder", "system": "http://loinc.org" }, { "code": "LA9263-0", "text": "Nasal", "system": "http://loinc.org" } ], "dataType": "CNE", "isHeader": false, "question": "Bdy temp measurement site", "questionCode": "8327-9", "questionCodeSystem": "http://loinc.org" }, { "linkId": "/34566-0/35095-9/9849-1", "dataType": "ST", "isHeader": false, "question": "Bdy Temp Device Inventory #", "questionCode": "9849-1", "questionCodeSystem": "http://loinc.org" }, { "linkId": "/34566-0/35095-9/9850-9", "dataType": "ST", "isHeader": false, "question": "Bdy Temp Device Model #", "questionCode": "9850-9", "questionCodeSystem": "http://loinc.org" }, { "linkId": "/34566-0/35095-9/9851-7", "dataType": "ST", "isHeader": false, "question": "Bdy Temp Device Serial #", "questionCode": "9851-7", "questionCodeSystem": "http://loinc.org" } ], "linkId": "/34566-0/35095-9", "dataType": "SECTION", "isHeader": true, "question": "Bdy temp Pnl", "questionCode": "35095-9", "questionCodeSystem": "http://loinc.org" }, { "units": [ { "name": "centimeters", "isDefault": false }, { "name": "feet", "isDefault": false }, { "name": "inches", "isDefault": false }, { "name": "meters", "isDefault": false } ], "linkId": "/34566-0/8302-2", "dataType": "REAL", "isHeader": false, "question": "Body height", "questionCode": "8302-2", "questionCodeSystem": "http://loinc.org" }, { "units": [ { "code": "[lb_av]", "name": "[lb_av]", "system": "http://unitsofmeasure.org", "isDefault": false }, { "code": "kg", "name": "kg", "system": "http://unitsofmeasure.org", "isDefault": false } ], "linkId": "/34566-0/3141-9", "dataType": "REAL", "isHeader": false, "question": "Weight Measured", "questionCode": "3141-9", "questionCodeSystem": "http://loinc.org" }, { "linkId": "/34566-0/8361-8", "answers": [ { "code": "LA11868-9", "text": "Sitting", "system": "http://loinc.org" }, { "code": "LA11869-7", "text": "Lying", "system": "http://loinc.org" }, { "code": "LA11870-5", "text": "Standing", "system": "http://loinc.org" } ], "dataType": "CNE", "isHeader": false, "question": "Bdy position with respect to gravity", "questionCode": "8361-8", "questionCodeSystem": "http://loinc.org" }, { "linkId": "/34566-0/8352-7", "answers": [ { "code": "LA11871-3", "text": "Underwear or less", "system": "http://loinc.org" }, { "code": "LA11872-1", "text": "Street clothes, no shoes", "system": "http://loinc.org" }, { "code": "LA11873-9", "text": "Street clothes & shoes", "system": "http://loinc.org" } ], "dataType": "CNE", "isHeader": false, "question": "Clothing worn during measure", "questionCode": "8352-7", "questionCodeSystem": "http://loinc.org" } ], "linkId": "/34566-0", "dataType": "SECTION", "isHeader": true, "question": "Vital Signs Pnl", "questionCode": "34566-0", "questionCodeSystem": "http://loinc.org" } ], "codeType": "LOINC", "loincNum": "34565-2", "provider": "clinical-tables", "codeSystem": "http://loinc.org", "lformsVersion": "29.0.0", "copyrightNotice": null, "codingInstructions": null } ``` --- ### Genes NCBI gene records — clinicaltables.nlm.nih.gov `ncbi_genes`, direct JSON, no key. The service answers with a positional array [total, codes, extra, displayRows] - **Method:** `GET` - **Endpoint:** `https://api.zpi.web.id/v1/health:clinical-tables/genes` - **Cache TTL:** 300s **Parameters:** | Name | Type | Location | Required | Description | |------|------|----------|----------|-------------| | `terms` | string | query | yes | Search text. Several partial words are combined with an implicit AND | | `page` | number | query | no | Page number. Default 1 | | `limit` | number | query | no | Items per page. Default 10, max 500. Page times limit may not exceed 7500 | | `fields` | string | query | no | Comma-separated fields returned as display strings. Allowed: GeneID, HGNC_ID, Symbol, Synonyms, dbXrefs, chromosome, map_location, description, type_of_gene, na_symbol, na_name, Other_designations, Modification_date. | | `extraFields` | string | query | no | Comma-separated fields returned with their native types, so objects and arrays stay structured. Accepts field:alias. Allowed: GeneID, HGNC_ID, Symbol, Synonyms, dbXrefs, chromosome, map_location, description, type_of_gene, na_symbol, na_name, Other_designations, Modification_date. | | `searchFields` | string | query | no | Comma-separated fields the search text is matched against. Allowed: GeneID, HGNC_ID, Symbol, Synonyms, dbXrefs, chromosome, map_location, description, type_of_gene, na_symbol, na_name, Other_designations, Modification_date. | | `codeField` | string | query | no | The single field to report as each item's code. Allowed: GeneID, HGNC_ID, Symbol, Synonyms, dbXrefs, chromosome, map_location, description, type_of_gene, na_symbol, na_name, Other_designations, Modification_date. | | `filter` | string | query | no | Elasticsearch query-string filter applied on top of the search text. It is not wildcarded automatically | **cURL:** ```bash curl "https://api.zpi.web.id/v1/health:clinical-tables/genes?terms=BRCA1&page=1&limit=10&fields=Symbol%2Cdescription%2Cchromosome&extraFields=Synonyms%2CdbXrefs&searchFields=Symbol%2Cdescription%2Cchromosome&codeField=GeneID&filter=chromosome%3A17" \ -H "x-api-key: YOUR_API_KEY" ``` **JavaScript / TypeScript:** ```javascript const res = await fetch("https://api.zpi.web.id/v1/health:clinical-tables/genes?terms=BRCA1&page=1&limit=10&fields=Symbol%2Cdescription%2Cchromosome&extraFields=Synonyms%2CdbXrefs&searchFields=Symbol%2Cdescription%2Cchromosome&codeField=GeneID&filter=chromosome%3A17", { headers: { "x-api-key": process.env.ZAPI_KEY } }); const data = await res.json(); ``` **Python:** ```python import requests r = requests.get("https://api.zpi.web.id/v1/health:clinical-tables/genes?terms=BRCA1&page=1&limit=10&fields=Symbol%2Cdescription%2Cchromosome&extraFields=Synonyms%2CdbXrefs&searchFields=Symbol%2Cdescription%2Cchromosome&codeField=GeneID&filter=chromosome%3A17", headers={"x-api-key": "YOUR_API_KEY"}) data = r.json() ``` **Example response:** ```json { "page": 1, "count": 3, "items": [ { "code": "394269", "symbol": "BRCA1P1", "dbXrefs": "HGNC:HGNC:28470|AllianceGenome:HGNC:28470", "synonyms": "LBRCA1|PsiBRCA1|pseudo-BRCA1", "chromosome": "17", "codeSystem": "NCBI-gene code", "description": "BRCA1 pseudogene 1" }, { "code": "111589215", "symbol": "LOC111589215", "dbXrefs": "-", "synonyms": "-", "chromosome": "17", "codeSystem": "NCBI-gene code", "description": "BRCA1 promoter region" }, { "code": "101929767", "symbol": "BRCA1-OT1", "dbXrefs": "HGNC:HGNC:58363", "synonyms": "-", "chromosome": "17", "codeSystem": "NCBI-gene code", "description": "BRCA1 overlapping transcript 1" } ], "limit": 3, "terms": "BRCA1", "total": 9, "hasMore": true, "nextPage": 2, "provider": "clinical-tables" } ``` --- ### Hcpcs HCPCS Level II codes — clinicaltables.nlm.nih.gov `hcpcs`, direct JSON, no key. The service answers with a positional array [total, codes, extra, displayRows] - **Method:** `GET` - **Endpoint:** `https://api.zpi.web.id/v1/health:clinical-tables/hcpcs` - **Cache TTL:** 300s **Parameters:** | Name | Type | Location | Required | Description | |------|------|----------|----------|-------------| | `terms` | string | query | yes | Search text. Several partial words are combined with an implicit AND | | `page` | number | query | no | Page number. Default 1 | | `limit` | number | query | no | Items per page. Default 10, max 500. Page times limit may not exceed 7500 | | `fields` | string | query | no | Comma-separated fields returned as display strings. Allowed: code, short_desc, long_desc, display, add_dt, term_dt, act_eff_dt, obsolete, is_noc. | | `extraFields` | string | query | no | Comma-separated fields returned with their native types, so objects and arrays stay structured. Accepts field:alias. Allowed: code, short_desc, long_desc, display, add_dt, term_dt, act_eff_dt, obsolete, is_noc. | | `searchFields` | string | query | no | Comma-separated fields the search text is matched against. Allowed: code, short_desc, long_desc, display, add_dt, term_dt, act_eff_dt, obsolete, is_noc. | | `codeField` | string | query | no | The single field to report as each item's code. Allowed: code, short_desc, long_desc, display, add_dt, term_dt, act_eff_dt, obsolete, is_noc. | | `filter` | string | query | no | Elasticsearch query-string filter applied on top of the search text. It is not wildcarded automatically | **cURL:** ```bash curl "https://api.zpi.web.id/v1/health:clinical-tables/hcpcs?terms=wheelchair&page=1&limit=10&fields=code%2Cdisplay%2Cshort_desc&extraFields=code%2Cdisplay&searchFields=code%2Cdisplay%2Cshort_desc&codeField=code&filter=obsolete%3Afalse" \ -H "x-api-key: YOUR_API_KEY" ``` **JavaScript / TypeScript:** ```javascript const res = await fetch("https://api.zpi.web.id/v1/health:clinical-tables/hcpcs?terms=wheelchair&page=1&limit=10&fields=code%2Cdisplay%2Cshort_desc&extraFields=code%2Cdisplay&searchFields=code%2Cdisplay%2Cshort_desc&codeField=code&filter=obsolete%3Afalse", { headers: { "x-api-key": process.env.ZAPI_KEY } }); const data = await res.json(); ``` **Python:** ```python import requests r = requests.get("https://api.zpi.web.id/v1/health:clinical-tables/hcpcs?terms=wheelchair&page=1&limit=10&fields=code%2Cdisplay%2Cshort_desc&extraFields=code%2Cdisplay&searchFields=code%2Cdisplay%2Cshort_desc&codeField=code&filter=obsolete%3Afalse", headers={"x-api-key": "YOUR_API_KEY"}) data = r.json() ``` **Example response:** ```json { "page": 1, "count": 3, "items": [ { "code": "E2210", "display": "Wheelchair bearings", "shortDesc": "Wheelchair bearings" }, { "code": "K0001", "display": "Standard wheelchair", "shortDesc": "Standard wheelchair" }, { "code": "K0003", "display": "Lightweight wheelchair", "shortDesc": "Lightweight wheelchair" } ], "limit": 3, "terms": "wheelchair", "total": 63, "hasMore": true, "nextPage": 2, "provider": "clinical-tables" } ``` --- ### Hpo Human Phenotype Ontology terms — clinicaltables.nlm.nih.gov `hpo`, direct JSON, no key. The service answers with a positional array [total, codes, extra, displayRows] - **Method:** `GET` - **Endpoint:** `https://api.zpi.web.id/v1/health:clinical-tables/hpo` - **Cache TTL:** 300s **Parameters:** | Name | Type | Location | Required | Description | |------|------|----------|----------|-------------| | `terms` | string | query | yes | Search text. Several partial words are combined with an implicit AND | | `page` | number | query | no | Page number. Default 1 | | `limit` | number | query | no | Items per page. Default 10, max 500. Page times limit may not exceed 7500 | | `fields` | string | query | no | Comma-separated fields returned as display strings. Allowed: id, name, definition, def_xref, created_by, creation_date, comment, is_obsolete, replaced_by, consider, alt_id, synonym, synonym.term, synonym.relation, synonym.type, synonym.xref, is_a, is_a.id, is_a.name, xref, xref.id, xref.name, property, property.name, property.value, property.data_type, property.xref. | | `extraFields` | string | query | no | Comma-separated fields returned with their native types, so objects and arrays stay structured. Accepts field:alias. Allowed: id, name, definition, def_xref, created_by, creation_date, comment, is_obsolete, replaced_by, consider, alt_id, synonym, synonym.term, synonym.relation, synonym.type, synonym.xref, is_a, is_a.id, is_a.name, xref, xref.id, xref.name, property, property.name, property.value, property.data_type, property.xref. | | `searchFields` | string | query | no | Comma-separated fields the search text is matched against. Allowed: id, name, definition, def_xref, created_by, creation_date, comment, is_obsolete, replaced_by, consider, alt_id, synonym, synonym.term, synonym.relation, synonym.type, synonym.xref, is_a, is_a.id, is_a.name, xref, xref.id, xref.name, property, property.name, property.value, property.data_type, property.xref. | | `codeField` | string | query | no | The single field to report as each item's code. Allowed: id, name, definition, def_xref, created_by, creation_date, comment, is_obsolete, replaced_by, consider, alt_id, synonym, synonym.term, synonym.relation, synonym.type, synonym.xref, is_a, is_a.id, is_a.name, xref, xref.id, xref.name, property, property.name, property.value, property.data_type, property.xref. | | `filter` | string | query | no | Elasticsearch query-string filter applied on top of the search text. It is not wildcarded automatically | **cURL:** ```bash curl "https://api.zpi.web.id/v1/health:clinical-tables/hpo?terms=seizure&page=1&limit=10&fields=id%2Cname%2Cdefinition&extraFields=synonym%2Cis_a&searchFields=id%2Cname%2Cdefinition&codeField=id&filter=id%3AHP%5C%3A0001250" \ -H "x-api-key: YOUR_API_KEY" ``` **JavaScript / TypeScript:** ```javascript const res = await fetch("https://api.zpi.web.id/v1/health:clinical-tables/hpo?terms=seizure&page=1&limit=10&fields=id%2Cname%2Cdefinition&extraFields=synonym%2Cis_a&searchFields=id%2Cname%2Cdefinition&codeField=id&filter=id%3AHP%5C%3A0001250", { headers: { "x-api-key": process.env.ZAPI_KEY } }); const data = await res.json(); ``` **Python:** ```python import requests r = requests.get("https://api.zpi.web.id/v1/health:clinical-tables/hpo?terms=seizure&page=1&limit=10&fields=id%2Cname%2Cdefinition&extraFields=synonym%2Cis_a&searchFields=id%2Cname%2Cdefinition&codeField=id&filter=id%3AHP%5C%3A0001250", headers={"x-api-key": "YOUR_API_KEY"}) data = r.json() ``` **Example response:** ```json { "page": 1, "count": 1, "items": [ { "id": "HP:0001250", "isA": [ { "id": "HP:0012638", "name": "Abnormal nervous system physiology" } ], "code": "HP:0001250", "name": "Seizure", "synonym": [ { "term": "Epilepsy", "type": "layperson", "relation": "RELATED" }, { "term": "Epileptic seizure", "relation": "EXACT" }, { "term": "Seizures", "type": "plural_form", "relation": "EXACT" } ], "definition": "A seizure is an intermittent abnormality of nervous system physiology characterized by a transient occurrence of signs and/or symptoms due to abnormal excessive or synchronous neuronal activity in the brain" } ], "limit": 3, "terms": "seizure", "total": 1, "hasMore": false, "nextPage": null, "provider": "clinical-tables" } ``` --- ### Icd10 ICD-10-CM diagnosis codes — clinicaltables.nlm.nih.gov, direct JSON, no key. The service answers with a positional array and returns empty strings on a 200 - **Method:** `GET` - **Endpoint:** `https://api.zpi.web.id/v1/health:clinical-tables/icd10` - **Cache TTL:** 300s **Parameters:** | Name | Type | Location | Required | Description | |------|------|----------|----------|-------------| | `terms` | string | query | yes | Search text. Several partial words are combined with an implicit AND | | `page` | number | query | no | Page number. Default 1 | | `limit` | number | query | no | Items per page. Default 10, max 500. Page times limit may not exceed 7500 | | `fields` | string | query | no | Comma-separated fields returned as display strings. Allowed: code, name. | | `extraFields` | string | query | no | Comma-separated fields returned with their native types, so objects and arrays stay structured. Accepts field:alias. Allowed: code, name. | | `searchFields` | string | query | no | Comma-separated fields the search text is matched against. Allowed: code, name. | | `codeField` | string | query | no | The single field to report as each item's code. Allowed: code, name. | | `filter` | string | query | no | Elasticsearch query-string filter applied on top of the search text. It is not wildcarded automatically | **cURL:** ```bash curl "https://api.zpi.web.id/v1/health:clinical-tables/icd10?terms=diabetes&page=1&limit=10&fields=code%2Cname&extraFields=code%2Cname&searchFields=code%2Cname&codeField=code&filter=code%3AE11*" \ -H "x-api-key: YOUR_API_KEY" ``` **JavaScript / TypeScript:** ```javascript const res = await fetch("https://api.zpi.web.id/v1/health:clinical-tables/icd10?terms=diabetes&page=1&limit=10&fields=code%2Cname&extraFields=code%2Cname&searchFields=code%2Cname&codeField=code&filter=code%3AE11*", { headers: { "x-api-key": process.env.ZAPI_KEY } }); const data = await res.json(); ``` **Python:** ```python import requests r = requests.get("https://api.zpi.web.id/v1/health:clinical-tables/icd10?terms=diabetes&page=1&limit=10&fields=code%2Cname&extraFields=code%2Cname&searchFields=code%2Cname&codeField=code&filter=code%3AE11*", headers={"x-api-key": "YOUR_API_KEY"}) data = r.json() ``` **Example response:** ```json { "page": 1, "count": 3, "items": [ { "code": "E11.65", "name": "Type 2 diabetes mellitus with hyperglycemia" }, { "code": "E11.9", "name": "Type 2 diabetes mellitus without complications" }, { "code": "E11.21", "name": "Type 2 diabetes mellitus with diabetic nephropathy" } ], "limit": 3, "terms": "diabetes", "total": 87, "hasMore": true, "nextPage": 2, "provider": "clinical-tables" } ``` --- ### Icd11 ICD-11 codes — clinicaltables.nlm.nih.gov `icd11_codes`, direct JSON, no key. The service answers with a positional array [total, codes, extra, displayRows] - **Method:** `GET` - **Endpoint:** `https://api.zpi.web.id/v1/health:clinical-tables/icd11` - **Cache TTL:** 300s **Parameters:** | Name | Type | Location | Required | Description | |------|------|----------|----------|-------------| | `terms` | string | query | yes | Search text. Several partial words are combined with an implicit AND | | `page` | number | query | no | Page number. Default 1 | | `limit` | number | query | no | Items per page. Default 10, max 500. Page times limit may not exceed 7500 | | `fields` | string | query | no | Comma-separated fields returned as display strings. Allowed: code, title, definition, type, chapter, entityId, source, indexTerm, browserUrl, parent. | | `extraFields` | string | query | no | Comma-separated fields returned with their native types, so objects and arrays stay structured. Accepts field:alias. Allowed: code, title, definition, type, chapter, entityId, source, indexTerm, browserUrl, parent. | | `searchFields` | string | query | no | Comma-separated fields the search text is matched against. Allowed: code, title, definition, type, chapter, entityId, source, indexTerm, browserUrl, parent. | | `codeField` | string | query | no | The single field to report as each item's code. Allowed: code, title, definition, type, chapter, entityId, source, indexTerm, browserUrl, parent. | | `filter` | string | query | no | Elasticsearch query-string filter applied on top of the search text. It is not wildcarded automatically | | `codeType` | enum(stem|extension|category) | query | no | Restrict to stem codes, extension codes, or both. Default category, which is both | **cURL:** ```bash curl "https://api.zpi.web.id/v1/health:clinical-tables/icd11?terms=diabetes&page=1&limit=10&fields=code%2Ctitle%2Cdefinition&extraFields=indexTerm&searchFields=code%2Ctitle%2Cdefinition&codeField=code&filter=type%3Astem&codeType=stem" \ -H "x-api-key: YOUR_API_KEY" ``` **JavaScript / TypeScript:** ```javascript const res = await fetch("https://api.zpi.web.id/v1/health:clinical-tables/icd11?terms=diabetes&page=1&limit=10&fields=code%2Ctitle%2Cdefinition&extraFields=indexTerm&searchFields=code%2Ctitle%2Cdefinition&codeField=code&filter=type%3Astem&codeType=stem", { headers: { "x-api-key": process.env.ZAPI_KEY } }); const data = await res.json(); ``` **Python:** ```python import requests r = requests.get("https://api.zpi.web.id/v1/health:clinical-tables/icd11?terms=diabetes&page=1&limit=10&fields=code%2Ctitle%2Cdefinition&extraFields=indexTerm&searchFields=code%2Ctitle%2Cdefinition&codeField=code&filter=type%3Astem&codeType=stem", headers={"x-api-key": "YOUR_API_KEY"}) data = r.json() ``` **Example response:** ```json { "page": 1, "count": 3, "items": [ { "code": "5A10", "title": "Type 1 diabetes mellitus", "indexTerm": "Type 1 diabetes mellitus; IDDM - [insulin dependent diabetes mellitus]; T1DM - [type 1 diabetes mellitus]; idiopathic insulin-dependent diabetes mellitus without complications; juvenile diabetes mellitus without complications; juvenile-onset diabetes mellitus without complications; juvenile-onset-type diabetes mellitus without complications; ketosis-prone diabetes mellitus without complications; type 1 IDDM; type 1 diabetes; Idiopathic Type 1 diabetes mellitus; Fulminant type 1 diabetes mellitus; Immune-related Type 1 diabetes mellitus; Immune-mediated Type 1 diabetes mellitus; Juvenile onset diabetes mellitus; Latent autoimmune diabetes in adults; LADA - [Latent autoimmune diabetes in adults]; SPIDDM - [Slowly progressive insulin-dependent diabetes mellitus]; slowly progressive insulin-dependent diabetes mellitus", "definition": "Diabetes mellitus type 1 (type 1 diabetes, T1DM, formerly insulin dependent or juvenile diabetes) is a form of diabetes mellitus that results from destruction of insulin-producing beta cells, mostly by autoimmune mechanisms. The subsequent lack of insulin leads to increased blood and urine glucose." }, { "code": "5A13", "title": "Diabetes mellitus, other specified type", "indexTerm": "Diabetes mellitus, other specified type; Other specified Diabetes mellitus, not Type 1 and not Type 2", "definition": "Diabetes mellitus which cannot be classified as either Type 1 or Type 2 diabetes mellitus." }, { "code": "5A11", "title": "Type 2 diabetes mellitus", "indexTerm": "Type 2 diabetes mellitus; DM type II; DM2; Diabetic type 2; NIDDM - [non insulin dependent diabetes mellitus]; T2DM - [Type 2 diabetes mellitus]; Type II diabetes mellitus; adult onset diabetes; diabetes due to insulin secretory defect; diabetes mellitus Type 2; diabetes mellitus due to insulin secretory defect; insulin requiring type 2 diabetes; maturity onset diabetes; maturity-onset diabetes mellitus; non-insulin dependent diabetes mellitus; non-insulin-dependent diabetes mellitus without complications; non-insulin-dependent diabetes of the young; noninsulin dependent diabetes; nonketotic diabetes; nonketotic hyperglycaemia; senile diabetes; stable diabetes; type 2 diabetes; type II diabetes; Ketosis-resistant diabetes mellitus; Insulin resistant diabetes mellitus; insulin resistant diabetes", "definition": "Diabetes mellitus type 2 (formerly noninsulin-dependent diabetes mellitus (NIDDM) or adult-onset diabetes) is a metabolic disorder that is characterised by high blood glucose in the context of insulin resistance and relative insulin deficiency." } ], "limit": 3, "terms": "diabetes", "total": 81, "hasMore": true, "nextPage": 2, "provider": "clinical-tables" } ``` --- ### Icd9 Dx ICD-9-CM diagnosis codes — clinicaltables.nlm.nih.gov `icd9cm_dx`, direct JSON, no key. The service answers with a positional array [total, codes, extra, displayRows] - **Method:** `GET` - **Endpoint:** `https://api.zpi.web.id/v1/health:clinical-tables/icd9-dx` - **Cache TTL:** 300s **Parameters:** | Name | Type | Location | Required | Description | |------|------|----------|----------|-------------| | `terms` | string | query | yes | Search text. Several partial words are combined with an implicit AND | | `page` | number | query | no | Page number. Default 1 | | `limit` | number | query | no | Items per page. Default 10, max 500. Page times limit may not exceed 7500 | | `fields` | string | query | no | Comma-separated fields returned as display strings. Allowed: code, code_dotted, short_name, long_name. | | `extraFields` | string | query | no | Comma-separated fields returned with their native types, so objects and arrays stay structured. Accepts field:alias. Allowed: code, code_dotted, short_name, long_name. | | `searchFields` | string | query | no | Comma-separated fields the search text is matched against. Allowed: code, code_dotted, short_name, long_name. | | `codeField` | string | query | no | The single field to report as each item's code. Allowed: code, code_dotted, short_name, long_name. | | `filter` | string | query | no | Elasticsearch query-string filter applied on top of the search text. It is not wildcarded automatically | **cURL:** ```bash curl "https://api.zpi.web.id/v1/health:clinical-tables/icd9-dx?terms=asthma&page=1&limit=10&fields=code%2Ccode_dotted%2Cshort_name&extraFields=code%2Ccode_dotted&searchFields=code%2Ccode_dotted%2Cshort_name&codeField=code&filter=code%3A493*" \ -H "x-api-key: YOUR_API_KEY" ``` **JavaScript / TypeScript:** ```javascript const res = await fetch("https://api.zpi.web.id/v1/health:clinical-tables/icd9-dx?terms=asthma&page=1&limit=10&fields=code%2Ccode_dotted%2Cshort_name&extraFields=code%2Ccode_dotted&searchFields=code%2Ccode_dotted%2Cshort_name&codeField=code&filter=code%3A493*", { headers: { "x-api-key": process.env.ZAPI_KEY } }); const data = await res.json(); ``` **Python:** ```python import requests r = requests.get("https://api.zpi.web.id/v1/health:clinical-tables/icd9-dx?terms=asthma&page=1&limit=10&fields=code%2Ccode_dotted%2Cshort_name&extraFields=code%2Ccode_dotted&searchFields=code%2Ccode_dotted%2Cshort_name&codeField=code&filter=code%3A493*", headers={"x-api-key": "YOUR_API_KEY"}) data = r.json() ``` **Example response:** ```json { "page": 1, "count": 3, "items": [ { "code": "49390", "shortName": "Asthma NOS", "codeDotted": "493.90" }, { "code": "49300", "shortName": "Extrinsic asthma NOS", "codeDotted": "493.00" }, { "code": "49310", "shortName": "Intrinsic asthma NOS", "codeDotted": "493.10" } ], "limit": 3, "terms": "asthma", "total": 12, "hasMore": true, "nextPage": 2, "provider": "clinical-tables" } ``` --- ### Icd9 Sg ICD-9-CM procedure codes — clinicaltables.nlm.nih.gov `icd9cm_sg`, direct JSON, no key. The service answers with a positional array [total, codes, extra, displayRows] - **Method:** `GET` - **Endpoint:** `https://api.zpi.web.id/v1/health:clinical-tables/icd9-sg` - **Cache TTL:** 300s **Parameters:** | Name | Type | Location | Required | Description | |------|------|----------|----------|-------------| | `terms` | string | query | yes | Search text. Several partial words are combined with an implicit AND | | `page` | number | query | no | Page number. Default 1 | | `limit` | number | query | no | Items per page. Default 10, max 500. Page times limit may not exceed 7500 | | `fields` | string | query | no | Comma-separated fields returned as display strings. Allowed: code, code_dotted, short_name, long_name. | | `extraFields` | string | query | no | Comma-separated fields returned with their native types, so objects and arrays stay structured. Accepts field:alias. Allowed: code, code_dotted, short_name, long_name. | | `searchFields` | string | query | no | Comma-separated fields the search text is matched against. Allowed: code, code_dotted, short_name, long_name. | | `codeField` | string | query | no | The single field to report as each item's code. Allowed: code, code_dotted, short_name, long_name. | | `filter` | string | query | no | Elasticsearch query-string filter applied on top of the search text. It is not wildcarded automatically | **cURL:** ```bash curl "https://api.zpi.web.id/v1/health:clinical-tables/icd9-sg?terms=appendectomy&page=1&limit=10&fields=code%2Ccode_dotted%2Cshort_name&extraFields=code%2Ccode_dotted&searchFields=code%2Ccode_dotted%2Cshort_name&codeField=code&filter=code%3A47*" \ -H "x-api-key: YOUR_API_KEY" ``` **JavaScript / TypeScript:** ```javascript const res = await fetch("https://api.zpi.web.id/v1/health:clinical-tables/icd9-sg?terms=appendectomy&page=1&limit=10&fields=code%2Ccode_dotted%2Cshort_name&extraFields=code%2Ccode_dotted&searchFields=code%2Ccode_dotted%2Cshort_name&codeField=code&filter=code%3A47*", { headers: { "x-api-key": process.env.ZAPI_KEY } }); const data = await res.json(); ``` **Python:** ```python import requests r = requests.get("https://api.zpi.web.id/v1/health:clinical-tables/icd9-sg?terms=appendectomy&page=1&limit=10&fields=code%2Ccode_dotted%2Cshort_name&extraFields=code%2Ccode_dotted&searchFields=code%2Ccode_dotted%2Cshort_name&codeField=code&filter=code%3A47*", headers={"x-api-key": "YOUR_API_KEY"}) data = r.json() ``` **Example response:** ```json { "page": 1, "count": 3, "items": [ { "code": "4701", "shortName": "Lap appendectomy", "codeDotted": "47.01" }, { "code": "4709", "shortName": "Other appendectomy", "codeDotted": "47.09" }, { "code": "4711", "shortName": "Lap incid appendectomy", "codeDotted": "47.11" } ], "limit": 3, "terms": "appendectomy", "total": 4, "hasMore": true, "nextPage": 2, "provider": "clinical-tables" } ``` --- ### Lab Codes LOINC panels and forms — clinicaltables.nlm.nih.gov `loinc_items`, direct JSON. This is the panels-and-forms subset of LOINC, not the full six-axis lab table: - **Method:** `GET` - **Endpoint:** `https://api.zpi.web.id/v1/health:clinical-tables/lab-codes` - **Cache TTL:** 300s **Parameters:** | Name | Type | Location | Required | Description | |------|------|----------|----------|-------------| | `terms` | string | query | yes | Search text. Several partial words are combined with an implicit AND | | `page` | number | query | no | Page number. Default 1 | | `limit` | number | query | no | Items per page. Default 10, max 500. Page times limit may not exceed 7500 | | `fields` | string | query | no | Comma-separated fields returned as display strings. Allowed: text, LOINC_NUM, LONG_COMMON_NAME, COMPONENT, PROPERTY, RELATEDNAMES2, METHOD_TYP, SHORTNAME, CONSUMER_NAME, SURVEY_QUEST_TEXT, AnswerLists, units, datatype, isCopyrighted, containsCopyrighted, EXTERNAL_COPYRIGHT_NOTICE. | | `extraFields` | string | query | no | Comma-separated fields returned with their native types, so objects and arrays stay structured. Accepts field:alias. Allowed: text, LOINC_NUM, LONG_COMMON_NAME, COMPONENT, PROPERTY, RELATEDNAMES2, METHOD_TYP, SHORTNAME, CONSUMER_NAME, SURVEY_QUEST_TEXT, AnswerLists, units, datatype, isCopyrighted, containsCopyrighted, EXTERNAL_COPYRIGHT_NOTICE. | | `searchFields` | string | query | no | Comma-separated fields the search text is matched against. Allowed: text, LOINC_NUM, LONG_COMMON_NAME, COMPONENT, PROPERTY, RELATEDNAMES2, METHOD_TYP, SHORTNAME, CONSUMER_NAME, SURVEY_QUEST_TEXT, AnswerLists, units, datatype, isCopyrighted, containsCopyrighted, EXTERNAL_COPYRIGHT_NOTICE. | | `codeField` | string | query | no | The single field to report as each item's code. Allowed: text, LOINC_NUM, LONG_COMMON_NAME, COMPONENT, PROPERTY, RELATEDNAMES2, METHOD_TYP, SHORTNAME, CONSUMER_NAME, SURVEY_QUEST_TEXT, AnswerLists, units, datatype, isCopyrighted, containsCopyrighted, EXTERNAL_COPYRIGHT_NOTICE. | | `filter` | string | query | no | Elasticsearch query-string filter applied on top of the search text. It is not wildcarded automatically | | `type` | enum(question|form|panel) | query | no | Restrict to questions, forms or panels. Default searches questions and panel names together | | `available` | enum(true|false) | query | no | With true, only forms whose definition the form-definition endpoint can return | | `excludeCopyrighted` | enum(true|false) | query | no | With true, drop items that are copyrighted or carry a copyrighted item. Default false | **cURL:** ```bash curl "https://api.zpi.web.id/v1/health:clinical-tables/lab-codes?terms=glucose&page=1&limit=10&fields=text%2CLOINC_NUM%2CLONG_COMMON_NAME&extraFields=RELATEDNAMES2%2CAnswerLists&searchFields=text%2CLOINC_NUM%2CLONG_COMMON_NAME&codeField=LOINC_NUM&filter=isCopyrighted%3Afalse&type=panel&available=true&excludeCopyrighted=false" \ -H "x-api-key: YOUR_API_KEY" ``` **JavaScript / TypeScript:** ```javascript const res = await fetch("https://api.zpi.web.id/v1/health:clinical-tables/lab-codes?terms=glucose&page=1&limit=10&fields=text%2CLOINC_NUM%2CLONG_COMMON_NAME&extraFields=RELATEDNAMES2%2CAnswerLists&searchFields=text%2CLOINC_NUM%2CLONG_COMMON_NAME&codeField=LOINC_NUM&filter=isCopyrighted%3Afalse&type=panel&available=true&excludeCopyrighted=false", { headers: { "x-api-key": process.env.ZAPI_KEY } }); const data = await res.json(); ``` **Python:** ```python import requests r = requests.get("https://api.zpi.web.id/v1/health:clinical-tables/lab-codes?terms=glucose&page=1&limit=10&fields=text%2CLOINC_NUM%2CLONG_COMMON_NAME&extraFields=RELATEDNAMES2%2CAnswerLists&searchFields=text%2CLOINC_NUM%2CLONG_COMMON_NAME&codeField=LOINC_NUM&filter=isCopyrighted%3Afalse&type=panel&available=true&excludeCopyrighted=false", headers={"x-api-key": "YOUR_API_KEY"}) data = r.json() ``` **Example response:** ```json { "page": 1, "count": 3, "items": [ { "code": "101652-6", "text": "Somatotropin & glucose post glucose stimulation panel", "loincNum": "101652-6", "relatednames2": "After; CHEMISTRY.CHALLENGE TESTING; GH; GH + Glc pst Glc stim pnl; Glu; Glu tol; Gluc; Glucose tolerance; Glucoseur; Growth hormone; GTT; HGH; Human growth hormone; Pan; PANEL.CHALLENGE; Panl; Pl; Plasma; Plsm; Pnl; Point in time; PST; Random; SerP; SerPl; SerPlas; Serum; Serum or plasma; Somatotropic hormone; SR; STH; Stim", "longCommonName": "Somatotropin and glucose post glucose stimulation panel - Serum or Plasma" }, { "code": "43151-0", "text": "Glucose meter device panel", "loincNum": "43151-0", "relatednames2": "Glu; Gluc; Glucose Meter Device Pnl; Glucoseur; Pan; Panel.devices; Panl; Pnl; Point in time; Random", "longCommonName": "Glucose meter device panel" }, { "code": "74790-7", "text": "Glucose challenge panel", "loincNum": "74790-7", "relatednames2": "Breath; CHEMISTRY.CHALLENGE TESTING; ExG; Exhaled gas; Exhaled gas (=breath); Gases; Glu; Glu tol; Gluc; Glucose HBT; Glucose HBT Pnl; Glucose tolerance; Glucoseur; GTT; Pan; PANEL.CHALLENGE; Panl; Pnl; Point in time; QNT; Quan; Quant; Quantitative; Random", "longCommonName": "Glucose challenge (hydrogen breath test) panel - Exhaled gas" } ], "limit": 3, "terms": "glucose", "total": 33, "hasMore": true, "nextPage": 2, "provider": "clinical-tables" } ``` --- ### Procedures Procedure names — clinicaltables.nlm.nih.gov `procedures`, direct JSON, no key. The service answers with a positional array [total, codes, extra, displayRows] - **Method:** `GET` - **Endpoint:** `https://api.zpi.web.id/v1/health:clinical-tables/procedures` - **Cache TTL:** 300s **Parameters:** | Name | Type | Location | Required | Description | |------|------|----------|----------|-------------| | `terms` | string | query | yes | Search text. Several partial words are combined with an implicit AND | | `page` | number | query | no | Page number. Default 1 | | `limit` | number | query | no | Items per page. Default 10, max 500. Page times limit may not exceed 7500 | | `fields` | string | query | no | Comma-separated fields returned as display strings. Allowed: primary_name, consumer_name, key_id, term_icd9_code, term_icd9_text, word_synonyms, synonyms, info_link_data. | | `extraFields` | string | query | no | Comma-separated fields returned with their native types, so objects and arrays stay structured. Accepts field:alias. Allowed: primary_name, consumer_name, key_id, term_icd9_code, term_icd9_text, word_synonyms, synonyms, info_link_data. | | `searchFields` | string | query | no | Comma-separated fields the search text is matched against. Allowed: primary_name, consumer_name, key_id, term_icd9_code, term_icd9_text, word_synonyms, synonyms, info_link_data. | | `codeField` | string | query | no | The single field to report as each item's code. Allowed: primary_name, consumer_name, key_id, term_icd9_code, term_icd9_text, word_synonyms, synonyms, info_link_data. | | `filter` | string | query | no | Elasticsearch query-string filter applied on top of the search text. It is not wildcarded automatically | **cURL:** ```bash curl "https://api.zpi.web.id/v1/health:clinical-tables/procedures?terms=appendectomy&page=1&limit=10&fields=primary_name%2Cconsumer_name%2Ckey_id&extraFields=synonyms%2Cword_synonyms&searchFields=primary_name%2Cconsumer_name%2Ckey_id&codeField=key_id&filter=primary_name%3Aappend*" \ -H "x-api-key: YOUR_API_KEY" ``` **JavaScript / TypeScript:** ```javascript const res = await fetch("https://api.zpi.web.id/v1/health:clinical-tables/procedures?terms=appendectomy&page=1&limit=10&fields=primary_name%2Cconsumer_name%2Ckey_id&extraFields=synonyms%2Cword_synonyms&searchFields=primary_name%2Cconsumer_name%2Ckey_id&codeField=key_id&filter=primary_name%3Aappend*", { headers: { "x-api-key": process.env.ZAPI_KEY } }); const data = await res.json(); ``` **Python:** ```python import requests r = requests.get("https://api.zpi.web.id/v1/health:clinical-tables/procedures?terms=appendectomy&page=1&limit=10&fields=primary_name%2Cconsumer_name%2Ckey_id&extraFields=synonyms%2Cword_synonyms&searchFields=primary_name%2Cconsumer_name%2Ckey_id&codeField=key_id&filter=primary_name%3Aappend*", headers={"x-api-key": "YOUR_API_KEY"}) data = r.json() ``` **Example response:** ```json { "page": 1, "count": 1, "items": [ { "code": "377", "keyId": "377", "synonyms": [ "appy" ], "primaryName": "Appendectomy", "consumerName": "Appendectomy" } ], "limit": 3, "terms": "appendectomy", "total": 1, "hasMore": false, "nextPage": null, "provider": "clinical-tables" } ``` --- ### Providers Individual NPI registry — individual providers — clinicaltables.nlm.nih.gov `npi_idv`, direct JSON, no key. The service answers with a positional array [total, codes, extra, displayRows] - **Method:** `GET` - **Endpoint:** `https://api.zpi.web.id/v1/health:clinical-tables/providers-individual` - **Cache TTL:** 300s **Parameters:** | Name | Type | Location | Required | Description | |------|------|----------|----------|-------------| | `terms` | string | query | yes | Search text. Several partial words are combined with an implicit AND | | `page` | number | query | no | Page number. Default 1 | | `limit` | number | query | no | Items per page. Default 10, max 500. Page times limit may not exceed 7500 | | `fields` | string | query | no | Comma-separated fields returned as display strings. Allowed: NPI, provider_type, gender, name, name.full, name.last, name.first, name.middle, name.credential, name.prefix, name.suffix, addr_practice, addr_practice.full, addr_practice.line1, addr_practice.line2, addr_practice.city, addr_practice.state, addr_practice.zip, addr_practice.phone, addr_practice.fax, addr_practice.country, addr_mailing, addr_mailing.full, addr_mailing.line1, addr_mailing.line2, addr_mailing.city, addr_mailing.state, addr_mailing.zip, addr_mailing.phone, addr_mailing.fax, addr_mailing.country, name_other, name_other.full, name_other.last, name_other.first, name_other.middle, name_other.credential, name_other.prefix, name_other.suffix, licenses, licenses.taxonomy, licenses.taxonomy.code, licenses.taxonomy.grouping, licenses.taxonomy.classification, licenses.taxonomy.specialization, licenses.medicare, licenses.medicare.spc_code, licenses.medicare.type, other_ids, other_ids.id, other_ids.type, other_ids.issuer, other_ids.state, misc, misc.auth_official, misc.replacement_NPI, misc.EIN, misc.enumeration_date, misc.last_update_date, misc.is_sole_proprietor, misc.is_org_subpart, misc.parent_LBN, misc.parent_TIN. | | `extraFields` | string | query | no | Comma-separated fields returned with their native types, so objects and arrays stay structured. Accepts field:alias. Allowed: NPI, provider_type, gender, name, name.full, name.last, name.first, name.middle, name.credential, name.prefix, name.suffix, addr_practice, addr_practice.full, addr_practice.line1, addr_practice.line2, addr_practice.city, addr_practice.state, addr_practice.zip, addr_practice.phone, addr_practice.fax, addr_practice.country, addr_mailing, addr_mailing.full, addr_mailing.line1, addr_mailing.line2, addr_mailing.city, addr_mailing.state, addr_mailing.zip, addr_mailing.phone, addr_mailing.fax, addr_mailing.country, name_other, name_other.full, name_other.last, name_other.first, name_other.middle, name_other.credential, name_other.prefix, name_other.suffix, licenses, licenses.taxonomy, licenses.taxonomy.code, licenses.taxonomy.grouping, licenses.taxonomy.classification, licenses.taxonomy.specialization, licenses.medicare, licenses.medicare.spc_code, licenses.medicare.type, other_ids, other_ids.id, other_ids.type, other_ids.issuer, other_ids.state, misc, misc.auth_official, misc.replacement_NPI, misc.EIN, misc.enumeration_date, misc.last_update_date, misc.is_sole_proprietor, misc.is_org_subpart, misc.parent_LBN, misc.parent_TIN. | | `searchFields` | string | query | no | Comma-separated fields the search text is matched against. Allowed: NPI, provider_type, gender, name, name.full, name.last, name.first, name.middle, name.credential, name.prefix, name.suffix, addr_practice, addr_practice.full, addr_practice.line1, addr_practice.line2, addr_practice.city, addr_practice.state, addr_practice.zip, addr_practice.phone, addr_practice.fax, addr_practice.country, addr_mailing, addr_mailing.full, addr_mailing.line1, addr_mailing.line2, addr_mailing.city, addr_mailing.state, addr_mailing.zip, addr_mailing.phone, addr_mailing.fax, addr_mailing.country, name_other, name_other.full, name_other.last, name_other.first, name_other.middle, name_other.credential, name_other.prefix, name_other.suffix, licenses, licenses.taxonomy, licenses.taxonomy.code, licenses.taxonomy.grouping, licenses.taxonomy.classification, licenses.taxonomy.specialization, licenses.medicare, licenses.medicare.spc_code, licenses.medicare.type, other_ids, other_ids.id, other_ids.type, other_ids.issuer, other_ids.state, misc, misc.auth_official, misc.replacement_NPI, misc.EIN, misc.enumeration_date, misc.last_update_date, misc.is_sole_proprietor, misc.is_org_subpart, misc.parent_LBN, misc.parent_TIN. | | `codeField` | string | query | no | The single field to report as each item's code. Allowed: NPI, provider_type, gender, name, name.full, name.last, name.first, name.middle, name.credential, name.prefix, name.suffix, addr_practice, addr_practice.full, addr_practice.line1, addr_practice.line2, addr_practice.city, addr_practice.state, addr_practice.zip, addr_practice.phone, addr_practice.fax, addr_practice.country, addr_mailing, addr_mailing.full, addr_mailing.line1, addr_mailing.line2, addr_mailing.city, addr_mailing.state, addr_mailing.zip, addr_mailing.phone, addr_mailing.fax, addr_mailing.country, name_other, name_other.full, name_other.last, name_other.first, name_other.middle, name_other.credential, name_other.prefix, name_other.suffix, licenses, licenses.taxonomy, licenses.taxonomy.code, licenses.taxonomy.grouping, licenses.taxonomy.classification, licenses.taxonomy.specialization, licenses.medicare, licenses.medicare.spc_code, licenses.medicare.type, other_ids, other_ids.id, other_ids.type, other_ids.issuer, other_ids.state, misc, misc.auth_official, misc.replacement_NPI, misc.EIN, misc.enumeration_date, misc.last_update_date, misc.is_sole_proprietor, misc.is_org_subpart, misc.parent_LBN, misc.parent_TIN. | | `filter` | string | query | no | Elasticsearch query-string filter applied on top of the search text. It is not wildcarded automatically | **cURL:** ```bash curl "https://api.zpi.web.id/v1/health:clinical-tables/providers-individual?terms=john%20smith&page=1&limit=10&fields=NPI%2Cprovider_type%2Cgender&extraFields=name%2Caddr_practice&searchFields=NPI%2Cprovider_type%2Cgender&codeField=NPI&filter=addr_practice.state%3APA" \ -H "x-api-key: YOUR_API_KEY" ``` **JavaScript / TypeScript:** ```javascript const res = await fetch("https://api.zpi.web.id/v1/health:clinical-tables/providers-individual?terms=john%20smith&page=1&limit=10&fields=NPI%2Cprovider_type%2Cgender&extraFields=name%2Caddr_practice&searchFields=NPI%2Cprovider_type%2Cgender&codeField=NPI&filter=addr_practice.state%3APA", { headers: { "x-api-key": process.env.ZAPI_KEY } }); const data = await res.json(); ``` **Python:** ```python import requests r = requests.get("https://api.zpi.web.id/v1/health:clinical-tables/providers-individual?terms=john%20smith&page=1&limit=10&fields=NPI%2Cprovider_type%2Cgender&extraFields=name%2Caddr_practice&searchFields=NPI%2Cprovider_type%2Cgender&codeField=NPI&filter=addr_practice.state%3APA", headers={"x-api-key": "YOUR_API_KEY"}) data = r.json() ``` **Example response:** ```json { "page": 1, "count": 0, "items": [], "limit": 3, "terms": "john smith", "total": 0, "hasMore": false, "nextPage": null, "provider": "clinical-tables" } ``` --- ### Providers Organisation NPI registry — organisation providers — clinicaltables.nlm.nih.gov `npi_org`, direct JSON, no key. The service answers with a positional array [total, codes, extra, displayRows] - **Method:** `GET` - **Endpoint:** `https://api.zpi.web.id/v1/health:clinical-tables/providers-organisation` - **Cache TTL:** 300s **Parameters:** | Name | Type | Location | Required | Description | |------|------|----------|----------|-------------| | `terms` | string | query | yes | Search text. Several partial words are combined with an implicit AND | | `page` | number | query | no | Page number. Default 1 | | `limit` | number | query | no | Items per page. Default 10, max 500. Page times limit may not exceed 7500 | | `fields` | string | query | no | Comma-separated fields returned as display strings. Allowed: NPI, provider_type, name, name.full, name.last, name.first, name.middle, name.credential, name.prefix, name.suffix, addr_practice, addr_practice.full, addr_practice.line1, addr_practice.line2, addr_practice.city, addr_practice.state, addr_practice.zip, addr_practice.phone, addr_practice.fax, addr_practice.country, addr_mailing, addr_mailing.full, addr_mailing.line1, addr_mailing.line2, addr_mailing.city, addr_mailing.state, addr_mailing.zip, addr_mailing.phone, addr_mailing.fax, addr_mailing.country, name_other, name_other.full, name_other.last, name_other.first, name_other.middle, name_other.credential, name_other.prefix, name_other.suffix, licenses, licenses.taxonomy, licenses.taxonomy.code, licenses.taxonomy.grouping, licenses.taxonomy.classification, licenses.taxonomy.specialization, licenses.medicare, licenses.medicare.spc_code, licenses.medicare.type, other_ids, other_ids.id, other_ids.type, other_ids.issuer, other_ids.state, misc, misc.auth_official, misc.replacement_NPI, misc.EIN, misc.enumeration_date, misc.last_update_date, misc.is_sole_proprietor, misc.is_org_subpart, misc.parent_LBN, misc.parent_TIN. | | `extraFields` | string | query | no | Comma-separated fields returned with their native types, so objects and arrays stay structured. Accepts field:alias. Allowed: NPI, provider_type, name, name.full, name.last, name.first, name.middle, name.credential, name.prefix, name.suffix, addr_practice, addr_practice.full, addr_practice.line1, addr_practice.line2, addr_practice.city, addr_practice.state, addr_practice.zip, addr_practice.phone, addr_practice.fax, addr_practice.country, addr_mailing, addr_mailing.full, addr_mailing.line1, addr_mailing.line2, addr_mailing.city, addr_mailing.state, addr_mailing.zip, addr_mailing.phone, addr_mailing.fax, addr_mailing.country, name_other, name_other.full, name_other.last, name_other.first, name_other.middle, name_other.credential, name_other.prefix, name_other.suffix, licenses, licenses.taxonomy, licenses.taxonomy.code, licenses.taxonomy.grouping, licenses.taxonomy.classification, licenses.taxonomy.specialization, licenses.medicare, licenses.medicare.spc_code, licenses.medicare.type, other_ids, other_ids.id, other_ids.type, other_ids.issuer, other_ids.state, misc, misc.auth_official, misc.replacement_NPI, misc.EIN, misc.enumeration_date, misc.last_update_date, misc.is_sole_proprietor, misc.is_org_subpart, misc.parent_LBN, misc.parent_TIN. | | `searchFields` | string | query | no | Comma-separated fields the search text is matched against. Allowed: NPI, provider_type, name, name.full, name.last, name.first, name.middle, name.credential, name.prefix, name.suffix, addr_practice, addr_practice.full, addr_practice.line1, addr_practice.line2, addr_practice.city, addr_practice.state, addr_practice.zip, addr_practice.phone, addr_practice.fax, addr_practice.country, addr_mailing, addr_mailing.full, addr_mailing.line1, addr_mailing.line2, addr_mailing.city, addr_mailing.state, addr_mailing.zip, addr_mailing.phone, addr_mailing.fax, addr_mailing.country, name_other, name_other.full, name_other.last, name_other.first, name_other.middle, name_other.credential, name_other.prefix, name_other.suffix, licenses, licenses.taxonomy, licenses.taxonomy.code, licenses.taxonomy.grouping, licenses.taxonomy.classification, licenses.taxonomy.specialization, licenses.medicare, licenses.medicare.spc_code, licenses.medicare.type, other_ids, other_ids.id, other_ids.type, other_ids.issuer, other_ids.state, misc, misc.auth_official, misc.replacement_NPI, misc.EIN, misc.enumeration_date, misc.last_update_date, misc.is_sole_proprietor, misc.is_org_subpart, misc.parent_LBN, misc.parent_TIN. | | `codeField` | string | query | no | The single field to report as each item's code. Allowed: NPI, provider_type, name, name.full, name.last, name.first, name.middle, name.credential, name.prefix, name.suffix, addr_practice, addr_practice.full, addr_practice.line1, addr_practice.line2, addr_practice.city, addr_practice.state, addr_practice.zip, addr_practice.phone, addr_practice.fax, addr_practice.country, addr_mailing, addr_mailing.full, addr_mailing.line1, addr_mailing.line2, addr_mailing.city, addr_mailing.state, addr_mailing.zip, addr_mailing.phone, addr_mailing.fax, addr_mailing.country, name_other, name_other.full, name_other.last, name_other.first, name_other.middle, name_other.credential, name_other.prefix, name_other.suffix, licenses, licenses.taxonomy, licenses.taxonomy.code, licenses.taxonomy.grouping, licenses.taxonomy.classification, licenses.taxonomy.specialization, licenses.medicare, licenses.medicare.spc_code, licenses.medicare.type, other_ids, other_ids.id, other_ids.type, other_ids.issuer, other_ids.state, misc, misc.auth_official, misc.replacement_NPI, misc.EIN, misc.enumeration_date, misc.last_update_date, misc.is_sole_proprietor, misc.is_org_subpart, misc.parent_LBN, misc.parent_TIN. | | `filter` | string | query | no | Elasticsearch query-string filter applied on top of the search text. It is not wildcarded automatically | **cURL:** ```bash curl "https://api.zpi.web.id/v1/health:clinical-tables/providers-organisation?terms=hospital&page=1&limit=10&fields=NPI%2Cprovider_type%2Cname.full&extraFields=name%2Caddr_practice&searchFields=NPI%2Cprovider_type%2Cname.full&codeField=NPI&filter=addr_practice.state%3ATX" \ -H "x-api-key: YOUR_API_KEY" ``` **JavaScript / TypeScript:** ```javascript const res = await fetch("https://api.zpi.web.id/v1/health:clinical-tables/providers-organisation?terms=hospital&page=1&limit=10&fields=NPI%2Cprovider_type%2Cname.full&extraFields=name%2Caddr_practice&searchFields=NPI%2Cprovider_type%2Cname.full&codeField=NPI&filter=addr_practice.state%3ATX", { headers: { "x-api-key": process.env.ZAPI_KEY } }); const data = await res.json(); ``` **Python:** ```python import requests r = requests.get("https://api.zpi.web.id/v1/health:clinical-tables/providers-organisation?terms=hospital&page=1&limit=10&fields=NPI%2Cprovider_type%2Cname.full&extraFields=name%2Caddr_practice&searchFields=NPI%2Cprovider_type%2Cname.full&codeField=NPI&filter=addr_practice.state%3ATX", headers={"x-api-key": "YOUR_API_KEY"}) data = r.json() ``` **Example response:** ```json { "page": 1, "count": 3, "items": [ { "npi": "1821205840", "code": "1821205840", "name": { "full": "HOSPITAL" }, "nameFull": "HOSPITAL", "addrPractice": { "zip": "75115", "city": "DESOTO", "full": "605 AUSTIN DR, DESOTO, TX 75115", "zip4": "6605", "line1": "605 AUSTIN DR", "phone": "(972) 230-0854", "state": "TX", "country": "US" }, "providerType": "Hospital-General" }, { "npi": "1922162403", "code": "1922162403", "name": { "full": "INNOVA HOSPITAL HOUSTON LP DBA INNOVA HOSPITAL HOUSTON" }, "nameFull": "INNOVA HOSPITAL HOUSTON LP DBA INNOVA HOSPITAL HOUSTON", "addrPractice": { "zip": "77004", "city": "HOUSTON", "full": "2001 HERMANN DR, HOUSTON, TX 77004", "zip4": "7321", "line1": "2001 HERMANN DR", "phone": "(713) 358-5300", "state": "TX", "country": "US" }, "providerType": "Hospital-General" }, { "npi": "1114293701", "code": "1114293701", "name": { "full": "REDOAK HOSPITAL" }, "nameFull": "REDOAK HOSPITAL", "addrPractice": { "fax": "(281) 605-4563", "zip": "77090", "city": "HOUSTON", "full": "17440 REDOAK DR, HOUSTON, TX 77090", "line1": "17440 REDOAK DR", "phone": "(281) 257-0404", "state": "TX", "country": "US" }, "providerType": "Hospital-General" } ], "limit": 3, "terms": "hospital", "total": 5386, "hasMore": true, "nextPage": 2, "provider": "clinical-tables" } ``` --- ### Refseqs RefSeq transcript accessions — clinicaltables.nlm.nih.gov `refseqs`, direct JSON, no key. The service answers with a positional array [total, codes, extra, displayRows] - **Method:** `GET` - **Endpoint:** `https://api.zpi.web.id/v1/health:clinical-tables/refseqs` - **Cache TTL:** 300s **Parameters:** | Name | Type | Location | Required | Description | |------|------|----------|----------|-------------| | `terms` | string | query | yes | Search text. Several partial words are combined with an implicit AND | | `page` | number | query | no | Page number. Default 1 | | `limit` | number | query | no | Items per page. Default 10, max 500. Page times limit may not exceed 7500 | | `fields` | string | query | no | Comma-separated fields returned as display strings. Allowed: RefSeq, gene, NP_RefSeq, NC_RefSeq. | | `extraFields` | string | query | no | Comma-separated fields returned with their native types, so objects and arrays stay structured. Accepts field:alias. Allowed: RefSeq, gene, NP_RefSeq, NC_RefSeq. | | `searchFields` | string | query | no | Comma-separated fields the search text is matched against. Allowed: RefSeq, gene, NP_RefSeq, NC_RefSeq. | | `codeField` | string | query | no | The single field to report as each item's code. Allowed: RefSeq, gene, NP_RefSeq, NC_RefSeq. | | `filter` | string | query | no | Elasticsearch query-string filter applied on top of the search text. It is not wildcarded automatically | **cURL:** ```bash curl "https://api.zpi.web.id/v1/health:clinical-tables/refseqs?terms=BRCA1&page=1&limit=10&fields=RefSeq%2Cgene%2CNP_RefSeq&extraFields=RefSeq%2Cgene&searchFields=RefSeq%2Cgene%2CNP_RefSeq&codeField=RefSeq&filter=gene%3ABRCA1" \ -H "x-api-key: YOUR_API_KEY" ``` **JavaScript / TypeScript:** ```javascript const res = await fetch("https://api.zpi.web.id/v1/health:clinical-tables/refseqs?terms=BRCA1&page=1&limit=10&fields=RefSeq%2Cgene%2CNP_RefSeq&extraFields=RefSeq%2Cgene&searchFields=RefSeq%2Cgene%2CNP_RefSeq&codeField=RefSeq&filter=gene%3ABRCA1", { headers: { "x-api-key": process.env.ZAPI_KEY } }); const data = await res.json(); ``` **Python:** ```python import requests r = requests.get("https://api.zpi.web.id/v1/health:clinical-tables/refseqs?terms=BRCA1&page=1&limit=10&fields=RefSeq%2Cgene%2CNP_RefSeq&extraFields=RefSeq%2Cgene&searchFields=RefSeq%2Cgene%2CNP_RefSeq&codeField=RefSeq&filter=gene%3ABRCA1", headers={"x-api-key": "YOUR_API_KEY"}) data = r.json() ``` **Example response:** ```json { "page": 1, "count": 3, "items": [ { "code": "NM_007300.3", "gene": "BRCA1", "refSeq": "NM_007300.3", "npRefSeq": "NP_009231.2" }, { "code": "NR_027676.1", "gene": "BRCA1", "refSeq": "NR_027676.1" }, { "code": "NM_007294.3", "gene": "BRCA1", "refSeq": "NM_007294.3", "npRefSeq": "NP_009225.1" } ], "limit": 3, "terms": "BRCA1", "total": 11, "hasMore": true, "nextPage": 2, "provider": "clinical-tables" } ``` --- ### Search Generic Clinical Table Search — one grammar over all 22 keyless NLM tables. The escape hatch for the per-table endpoints: a table added upstream is reachable here without a new handler. - **Method:** `GET` - **Endpoint:** `https://api.zpi.web.id/v1/health:clinical-tables/search` - **Cache TTL:** 300s **Parameters:** | Name | Type | Location | Required | Description | |------|------|----------|----------|-------------| | `table` | enum(conditions|cosmic_struct|cytogenetic_locs|dbvar|disease_names|drug_ingredients|hcpcs|hpo|icd10cm|icd11_codes|icd9cm_dx|icd9cm_sg|loinc_items|ncbi_genes|npi_idv|npi_org|procedures|refseqs|rxterms|snps|star_alleles|ucum) | query | yes | The NLM clinical table to search | | `terms` | string | query | yes | Search text. Several partial words are combined with an implicit AND | | `page` | number | query | no | Page number. Default 1 | | `limit` | number | query | no | Items per page. Default 10, max 500. Page times limit may not exceed 7500 | | `fields` | string | query | no | Comma-separated fields returned as display strings. Each table has its own field list, and a name outside it is rejected rather than passed on | | `extraFields` | string | query | no | Comma-separated fields returned with their native types, so objects and arrays stay structured. Accepts field:alias | | `searchFields` | string | query | no | Comma-separated fields the search text is matched against | | `codeField` | string | query | no | The single field to report as each item's code | | `filter` | string | query | no | Elasticsearch query-string filter applied on top of the search text. It is not wildcarded automatically | | `type` | enum(question|form|panel) | query | no | loinc_items only. Restrict to questions, forms or panels | | `available` | enum(true|false) | query | no | loinc_items only. With true, only forms whose definition this service can return | | `excludeCopyrighted` | enum(true|false) | query | no | loinc_items only. With true, drop copyrighted items. Default false | | `codeType` | enum(stem|extension|category) | query | no | icd11_codes only. Restrict to stem codes, extension codes, or both | | `genomeBuild` | enum(37|38) | query | no | cosmic_struct only. GRCh human genome build the coordinates refer to | **cURL:** ```bash curl "https://api.zpi.web.id/v1/health:clinical-tables/search?table=icd10cm&terms=diabetes&page=1&limit=10&fields=code%2Cname&extraFields=synonyms&searchFields=code%2Cname&codeField=code&filter=code%3AE11*&type=panel&available=true&excludeCopyrighted=false&codeType=stem&genomeBuild=38" \ -H "x-api-key: YOUR_API_KEY" ``` **JavaScript / TypeScript:** ```javascript const res = await fetch("https://api.zpi.web.id/v1/health:clinical-tables/search?table=icd10cm&terms=diabetes&page=1&limit=10&fields=code%2Cname&extraFields=synonyms&searchFields=code%2Cname&codeField=code&filter=code%3AE11*&type=panel&available=true&excludeCopyrighted=false&codeType=stem&genomeBuild=38", { headers: { "x-api-key": process.env.ZAPI_KEY } }); const data = await res.json(); ``` **Python:** ```python import requests r = requests.get("https://api.zpi.web.id/v1/health:clinical-tables/search?table=icd10cm&terms=diabetes&page=1&limit=10&fields=code%2Cname&extraFields=synonyms&searchFields=code%2Cname&codeField=code&filter=code%3AE11*&type=panel&available=true&excludeCopyrighted=false&codeType=stem&genomeBuild=38", headers={"x-api-key": "YOUR_API_KEY"}) data = r.json() ``` **Example response:** ```json { "page": 1, "count": 10, "items": [ { "code": "E23.2", "name": "Diabetes insipidus" }, { "code": "N25.1", "name": "Nephrogenic diabetes insipidus" }, { "code": "P70.2", "name": "Neonatal diabetes mellitus" }, { "code": "O24.92", "name": "Unspecified diabetes mellitus in childbirth" }, { "code": "Z83.3", "name": "Family history of diabetes mellitus" }, { "code": "Z86.32", "name": "Personal history of gestational diabetes" }, { "code": "E10.65", "name": "Type 1 diabetes mellitus with hyperglycemia" }, { "code": "E10.9", "name": "Type 1 diabetes mellitus without complications" } ], "limit": 10, "table": "icd10cm", "terms": "diabetes", "total": 481, "hasMore": true, "nextPage": 2, "provider": "clinical-tables" } ``` --- ### Snps dbSNP reference SNPs — clinicaltables.nlm.nih.gov `snps`, direct JSON, no key. The service answers with a positional array [total, codes, extra, displayRows] - **Method:** `GET` - **Endpoint:** `https://api.zpi.web.id/v1/health:clinical-tables/snps` - **Cache TTL:** 300s **Parameters:** | Name | Type | Location | Required | Description | |------|------|----------|----------|-------------| | `terms` | string | query | yes | Search text. Several partial words are combined with an implicit AND | | `page` | number | query | no | Page number. Default 1 | | `limit` | number | query | no | Items per page. Default 10, max 500. Page times limit may not exceed 7500 | | `fields` | string | query | no | Comma-separated fields returned as display strings. Allowed: rsNum, 38.alleles, 38.chr, 38.pos, 38.gene, 38.assembly, 38.seqID, 37.alleles, 37.chr, 37.pos, 37.gene, 37.assembly, 37.seqID. | | `extraFields` | string | query | no | Comma-separated fields returned with their native types, so objects and arrays stay structured. Accepts field:alias. Allowed: rsNum, 38.alleles, 38.chr, 38.pos, 38.gene, 38.assembly, 38.seqID, 37.alleles, 37.chr, 37.pos, 37.gene, 37.assembly, 37.seqID. | | `searchFields` | string | query | no | Comma-separated fields the search text is matched against. Allowed: rsNum, 38.alleles, 38.chr, 38.pos, 38.gene, 38.assembly, 38.seqID, 37.alleles, 37.chr, 37.pos, 37.gene, 37.assembly, 37.seqID. | | `codeField` | string | query | no | The single field to report as each item's code. Allowed: rsNum, 38.alleles, 38.chr, 38.pos, 38.gene, 38.assembly, 38.seqID, 37.alleles, 37.chr, 37.pos, 37.gene, 37.assembly, 37.seqID. | | `filter` | string | query | no | Elasticsearch query-string filter applied on top of the search text. It is not wildcarded automatically | **cURL:** ```bash curl "https://api.zpi.web.id/v1/health:clinical-tables/snps?terms=rs1000&page=1&limit=10&fields=rsNum%2C38.chr%2C38.pos&extraFields=rsNum%2C38.chr&searchFields=rsNum%2C38.chr%2C38.pos&codeField=rsNum&filter=38.chr%3A6" \ -H "x-api-key: YOUR_API_KEY" ``` **JavaScript / TypeScript:** ```javascript const res = await fetch("https://api.zpi.web.id/v1/health:clinical-tables/snps?terms=rs1000&page=1&limit=10&fields=rsNum%2C38.chr%2C38.pos&extraFields=rsNum%2C38.chr&searchFields=rsNum%2C38.chr%2C38.pos&codeField=rsNum&filter=38.chr%3A6", { headers: { "x-api-key": process.env.ZAPI_KEY } }); const data = await res.json(); ``` **Python:** ```python import requests r = requests.get("https://api.zpi.web.id/v1/health:clinical-tables/snps?terms=rs1000&page=1&limit=10&fields=rsNum%2C38.chr%2C38.pos&extraFields=rsNum%2C38.chr&searchFields=rsNum%2C38.chr%2C38.pos&codeField=rsNum&filter=38.chr%3A6", headers={"x-api-key": "YOUR_API_KEY"}) data = r.json() ``` **Example response:** ```json { "page": 1, "count": 3, "items": [ { "code": "rs1000", "chr38": "6", "pos38": "32186117", "rsNum": "rs1000" }, { "code": "rs1000000629", "chr38": "6", "pos38": "33235706", "rsNum": "rs1000000629" }, { "code": "rs1000001594", "chr38": "6", "pos38": "33021616", "rsNum": "rs1000001594" } ], "limit": 3, "terms": "rs1000", "total": 10000, "hasMore": true, "nextPage": 2, "provider": "clinical-tables" } ``` --- ### Star Alleles Pharmacogenomic star alleles — clinicaltables.nlm.nih.gov `star_alleles`, direct JSON, no key. The service answers with a positional array [total, codes, extra, displayRows] - **Method:** `GET` - **Endpoint:** `https://api.zpi.web.id/v1/health:clinical-tables/star-alleles` - **Cache TTL:** 300s **Parameters:** | Name | Type | Location | Required | Description | |------|------|----------|----------|-------------| | `terms` | string | query | yes | Search text. Several partial words are combined with an implicit AND | | `page` | number | query | no | Page number. Default 1 | | `limit` | number | query | no | Items per page. Default 10, max 500. Page times limit may not exceed 7500 | | `fields` | string | query | no | Comma-separated fields returned as display strings. Allowed: StarAlleleName, GenBank, ProteinAffected, cDNANucleotideChanges, GeneNucleotideChange, XbaIHaplotype, RFLP, OtherNames, ProteinChange, InVivoEnzymeActivity, InVitroEnzymeActivity, References, ClinicalPhenotype, Notes. | | `extraFields` | string | query | no | Comma-separated fields returned with their native types, so objects and arrays stay structured. Accepts field:alias. Allowed: StarAlleleName, GenBank, ProteinAffected, cDNANucleotideChanges, GeneNucleotideChange, XbaIHaplotype, RFLP, OtherNames, ProteinChange, InVivoEnzymeActivity, InVitroEnzymeActivity, References, ClinicalPhenotype, Notes. | | `searchFields` | string | query | no | Comma-separated fields the search text is matched against. Allowed: StarAlleleName, GenBank, ProteinAffected, cDNANucleotideChanges, GeneNucleotideChange, XbaIHaplotype, RFLP, OtherNames, ProteinChange, InVivoEnzymeActivity, InVitroEnzymeActivity, References, ClinicalPhenotype, Notes. | | `codeField` | string | query | no | The single field to report as each item's code. Allowed: StarAlleleName, GenBank, ProteinAffected, cDNANucleotideChanges, GeneNucleotideChange, XbaIHaplotype, RFLP, OtherNames, ProteinChange, InVivoEnzymeActivity, InVitroEnzymeActivity, References, ClinicalPhenotype, Notes. | | `filter` | string | query | no | Elasticsearch query-string filter applied on top of the search text. It is not wildcarded automatically | **cURL:** ```bash curl "https://api.zpi.web.id/v1/health:clinical-tables/star-alleles?terms=CYP2D6&page=1&limit=10&fields=StarAlleleName%2COtherNames%2CGenBank&extraFields=XbaIHaplotype%2CRFLP&searchFields=StarAlleleName%2COtherNames%2CGenBank&codeField=StarAlleleName&filter=StarAlleleName%3ACYP2D6*" \ -H "x-api-key: YOUR_API_KEY" ``` **JavaScript / TypeScript:** ```javascript const res = await fetch("https://api.zpi.web.id/v1/health:clinical-tables/star-alleles?terms=CYP2D6&page=1&limit=10&fields=StarAlleleName%2COtherNames%2CGenBank&extraFields=XbaIHaplotype%2CRFLP&searchFields=StarAlleleName%2COtherNames%2CGenBank&codeField=StarAlleleName&filter=StarAlleleName%3ACYP2D6*", { headers: { "x-api-key": process.env.ZAPI_KEY } }); const data = await res.json(); ``` **Python:** ```python import requests r = requests.get("https://api.zpi.web.id/v1/health:clinical-tables/star-alleles?terms=CYP2D6&page=1&limit=10&fields=StarAlleleName%2COtherNames%2CGenBank&extraFields=XbaIHaplotype%2CRFLP&searchFields=StarAlleleName%2COtherNames%2CGenBank&codeField=StarAlleleName&filter=StarAlleleName%3ACYP2D6*", headers={"x-api-key": "YOUR_API_KEY"}) data = r.json() ``` **Example response:** ```json { "page": 1, "count": 3, "items": [ { "code": "CYP2D6*18", "otherNames": "CYP2D6(J9)", "xbaIHaplotype": "29", "starAlleleName": "CYP2D6*18" }, { "code": "CYP2D6*1A", "genBank": "M33388.1", "otherNames": "Wild-type", "xbaIHaplotype": "29", "starAlleleName": "CYP2D6*1A" }, { "code": "CYP2D6*1B", "genBank": "M33388.1", "xbaIHaplotype": "29", "starAlleleName": "CYP2D6*1B" } ], "limit": 3, "terms": "CYP2D6", "total": 168, "hasMore": true, "nextPage": 2, "provider": "clinical-tables" } ``` --- ### Units UCUM units of measure — clinicaltables.nlm.nih.gov `ucum`, direct JSON, no key. The service answers with a positional array [total, codes, extra, displayRows] - **Method:** `GET` - **Endpoint:** `https://api.zpi.web.id/v1/health:clinical-tables/units` - **Cache TTL:** 300s **Parameters:** | Name | Type | Location | Required | Description | |------|------|----------|----------|-------------| | `terms` | string | query | yes | Search text. Several partial words are combined with an implicit AND | | `page` | number | query | no | Page number. Default 1 | | `limit` | number | query | no | Items per page. Default 10, max 500. Page times limit may not exceed 7500 | | `fields` | string | query | no | Comma-separated fields returned as display strings. Allowed: cs_code, name, category, synonyms, loinc_property, guidance, source, is_simple, cs_code_tokens. | | `extraFields` | string | query | no | Comma-separated fields returned with their native types, so objects and arrays stay structured. Accepts field:alias. Allowed: cs_code, name, category, synonyms, loinc_property, guidance, source, is_simple, cs_code_tokens. | | `searchFields` | string | query | no | Comma-separated fields the search text is matched against. Allowed: cs_code, name, category, synonyms, loinc_property, guidance, source, is_simple, cs_code_tokens. | | `codeField` | string | query | no | The single field to report as each item's code. Allowed: cs_code, name, category, synonyms, loinc_property, guidance, source, is_simple, cs_code_tokens. | | `filter` | string | query | no | Elasticsearch query-string filter applied on top of the search text. It is not wildcarded automatically | **cURL:** ```bash curl "https://api.zpi.web.id/v1/health:clinical-tables/units?terms=mg&page=1&limit=10&fields=cs_code%2Cname%2Ccategory&extraFields=synonyms%2Ccs_code_tokens&searchFields=cs_code%2Cname%2Ccategory&codeField=cs_code&filter=is_simple%3Atrue" \ -H "x-api-key: YOUR_API_KEY" ``` **JavaScript / TypeScript:** ```javascript const res = await fetch("https://api.zpi.web.id/v1/health:clinical-tables/units?terms=mg&page=1&limit=10&fields=cs_code%2Cname%2Ccategory&extraFields=synonyms%2Ccs_code_tokens&searchFields=cs_code%2Cname%2Ccategory&codeField=cs_code&filter=is_simple%3Atrue", { headers: { "x-api-key": process.env.ZAPI_KEY } }); const data = await res.json(); ``` **Python:** ```python import requests r = requests.get("https://api.zpi.web.id/v1/health:clinical-tables/units?terms=mg&page=1&limit=10&fields=cs_code%2Cname%2Ccategory&extraFields=synonyms%2Ccs_code_tokens&searchFields=cs_code%2Cname%2Ccategory&codeField=cs_code&filter=is_simple%3Atrue", headers={"x-api-key": "YOUR_API_KEY"}) data = r.json() ``` **Example response:** ```json { "page": 1, "count": 1, "items": [ { "code": "mg", "name": "milligram", "csCode": "mg", "category": "Clinical", "synonyms": "milligrams", "csCodeTokens": "mg" } ], "limit": 3, "terms": "mg", "total": 1, "hasMore": false, "nextPage": null, "provider": "clinical-tables" } ``` --- _Generated: 2026-08-30T05:07:39.192Z_