CasafariMCP
Get started

Casafari is the AI agent-native real estate data intelligence platform. The most complete property index in Europe: a deduplicated, cleaned property graph of residential and commercial property, for sale and for rent, in 16 countries.The most complete property index in Europe: a deduplicated, cleaned property graph.

How the graph is built

References · REST API

Get locations typeahead suggestions scoped by country code (v1)

POSThttps://api.casafari.com/api/v1/references/locations/typeahead
Bearer token4 parameters

Send Authorization: Bearer $CASAFARI_TOKEN; see how to get a token.

Over MCP: ma_get_location_typeahead (related). MCP and REST compared.

Description

Returns location typeahead suggestions within the given country (ES or PT).

Request body

Content type application/json. Optional. Type: object.

country_codesstring[]required
Country codes to scope the search. Supported: ES, PT.
ES PT
namestringrequired
The location name to search for.
2–100 characters
sizeinteger
The maximum number of suggestions to return. Default 30, maximum 100.
1–100default 30
langstring
Language to use for the location name in the response. One of: en, pt, es, de.
en pt es de
default "en"

Example request

Placeholders only: replace the token and the values with your own.

curl
curl -X POST "https://api.casafari.com/api/v1/references/locations/typeahead" \
  -H "Authorization: Bearer $CASAFARI_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
  "country_codes": [
    "PT"
  ],
  "name": "lisboa",
  "lang": "en",
  "size": 30
}'

Responses

200 OK

Type: object.

Show the response shape (8 fields)
typeaheadobject[]required
The typeahead suggestions.
5 properties
location_idintegerrequired
The location id.
namestringrequired
The location name.
matched_namestringrequired
The matched name of the location name.
at most 256 characters
administrative_levelstringrequired
The administrative level.
breadcrumbsobject[]required
Location breadcrumbs sorted from top to bottom.
2 properties
location_idintegerrequired
Location ID.
namestringrequired
The name of location.
Example from the API description
JSON
{
  "typeahead": [
    {
      "location_id": 1296,
      "name": "Lisboa",
      "matched_name": "Lisboa",
      "administrative_level": "Distrito",
      "breadcrumbs": [
        {
          "location_id": 499,
          "name": "Portugal"
        },
        {
          "location_id": 1296,
          "name": "Lisboa"
        }
      ]
    }
  ]
}

401 Unauthorized

Type: object.

Show the response shape (1 fields)
detailstring
Description of the error encountered.

403 Forbidden

Type: object.

Show the response shape (1 fields)
detailstring
Description of the error encountered.

Questions about this

Tip: add .md to any URL to read it as Markdown.