# NZ Doctor Register Scraper (`vexaloom-labs/nz-doctor-register-scraper`) Actor

Search and browse the Medical Council of New Zealand (MCNZ) public Register of Doctors - filter by name, town/city, specialty, and registration status.

- **URL**: https://apify.com/vexaloom-labs/nz-doctor-register-scraper.md
- **Developed by:** [vexaloom-labs](https://apify.com/vexaloom-labs) (community)
- **Categories:** Automation, Lead generation, Other
- **Features:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $0.49 / 1,000 results

This Actor is paid per event and usage. You are charged both the fixed price for specific events and for Apify platform usage.
Since this Actor supports Apify Store discounts, the price gets lower the higher subscription plan you have.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

## NZ Doctor Register Scraper

Search and browse the **Medical Council of New Zealand (MCNZ) public register of doctors and physician associates** — the official register of practitioners licensed to work in New Zealand. Filter by name, profession, town/city, specialty (vocational scope), and registration status, then export structured records with the practitioner's name, previous name, profession, practice location, specialty, registration status, and practising-certificate expiry date.

No login, no API key, no cookies, and no proxy setup required — the actor reads the public register pages directly.

### What this actor does

- **Two modes** — search by current or previous name, or browse the register using only the dropdown filters
- **Doctor and physician-associate coverage** — the MCNZ register now lists both professions; choose one or include all
- **170 live locations**, **36 medical specialties**, and **4 registration statuses** as dropdowns
- **Real pagination** — follows MCNZ's cumulative `start` paging up to the register's 1000-result ceiling, with a page-by-page fallback and duplicate protection
- **Legacy input support** — saved tasks using older key names (`query`, `area`, `region`, `registrationStatus`, `limit`, …) are mapped onto the current fields automatically
- **Clean output** — every field is a real value or omitted entirely; no `null`, `""`, or `"N/A"` placeholders

### Output per practitioner

| Field | Description |
|---|---|
| `fullName` | Current registered name exactly as published |
| `previouslyKnownAs` | Previous registered name, when MCNZ records one |
| `profession` | `Doctor` or `Physician Associate` |
| `location` | Recorded practice town/city, when published |
| `specialty` | Vocational scope / type of medicine; multiple scopes are comma-separated |
| `registrationStatus` | `Practising`, `Not Practising`, `Inactive`, or `Suspended` |
| `certificateExpiryDate` | Practising-certificate expiry date (ISO `YYYY-MM-DD`), when shown |
| `profileUrl` | Canonical MCNZ register URL for this practitioner |
| `recordType` | `doctor` or `physician-associate` |
| `scrapedAt` | UTC timestamp the record was collected |

Only fields MCNZ publishes for that practitioner are included — for example, a practitioner with no recorded location omits `location` rather than showing a placeholder.

### Input

| Field | Type | Default | Description |
|---|---|---|---|
| `mode` | select | `search` | `search` matches names; `browse` ignores the keyword and uses only the filters |
| `keyword` | string | – | Free-text name / previous-name search. MCNZ also matches phonetically |
| `profession` | select | *(all)* | `Doctor`, `Physician Associate`, or all professions |
| `location` | select | *(all)* | Restrict to a live town/city/overseas option (170 options) |
| `specialty` | select | *(all)* | Restrict to a vocational scope / type of medicine (36 options) |
| `status` | select | *(all)* | `Practising`, `Not Practising`, `Inactive`, or `Suspended` |
| `maxItems` | integer | `50` | Hard cap on records returned (1–1000) |

#### Example: search a name

```json
{
  "mode": "search",
  "keyword": "wilson",
  "profession": "doctor",
  "maxItems": 50
}
```

#### Example: browse practising GPs in Auckland

```json
{
  "mode": "browse",
  "profession": "doctor",
  "location": "auckland",
  "specialty": "general-practice",
  "status": "practising",
  "maxItems": 100
}
```

#### Example: physician associates nationwide

```json
{
  "mode": "browse",
  "profession": "physician-associate",
  "maxItems": 20
}
```

#### Example: every suspended practitioner

```json
{
  "mode": "browse",
  "profession": "",
  "status": "suspended",
  "maxItems": 100
}
```

### Use cases

- **Employer and credentialing checks** — confirm a practitioner's current registration status and certificate expiry
- **Healthcare directories** — build location- or specialty-based directories for patients and referrers
- **Compliance monitoring** — track suspended, inactive, or not-practising practitioners
- **Workforce research** — measure the geographic and specialty distribution of New Zealand's medical workforce
- **Recruitment** — find practising practitioners in a target specialty and city

### FAQ

**Is this official data?** Yes. Every record comes from the Medical Council of New Zealand's public register, the statutory authority that registers doctors and physician associates in New Zealand.

**Does this include physician associates?** Yes. Set `profession` to `Physician Associate`, or leave it on all professions to include both.

**Does this cover practitioners outside New Zealand?** No. It is specific to MCNZ's New Zealand register.

**Why is `location` sometimes missing?** Not every practitioner has a published practice location; some records show "Not available". The actor omits the field rather than inventing a value.

**Can I search by registration number?** The public listing search is name-based. Registration numbers are not exposed on the listing tiles, so the actor does not invent or guess them.

**Does the actor visit individual profile pages?** No. MCNZ's `robots.txt` disallows crawling individual practitioner profiles, so the actor only reads the public search/browse listing (which is not restricted) and links to each profile via `profileUrl`.

**Why do I get at most 1000 records even though MCNZ reports more matches?** MCNZ's own search backend never serves past the first 1000 cumulative results for a single query. Narrow the keyword, profession, location, specialty, or status filters so each query's match count stays under 1000. The register also displays a 10,000 cap for some profession counts, so the reported total can be an approximation.

**What happens if I pass an old location or specialty that no longer exists?** The actor validates dropdown values against the live register and stops with a clear status message instead of sending an unknown value, which MCNZ would silently ignore and answer with the whole register.

**How often is the register updated?** MCNZ updates it continuously; every run reads the live page.

**What if my filters return zero practitioners?** The run finishes cleanly with 0 records and a status message, so broad filter sweeps are safe to automate.

**Are cookies, API keys, or a proxy required?** No. The actor runs cookielessly on a plain HTTP client.

# Actor input Schema

## `mode` (type: `string`):

What to do. 'Search by name' matches current and previous names; 'Browse by filters' ignores any keyword and pages through the register using the dropdowns.

## `keyword` (type: `string`):

Free-text search across current and previous names. MCNZ also does phonetic matching (e.g. 'smith' can surface 'smyth'). Ignored in browse mode.

## `profession` (type: `string`):

Restrict to doctors or physician associates. The register lists both professions; choose 'All professions' to include every practitioner.

## `location` (type: `string`):

Restrict results to a practitioner's recorded practice town or city. Leave on 'All of New Zealand' to search nationwide.

## `specialty` (type: `string`):

Restrict results to a vocational scope / type of medicine. Practitioners with more than one scope match if any of their scopes matches.

## `status` (type: `string`):

Restrict results to a current registration status.

## `maxItems` (type: `integer`):

Hard cap on the number of practitioner records emitted in this run. MCNZ's register serves at most the first 1000 results for a single query — narrow the keyword, profession, location, specialty, or status filters to reach practitioners beyond the first 1000 matches.

## Actor input object example

```json
{
  "mode": "search",
  "keyword": "smith",
  "profession": "doctor",
  "location": "",
  "specialty": "",
  "status": "",
  "maxItems": 3
}
```

# Actor output Schema

## `doctors` (type: `string`):

Dataset containing all scraped MCNZ register entries (doctors and physician associates).

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "mode": "search",
    "keyword": "smith",
    "profession": "doctor",
    "maxItems": 3
};

// Run the Actor and wait for it to finish
const run = await client.actor("vexaloom-labs/nz-doctor-register-scraper").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {
    "mode": "search",
    "keyword": "smith",
    "profession": "doctor",
    "maxItems": 3,
}

# Run the Actor and wait for it to finish
run = client.actor("vexaloom-labs/nz-doctor-register-scraper").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "mode": "search",
  "keyword": "smith",
  "profession": "doctor",
  "maxItems": 3
}' |
apify call vexaloom-labs/nz-doctor-register-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,vexaloom-labs/nz-doctor-register-scraper"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/ap3otP5X2dI6nThq0/builds/gQjdeM53OIIn0HERM/openapi.json
