{
  "openapi": "3.0.1",
  "info": {
    "title": "NPI Registry Lookup - Bulk NPI Search & Healthcare Providers",
    "description": "Bulk NPI lookup and US healthcare provider search from the official CMS NPPES NPI Registry API: NPI numbers or specialty + city/state/ZIP to name, taxonomy, license, practice address and phone. $0.80 per 1,000 records; invalid and not-found NPIs free.",
    "version": "0.1",
    "x-build-id": "uOVhJTUxiM0ijBXIA"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/tinyrex~npi-registry-lookup/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-tinyrex-npi-registry-lookup",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor, waits for its completion, and returns Actor's dataset items in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/acts/tinyrex~npi-registry-lookup/runs": {
      "post": {
        "operationId": "runs-sync-tinyrex-npi-registry-lookup",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor and returns information about the initiated run in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/runsResponseSchema"
                }
              }
            }
          }
        }
      }
    },
    "/acts/tinyrex~npi-registry-lookup/run-sync": {
      "post": {
        "operationId": "run-sync-tinyrex-npi-registry-lookup",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor, waits for completion, and returns the OUTPUT from Key-value store in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "inputSchema": {
        "type": "object",
        "properties": {
          "npis": {
            "title": "NPI numbers",
            "type": "array",
            "description": "10-digit National Provider Identifiers to look up or validate. The check digit is verified first; invalid, unknown or deactivated NPIs come back as free rows with found=false.",
            "items": {
              "type": "string"
            }
          },
          "taxonomyDescription": {
            "title": "Specialty / taxonomy",
            "type": "string",
            "description": "Provider specialty as written in the NPPES taxonomy, e.g. \"Dentist\", \"Cardiovascular Disease\", \"Nurse Practitioner\", \"Physical Therapist\", \"Pharmacy\". Trailing * works as a wildcard (\"cardio*\")."
          },
          "entityType": {
            "title": "Provider type",
            "enum": [
              "any",
              "individual",
              "organization"
            ],
            "type": "string",
            "description": "Limit results to individual providers (doctors, nurses, therapists) or organizations (clinics, hospitals, pharmacies).",
            "default": "any"
          },
          "organizationName": {
            "title": "Organization name",
            "type": "string",
            "description": "Organization name, trailing * wildcard allowed (e.g. \"Mayo Clinic*\"). Matches legal, DBA and former names."
          },
          "firstName": {
            "title": "First name",
            "type": "string",
            "description": "Individual provider first name (wildcard * allowed after 2 characters)."
          },
          "lastName": {
            "title": "Last name",
            "type": "string",
            "description": "Individual provider last name (wildcard * allowed after 2 characters)."
          },
          "states": {
            "title": "States",
            "type": "array",
            "description": "2-letter US state codes (TX, NY...). One search runs per state, or per city x state when cities are set. A state alone is not enough; combine it with a specialty or name.",
            "items": {
              "type": "string"
            }
          },
          "cities": {
            "title": "Cities",
            "type": "array",
            "description": "Practice or mailing city names. One search runs per city (per city x state when states are set).",
            "items": {
              "type": "string"
            }
          },
          "postalCodes": {
            "title": "ZIP codes",
            "type": "array",
            "description": "5-digit ZIP codes (or prefixes like 787*). One search runs per ZIP; overrides cities and states.",
            "items": {
              "type": "string"
            }
          },
          "primaryTaxonomyOnly": {
            "title": "Primary specialty only",
            "type": "boolean",
            "description": "NPPES matches the specialty against all of a provider's taxonomies. Turn this on to keep only providers whose primary taxonomy contains your specialty text. Filtered-out providers are not charged.",
            "default": false
          },
          "searches": {
            "title": "Advanced: raw NPPES searches",
            "type": "array",
            "description": "Optional list of raw NPPES API v2.1 query objects, e.g. [{\"taxonomy_description\": \"Pharmacy\", \"postal_code\": \"10001\"}]. Fields: taxonomy_description, enumeration_type, first_name, last_name, organization_name, name_purpose, city, state, postal_code, country_code, address_purpose."
          },
          "maxResultsPerSearch": {
            "title": "Max results per search",
            "minimum": 1,
            "maximum": 1200,
            "type": "integer",
            "description": "Results to fetch per search (pages of 200). The NPPES API returns at most 1,200 per search; split big searches by city or ZIP to get more.",
            "default": 200
          },
          "maxRecords": {
            "title": "Max records",
            "minimum": 1,
            "maximum": 100000,
            "type": "integer",
            "description": "Hard cap on provider records (charged rows) in this run. Duplicates across searches are removed and charged once.",
            "default": 1000
          }
        }
      },
      "runsResponseSchema": {
        "type": "object",
        "properties": {
          "data": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string"
              },
              "actId": {
                "type": "string"
              },
              "userId": {
                "type": "string"
              },
              "startedAt": {
                "type": "string",
                "format": "date-time",
                "example": "2025-01-08T00:00:00.000Z"
              },
              "finishedAt": {
                "type": "string",
                "format": "date-time",
                "example": "2025-01-08T00:00:00.000Z"
              },
              "status": {
                "type": "string",
                "example": "READY"
              },
              "meta": {
                "type": "object",
                "properties": {
                  "origin": {
                    "type": "string",
                    "example": "API"
                  },
                  "userAgent": {
                    "type": "string"
                  }
                }
              },
              "stats": {
                "type": "object",
                "properties": {
                  "inputBodyLen": {
                    "type": "integer",
                    "example": 2000
                  },
                  "rebootCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "restartCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "resurrectCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "computeUnits": {
                    "type": "integer",
                    "example": 0
                  }
                }
              },
              "options": {
                "type": "object",
                "properties": {
                  "build": {
                    "type": "string",
                    "example": "latest"
                  },
                  "timeoutSecs": {
                    "type": "integer",
                    "example": 300
                  },
                  "memoryMbytes": {
                    "type": "integer",
                    "example": 1024
                  },
                  "diskMbytes": {
                    "type": "integer",
                    "example": 2048
                  }
                }
              },
              "buildId": {
                "type": "string"
              },
              "defaultKeyValueStoreId": {
                "type": "string"
              },
              "defaultDatasetId": {
                "type": "string"
              },
              "defaultRequestQueueId": {
                "type": "string"
              },
              "buildNumber": {
                "type": "string",
                "example": "1.0.0"
              },
              "containerUrl": {
                "type": "string"
              },
              "usage": {
                "type": "object",
                "properties": {
                  "ACTOR_COMPUTE_UNITS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_WRITES": {
                    "type": "integer",
                    "example": 1
                  },
                  "KEY_VALUE_STORE_LISTS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_INTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_EXTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_SERPS": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_UNBLOCKER_UNITS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              },
              "usageTotalUsd": {
                "type": "number",
                "example": 0.00005
              },
              "usageUsd": {
                "type": "object",
                "properties": {
                  "ACTOR_COMPUTE_UNITS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_WRITES": {
                    "type": "number",
                    "example": 0.00005
                  },
                  "KEY_VALUE_STORE_LISTS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_INTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_EXTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_SERPS": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_UNBLOCKER_UNITS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}