# Metrocuadrado Scraper — Colombia Listings (Enhanced) (`stone_jadex/metrocuadrado-colombia-scraper`) Actor

Enhanced Metrocuadrado.com scraper for Bogotá apartment sales: anonymous list API plus optional detail enrichment for builder company, sales-room address/hours and delivery date. Phones and WhatsApp kept as published; no login, JWT or reveal clicks.

- **URL**: https://apify.com/stone_jadex/metrocuadrado-colombia-scraper.md
- **Developed by:** [Stone Jade](https://apify.com/stone_jadex) (community)
- **Categories:** Real estate, Lead generation
- **Features:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $0.64 / 1,000 metrocuadrado listing results

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.
Since this Actor supports Apify Store discounts, the price gets lower the higher subscription plan you have.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

## Metrocuadrado Scraper — Colombia Listings (Enhanced)

**Turn public Metrocuadrado.com apartment-for-sale cards into a Bogotá shortlist your agency, investor or research team can review and export — with optional detail enrichment for builder company, sales-room and delivery fields that the free list API alone does not expose.**

Provide `city` / `propertyType` / `business` filters (Console **prefill** and Actor runtime fallback: Bogotá D.C., apartamento, venta — **no schema `default`**, so the platform will not inject these when you omit them), or supported public Metrocuadrado.com list and detail URLs. Receive titles, sale prices (COP), area, rooms, bathrooms, neighbourhood, phones and WhatsApp in an Apify dataset. Optional detail enrichment adds builder `companyName` / `companyImage` / `companyLink`, `salesRoomAddress` / `salesRoomSchedule`, `deliverDate`, `publicationId`, price and area ranges, grouped amenities (`featuresDetail`) and real photo URLs. This Actor reads the anonymous public list endpoint and public detail Flight/RSC pages only: it does not log in, use X-Api-Key or JWT, click contact-reveal controls or send WhatsApp OTP.

**This is an enhanced product, not a thin wrap of the free list JSON.** List mode calls `GET /api/rest-search/search` and maps only `$.results[*]` (not `highlights` / `recommended`). Detail mode merges public project/property pages for enrichment fields that stay null on list-only runs. **Default mode is list-only** (`includeDetails=false`). A successfully detail-merged row charges the detail event instead of the listing event (not both).

Start with five Bogotá sale apartments before widening filters.

### What you gain

- **Cut portal copy-paste:** keep `title`, `salePrice` / `price`, `sizeM2`, `rooms` / `bathrooms`, `neighborhood`, `contactPhone` and `whatsappNumber` together for spreadsheet screening.
- **Reach builders, not only listing cards:** with details enabled, get `companyName`, `salesRoomAddress`, `salesRoomSchedule` and `deliverDate` when the public project page publishes them (list-only leaves these null).
- **Pay for the depth you choose:** stay on list-only shortlists by default ($0.00075 per row), or enable details ($0.0015 per enriched row) without stacking two result events on the same listing.
- **Keep published contact text as published:** phones and WhatsApp numbers already shown on public cards are kept as-is; emails are never invented; reveal/OTP flows are never triggered.

### Built for these workflows

- **Agencies monitoring Bogotá apartment sales:** run the default Bogotá D.C. / apartamento / venta search, export price–size–neighbourhood rows, and open the original Metrocuadrado URL before contacting anyone.
- **Investors screening new-build projects:** enable details to attach builder company name, sales-room address/hours and stated delivery date next to price ranges for your own models. This is not a built-in comps, valuation or sold-price service.
- **Lead ops assembling outreach queues:** use publicly shown `contactPhone` / `whatsappNumber` when present, knowing the Actor will not invent an email or bypass contact walls.

### Preview what you receive

Real mapped samples from `test/fixtures/list-tiny.body` (anonymous public list API for Bogotá apartment sales, captured 8 November 2026 per `test/fixtures/PROVENANCE.txt`). Prices are **COP** sale amounts as published. Not a production-run performance claim.

| Title | Sale price (COP) | Area | Beds/Baths | Neighbourhood | Phone |
|---|---|---|---|---|---|
| Apartamento en Venta, SAN JOSE DE USAQUEN, Bogotá D.C. | 850,246,000 | 90.56 m² | 3/2 | SAN JOSE DE USAQUEN | 3102595913 |
| Apartamento en Venta, SALITRE, Bogotá D.C. | 1,145,000,000 | 97.5 m² | 3/3 | SALITRE | 3214569086 |
| Apartamento en Venta, GRANJAS DE TECHO, Bogotá D.C. | 620,000,000 | 58.0 m² | 2/1 | GRANJAS DE TECHO | 3103157550 |

Beds/Baths map to `rooms` / `bathrooms`; Sale price to `salePrice` / `price`; Area to `sizeM2`; Phone to `contactPhone`. Overview also surfaces `adId`, `title`, `city`, `neighborhood`, `url`, `companyName`, `salesRoomAddress`, `deliverDate` and `detailStatus` when present. List-only runs leave enrichment fields null and typically set `detailStatus` accordingly. From the detail fixture merge for listing `21902-C0007-02` (same probe day), enrichment includes `companyName` **MARVAL S.A.S**, `salesRoomAddress` **Calle 170 con carrera 17**, `salesRoomSchedule` weekdays/weekends **10:00 AM–06:00 PM**, `deliverDate` **30-06-2028**, and `publicationId` **21902-C0007**. List gallery entries are photo IDs with `url:null`; real image URLs appear after detail merge. Agency aggregation fields stay null with a reason in this freeze. Review overview columns in Apify and export with available dataset formats such as JSON or CSV.

Sample JSON dataset item (selected core fields from listing `21902-C0007-02` above, list-only mode):

```json
{
  "adId": "21902-C0007-02",
  "listingId": "21902-C0007-02",
  "operation": "Venta",
  "propertyType": "Apartamento",
  "price": 850246000,
  "salePrice": 850246000,
  "priceCurrency": "COP",
  "pricePerM2": 9388759,
  "sizeM2": 90.56,
  "rooms": 3,
  "bathrooms": 2,
  "garages": 0,
  "neighborhood": "SAN JOSE DE USAQUEN",
  "city": "Bogotá D.C.",
  "stratum": 3,
  "url": "https://www.metrocuadrado.com/proyecto/ciudad-la-salle-montpellier/21902-C0007-02",
  "contactPhone": "3102595913",
  "whatsappNumber": "573102595913",
  "title": "Apartamento en Venta, SAN JOSE DE USAQUEN, Bogotá D.C.",
  "companyName": null,
  "salesRoomAddress": null,
  "deliverDate": null,
  "contentQuality": "list",
  "detailStatus": null
}
```

### Why choose this Actor

- **Enhanced vs list-API-only wraps:** optional detail enrichment delivers builder company, sales-room and delivery fields that anonymous `$.results[*]` alone does not provide — verified against probe fixtures, not restated free JSON.
- **Clear result events:** list-only rows charge `metrocuadrado-listing-result` ($0.00075); successfully detail-merged rows charge `metrocuadrado-detail-result` ($0.0015) instead. A row whose detail fetch fails is still delivered as a list row at the listing price. Apify’s synthetic `apify-actor-start` event adds $0.00025 per run start.
- **Honest boundaries:** agency aggregation, incremental/hash history and nationwide/rent calibration are not claimed; `totalEntries` / `totalHits` are not treated as a hard full-index guarantee.

### Pricing

All amounts below are **USD**.

| Product / mode | Event | Fee for 1,000 valid rows | Start event |
|---|---|---:|---:|
| This Actor, list-only (default) | `metrocuadrado-listing-result` @ $0.00075 | $0.75 | `apify-actor-start` @ $0.00025 per run start |
| This Actor, details enabled | `metrocuadrado-detail-result` @ $0.0015 | $1.50 | `apify-actor-start` @ $0.00025 per run start |
| [blackfalcondata/metrocuadrado-scraper](https://apify.com/blackfalcondata/metrocuadrado-scraper), result item | `apify-default-dataset-item` @ $0.0015 | $1.50 | $0.0005 per GB, minimum one event |

The start event is Apify’s synthetic `apify-actor-start` event: the platform charges it automatically, once per run start at the default 256 MB memory (one more for each additional GB above 1 GB); the Actor code never charges it. For one run at the default memory:

- **1,000 list-only rows:** $0.75 + $0.00025 = **$0.75025**.
- **1,000 detail-enriched rows:** $1.50 + $0.00025 = **$1.50025** (the detail event replaces the listing event for that row).

#### Store subscription tier pricing

Apify Store subscription tier discounts apply automatically across **Bronze**, **Silver**, **Gold**, **Platinum**, and **Diamond** plans (live per-event USD rates; Free-tier base rates unchanged):

| Apify plan tier | `apify-actor-start` (per GB start) | `metrocuadrado-listing-result` (per row / per 1,000) | `metrocuadrado-detail-result` (per row / per 1,000) |
|---|---:|---:|---:|
| Free | $0.00025 | $0.00075 / $0.75 | $0.0015 / $1.50 |
| Bronze | $0.0002375 | $0.0007125 / $0.7125 | $0.001425 / $1.425 |
| Silver | $0.000225 | $0.000675 / $0.675 | $0.00135 / $1.35 |
| Gold | $0.0002125 | $0.0006375 / $0.6375 | $0.001275 / $1.275 |
| Platinum | $0.0002125 | $0.0006375 / $0.6375 | $0.001275 / $1.275 |
| Diamond | $0.0002125 | $0.0006375 / $0.6375 | $0.001275 / $1.275 |

Competitor list price checked through the Apify public API on **16 November 2026** (UTC+8): blackfalcondata/metrocuadrado-scraper charges $0.0015 per result plus a $0.0005 start event. Our list-only price is 50% of the competitor’s per-result price, and our start event is 50% of its start event: 1,000 list-only rows cost $0.75025 here versus $1.5005 in competitor event charges for one run at up to 1 GB. The competitor has no separate detail event; 1,000 detail-enriched rows cost $1.50025 here. This compares billing units, not identical coverage or guaranteed result counts.

**Same-row rule:** when `includeDetails` succeeds for a listing, only `metrocuadrado-detail-result` is charged for that row — `metrocuadrado-listing-result` is not also charged. **Detail failures degrade, they do not drop the row:** if a listing’s detail page is not found, errors, lacks the property data, or is blocked, the row is still delivered as a list row with `detailStatus` showing why, and only `metrocuadrado-listing-result` ($0.00075) is charged. A block or challenge on a detail page still stops the whole run after that row is saved. Direct `/inmueble` / `/proyecto` seeds have no list row to fall back to: a failed direct detail seed is recorded in `errors` and is neither saved nor charged, and a row whose detail fetch is cut off by the run time limit is not saved. Duplicate, empty and `highlights` / `recommended` entries do not incur a result event. **What you pay:** under this Actor's pay-per-event pricing you pay the event prices above; the platform compute used by the run is not billed to you separately, unless the Actor's Pricing tab says usage is added on top. Reading, exporting or writing stored data after the run has finished is billed as platform usage on your own Apify plan.

**Proxy:** this freeze **rejects nonempty** `proxyConfiguration` (omit the field, or pass only `{"useApifyProxy":false}`). There is no automatic proxy, session, IP or UA rotation after blocks.

### Get started in three steps

1. Start from the Bogotá apartment-sale starter values (set them explicitly — `city` / `propertyType` / `business` have Console prefill only, not a schema default) and request a small limit, for example:

```json
{
  "city": "Bogotá D.C.",
  "propertyType": "apartamento",
  "business": "venta",
  "maxItems": 5,
  "includeDetails": false
}
```

2. Run the Actor. Leave details off for the default list-only bill, or set `includeDetails` to true when you need company / sales-room / delivery enrichment and real photo URLs. You may instead supply supported public list paths, search API URLs or detail `/inmueble` / `/proyecto` URLs (direct detail seeds require `includeDetails=true`). Do not pass a nonempty proxy configuration.
3. Review the dataset and run summary, and export your shortlist. Confirm price, availability and how to enquire on the original Metrocuadrado page before acting.

#### SDK quickstart (JavaScript & Python)

JavaScript (`npm install apify-client`):

```javascript
import { ApifyClient } from 'apify-client';

const client = new ApifyClient({ token: process.env.APIFY_TOKEN });
const run = await client.actor('Stone_JadeX/metrocuadrado-colombia-scraper').call({
    city: 'Bogotá D.C.',
    propertyType: 'apartamento',
    business: 'venta',
    maxItems: 5,
    includeDetails: false,
});
const { items } = await client.dataset(run.defaultDatasetId).listItems();
console.log(items);
```

Python (`pip install apify-client`):

```python
import os
from apify_client import ApifyClient

client = ApifyClient(os.environ['APIFY_TOKEN'])
run = client.actor('Stone_JadeX/metrocuadrado-colombia-scraper').call(run_input={
    'city': 'Bogotá D.C.',
    'propertyType': 'apartamento',
    'business': 'venta',
    'maxItems': 5,
    'includeDetails': False,
})
items = list(client.dataset(run['defaultDatasetId']).iterate_items())
print(items)
```

### Coverage and common questions

**Which searches are supported?** Starter filters: `city` Bogotá D.C., `propertyType` apartamento, `business` venta — these three have **Console prefill only** (no schema `default`; Actor code falls back to the same values when you omit them and are not using conflicting `startUrls`). Schema defaults that *are* injected: `maxItems` 100, `includeDetails` false, `requestDelayMs` 1200, `size`/`pageSize` 50. Supported seeds include public `www.metrocuadrado.com` list paths (for example `/apartamentos/venta/bogota/`), anonymous `/api/rest-search/search` URLs, and detail `/inmueble/...` / `/proyecto/...` pages. Login, Homlity, JWT / API-key query params and blocked account paths are refused. Rent (business `arriendo`) and other cities are accepted as input parameters but were **not independently light-tested** in this freeze — do not treat them as verified coverage.

**What are the limits and stop conditions?** Requested item limits are 1–10,000 (default 100), not a promised result count. List pagination uses `from` + `size` (default size 50); actual result lengths can vary. Empty list `results` ends successfully with counters recorded. List-API claimed `totalEntries` / `totalHits` metadata (not dataset columns) are **not** used as a hard full-crawl bound. Requests run serially with at least 1.2 seconds after completion. **A block stops the whole run.** HTTP 403, 412 or 429 gets two backoffs, 30 s and then 60 s; if the block persists, or if a later attempt for that request gets any other non-200 response (including 404 or 5xx), a timeout or a network error, the run stops at once with `stopReason` `blocked-<code>` (`blocked-403`, `blocked-412` or `blocked-429`, the most recent block code). If too little run time is left to back off, the request also ends as `blocked-<code>`. A captcha, challenge or login page stops the run as `blocked-challenge`. Rows already saved are kept and charged; nothing else is charged. The run OUTPUT field `runNotice` (also the run’s status message) states the block code, the backoffs actually waited, the failure that ended the request and how many rows were saved. A list page that fails without a block (after its normal retries, for example a 5xx or unreadable JSON) is recorded in `errors`, and the run ends with `stopReason` `errors`. A soft run deadline (`maxRunSeconds`, default 3,600 seconds, capped 20 seconds before the platform timeout) ends the run as `run-time-limit`. For `blocked-<code>`, `blocked-challenge`, `run-time-limit` and `errors`, OUTPUT `failed` is `true` while the platform run status stays SUCCEEDED, so inspect the OUTPUT even when the platform status is successful. A run that finishes normally with rows ends as `completed`; 0 rows with no errors ends as `empty`; `empty-page`, `maxItems` and `maxFrom` are also normal endings with `failed=false`.

**How are photos and flags handled?** List `mgaleriainmueble` values are gallery IDs with `url:null` — URLs are not invented. Detail pages supply real image URLs when present. `hasElevator` / `gatedCommunity` are `true` only when features explicitly say so; otherwise `null`. Sale price `0` is marked invalid/unknown; garage count `0` is a valid zero.

**Will every field be available?** No. List-only runs leave enrichment fields null. Agency aggregation (`listingsSeen`, city/neighbourhood rollups, contact totals) stays null with `agencyAggReason` in this freeze. Incremental hash / expiry tracking is not implemented. Listings are snapshots, not a live feed. Commercial site terms may restrict automated collection → **`termsRisk`** is recorded in the run OUTPUT as a warning, not a technical veto — you must still assess Metrocuadrado terms for your use case. In testing, one list-only run (Bogotá D.C. / apartamento / venta, no proxy, default 256 MB memory) saved 1,000 rows in about three minutes: all 20 requests succeeded, with no 403, 429 or 5xx responses and no memory problems (peak about 69 MiB). Detail mode has only been tested on a 5-row sample. Larger runs, other searches and detail runs at that scale have not been tested. Automatic failure alerts and repair timelines are not offered.

**Is it legal to scrape Metrocuadrado?** This Actor accesses only publicly available Metrocuadrado.com list and detail data. It does not log in, bypass access controls, solve captchas, call authenticated Homlity / X-Api-Key APIs, click contact-reveal controls or send WhatsApp OTP. Public availability is not blanket permission for every reuse, and site terms may restrict automated collection: you are responsible for complying with applicable laws, Metrocuadrado terms and the requirements of your own use case.

### Changelog

#### 2026-11-21

- Grouped `.actor/input_schema.json` fields with `sectionCaption` headings (`Start URLs`, `Search Filters`, `Crawl Limits & Enrichment`, `Rate Limiting & Runtime`, `Pagination Controls`, `Proxy Configuration`) and updated `maxItems.prefill` to `100` to align with `default: 100`.
- Added JSON dataset output sample, live Pay-Per-Event Store subscription tier pricing (Free, Bronze, Silver, Gold, Platinum, Diamond), JavaScript and Python `ApifyClient` SDK quickstart examples (`Stone_JadeX/metrocuadrado-colombia-scraper`), and changelog entry.

# Changelog

This Actor's version history is a separate document: https://apify.com/stone_jadex/metrocuadrado-colombia-scraper/changelog.md

# Actor input Schema

## `startUrls` (type: `array`):

HTTPS www.metrocuadrado.com public /apartamentos|/casas|/inmueble|/proyecto|/api/rest-search/search URLs. Off-site hosts, credentials, non-443 ports, Homlity, JWT/auth query tokens, /web/, /detail/, favorites, Incapsula and login paths are rejected. Mutually preferred over top-level city/propertyType/business when provided — those filter fields have no schema default so omitting them with startUrls does not inject a conflict. Direct /inmueble|/proyecto detail URLs require includeDetails=true.

## `city` (type: `string`):

Search city for the anonymous list API (city query param). Prefill is Console UI-only — there is no schema default, so the platform will not inject a city when you omit it (avoids overriding a city already present in startUrls path/query). When neither startUrls nor city are supplied, Actor code falls back to Bogotá D.C.

## `propertyType` (type: `string`):

realEstateTypeList value (e.g. apartamento, casa). Prefill only — no schema default (avoids startUrls conflict). Actor code fallback: apartamento.

## `business` (type: `string`):

realEstateBusinessList value (venta or arriendo). Prefill only — no schema default (avoids startUrls conflict). Actor code fallback: venta.

## `realEstateTypeList` (type: `string`):

Alias of propertyType (realEstateTypeList query). Prefill only — no schema default.

## `realEstateBusinessList` (type: `string`):

Alias of business (realEstateBusinessList query). Prefill only — no schema default.

## `maxItems` (type: `integer`):

Global successfully pushed-row limit; clamped to 1–10000. Duplicate adId values are skipped before enrich/charge when deduplicate=true and do not count toward the limit.

## `includeDetails` (type: `boolean`):

Fetch public detail HTML Flight/RSC enrichment. Default false = list-only. Direct detail startUrls require includeDetails=true (no silent force). List-only rows charge metrocuadrado-listing-result; successfully detail-merged rows charge metrocuadrado-detail-result only (not both). Failed detail enrichments are not charged. Enhanced delta vs free list API: companyName/companyImage/companyLink/salesRoom\*/deliverDate/video/publicationId/ranges/featuresDetail.

## `deduplicate` (type: `boolean`):

Skip already-seen adId/listingId values before enrich/charge. Default true.

## `requestDelayMs` (type: `integer`):

Minimum interval between consecutive completed requests (serial). Clamped to 1200–60000. robots.txt has no crawl-delay; Disallow hits still increment robotsDisallowedHits (continuing per task rule).

## `maxRunSeconds` (type: `integer`):

Soft wall-clock budget for the run. Soft deadline is also capped 20s before the platform timeout when ACTOR_TIMEOUT_AT / APIFY_TIMEOUT_AT is set. Hitting the budget stops SUCCEEDED (run-time-limit).

## `pageSize` (type: `integer`):

List API size query param (results per request). Clamped to 1–100. Default 50. Actual results length can vary; empty results end the page loop SUCCEEDED.

## `size` (type: `integer`):

Alias of pageSize (size query). Same clamp 1–100.

## `startFrom` (type: `integer`):

Initial list API from offset (0-based). Soft pagination — claimed totalEntries/totalHits are metadata only, not a hard crawl end.

## `from` (type: `integer`):

Alias of startFrom. Same 0–1000000 clamp.

## `maxFrom` (type: `integer`):

Optional soft-cap on list API from offset. When reached, run stops SUCCEEDED with a warning. Omit for no soft-cap. Claimed totals are NOT a hard bound.

## `proxyConfiguration` (type: `object`):

Buyer proxy is not supported in this freeze. Omit the field, or pass {"useApifyProxy":false} only. Any nonempty proxy settings are rejected. No automatic proxy/session/UA/IP rotate/requeue.

## Actor input object example

```json
{
  "startUrls": [],
  "city": "Bogotá D.C.",
  "propertyType": "apartamento",
  "business": "venta",
  "realEstateTypeList": "apartamento",
  "realEstateBusinessList": "venta",
  "maxItems": 100,
  "includeDetails": false,
  "deduplicate": true,
  "requestDelayMs": 1200,
  "maxRunSeconds": 3600,
  "pageSize": 50,
  "size": 50,
  "startFrom": 0,
  "from": 0,
  "maxFrom": 100,
  "proxyConfiguration": {
    "useApifyProxy": false
  }
}
```

# Actor output Schema

## `dataset` (type: `string`):

All successfully pushed listing rows. Default list-only runs leave enrichment fields null with detailStatus=null|pending. Detail-enriched successful rows have detailStatus=ok and companyName/salesRoom\*/deliverDate filled when present on the public detail page. Deduped by adId. highlights/recommended are never emitted as charged primary rows. When includeDetails=true and detailStatus is not ok, the list row is still pushed and charged as metrocuadrado-listing-result only.

## `report` (type: `string`):

Run stop reason and failed flag (blocked-403 / blocked-412 / blocked-429 / blocked-challenge / run-time-limit / errors → failed=true; empty / completed — the former name complete is no longer emitted — / empty-page / maxItems / maxFrom / charge-error / max-charge-reached → failed=false; invalid-input → failed=true and Actor.fail). Platform run status is SUCCEEDED except invalid-input. Also runNotice, errors\[].type (blocked / blocked-challenge / list-error / detail-error), errors\[].lastFailure, errors\[].url, http.status412, pricingEvents.start=apify-actor-start ($0.00025, never charged by this code), pagesFetched / from / lastFrom / pageCount, claimed totals (NOT a crawl promise), rowsPushed / chargedByEvent (metrocuadrado-listing-result / metrocuadrado-detail-result), truncation flags, robotsDisallowedHits, fieldsUnavailable, warnings, termsRisk=high and productKind=enhanced. Diagnostics live here, not as separate dataset rows.

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "startUrls": [],
    "city": "Bogotá D.C.",
    "propertyType": "apartamento",
    "business": "venta",
    "realEstateTypeList": "apartamento",
    "realEstateBusinessList": "venta",
    "maxItems": 100,
    "includeDetails": false,
    "deduplicate": true,
    "requestDelayMs": 1200,
    "maxRunSeconds": 3600,
    "pageSize": 50,
    "size": 50,
    "startFrom": 0,
    "from": 0,
    "maxFrom": 100,
    "proxyConfiguration": {
        "useApifyProxy": false
    }
};

// Run the Actor and wait for it to finish
const run = await client.actor("stone_jadex/metrocuadrado-colombia-scraper").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {
    "startUrls": [],
    "city": "Bogotá D.C.",
    "propertyType": "apartamento",
    "business": "venta",
    "realEstateTypeList": "apartamento",
    "realEstateBusinessList": "venta",
    "maxItems": 100,
    "includeDetails": False,
    "deduplicate": True,
    "requestDelayMs": 1200,
    "maxRunSeconds": 3600,
    "pageSize": 50,
    "size": 50,
    "startFrom": 0,
    "from": 0,
    "maxFrom": 100,
    "proxyConfiguration": { "useApifyProxy": False },
}

# Run the Actor and wait for it to finish
run = client.actor("stone_jadex/metrocuadrado-colombia-scraper").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "startUrls": [],
  "city": "Bogotá D.C.",
  "propertyType": "apartamento",
  "business": "venta",
  "realEstateTypeList": "apartamento",
  "realEstateBusinessList": "venta",
  "maxItems": 100,
  "includeDetails": false,
  "deduplicate": true,
  "requestDelayMs": 1200,
  "maxRunSeconds": 3600,
  "pageSize": 50,
  "size": 50,
  "startFrom": 0,
  "from": 0,
  "maxFrom": 100,
  "proxyConfiguration": {
    "useApifyProxy": false
  }
}' |
apify call stone_jadex/metrocuadrado-colombia-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,stone_jadex/metrocuadrado-colombia-scraper"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/oEcw0qvzvF1oWWY8f/builds/IepG6OLHuu4og6iQt/openapi.json
