{
  "openapi": "3.0.1",
  "info": {
    "title": "RateMDs Patient Review & Practice Finder",
    "description": "Search RateMDs doctors by name, specialty or city, or fetch known profiles directly, with ratings, review counts, practice contact details and recent patient reviews.",
    "version": "2.0",
    "x-build-id": "AfXbJnolU6LkOkZuT"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/dataspryva~ratemds-patient-review-and-practice-finder/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-dataspryva-ratemds-patient-review-and-practice-finder",
        "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/dataspryva~ratemds-patient-review-and-practice-finder/runs": {
      "post": {
        "operationId": "runs-sync-dataspryva-ratemds-patient-review-and-practice-finder",
        "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/dataspryva~ratemds-patient-review-and-practice-finder/run-sync": {
      "post": {
        "operationId": "run-sync-dataspryva-ratemds-patient-review-and-practice-finder",
        "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": {
          "mode": {
            "title": "Mode",
            "enum": [
              "search",
              "bySpecialty",
              "doctorProfile",
              "byUrl",
              "practiceSearch",
              "practiceProfile"
            ],
            "type": "string",
            "description": "What to fetch from RateMDs.",
            "default": "search"
          },
          "searchQuery": {
            "title": "Search query",
            "type": "string",
            "description": "Doctor name, specialty keyword or medical condition (mode=search). Example: 'cardiologist' or 'Dr. Jane Doe'.",
            "default": "cardiologist"
          },
          "location": {
            "title": "Location",
            "type": "string",
            "description": "Legacy free-text location, e.g. 'New York' or 'Toronto, ON'. Used with search and bySpecialty. Structured City/State below take precedence.",
            "default": ""
          },
          "specialty": {
            "title": "Specialty",
            "enum": [
              "",
              "acupuncturist",
              "addiction-medicine",
              "allergist-immunologist",
              "anesthesiologist",
              "audiologist",
              "bariatric-weight-loss",
              "cardiologist",
              "cardiothoracic-surgeon",
              "chiropodist",
              "chiropractor",
              "colorectal-proctologist",
              "cosmetic-plastic-surgeon",
              "dentist",
              "dermatologist",
              "dietitian",
              "ear-nose-and-throat-ent",
              "emergency-critical",
              "endocrinologist",
              "endodontist-root-canal",
              "family-gp",
              "gastroenterologist",
              "geneticist",
              "gynecologist-obgyn",
              "homeopath",
              "infectious-disease",
              "internist-geriatrician",
              "midwife",
              "naturopath",
              "nephrologist-kidney",
              "neurologist",
              "neurosurgeon",
              "nurse-practitioner",
              "occupational-therapist",
              "oncologist-hematologist",
              "ophthalmologist",
              "optometrist",
              "oral-surgeon",
              "orthodontist",
              "orthopedics-sports",
              "osteopath",
              "pain-medicine-specialist",
              "pain-mgmt-physical-rehab",
              "pathologist",
              "pediatrician",
              "perinatologist-maternal-fetal-medicine",
              "periodontist-gums",
              "physiatrist-physical-medicine-rehabilitation",
              "physical-therapist-physiotherapist",
              "physician-assistant",
              "podiatrist",
              "psychiatrist",
              "psychologist",
              "pulmonologist-lungs",
              "radiation-oncologist",
              "radiologist",
              "registered-massage-therapist",
              "reproductive-endocrinologist",
              "rheumatologist",
              "sleep-disorders",
              "sports-medicine-physicians",
              "surgeon-general",
              "therapist",
              "urogynecologist",
              "urologist",
              "vascular-phlebologist"
            ],
            "type": "string",
            "description": "Medical specialty to browse (mode=bySpecialty) or to narrow a keyword search.",
            "default": ""
          },
          "state": {
            "title": "State / province",
            "type": "string",
            "description": "Two-letter state/province code (e.g. 'ny', 'ca', 'on') used with search, bySpecialty and practiceSearch.",
            "default": ""
          },
          "city": {
            "title": "City",
            "type": "string",
            "description": "City name or slug (e.g. 'New York' or 'new-york') used with search, bySpecialty and practiceSearch.",
            "default": ""
          },
          "country": {
            "title": "Country",
            "enum": [
              "",
              "us",
              "ca",
              "au",
              "in",
              "za",
              "uk"
            ],
            "type": "string",
            "description": "Country filter for doctor or practice searches.",
            "default": ""
          },
          "gender": {
            "title": "Doctor gender",
            "enum": [
              "any",
              "F",
              "M"
            ],
            "type": "string",
            "description": "Filter doctors by gender when RateMDs publishes it.",
            "default": "any"
          },
          "verified": {
            "title": "Verified profiles only",
            "type": "boolean",
            "description": "Only return doctors marked as verified by RateMDs.",
            "default": false
          },
          "acceptingNewPatients": {
            "title": "Accepting new patients",
            "type": "boolean",
            "description": "Only return doctors currently accepting new patients.",
            "default": false
          },
          "acceptingVirtualVisits": {
            "title": "Accepting virtual visits",
            "type": "boolean",
            "description": "Only return doctors offering virtual/telehealth appointments.",
            "default": false
          },
          "onlineScheduling": {
            "title": "Online scheduling",
            "type": "boolean",
            "description": "Only return doctors with online appointment booking enabled.",
            "default": false
          },
          "openNow": {
            "title": "Open now",
            "type": "boolean",
            "description": "Only return practices that are open at the time of the run.",
            "default": false
          },
          "doctorSlug": {
            "title": "Doctor slug or URL",
            "type": "string",
            "description": "A doctor's RateMDs slug or full profile URL (mode=doctorProfile). Current and legacy URL formats are accepted."
          },
          "profileUrls": {
            "title": "Doctor profile URLs (mode=byUrl)",
            "type": "array",
            "description": "List of RateMDs doctor profile URLs or slugs to fetch.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "practiceUrls": {
            "title": "Practice profile URLs (mode=practiceProfile)",
            "type": "array",
            "description": "List of RateMDs clinic URLs or slugs to fetch, e.g. 'https://www.ratemds.com/clinic/us-sc-north-charleston-total-family-wellness/'.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "includeReviews": {
            "title": "Include recent reviews",
            "type": "boolean",
            "description": "Fetch patient reviews. For doctor search this adds one profile request per doctor; for profile modes it fetches more review pages; for practice modes it includes embedded practice reviews.",
            "default": false
          },
          "includePartnerReviews": {
            "title": "Include partner reviews",
            "type": "boolean",
            "description": "Also fetch RateMDs 'Our Partners' reviews for doctor profiles (one extra request per review page).",
            "default": false
          },
          "includePracticeDetails": {
            "title": "Enrich practices with details",
            "type": "boolean",
            "description": "For practiceSearch, fetch each clinic page for address, phone, website, rating and doctors. Adds one request per practice.",
            "default": false
          },
          "maxReviewPages": {
            "title": "Max review pages per doctor",
            "minimum": 1,
            "maximum": 20,
            "type": "integer",
            "description": "Number of review pages to fetch per doctor when reviews are enabled (10 reviews per page).",
            "default": 1
          },
          "maxPages": {
            "title": "Max listing pages",
            "minimum": 1,
            "maximum": 1000,
            "type": "integer",
            "description": "Maximum number of search result pages to walk per run.",
            "default": 1000
          },
          "maxItems": {
            "title": "Max items",
            "minimum": 1,
            "maximum": 5000,
            "type": "integer",
            "description": "Maximum number of records to emit.",
            "default": 20
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}