{
  "openapi": "3.0.1",
  "info": {
    "title": "Marktplaats Ads Scraper",
    "description": "Scrape public classified ads from Marktplaats and get fields such as title, description, price type, city, coordinates, images, seller details and category attributes. Start searches with keywords, category IDs or Marktplaats URLs. The Actor reads JSON search results and needs no account or login.",
    "version": "1.0",
    "x-build-id": "yE1AOTNt8Eg9kPbWh"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/axiomworks~marktplaats-ads-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-axiomworks-marktplaats-ads-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/axiomworks~marktplaats-ads-scraper/runs": {
      "post": {
        "operationId": "runs-sync-axiomworks-marktplaats-ads-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/axiomworks~marktplaats-ads-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-axiomworks-marktplaats-ads-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": {
          "searchQueries": {
            "title": "Keyword strings, e.g. fiets",
            "type": "array",
            "description": "Search keywords as strings, e.g. [\"fiets\", \"iphone 13\"]. Supply searchQueries, categoryIds or startUrls; none is filled automatically in API calls. With categoryIds, each keyword is searched in every supplied category. Results share maxItems.",
            "items": {
              "type": "string"
            }
          },
          "categoryIds": {
            "title": "Category numbers, e.g. 91",
            "type": "array",
            "description": "Positive integer Marktplaats category IDs (l1CategoryId), e.g. [91] for cars. Default []. Without keywords, browse these categories; with searchQueries, restrict each keyword to each category. All searches share maxItems.",
            "default": []
          },
          "startUrls": {
            "title": "Search URLs, e.g. /q/fiets/",
            "type": "array",
            "description": "Marktplaats search URLs as strings or {\"url\":\"https://www.marktplaats.nl/q/fiets/\"} objects. Default []. Accepts /q/<keyword>/ or URLs with query and l1CategoryId parameters. Only the keyword and l1CategoryId are extracted; other URL filters are ignored. Adds searches to the other targets.",
            "default": [],
            "items": {
              "type": "object",
              "required": [
                "url"
              ],
              "properties": {
                "url": {
                  "type": "string",
                  "title": "URL of a web page",
                  "format": "uri"
                }
              }
            }
          },
          "sortBy": {
            "title": "Sort value, e.g. newest",
            "enum": [
              "newest",
              "relevance",
              "priceAsc",
              "priceDesc"
            ],
            "type": "string",
            "description": "Choose newest (default, recent ads first), relevance, priceAsc (lowest prices first) or priceDesc (highest prices first). Applies to every search, e.g. \"priceAsc\".",
            "default": "newest"
          },
          "minPrice": {
            "title": "Minimum euros, e.g. 100",
            "minimum": 0,
            "type": "number",
            "description": "Minimum asking price in euros, e.g. 100, zero or more; omitted by default. Excludes ads without a fixed price when a price filter is set. Applies to all searches."
          },
          "maxPrice": {
            "title": "Maximum euros, e.g. 500",
            "minimum": 0,
            "type": "number",
            "description": "Maximum asking price in euros, e.g. 500, zero or more; omitted by default. Use with minPrice to set a range. Applies to all searches."
          },
          "postcode": {
            "title": "Dutch postcode, e.g. 1012AB",
            "type": "string",
            "description": "Dutch postcode string, e.g. \"1012AB\"; omitted by default. Spaces are removed. Searches within distanceKm and supplies distanceMeters when the source provides it."
          },
          "distanceKm": {
            "title": "Radius kilometers, e.g. 10",
            "minimum": 1,
            "type": "integer",
            "description": "Positive integer radius in kilometers around postcode, e.g. 10 (default). Ignored without postcode.",
            "default": 10
          },
          "maxItems": {
            "title": "Total unique ads, e.g. 30",
            "minimum": 1,
            "type": "integer",
            "description": "Positive integer maximum of unique ads across all keywords, categories and URLs, e.g. 30; default 50. Duplicates do not use the limit. Fewer ads are returned if searches end or the run cost limit is reached. Marktplaats caps depth per query.",
            "default": 50
          },
          "proxyConfiguration": {
            "title": "Proxy settings, e.g. disabled",
            "type": "object",
            "description": "Apify Proxy settings, e.g. {\"useApifyProxy\":false} (default). Direct requests are used first; on Apify, blocked responses trigger automatic proxy fallback. Enable {\"useApifyProxy\":true} to use it from the start. Blocked targets are retried then skipped; an empty run says what to change.",
            "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}