REST API: una API inmobiliaria para agentes de IA y aplicaciones
The same data as the MCP tools, over HTTP: an API for AI agents whose code makes fixed requests, and for any app. To let a model choose the calls instead, use the MCP servers, or call them from the OpenAI API or the Claude API. The REST API is the platform's: https://platform.casafari.com/v1/<product>, one base per product, signed with the platform API key from your console and billed in tokens, the same key and the same tokens as the MCP servers. This reference is generated from the platform's own OpenAPI files (version 2026-10-31.1, vendored 2026-11-02): 37 operations in 9 sections, 7 of them products. Operations are grouped by product, the same way the MCP tools are; MCP and REST compared shows where the two overlap and where they do not. This reference lists the platform's routes only: Casafari clients with a contract who still call the old routes at https://api.casafari.com find them on the Legacy API page, each with its platform equivalent.
Platform API keys
| Base URL | https://platform.casafari.com: each product under /v1/<product> (/v1/property-sourcing, /v1/seller-leads, /v1/private-sellers, /v1/comparables, /v1/comparables-transactions, /v1/area-insights, /v1/parcel-zoning); place lookup under /v1/locations, your account under /v1/account |
| Credential | A platform API key (cf_sk_...) from the console, sent as Authorization: Bearer <api_key> or X-API-Key: <api_key>; or an OAuth access token as the bearer (MCP authorization). The key travels in a header, never in the query string. |
| Format | JSON requests and responses; errors as application/problem+json (RFC 9457): detail says how to fix it, code names the problem, request_id is what to quote to support |
| Tokens | Every operation costs a fixed number of tokens (1 token = EUR 0.04); each operation's page says what it costs, and the file says it in x-casafari-units. Some cost less as MCP tool calls in an AI assistant: see Pricing. The response headers Casafari-Units-Charged and Casafari-Units-Remaining say what a call cost and what is left. When tokens run out the API answers 402 payment_required with an upgrade_url to top up. |
| Plans | Free: 1,000 tokens for 30 days. Pay as you go: credits. Agent: EUR 49 a month, or EUR 39 a month billed yearly, with 1,500 tokens a month. Agency: EUR 249 a month, or EUR 199 a month billed yearly, with 10,000 tokens a month. Business: EUR 990 a month, or EUR 792 a month billed yearly, with 50,000 tokens a month. Custom: talk to Casafari. See Pricing and Limits: Free and the paid self-serve plans have request limits, such as distinct places a day. |
| OpenAPI | One file per product, the platform's own (see Download the OpenAPI description) |
A first call, with the key in an environment variable ($CASAFARI_API_KEY in every example on this site is a placeholder, never a credential): Comparables, the platform's default product.
curl -X POST "https://platform.casafari.com/v1/comparables/search" \
-H "Authorization: Bearer $CASAFARI_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"comparables_count": 5,
"location_boundary": {
"circle": {
"target_point": {
"coordinates": {
"latitude": 40.4168,
"longitude": -3.7038
}
},
"distance": 1
}
},
"operation": "sale",
"comparables_types": [
"apartment"
]
}'Most products take a location_id: get it first from GET /v1/locations/search (free). GET /v1/account (free) shows your plan and the tokens left.
Download the OpenAPI description
For Postman (Import → Link, paste the URL), Insomnia, code generators or an agent's tool loader. The platform's files are its own, one per product, public and served by the platform itself; the hub keeps a copy of each (vendored 2026-11-02, version 2026-10-31.1), which these pages are generated from.
Every product's platform routes in one file, every path on its own server, with examples filled in from real calls: /openapi.json covers every product; per product, /docs/rest/property-sourcing/openapi.json, /docs/rest/seller-leads/openapi.json, /docs/rest/private-sellers/openapi.json, /docs/rest/comparables-valuation/openapi.json, /docs/rest/comparables-with-transactions/openapi.json, /docs/rest/area-insights/openapi.json, /docs/rest/parcel-zoning/openapi.json, /docs/rest/locations/openapi.json, /docs/rest/account/openapi.json. The Legacy API's description is apart: /docs/existing-api-customers/openapi.json.
Operations by product
Property Sourcing
POST /v1/property-sourcing/searches: Search properties. Costs 50 tokens a call.GET /v1/property-sourcing/searches/{cursor}: Next page of a search. Costs 50 tokens a call.GET /v1/property-sourcing/properties/{property_id}: Get a property. Costs 10 tokens a call.GET /v1/property-sourcing/properties/{property_id}/closing-prices: Registered sale prices around a property. Costs 5 tokens a call.POST /v1/property-sourcing/properties/resolve: Resolve a link or reference to its property. Costs 25 tokens a call.
High Potential Seller Leads
GET /v1/seller-leads: List seller leads. Costs 100 tokens a call.GET /v1/seller-leads/{lead_id}: Get a seller lead. Costs 10 tokens a call.
Private Seller Leads
POST /v1/private-sellers/search: Search private-seller listings by place and date. Costs 10 tokens a call.GET /v1/private-sellers/listings/{id}: One private-seller listing. Costs 1 token a call.GET /v1/private-sellers/coverage: Countries with private-seller listings and their counts. Free (uses no tokens).
Comparables & Valuation
POST /v1/comparables/search: Value a property with comparables. Costs 25 tokens a call.
Comparables with Transactions
POST /v1/comparables-transactions/search: Value a property with comparables and registered closing prices. Costs 65 tokens a call.
Area Insights
POST /v1/area-insights/analysis: Market analysis of an area. Costs 25 tokens a call.POST /v1/area-insights/distributions/properties: Property type distribution in an area. Costs 25 tokens a call.POST /v1/area-insights/distributions/prices: Price distribution in an area. Costs 25 tokens a call.POST /v1/area-insights/distributions/bedrooms: Bedrooms distribution in an area. Costs 25 tokens a call.POST /v1/area-insights/distributions/time-on-market: Time on market distribution in an area. Costs 25 tokens a call.POST /v1/area-insights/time-series: Price and activity time series for an area. Costs 25 tokens a call.POST /v1/area-insights/heatmap: Heatmap of an area by district. Costs 25 tokens a call.POST /v1/area-insights/sales/time-series: Registered sale price trend in an area, week by week. Costs 10 tokens a call.POST /v1/area-insights/sales/average-prices: Average registered sale prices by location. Costs 10 tokens a call.POST /v1/area-insights/sales/count-by-type: Number of registered sales by property type. Costs 10 tokens a call.
Parcel Zoning
GET /v1/parcel-zoning/es/parcels/{cadastral_ref}: Zoning and buildable area of a parcel by cadastral reference. Costs 5 tokens a call.GET /v1/parcel-zoning/es/parcels: Zoning and buildable area of the parcel at a point. Costs 5 tokens a call.GET /v1/parcel-zoning/de/parcels/{cadastral_ref}: Zoning and buildable area of a German parcel by Flurstückskennzeichen. Costs 5 tokens a call.GET /v1/parcel-zoning/de/parcels: Zoning and buildable area of the German parcel at a point. Costs 5 tokens a call.GET /v1/parcel-zoning/coverage: Regions covered, with parcel counts and data dates. Free (uses no tokens).GET /v1/parcel-zoning/health: Service status. Free (uses no tokens).
Location Lookup
GET /v1/locations/search: Search locations by name or postcode. Free (uses no tokens).GET /v1/locations/{location_id}: Get a location with its parents. Free (uses no tokens).GET /v1/locations/{location_id}/children: List the child locations of a location. Free (uses no tokens).GET /v1/locations/by-coordinates: Find the locations that contain a point. Free (uses no tokens).
Cuenta y registro
GET /v1/account: Account status: plan, tokens and limits. Free (uses no tokens).GET /v1/account/payment-links/{payment_link_id}: Status of a payment link. Free (uses no tokens).GET /v1/signups/terms: Read the current termsPOST /v1/signups: Start a sign-up. Emails a 6-digit code to the person.POST /v1/signups/{signup_id}/verify: Finish a sign-up with the emailed code. Returns the account and an API key, shown once.
Legacy API (api.casafari.com)
Already a Casafari API customer? Your token keeps working, and the existing API's reference is now on this site. Log in to your API account to see your token.
Using the old api.casafari.com routes? See Legacy API. The old routes at https://api.casafari.com (39 operations, sign-in included) are listed there by product, each with the platform route that replaces it, with how to sign in and the old API's own OpenAPI description. A platform API key does not work there, and an old token does not work on the platform.
Status codes
Every operation documents its own responses. Across the platform's operations:
| Status | Meaning | Operations that can return it |
|---|---|---|
200 | OK | 35 |
201 | Created | 1 |
202 | Accepted | 1 |
400 | Solicitud incorrecta | 36 |
401 | No autorizado | 34 |
402 | payment_required (https://platform.casafari.com/errors/payment-required) | 25 |
403 | Prohibido | 34 |
404 | No encontrado | 36 |
405 | method_not_allowed (https://platform.casafari.com/errors/method-not-allowed) | 37 |
409 | Conflict | 15 |
413 | payload_too_large (https://platform.casafari.com/errors/payload-too-large) | 15 |
415 | unsupported_media_type (https://platform.casafari.com/errors/unsupported-media-type) | 15 |
422 | Error de validación | 15 |
429 | Too Many Requests | 36 |
500 | internal_error (https://platform.casafari.com/errors/internal-error) | 37 |
502 | upstream_error (https://platform.casafari.com/errors/upstream-error) | 32 |
503 | capacity_exhausted, unavailable (https://platform.casafari.com/errors/capacity-exhausted, https://platform.casafari.com/errors/unavailable) | 37 |
504 | upstream_timeout (https://platform.casafari.com/errors/upstream-timeout) | 32 |
Read this reference as Markdown
Add .md to any page's URL, or send Accept: text/markdown. /llms.txt lists every operation next to every MCP tool.
Preguntas sobre esto
- ¿Qué es Casafari MCP?
- ¿Qué dirección debo usar: api.casafari.com o platform.casafari.com (mcp.casafari.com es la pasarela heredada)?
- Ya tengo acceso a la API o a MCP de Casafari. ¿Cambia algo para mí?
- ¿Cómo obtengo una clave API y realizo mi primera llamada?
- ¿Qué son los tokens en la plataforma Casafari?