{
  "openapi": "3.0.1",
  "info": {
    "title": "Finca Particular",
    "description": "Coverage: Spain, France, Andorra, the Netherlands.\nA report bundles ~20 chapters: cadastral identity, flood/wildfire/seismic/radon hazards, climate, wind, solar, air quality, noise, transport access, demographics and more.\nhttps://github.com/pavelmiljutin-beep/fincaparticular/tree/main/apify-actor",
    "version": "0.0",
    "x-build-id": "ABjiLeLwaBX8Gcpm0"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/fincaparticular~finca-particular/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-fincaparticular-finca-particular",
        "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/fincaparticular~finca-particular/runs": {
      "post": {
        "operationId": "runs-sync-fincaparticular-finca-particular",
        "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/fincaparticular~finca-particular/run-sync": {
      "post": {
        "operationId": "run-sync-fincaparticular-finca-particular",
        "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": {
          "location": {
            "title": "Location (lat,lng)",
            "type": "string",
            "description": "A single 'lat,lng' string aimed at a building or plot, e.g. '41.4036,2.1744'. In Google Maps, right-click the centre of a building's rooftop and copy the coordinates — a plaza, road, park or water has no cadastral parcel and returns no report."
          },
          "dryRun": {
            "title": "Free preview only (no report)",
            "type": "boolean",
            "description": "Free. Returns what a report for this location would contain — the chapter list, how dense the local data is, and the estimated bytes/tokens for each output format — without generating or charging for a report. Needs coordinates; a cadastral reference alone cannot be previewed.",
            "default": false
          },
          "ref": {
            "title": "Cadastral reference",
            "type": "string",
            "description": "Alternative to a location: an exact cadastral reference. Spain (20-char RC, e.g. 8034006VP3183C0001IH), France (14-char IDU, e.g. 56005000AM0333) or Netherlands (kadastrale aanduiding, e.g. ASD40-C-7285). Takes priority over lat/lng and location."
          },
          "country": {
            "title": "Cadastre country (for ref)",
            "enum": [
              "ES",
              "FR",
              "NL"
            ],
            "type": "string",
            "description": "Optional. Force which cadastre to use for an ambiguous 'ref'."
          },
          "lat": {
            "title": "Latitude",
            "type": "string",
            "description": "Decimal latitude (WGS-84), e.g. '41.4036'. Aim at a building rooftop — a plaza, road, park or water has no cadastral parcel and returns no report. Use together with 'lng' as an alternative to 'location'."
          },
          "lng": {
            "title": "Longitude",
            "type": "string",
            "description": "Decimal longitude (WGS-84), e.g. '2.1744'. Use together with 'lat'."
          },
          "format": {
            "title": "Output format",
            "enum": [
              "json",
              "markdown",
              "both"
            ],
            "type": "string",
            "description": "'json' (default) returns structured per-chapter facts — verdicts, numbers and sources — with no prose. 'markdown' returns the human-readable report. 'both' returns each.",
            "default": "json"
          },
          "detail": {
            "title": "Detail level",
            "enum": [
              "full",
              "brief"
            ],
            "type": "string",
            "description": "Applies to the JSON facts. 'full' includes every metric and source per chapter. 'brief' keeps only the verdict and headline per chapter — a fraction of the size when you just need a go/no-go read. Markdown output is unaffected.",
            "default": "full"
          },
          "chapters": {
            "title": "Only these chapters",
            "type": "array",
            "description": "Optional. Limit the report to specific chapter slugs (e.g. 'flood-risk-snczi', 'seismic-zoning-ign'). Chapters that another chapter depends on are added automatically and reported back in 'chapters_auto_added'. Leave empty for the full report. Run with 'dryRun' to list the available slugs.",
            "items": {
              "type": "string"
            }
          },
          "excludeChapters": {
            "title": "Exclude these chapters",
            "type": "array",
            "description": "Optional. Drop specific chapter slugs from the report.",
            "items": {
              "type": "string"
            }
          },
          "includeImages": {
            "title": "Include map images",
            "type": "boolean",
            "description": "Off by default. Map images are large base64 PNGs — a single one can outweigh the entire text report. When on, they are written to the key-value store and referenced from the dataset record rather than inlined.",
            "default": false
          },
          "radiusKm": {
            "title": "Preview search radius (km)",
            "type": "string",
            "description": "Optional, dry run only. Radius used when counting nearby points of interest."
          },
          "language": {
            "title": "Report language",
            "enum": [
              "en",
              "es",
              "fr",
              "de",
              "uk",
              "ru",
              "ar"
            ],
            "type": "string",
            "description": "Language of the generated report.",
            "default": "en"
          },
          "persist": {
            "title": "Store a copy on the Parcelabot server",
            "type": "boolean",
            "description": "Ask the Parcelabot server to also persist the report for audit. Off by default — Apify already retains the result.",
            "default": false
          },
          "baseUrl": {
            "title": "Parcelabot base URL",
            "type": "string",
            "description": "Override the Parcelabot host. Leave empty to use the default.",
            "default": "https://parcelabot.duckdns.org"
          },
          "apiKey": {
            "title": "Parcelabot API key",
            "type": "string",
            "description": "Partner API key. Prefer setting the PARCELABOT_API_KEY environment variable (secret) on the Actor instead of passing it here."
          }
        }
      },
      "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
                  }
                }
              },
              "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}