---
title: "Search places"
---

> Documentation Index
> Fetch the complete documentation index at: https://docs.nicer.travel/llms.txt
> Use this file to discover all available pages before exploring further.

# Search places

Path: Nicer API › Search

`GET /search/places`

URL: `https://api.nicer.travel/search/places`

Search hotels, cities, airports and places by text. Hotels come from the Smith and shared catalogs first, then Google; cities and airports from the travel reference. Anonymous calls share one budget across the search routes, 600 per hour per IP; a valid bearer token lifts it. `Accept: text/event-stream` streams ranked snapshots as sources finish.

## Authentication

Requires one of the following:

- 
- `bearerAuth`, http bearer, header `Authorization`, format `JWT`

## Query parameters

- `q` (`search.places.list.query.q`; string, required) — Free text: a hotel, city, airport or venue name.
  - maxLength: `100` · minLength: `2`
- `kinds` (`search.places.list.query.kinds`; string, optional) — Comma-separated kinds to return: hotel, city, airport, place. All kinds when omitted.
  - pattern: `^(?:hotel|city|airport|place)(?:,(?:hotel|city|airport|place))*$`
- `type` (`search.places.list.query.type`; string, optional) — Google place type filter for `place` results, for example restaurant or tourist_attraction.
  - maxLength: `40` · minLength: `1` · pattern: `^[a-z_]+$`
- `limit` (`search.places.list.query.limit`; integer, optional) — Maximum items after ranking.
  - maximum: `50` · minimum: `1` · default: `10`
- `photos` (`search.places.list.query.photos`; integer, optional) — Photos per item in the list. The place details resource carries the full album.
  - maximum: `3` · minimum: `0` · default: `0`

## Header parameters

- `Accept` (`search.places.list.header.Accept`; string, optional) — application/json (default) for one document, text/event-stream for ordered snapshots as sources finish.
  - one of `"application/json"`, `"text/event-stream"`

## Code samples

### JavaScript SDK

```javascript
import { createClient } from "@nicertravel/sdk";

const nicer = createClient({
  baseUrl: "https://api.nicer.travel",
  token: process.env.NICER_TOKEN,
});

await nicer.search.places.list({
  "q": "string"
});
```

### Nicer CLI

```bash
nicer search places list --q 'string'
```

### cURL

```bash
curl --request GET \
  --url 'https://api.nicer.travel/search/places?q=string'
```

### TypeScript

```typescript
const url = 'https://api.nicer.travel/search/places?q=string';
const options = {method: 'GET'};

fetch(url, options)
  .then(res => res.json())
  .then(json => console.log(json))
  .catch(err => console.error(err));
```

### Python

```python
import requests

url = "https://api.nicer.travel/search/places?q=string"

response = requests.get(url)

print(response.text)
```

## Responses

### 200

JSON, or SSE frames when the request accepts text/event-stream (the event schema describes each frame's JSON data).

#### Body (application/json)

- `items` (`search.places.list.response.200.items`; array of object, required)
  - `id` (`search.places.list.response.200.items.id`; string, required)
  - `kind` (`search.places.list.response.200.items.kind`; string, required)
    - one of `"hotel"`, `"city"`, `"airport"`, `"place"`
  - `source` (`search.places.list.response.200.items.source`; string, required)
  - `name` (`search.places.list.response.200.items.name`; string, required)
  - `photos` (`search.places.list.response.200.items.photos`; array of object, required)
    - `url` (`search.places.list.response.200.items.photos.url`; string, required)
    - `name` (`search.places.list.response.200.items.photos.name`; string, optional)
    - `key` (`search.places.list.response.200.items.photos.key`; string, optional)
  - `address` (`search.places.list.response.200.items.address`; string, optional)
  - `fullAddress` (`search.places.list.response.200.items.fullAddress`; string, optional)
  - `city` (`search.places.list.response.200.items.city`; string, optional)
  - `state` (`search.places.list.response.200.items.state`; string, optional)
  - `country` (`search.places.list.response.200.items.country`; string, optional)
  - `countryCode` (`search.places.list.response.200.items.countryCode`; string, optional)
  - `zipCode` (`search.places.list.response.200.items.zipCode`; string, optional)
  - `latitude` (`search.places.list.response.200.items.latitude`; number, optional)
  - `longitude` (`search.places.list.response.200.items.longitude`; number, optional)
  - `iataCode` (`search.places.list.response.200.items.iataCode`; string, optional)
  - `hotelReference` (`search.places.list.response.200.items.hotelReference`; string, optional)
  - `placeId` (`search.places.list.response.200.items.placeId`; string, optional)

##### Example

```json
{
  "items": [
    {
      "id": "string",
      "kind": "hotel",
      "source": "string",
      "name": "string",
      "address": "string",
      "fullAddress": "string",
      "city": "string",
      "state": "string",
      "country": "string",
      "countryCode": "string",
      "zipCode": "string",
      "latitude": 0,
      "longitude": 0,
      "iataCode": "string",
      "hotelReference": "string",
      "placeId": "string",
      "photos": [
        {
          "url": "string",
          "name": "string",
          "key": "string"
        }
      ]
    }
  ]
}
```

#### Body (text/event-stream)

Type: `string`

##### Example

```text
string
```

### 400

Request failed. `errorCode` is stable; `errorMessage` is for humans.

#### Example

```json
{
  "errorCode": "string",
  "errorMessage": "string"
}
```

- `errorCode` (`search.places.list.response.400.errorCode`; string, required)
- `errorMessage` (`search.places.list.response.400.errorMessage`; string, required)

### 401

Request failed. `errorCode` is stable; `errorMessage` is for humans.

#### Example

```json
{
  "errorCode": "string",
  "errorMessage": "string"
}
```

- `errorCode` (`search.places.list.response.401.errorCode`; string, required)
- `errorMessage` (`search.places.list.response.401.errorMessage`; string, required)

### 403

Request failed. `errorCode` is stable; `errorMessage` is for humans.

#### Example

```json
{
  "errorCode": "string",
  "errorMessage": "string"
}
```

- `errorCode` (`search.places.list.response.403.errorCode`; string, required)
- `errorMessage` (`search.places.list.response.403.errorMessage`; string, required)

### 429

Request failed. `errorCode` is stable; `errorMessage` is for humans.

#### Example

```json
{
  "errorCode": "string",
  "errorMessage": "string"
}
```

- `errorCode` (`search.places.list.response.429.errorCode`; string, required)
- `errorMessage` (`search.places.list.response.429.errorMessage`; string, required)


Source: https://docs.nicer.travel/api/Search/search.places.list/index.md
