{
  "openapi": "3.0.1",
  "info": {
    "title": "Peru Judicial Auctions (REMAJU Remates Judiciales)",
    "description": "All current electronic judicial auctions of Peru's Poder Judicial (REMAJU): houses, apartments, land, commercial property and vehicles with base price, location, department and offer deadline. Filters and daily watch alerts.",
    "version": "0.1",
    "x-build-id": "ZCH1nIb7hB5ONdBbN"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/frankely84~peru-judicial-auctions-remaju/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-frankely84-peru-judicial-auctions-remaju",
        "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/frankely84~peru-judicial-auctions-remaju/runs": {
      "post": {
        "operationId": "runs-sync-frankely84-peru-judicial-auctions-remaju",
        "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/frankely84~peru-judicial-auctions-remaju/run-sync": {
      "post": {
        "operationId": "run-sync-frankely84-peru-judicial-auctions-remaju",
        "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": {
          "departments": {
            "title": "Departments (regions)",
            "type": "array",
            "description": "Only auctions in these Peruvian departments. The department is detected from the property description and district. Leave empty for all of Peru.",
            "items": {
              "type": "string",
              "enum": [
                "AMAZONAS",
                "ANCASH",
                "APURIMAC",
                "AREQUIPA",
                "AYACUCHO",
                "CAJAMARCA",
                "CALLAO",
                "CUSCO",
                "HUANCAVELICA",
                "HUANUCO",
                "ICA",
                "JUNIN",
                "LA LIBERTAD",
                "LAMBAYEQUE",
                "LIMA",
                "LORETO",
                "MADRE DE DIOS",
                "MOQUEGUA",
                "PASCO",
                "PIURA",
                "PUNO",
                "SAN MARTIN",
                "TACNA",
                "TUMBES",
                "UCAYALI"
              ]
            }
          },
          "districts": {
            "title": "Districts",
            "type": "array",
            "description": "Optional. Only these districts / cities as shown in REMAJU, e.g. MIRAFLORES, SAN ISIDRO, TRUJILLO. Accent-insensitive.",
            "items": {
              "type": "string"
            }
          },
          "propertyTypes": {
            "title": "Property types",
            "type": "array",
            "description": "Only these types (auto-classified from the description): house, apartment, land, commercial (shops, offices, warehouses), parking, vehicle, machinery, shares, other.",
            "items": {
              "type": "string",
              "enum": [
                "house",
                "apartment",
                "land",
                "commercial",
                "parking",
                "vehicle",
                "machinery",
                "shares",
                "other"
              ],
              "enumTitles": [
                "House / building",
                "Apartment",
                "Land / lot",
                "Commercial (shop, office, warehouse)",
                "Parking",
                "Vehicle / vessel",
                "Machinery",
                "Shares",
                "Other"
              ]
            }
          },
          "keywords": {
            "title": "Keywords",
            "type": "array",
            "description": "Optional. Auction matches if its description contains ANY item; all words of one item must appear. Accent-insensitive, e.g. 'piscina', 'av. javier prado'.",
            "items": {
              "type": "string"
            }
          },
          "currency": {
            "title": "Currency",
            "enum": [
              "ANY",
              "PEN",
              "USD"
            ],
            "type": "string",
            "description": "Base price currency: PEN (soles), USD or ANY.",
            "default": "ANY"
          },
          "minPrice": {
            "title": "Min base price",
            "type": "integer",
            "description": "Optional minimum base price (in the auction's currency; set Currency to compare like with like)."
          },
          "maxPrice": {
            "title": "Max base price",
            "type": "integer",
            "description": "Optional maximum base price."
          },
          "phaseDateFrom": {
            "title": "Offer deadline from",
            "type": "string",
            "description": "Optional (YYYY-MM-DD). Filters on the date of the current phase (offer submission)."
          },
          "phaseDateTo": {
            "title": "Offer deadline to",
            "type": "string",
            "description": "Optional (YYYY-MM-DD)."
          },
          "firstCallOnly": {
            "title": "Only first call (primera convocatoria)",
            "type": "boolean",
            "description": "Only auctions in their first call. Turn off to include second and third calls, which usually have lower base prices.",
            "default": false
          },
          "onlyNew": {
            "title": "Watch mode: only new since last run",
            "type": "boolean",
            "description": "Remembers auctions returned before (per Watch name) and outputs only new ones (a new call of the same auction counts as new). Schedule it daily for alerts; you pay only for new auctions.",
            "default": false
          },
          "monitorName": {
            "title": "Watch name",
            "type": "string",
            "description": "Name for this watch's memory, e.g. 'lima-houses'.",
            "default": "default"
          },
          "includeDetails": {
            "title": "Include case details (expediente, court, appraisal)",
            "type": "boolean",
            "description": "Also open each matching auction's public 'Detalle' page and add caseNumber (expediente), court, judge, courtClerk, caseMatter, judicialDistrict, resolutionNumber/Date, appraisalValue (tasación), discountVsAppraisalPct, minBidIncrement, registrationFee (arancel), depositRequired (oblaje) and registeredBidders. Slower (about 1-2 s per auction), same price.",
            "default": false
          },
          "minDiscountPct": {
            "title": "Minimum discount vs appraisal (%)",
            "minimum": 0,
            "maximum": 99,
            "type": "integer",
            "description": "Optional. Only auctions whose base price is at least this % below the official appraisal (tasación), sorted best deal first, e.g. 30. Turns on case details automatically (the appraisal comes from each auction's detail page), so the run is slower. Leave empty for no discount filter."
          },
          "maxItems": {
            "title": "Max auctions",
            "minimum": 1,
            "maximum": 5000,
            "type": "integer",
            "description": "Cap on auctions returned (and charged) per run.",
            "default": 500
          },
          "maxRunSeconds": {
            "title": "Max run time (seconds)",
            "minimum": 0,
            "maximum": 86400,
            "type": "integer",
            "description": "Optional safety cap: the Actor stops fetching shortly before this many seconds and finishes with SUCCEEDED, keeping all results found so far. 0 or empty = no extra cap (only the run timeout applies). Raise it or set 0 for big searches."
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}