{
  "openapi": "3.0.1",
  "info": {
    "title": "NPI Healthcare Provider Search (NPPES Registry, no 1,200 cap)",
    "description": "Search the official CMS NPPES NPI Registry by specialty, state, city, ZIP, name or NPI. Automatically splits big searches to get past the registry's 1,200-result limit, removes duplicates, and returns clean flat rows with address, phone, specialty, license and more.",
    "version": "0.1",
    "x-build-id": "taLNBRD690TTYRzNi"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/publicrecords-lab~npi-provider-search/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-publicrecords-lab-npi-provider-search",
        "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/publicrecords-lab~npi-provider-search/runs": {
      "post": {
        "operationId": "runs-sync-publicrecords-lab-npi-provider-search",
        "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/publicrecords-lab~npi-provider-search/run-sync": {
      "post": {
        "operationId": "run-sync-publicrecords-lab-npi-provider-search",
        "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": {
          "specialties": {
            "title": "Specialties (taxonomy descriptions)",
            "type": "array",
            "description": "NUCC taxonomy description as used by the NPI Registry, e.g. 'Cardiovascular Disease', 'Dentist', 'Nurse Practitioner', 'Physical Therapist', 'Pharmacy'. A trailing * matches by prefix (e.g. 'Psych*'). Each specialty is searched separately (and combined with each state / ZIP below).",
            "items": {
              "type": "string"
            }
          },
          "states": {
            "title": "States",
            "type": "array",
            "description": "2-letter state codes (e.g. CA, NY). Each state is a separate search. The registry needs another criterion besides state (specialty, city, ZIP or name).",
            "items": {
              "type": "string"
            }
          },
          "city": {
            "title": "City",
            "type": "string",
            "description": "Optional city name, e.g. 'Boston'."
          },
          "postalCodes": {
            "title": "ZIP codes or prefixes",
            "type": "array",
            "description": "5-digit ZIP codes or prefixes of 2+ digits (e.g. '021' or '021*' = all ZIPs starting 021). Each entry is a separate search.",
            "items": {
              "type": "string"
            }
          },
          "entityType": {
            "title": "Provider type",
            "enum": [
              "any",
              "individual",
              "organization"
            ],
            "type": "string",
            "description": "Restrict to individual providers (NPI-1) or organizations (NPI-2).",
            "default": "any"
          },
          "firstName": {
            "title": "First name",
            "type": "string",
            "description": "Individuals only. Exact, or 2+ letters followed by * for prefix match."
          },
          "lastName": {
            "title": "Last name",
            "type": "string",
            "description": "Individuals only. Exact, or 2+ letters followed by *."
          },
          "organizationName": {
            "title": "Organization name",
            "type": "string",
            "description": "Organizations only, e.g. 'Mayo*'. Exact, or 2+ characters followed by *."
          },
          "addressPurpose": {
            "title": "Location fields match on",
            "enum": [
              "LOCATION",
              "MAILING",
              "PRIMARY",
              "SECONDARY",
              "ANY"
            ],
            "type": "string",
            "description": "Which address the state / city / ZIP criteria apply to.",
            "default": "LOCATION"
          },
          "countryCode": {
            "title": "Country code",
            "type": "string",
            "description": "Optional 2-letter country code for providers with foreign addresses."
          },
          "npiNumbers": {
            "title": "NPI numbers to look up",
            "type": "array",
            "description": "Optional list of 10-digit NPI numbers to fetch directly (enrichment mode). Can be combined with searches.",
            "items": {
              "type": "string"
            }
          },
          "searches": {
            "title": "Advanced: list of searches (JSON)",
            "type": "array",
            "description": "Run many different searches in one go. Each object can have: specialty, state, city, postalCode, entityType, firstName, lastName, organizationName, addressPurpose, countryCode, label. Example: [{\"specialty\":\"Dentist\",\"city\":\"Austin\",\"state\":\"TX\"},{\"organizationName\":\"Kaiser*\",\"state\":\"CA\"}]"
          },
          "primarySpecialtyOnly": {
            "title": "Primary specialty must match",
            "type": "boolean",
            "description": "The registry matches a specialty listed anywhere on a provider's record. Turn this on to keep only providers whose PRIMARY taxonomy matches the searched specialty.",
            "default": false
          },
          "primaryLocationInStateOnly": {
            "title": "Main practice address must be in the searched state",
            "type": "boolean",
            "description": "The registry also matches providers who list a secondary practice location in the state. Turn on to keep only providers whose main practice address is in the searched state.",
            "default": false
          },
          "enumeratedWithinDays": {
            "title": "NPI issued within the last N days",
            "minimum": 1,
            "type": "integer",
            "description": "Keep only providers whose NPI was issued recently - great for finding newly licensed / newly opened practices. Note: the full search still runs (the registry can't filter by date), so this works best with focused searches."
          },
          "enumeratedAfter": {
            "title": "NPI issued on or after (YYYY-MM-DD)",
            "pattern": "^$|^\\d{4}-\\d{2}-\\d{2}$",
            "type": "string",
            "description": "Keep only providers whose NPI was issued on or after this date."
          },
          "updatedWithinDays": {
            "title": "Record updated within the last N days",
            "minimum": 1,
            "type": "integer",
            "description": "Keep only providers whose registry record changed in the last N days."
          },
          "activeOnly": {
            "title": "Active NPIs only",
            "type": "boolean",
            "description": "Skip deactivated NPIs.",
            "default": true
          },
          "dedupe": {
            "title": "Remove duplicates across searches",
            "type": "boolean",
            "description": "Each NPI is output (and charged) once per run, even if several searches find it.",
            "default": true
          },
          "maxResults": {
            "title": "Max providers to output",
            "minimum": 0,
            "type": "integer",
            "description": "Stop after this many provider rows in total (0 = no limit). Protects your budget on very broad searches.",
            "default": 1000
          },
          "autoSplit": {
            "title": "Auto-split searches past the 1,200-result cap",
            "type": "boolean",
            "description": "The registry returns at most 1,200 results per query. When a query hits that cap, the Actor re-runs it by ZIP prefix, then provider type, then name prefix, and merges the results.",
            "default": true
          },
          "maxApiRequestsPerSearch": {
            "title": "Max registry requests per search",
            "minimum": 10,
            "maximum": 10000,
            "type": "integer",
            "description": "Safety cap on splitting work for one search. If reached, the run summary marks that search as partial.",
            "default": 2000
          },
          "maxConcurrency": {
            "title": "Max parallel requests",
            "minimum": 1,
            "maximum": 5,
            "type": "integer",
            "description": "Parallel requests to the registry (be polite; 3 is plenty).",
            "default": 3
          },
          "requestIntervalSecs": {
            "title": "Minimum seconds between requests",
            "minimum": 0.1,
            "maximum": 5,
            "type": "number",
            "description": "Polite spacing between requests to the public registry.",
            "default": 0.25
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}