The StateIQ API provides programmatic access to NEMSIS state configuration data, schematron validation rules, and XML validation services. Use our API to validate ePCR records against state-specific requirements, query state configuration details, and search across all 51 US states.
Base URL: https://stateiq.amsler.io/api/v1
All API requests require an API key passed in the x-api-key header.
x-api-key: siq_live_your_key_hereAPI keys are managed through the StateIQ Settings page. Keys have the following scopes:
states:read | Query state data, agencies, facilities, elements |
search:read | Search across all states |
validate:write | Submit XML records for validation |
Rate limit headers are included on every response:
X-RateLimit-Limit: 1000
X-RateLimit-Remaining: 999
X-RateLimit-Reset: 1712134800Default limit is 1,000 requests per hour per API key. Contact us to increase limits for your organization.
The API uses conventional HTTP response codes to indicate success or failure.
| 400 | Bad Request | Invalid parameters |
| 401 | Unauthorized | Missing or invalid API key |
| 403 | Forbidden | Valid key but insufficient scope |
| 429 | Too Many Requests | Rate limit exceeded (1000/hour default) |
| 500 | Internal Error | Server error |
| 503 | Service Unavailable | Validation service offline |
{
"error": "Missing required scope: validate:write",
"code": 403
}/api/v1/healthReturns the current status of the API. This endpoint does not require authentication.
No parameters required.
curl https://stateiq.amsler.io/api/v1/health{
"status": "ok",
"version": "1.0",
"service": "StateIQ API",
"timestamp": "2026-04-03T12:00:00.000Z"
}/api/v1/statesReturns summary data for all 51 US states including agency counts, facility counts, surveillance scores and vendor information.
No parameters required.
curl https://stateiq.amsler.io/api/v1/states \
-H "x-api-key: siq_live_your_key_here"{
"data": [
{
"state_code": "06",
"state_name": "California",
"software_vendor": "ImageTrend, Inc.",
"software_name": "Elite",
"effective_date": "2026-03-03",
"required_elements": 229,
"custom_elements": 0,
"agency_count": 1088,
"facility_count": 10507,
"surveillance_score": 0
},
...
],
"count": 51
}/api/v1/states/{code}Returns detailed information for a specific state including summary data and surveillance flags.
| Name | Type | Required | Description |
|---|---|---|---|
code | path | required | Two-letter state abbreviation (e.g., CA, PA, TX) or FIPS code (e.g., 06, 42, 48) |
curl https://stateiq.amsler.io/api/v1/states/CA \
-H "x-api-key: siq_live_your_key_here"{
"data": {
"state_code": "06",
"state_name": "California",
"software_vendor": "ImageTrend, Inc.",
"software_name": "Elite",
"effective_date": "2026-03-03",
"required_elements": 229,
"custom_elements": 0,
"agency_count": 1088,
"facility_count": 10507,
"surveillance_score": 0,
"surveillance": {
"opioid": false,
"naloxone": false,
"trauma": false,
"homeless": false
},
"hrsa": {
"pc_hpsa_count": 374,
"pc_hpsa_avg_score": 17.80,
"mh_hpsa_count": 312,
"mh_hpsa_avg_score": 16.90
}
}
}/api/v1/states/{code}/agenciesReturns the list of EMS agencies registered in a state.
| Name | Type | Required | Description |
|---|---|---|---|
code | path | required | Two-letter state abbreviation or FIPS code |
limit | query | optional | Maximum number of results (default: 100, max: 1000) |
curl "https://stateiq.amsler.io/api/v1/states/PA/agencies?limit=50" \
-H "x-api-key: siq_live_your_key_here"{
"data": [
{
"id": 12345,
"state_code": "42",
"agency_id": "42001",
"agency_name": "Pittsburgh EMS"
},
...
],
"count": 50
}/api/v1/states/{code}/facilitiesReturns healthcare facilities in a state including hospitals, trauma centers, and other destinations.
| Name | Type | Required | Description |
|---|---|---|---|
code | path | required | Two-letter state abbreviation or FIPS code |
limit | query | optional | Maximum number of results (default: 100, max: 1000) |
type | query | optional | Filter by facility type code (e.g., 1701001 for hospital) |
curl "https://stateiq.amsler.io/api/v1/states/TX/facilities?limit=100" \
-H "x-api-key: siq_live_your_key_here"{
"data": [
{
"id": 98765,
"state_code": "48",
"facility_code": "TX-HOU-001",
"facility_name": "Houston Methodist Hospital",
"facility_type_code": "1701001",
"address": "6565 Fannin St",
"city_code": "Houston",
"state_abbr": "TX",
"zip_code": "77030",
"npi": "1234567890",
"coordinates": "29.7106,-95.3987"
},
...
],
"count": 100
}/api/v1/states/{code}/elementsReturns required and custom NEMSIS elements configured for a state.
| Name | Type | Required | Description |
|---|---|---|---|
code | path | required | Two-letter state abbreviation or FIPS code |
section | query | optional | Filter by NEMSIS section prefix (e.g., eArrest, eMedications) |
type | query | optional | Filter by element type: "required" or "custom" |
curl "https://stateiq.amsler.io/api/v1/states/NY/elements?section=eArrest" \
-H "x-api-key: siq_live_your_key_here"{
"data": {
"required": [
{
"id": 1234,
"state_code": "36",
"element_id": "eArrest.01",
"element_label": "Cardiac Arrest"
},
...
],
"custom": [
{
"id": 5678,
"state_code": "36",
"element_id": "eArrest.NY01",
"label": "Arrest Location Type",
"description": "NY-specific arrest location",
"is_multiselect": false,
"parent_section": "eArrest"
},
...
]
},
"count": 15
}/api/v1/states/{code}/formularyReturns medication formulary for a state organized by certification level.
| Name | Type | Required | Description |
|---|---|---|---|
code | path | required | Two-letter state abbreviation or FIPS code |
detailed | query | optional | Set to "true" to include medication codes per cert level |
curl "https://stateiq.amsler.io/api/v1/states/FL/formulary" \
-H "x-api-key: siq_live_your_key_here"{
"data": [
{
"state_code": "12",
"state_name": "Florida",
"cert_label": "Paramedic",
"medication_count": 87
},
{
"state_code": "12",
"state_name": "Florida",
"cert_label": "EMT",
"medication_count": 23
},
...
],
"count": 4
}/api/v1/states/{code}/rulesReturns schematron validation rules for a state. These rules define the business logic used to validate ePCR XML records.
| Name | Type | Required | Description |
|---|---|---|---|
code | path | required | Two-letter state abbreviation or FIPS code |
element_id | query | optional | Filter rules by element ID (partial match) |
role | query | optional | Filter by severity: "error" or "warning" |
limit | query | optional | Maximum number of results (default: 500, max: 1000) |
curl "https://stateiq.amsler.io/api/v1/states/PA/rules?element_id=eArrest&role=error" \
-H "x-api-key: siq_live_your_key_here"{
"data": [
{
"rule_id": "paSch_eArrest.01_check",
"element_id": "eArrest.01",
"role": "error",
"pattern_title": "Cardiac Arrest Check",
"message": "eArrest.01 must be present when cardiac arrest occurred",
"context": "nem:eArrest",
"test": "nem:eArrest.01"
},
...
],
"count": 12,
"limit": 500,
"page": 0
}/api/v1/searchSearch across all states for validation rules, custom elements, formulary entries, agencies, or facilities.
| Name | Type | Required | Description |
|---|---|---|---|
q | query | required | Search query (minimum 2 characters) |
type | query | required | Search type: rules, custom_elements, formulary, agencies, facilities |
role | query | optional | For rules search: filter by "error" or "warning" |
limit | query | optional | Maximum number of results (default: 100, max: 500) |
curl "https://stateiq.amsler.io/api/v1/search?q=naloxone&type=rules&role=error" \
-H "x-api-key: siq_live_your_key_here"{
"data": [
{
"state_abbr": "PA",
"rule_id": "paSch_naloxone_check",
"element_id": "eMedications.03",
"role": "error",
"pattern_title": "Naloxone Administration",
"message": "Naloxone must be documented when administered",
"context": "nem:eMedications",
"test": "..."
},
...
],
"count": 15
}/api/v1/validateValidates an ePCR XML record against all 51 state schematron rule sets. Returns a comprehensive report showing which states the record would pass or fail.
multipart/form-data
file | required | XML file to validate (ePCR record) |
No parameters required.
curl -X POST https://stateiq.amsler.io/api/v1/validate \
-H "x-api-key: siq_live_your_key_here" \
-F "file=@your_record.xml"{
"data": {
"total_states": 51,
"passed": 45,
"failed": 6,
"results": [
{
"state": "CA",
"pass_rate": 100,
"errors": 0,
"warnings": 2
},
{
"state": "PA",
"pass_rate": 97,
"errors": 1,
"warnings": 0
},
...
]
}
}/api/v1/validate/{state}Validates an ePCR XML record against a specific state's NEMSIS schematron rules. Returns detailed results including each rule that passed, failed as error, or failed as warning.
multipart/form-data
file | required | XML file to validate (ePCR record) |
| Name | Type | Required | Description |
|---|---|---|---|
state | path | required | Two-letter state code (e.g., CA, PA, TX) |
curl -X POST https://stateiq.amsler.io/api/v1/validate/PA \
-H "x-api-key: siq_live_your_key_here" \
-F "file=@your_record.xml"{
"data": {
"state": "PA",
"pass_rate": 97,
"rules_passed": 32,
"errors": 1,
"warnings": 0,
"skipped": 10,
"results": [
{
"rule_id": "paSch_dAgency.04_check",
"role": "error",
"message": "EMS Agency State must equal 42",
"element_id": "dAgency.04",
"location": "/EMSDataSet/Header/DemographicGroup"
}
]
}
}StateIQ API v1.0
Questions? Contact Support