{
  "openapi": "3.0.1",
  "info": {
    "title": "Mudah.my Classifieds Scraper - Cars, Property & Marketplace",
    "description": "Scrapes classified ads from Mudah.my, Malaysia's largest marketplace: cars, property for sale and rent, phones, electronics and more. Get title, price, description, photos, location, seller, specifications and WhatsApp numbers. Search by keyword, category, state or listing URL.",
    "version": "1.0",
    "x-build-id": "xi3RN5lt85opI7Ofd"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/confidential_gnat~mudah-classifieds-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-confidential_gnat-mudah-classifieds-scraper",
        "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/confidential_gnat~mudah-classifieds-scraper/runs": {
      "post": {
        "operationId": "runs-sync-confidential_gnat-mudah-classifieds-scraper",
        "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/confidential_gnat~mudah-classifieds-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-confidential_gnat-mudah-classifieds-scraper",
        "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": {
          "startUrls": {
            "title": "Listing or ad URLs",
            "type": "array",
            "description": "Mudah.my listing pages, with any filters set on the site (for example https://www.mudah.my/selangor/cars-for-sale/toyota?price=20000-60000 or https://www.mudah.my/kuala-lumpur/apartment-condominium-for-rent), or single ad pages (for example https://www.mudah.my/2018-toyota-alphard-115900606.htm).",
            "default": [],
            "items": {
              "type": "object",
              "required": [
                "url"
              ],
              "properties": {
                "url": {
                  "type": "string",
                  "title": "URL of a web page",
                  "format": "uri"
                }
              }
            }
          },
          "maxItems": {
            "title": "Max items per search",
            "minimum": 1,
            "type": "integer",
            "description": "Maximum unique listings saved for each keyword or listing URL. Mudah.my shows at most 10,000 results per search; use filters (state, price range) to split bigger searches.",
            "default": 5
          },
          "scrapeDetails": {
            "title": "Scrape full ad details",
            "type": "boolean",
            "description": "Open every ad for all specifications, HD photos, store details, building address and the seller's WhatsApp numbers (when the seller shows them). Turn off for faster runs with the search data only (title, price, description, photos, location, seller and key specs). Ad URLs always include the details.",
            "default": true
          },
          "cacheProjectName": {
            "title": "Cache project name",
            "type": "string",
            "description": "Use the same name on each scheduled run to get only new listings. Listings already scraped under this name are skipped and not charged, and they do not count towards Max items. Each record gets changeType: new."
          },
          "proxyConfiguration": {
            "title": "Proxy configuration",
            "type": "object",
            "description": "This website works without a proxy. Enable Apify Proxy only if you get blocked.",
            "default": {
              "useApifyProxy": true
            }
          },
          "keywords": {
            "title": "Search keywords",
            "type": "array",
            "description": "Words to search for, for example iphone 15 or myvi. Each keyword is searched separately with the filters below. Leave empty and pick a category or state to browse without a keyword.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "category": {
            "title": "Category",
            "enum": [
              "1000",
              "1020",
              "1040",
              "1060",
              "1080",
              "1100",
              "1120",
              "1160",
              "2000",
              "2020",
              "2040",
              "2060",
              "2080",
              "2100",
              "2200",
              "3000",
              "3020",
              "3040",
              "3060",
              "3080",
              "3100",
              "3120",
              "4000",
              "4020",
              "4060",
              "4200",
              "4220",
              "4280",
              "5000",
              "5020",
              "5040",
              "5060",
              "5080",
              "5100",
              "5120",
              "5140",
              "6000",
              "6020",
              "6040",
              "7020",
              "7040",
              "8020",
              "8040",
              "9020",
              "9040"
            ],
            "type": "string",
            "description": "Category for keyword searches. Leave empty to search all categories."
          },
          "region": {
            "title": "State",
            "enum": [
              "12",
              "2",
              "4",
              "9",
              "17",
              "11",
              "10",
              "7",
              "3",
              "6",
              "1",
              "16",
              "14",
              "13",
              "8",
              "5"
            ],
            "type": "string",
            "description": "Malaysian state or federal territory for keyword searches. Leave empty for the whole of Malaysia."
          },
          "listingType": {
            "title": "Listing type",
            "enum": [
              "sell",
              "let",
              "newprop",
              "auction"
            ],
            "type": "string",
            "description": "For sale, for rent, new properties or property auctions. Applies to keyword and category searches.",
            "default": "sell"
          },
          "minPrice": {
            "title": "Minimum price (RM)",
            "minimum": 0,
            "type": "integer",
            "description": "Lowest price in Malaysian ringgit (monthly rent for rentals)."
          },
          "maxPrice": {
            "title": "Maximum price (RM)",
            "minimum": 0,
            "type": "integer",
            "description": "Highest price in Malaysian ringgit (monthly rent for rentals)."
          },
          "sortBy": {
            "title": "Sort by",
            "enum": [
              "newest",
              "price_asc",
              "price_desc"
            ],
            "type": "string",
            "description": "Order of the results.",
            "default": "newest"
          },
          "sellerType": {
            "title": "Seller type",
            "enum": [
              "all",
              "private",
              "company"
            ],
            "type": "string",
            "description": "Only private sellers, only companies and dealers, or both.",
            "default": "all"
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}