# Rome2rio place autocomplete API

Search Rome2rio places by text and language via REST or OpenAny MCP—with pay-per-use pricing and no subscription. Powered by Apish, pass parameters such as output, q, raw, and retrieve structured data including place display name, source canonical place reference, source place type, source country code, and latitude for place selector, and route preparation.

Documentation: https://openany.si/rome2rio/rome2rio-place-autocomplete-api/39ed4ff2-555a-4d12-a3ec-451063afc945/
API ID: 39ed4ff2-555a-4d12-a3ec-451063afc945
Provider: apish
Contract revision: 3
Method: GET
Endpoint: https://api.openany.si/v1/agent-apis/apish/rome2rio/v1/autocomplete
Page update time: 2026-12-03T02:47:05.650Z
Access: OpenAny REST
OpenAny MCP: availability is not supplied by this REST contract. Check get_api on the configured OpenAny MCP server before execution.
Request content type: none
Execution mode: sync
Authentication: Authorization: Bearer $OPENANY_API_KEY

## Billing
Price: $0.002 / billing credit
API-key calls use your shared balance. Review the published billing rules before making a paid request.
Price source: OpenAny public API contract.
Contract update time: 2026-12-03T02:47:04.291Z. This is not a price-change timestamp.
```json
{
  "currency": "USD",
  "mode": "rules",
  "parameters": [],
  "policy_version": 2,
  "sale": {
    "addons": [],
    "base_price_micro_usd": "0",
    "max_cost_micro_usd": "2000",
    "quantities": [
      {
        "id": "upstream_credits",
        "label": "Actual API.SH credits consumed",
        "max_quantity": "1",
        "measure": "value",
        "pointer": "/credits_used",
        "price_micro_usd": "2000",
        "quantity_scale": 0,
        "source": "response",
        "unit": "credit",
        "unit_quantity": "1"
      }
    ],
    "rounding": "ceil",
    "variants": []
  }
}
```

## Usage and limits
## Rome2rio Place Search API

Pass q with at least two characters, optionally a two-letter lang. Each suggestion preserves canonical\_name, long\_name, kind and country\_code; coordinates and other geographic fields can be absent.

## What You Can Build

- **Place selector**: Keep location type and country with each source suggestion.
- **Route preparation**: Resolve the intended place before selecting route endpoints.

## Returned Data

| Field | Meaning |
| --- | --- |
| `places[].name` | Place display name |
| `places[].canonical_name` | Source canonical place reference |
| `places[].kind` | Source place type |
| `places[].country_code` | Source country code |
| `places[].lat` | Latitude when available |
| `count` | Returned suggestion count |

## Request parameters
```json
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "title": "Rome2rio place autocomplete API request inputs",
  "$comment": "Declared input types grouped by HTTP location. Path, query and header values describe decoded inputs and are serialized as text on the wire; body is the payload. This is not an exhaustive provider contract or a schema for the raw HTTP request.",
  "type": "object",
  "properties": {
    "path": {
      "type": "object",
      "properties": {}
    },
    "query": {
      "type": "object",
      "properties": {
        "q": {
          "type": "string",
          "description": "At least 2 characters."
        },
        "lang": {
          "type": "string",
          "description": "2-letter language code."
        },
        "raw": {
          "type": "string",
          "description": "0 leaves out the bulky `raw` source blocks (often 10-30x smaller).",
          "enum": [
            "0",
            "1"
          ]
        },
        "fields": {
          "type": "string",
          "description": "Comma-separated fields to return, e.g. `posts.id,posts.title`. Call metadata is always included."
        },
        "fresh": {
          "type": "string",
          "description": "1 skips the 24-hour cache and fetches live.",
          "enum": [
            "1"
          ]
        },
        "output": {
          "type": "string",
          "description": "JSON only for this OpenAny product. Omit output or use json; CSV and NDJSON are not supported.",
          "enum": [
            "json"
          ]
        },
        "records": {
          "type": "string",
          "description": "With output=csv|ndjson: the top-level list to turn into rows (e.g. `reviews`), or `.` for the whole object as one row."
        }
      },
      "required": [
        "q"
      ]
    },
    "headers": {
      "type": "object",
      "properties": {}
    }
  },
  "required": [
    "path",
    "query",
    "headers"
  ]
}
```

## Response fields
Source: Inferred from examples; not an exhaustive provider schema.
```json
{
  "type": "object",
  "properties": {
    "cached": {
      "type": "boolean"
    },
    "count": {
      "type": "integer"
    },
    "credits_used": {
      "type": "integer"
    },
    "fetched_at": {
      "type": "string"
    },
    "places": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "canonical_name": {
            "type": "string"
          },
          "code": {
            "type": "null"
          },
          "country": {
            "type": "string"
          },
          "country_code": {
            "type": "string"
          },
          "kind": {
            "type": "string"
          },
          "kinds": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "lat": {
            "type": "null"
          },
          "lng": {
            "type": "null"
          },
          "long_name": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "nearby_city": {
            "type": "null"
          },
          "radius_km": {
            "type": "null"
          },
          "region": {
            "type": "null"
          },
          "region_code": {
            "type": "null"
          },
          "timezone": {
            "type": "null"
          }
        }
      }
    },
    "q": {
      "type": "string"
    }
  }
}
```

## Request example
Scenario: Official example · Live API.SH response · Minimal request
```bash
curl \
  'https://api.openany.si/v1/agent-apis/apish/rome2rio/v1/autocomplete?output=json&q=bang&raw=0' \
  -X GET \
  -H "Authorization: Bearer $OPENANY_API_KEY" \
  -H 'Content-Type: application/json'
```

## Response example
Example from the provider's documentation. Field values in your results will differ.
Sample response · Documented HTTP 200
```json
{
  "cached": false,
  "count": 10,
  "credits_used": 1,
  "fetched_at": "2026-11-19T12:25:23.022Z",
  "places": [
    {
      "canonical_name": "Bangkok",
      "code": null,
      "country": "Thailand",
      "country_code": "TH",
      "kind": "capital",
      "kinds": [
        "capital",
        "city",
        "village"
      ],
      "lat": null,
      "lng": null,
      "long_name": "Bangkok, Thailand",
      "name": "Bangkok",
      "nearby_city": null,
      "radius_km": null,
      "region": null,
      "region_code": null,
      "timezone": null
    },
    {
      "canonical_name": "Bengaluru",
      "code": null,
      "country": "India",
      "country_code": "IN",
      "kind": "city",
      "kinds": [
        "city",
        "metropolis"
      ],
      "lat": null,
      "lng": null,
      "long_name": "Bengaluru, India",
      "name": "Bengaluru",
      "nearby_city": null,
      "radius_km": null,
      "region": null,
      "region_code": null,
      "timezone": null
    },
    {
      "canonical_name": "Western-Region",
      "code": null,
      "country": "Vietnam",
      "country_code": "VN",
      "kind": "land",
      "kinds": [
        "land"
      ],
      "lat": null,
      "lng": null,
      "long_name": "Western Region, Vĩnh Long, Vietnam",
      "name": "Western Region",
      "nearby_city": null,
      "radius_km": null,
      "region": null,
      "region_code": null,
      "timezone": null
    },
    {
      "canonical_name": "Bang-Phlat",
      "code": null,
      "country": "Thailand",
      "country_code": "TH",
      "kind": "city",
      "kinds": [
        "city",
        "village"
      ],
      "lat": null,
      "lng": null,
      "long_name": "Bang Phlat, Thailand",
      "name": "Bang Phlat",
      "nearby_city": null,
      "radius_km": null,
      "region": null,
      "region_code": null,
      "timezone": null
    },
    {
      "canonical_name": "Bang-Bua-Thong",
      "code": null,
      "country": "Thailand",
      "country_code": "TH",
      "kind": "city",
      "kinds": [
        "city",
        "town"
      ],
      "lat": null,
      "lng": null,
      "long_name": "Bang Bua Thong, Thailand",
      "name": "Bang Bua Thong",
      "nearby_city": null,
      "radius_km": null,
      "region": null,
      "region_code": null,
      "timezone": null
    },
    {
      "canonical_name": "Cao-Bằng",
      "code": null,
      "country": "Vietnam",
      "country_code": "VN",
      "kind": "city",
      "kinds": [
        "city",
        "town"
      ],
      "lat": null,
      "lng": null,
      "long_name": "Cao Bằng, Vietnam",
      "name": "Cao Bằng",
      "nearby_city": null,
      "radius_km": null,
      "region": null,
      "region_code": null,
      "timezone": null
    },
    {
      "canonical_name": "Bang-Kruai",
      "code": null,
      "country": "Thailand",
      "country_code": "TH",
      "kind": "city",
      "kinds": [
        "city",
        "town"
      ],
      "lat": null,
      "lng": null,
      "long_name": "Bang Kruai, Thailand",
      "name": "Bang Kruai",
      "nearby_city": null,
      "radius_km": null,
      "region": null,
      "region_code": null,
      "timezone": null
    },
    {
      "canonical_name": "Ban-Bang-Saen-2",
      "code": null,
      "country": "Thailand",
      "country_code": "TH",
      "kind": "town",
      "kinds": [
        "town",
        "village"
      ],
      "lat": null,
      "lng": null,
      "long_name": "Ban Bang Saen (2), Thailand",
      "name": "Ban Bang Saen (2)",
      "nearby_city": null,
      "radius_km": null,
      "region": null,
      "region_code": null,
      "timezone": null
    },
    {
      "canonical_name": "Bang-Phai",
      "code": null,
      "country": "Thailand",
      "country_code": "TH",
      "kind": "town",
      "kinds": [
        "town"
      ],
      "lat": null,
      "lng": null,
      "long_name": "Bang Phai, Bangkok, Thailand",
      "name": "Bang Phai",
      "nearby_city": null,
      "radius_km": null,
      "region": null,
      "region_code": null,
      "timezone": null
    },
    {
      "canonical_name": "Bang-Pa-in",
      "code": null,
      "country": "Thailand",
      "country_code": "TH",
      "kind": "town",
      "kinds": [
        "town",
        "village"
      ],
      "lat": null,
      "lng": null,
      "long_name": "Bang Pa-in, Thailand",
      "name": "Bang Pa-in",
      "nearby_city": null,
      "radius_km": null,
      "region": null,
      "region_code": null,
      "timezone": null
    }
  ],
  "q": "bang"
}
```

## Error handling
400: Check the request fields.
401 / 403: Verify credentials and access permissions.
402: Inspect payment requirements and balance.
429: Respect returned retry guidance.
5xx: Inspect the error and usage record before retrying a paid operation.

## Common questions
### What text and language formats are supported?
q needs at least two characters. lang accepts a two-letter language code.

### Can I treat every result as a city?
No. Retain kind and the source location label to distinguish cities, airports or landmarks.

### What if coordinates are missing?
Keep them missing rather than substituting zero; Place Details can provide additional source context for a selected name.

### How should I disambiguate similar names?
Keep long_name, country and region context with the selected source place reference.

### How do I bypass cached results?
Pass fresh=1. A cache bypass retrieves available source data; it does not make unpublished or restricted records available.

### Can I request CSV or NDJSON?
This OpenAny implementation serves JSON only. Omit output or set output=json.

## Available implementations
- apish: https://openany.si/rome2rio/rome2rio-place-autocomplete-api/39ed4ff2-555a-4d12-a3ec-451063afc945/

Integration guide: https://openany.si/docs/
Agent setup: https://openany.si/SKILL.md
