{
  "openapi": "3.0.1",
  "info": {
    "title": "Ikman.lk Scraper: Sri Lanka Houses, Land, Apartments & Rentals",
    "description": "Scrape ikman.lk property ads in Sri Lanka: houses, apartments, land, commercial property and rentals with LKR price, district, town, bedrooms, area in square meters, photos, dates and agencies. Splits searches past the 10,000 ad cap. No login. Export CSV, Excel, JSON or XML.",
    "version": "0.1",
    "x-build-id": "iMo563sYbgpuL8lE8"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/recordsdata~ikman-lk-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-recordsdata-ikman-lk-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/recordsdata~ikman-lk-scraper/runs": {
      "post": {
        "operationId": "runs-sync-recordsdata-ikman-lk-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/recordsdata~ikman-lk-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-recordsdata-ikman-lk-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": {
          "recordTypes": {
            "title": "What to collect",
            "type": "array",
            "description": "Listings = one row per property ad (house, apartment, land, commercial, room, holiday rental). Agencies = one row per agency met while reading. Every row counts toward the maximum; listings come first. Example: Listings.",
            "items": {
              "type": "string",
              "enum": [
                "listings",
                "agencies"
              ],
              "enumTitles": [
                "Listings (property ads)",
                "Agencies (real estate shops)"
              ]
            },
            "default": [
              "listings"
            ]
          },
          "maxItems": {
            "title": "Maximum rows to return",
            "minimum": 1,
            "maximum": 1000000,
            "type": "integer",
            "description": "Stops after this many rows. Free users are limited to 10 items per run (preview). Example: 50."
          },
          "categories": {
            "title": "Property categories (all selected = whole section)",
            "type": "array",
            "description": "Houses, apartments, land, commercial, rooms and holiday rentals, for sale or for rent. Each category is scanned in turn, so a small maximum still mixes categories. Untick to narrow down.",
            "items": {
              "type": "string",
              "enum": [
                "land-for-sale",
                "houses-for-sale",
                "apartments-for-sale",
                "commercial-properties-for-sale",
                "house-rentals",
                "apartment-rentals",
                "commercial-property-rentals",
                "room-annex-rentals",
                "holiday-short-term-rental",
                "land-for-rent"
              ],
              "enumTitles": [
                "Land for sale",
                "Houses for sale",
                "Apartments for sale",
                "Commercial property for sale",
                "House rentals",
                "Apartment rentals",
                "Commercial property rentals",
                "Room and annex rentals",
                "Holiday and short-term rentals",
                "Land rentals"
              ]
            },
            "default": [
              "land-for-sale",
              "houses-for-sale",
              "apartments-for-sale",
              "commercial-properties-for-sale",
              "house-rentals",
              "apartment-rentals",
              "commercial-property-rentals",
              "room-annex-rentals",
              "holiday-short-term-rental",
              "land-for-rent"
            ]
          },
          "districts": {
            "title": "Districts (optional)",
            "type": "array",
            "description": "Only ads in these districts. Example: Colombo. Empty means all Sri Lanka; a district with over 10,000 ads is split by town automatically.",
            "items": {
              "type": "string",
              "enum": [
                "ampara",
                "anuradhapura",
                "badulla",
                "batticaloa",
                "colombo",
                "galle",
                "gampaha",
                "hambantota",
                "jaffna",
                "kalutara",
                "kandy",
                "kegalle",
                "kilinochchi",
                "kurunegala",
                "mannar",
                "matale",
                "matara",
                "monaragala",
                "mullativu",
                "nuwara-eliya",
                "polonnaruwa",
                "puttalam",
                "ratnapura",
                "trincomalee",
                "vavuniya"
              ],
              "enumTitles": [
                "Ampara",
                "Anuradhapura",
                "Badulla",
                "Batticaloa",
                "Colombo",
                "Galle",
                "Gampaha",
                "Hambantota",
                "Jaffna",
                "Kalutara",
                "Kandy",
                "Kegalle",
                "Kilinochchi",
                "Kurunegala",
                "Mannar",
                "Matale",
                "Matara",
                "Monaragala",
                "Mullativu",
                "Nuwara Eliya",
                "Polonnaruwa",
                "Puttalam",
                "Ratnapura",
                "Trincomalee",
                "Vavuniya"
              ]
            },
            "default": []
          },
          "towns": {
            "title": "Towns or areas (optional)",
            "type": "array",
            "description": "One per line. Example: Nugegoda, Negombo, Colombo 5 or the slug colombo-5. Capitals and accents do not matter.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "minPrice": {
            "title": "Min price (LKR)",
            "minimum": 0,
            "type": "integer",
            "description": "Lowest price in Sri Lankan rupees, applied by the site to every category you search. For rentals it is the price per month (per night for holiday rentals), for land the price shown on the ad (often per perch). Leave empty or 0 for no minimum."
          },
          "maxPrice": {
            "title": "Max price (LKR)",
            "minimum": 0,
            "type": "integer",
            "description": "Highest price in Sri Lankan rupees, applied by the site to every category you search (per month for rentals, per night for holiday rentals). Leave empty or 0 for no maximum."
          },
          "bedrooms": {
            "title": "Bedrooms (exact number)",
            "type": "array",
            "description": "Only ads with exactly this number of bedrooms (10+ means ten or more). Several values are searched in turn. It applies to houses, apartments, room and annex rentals and holiday rentals; land and commercial categories have no bedrooms and are not searched while this filter is set. Leave empty for any.",
            "items": {
              "type": "string",
              "enum": [
                "1",
                "2",
                "3",
                "4",
                "5",
                "6",
                "7",
                "8",
                "9",
                "10",
                "10+"
              ],
              "enumTitles": [
                "1 bedroom",
                "2 bedrooms",
                "3 bedrooms",
                "4 bedrooms",
                "5 bedrooms",
                "6 bedrooms",
                "7 bedrooms",
                "8 bedrooms",
                "9 bedrooms",
                "10 bedrooms",
                "10 or more bedrooms"
              ]
            },
            "default": []
          },
          "minBathrooms": {
            "title": "Min bathrooms",
            "minimum": 0,
            "maximum": 20,
            "type": "integer",
            "description": "Only ads with at least this many bathrooms. The count comes from the list page, so ads that do not state their bathrooms are left out when this is set. Leave empty or 0 for any."
          },
          "sellerType": {
            "title": "Seller type",
            "enum": [
              "any",
              "agency",
              "private"
            ],
            "type": "string",
            "description": "Any: every ad. Agency: only ads posted by an agency (an ikman.lk shop). Private: only ads posted by a private seller. No private name, phone or e-mail is ever returned.",
            "default": "any"
          },
          "startUrls": {
            "title": "ikman.lk page links",
            "type": "array",
            "description": "List pages (ikman.lk/en/ads/colombo/apartment-rentals), ad pages (ikman.lk/en/ad/...) or agency pages (ikman.lk/en/shops/...). A list page may carry a price range. Leave empty to use the search above.",
            "default": [],
            "items": {
              "type": "object",
              "required": [
                "url"
              ],
              "properties": {
                "url": {
                  "type": "string",
                  "title": "URL of a web page",
                  "format": "uri"
                }
              }
            }
          },
          "listingIds": {
            "title": "Ad ids or slugs",
            "type": "array",
            "description": "24-character ad ids, the slug at the end of an ad URL, or full ad URLs. Example: 6aa821002453220ec21ab592. Search filters are not applied to them.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "fetchDetails": {
            "title": "Open every ad page for full detail (adds the detail charge)",
            "type": "boolean",
            "description": "Open every ad page for the full description, all photos, coordinates, amenities, condition, furnishing, building name, posted and expiry dates, views and seller badges. Billed as the listing-detail event on top of the listing. Turn off for a cheaper and faster list-only pass (price, place, bedrooms, bathrooms, area, seller name, one photo and the posted time).",
            "default": true
          },
          "includeContactDetails": {
            "title": "Include agency business phone and e-mail",
            "type": "boolean",
            "description": "Add the business contacts that agencies publish on their ikman.lk shop page: phone numbers and the shop e-mail, on listing rows posted by an agency and on agency rows. Without it those are removed, and phone numbers or e-mails written inside ad descriptions are removed too. Private sellers are never included, with or without this switch. Off by default.",
            "default": false
          },
          "maxRunSeconds": {
            "title": "Max run time (seconds)",
            "minimum": 30,
            "maximum": 86400,
            "type": "integer",
            "description": "Stop collecting after this many seconds and return what was gathered, so a very wide search never runs unbounded.",
            "default": 3600
          },
          "onlyNew": {
            "title": "Only new rows (monitor)",
            "type": "boolean",
            "description": "Only new rows: skip every ad or agency this same search already returned in an earlier run, so a scheduled run returns just the new ones and you are not charged for skipped rows. Max Items then means N new rows. Off by default.",
            "default": false
          },
          "stateKey": {
            "title": "Monitor name (optional)",
            "type": "string",
            "description": "Name of this monitor. Leave empty to derive it from your filters. Use a name to run two monitors with the same filters.",
            "default": ""
          },
          "resetSeen": {
            "title": "Forget previously seen rows",
            "type": "boolean",
            "description": "Clear the saved list for this monitor before the run, so everything counts as new again.",
            "default": false
          },
          "proxyConfiguration": {
            "title": "Proxy (optional)",
            "type": "object",
            "description": "Not needed: the actor reads ikman.lk directly at a polite pace (four requests at a time). If the site ever refuses the connection, the actor switches to the Apify datacenter proxy by itself. Switch the proxy on here to force it from the first request.",
            "default": {
              "useApifyProxy": false
            }
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}