Запрос

Для пользователей подсказок DaData.ru:

curl -X POST \
  -H "Content-Type: application/json" \
  -H "Accept: application/json" \
  -H "Authorization: Token ${API_KEY}" \
  -d '{ "query": "москва серпуховская" }' \
  https://suggestions.dadata.ru/suggestions/api/4_1/rs/suggest/fias

Для пользователей standalone-подсказок:

curl -X POST \
  -H "Content-Type: application/json" \
  -H "Accept: application/json" \
  -d '{ "query": "москва серпуховская" }' \
  http://ВАШ_СЕРВЕР:ПОРТ/suggestions/api/4_1/rs/suggest/fias

Параметры

ПараметрОбязательный?Описание
queryдаЗапрос, для которого нужно получить подсказки
count
нет
locations
нетОграничение области поиска
locations_boostнетПриоритет города при ранжировании

from_bound
to_bound

нетГранулярные подсказки по адресу

Ответ

Возвращается список объектов адреса:

Примеры

Запрос

{
  "query": "москва серпуховская" 
}

Ответ:

{
    "suggestions": [
        {
            "value": "г Москва, ул Серпуховская Б.",
            "unrestricted_value": "г Москва, ул Серпуховская Б.",
            "data": {
                "postal_code": null,
                "region_fias_id": "0c5b2444-70a0-4932-980c-b4dc0d3f02b5",
                "region_kladr_id": "7700000000000",
                "region_with_type": "г Москва",
                "region_type": "г",
                "region_type_full": "город",
                "region": "Москва",
                "area_fias_id": null,
                "area_kladr_id": null,
                "area_with_type": null,
                "area_type": null,
                "area_type_full": null,
                "area": null,
                "city_fias_id": null,
                "city_kladr_id": null,
                "city_with_type": null,
                "city_type": null,
                "city_type_full": null,
                "city": null,
                "city_district_fias_id": null,
                "city_district_kladr_id": null,
                "city_district_with_type": null,
                "city_district_type": null,
                "city_district_type_full": null,
                "city_district": null,
                "settlement_fias_id": null,
                "settlement_kladr_id": null,
                "settlement_with_type": null,
                "settlement_type": null,
                "settlement_type_full": null,
                "settlement": null,
                "planning_structure_fias_id": null,
                "planning_structure_kladr_id": null,
                "planning_structure_with_type": null,
                "planning_structure_type": null,
                "planning_structure_type_full": null,
                "planning_structure": null,
                "street_fias_id": "601875e2-717a-4c30-a3c4-1fb49e67d93f",
                "street_kladr_id": "77000000000262500",
                "street_with_type": "ул Серпуховская Б.",
                "street_type": "ул",
                "street_type_full": "улица",
                "street": "Серпуховская Б.",
                "house_fias_id": null,
                "house_kladr_id": null,
                "house_type": null,
                "house": null,
                "block": null,
                "building_type": null,
                "building": null,
                "fias_id": "601875e2-717a-4c30-a3c4-1fb49e67d93f",
                "fias_code": "7700000000000002625",
                "fias_level": "7",
                "fias_actuality_state": "0",
                "kladr_id": "77000000000262500",
                "capital_marker": "0",
                "okato": null,
                "oktmo": null,
                "cadastral_number": null,
                "tax_office": null,
                "tax_office_legal": null,
                "history_values": null,
                "source": null,
                "qc": null
            }
        },
        {
            "value": "г Москва, пл Серпуховская",
            "unrestricted_value": "115184, г Москва, пл Серпуховская",
            "data": {
                "postal_code": "115184",
                "region_fias_id": "0c5b2444-70a0-4932-980c-b4dc0d3f02b5",
                "region_kladr_id": "7700000000000",
                "region_with_type": "г Москва",
                "region_type": "г",
                "region_type_full": "город",
                "region": "Москва",
                "area_fias_id": null,
                "area_kladr_id": null,
                "area_with_type": null,
                "area_type": null,
                "area_type_full": null,
                "area": null,
                "city_fias_id": null,
                "city_kladr_id": null,
                "city_with_type": null,
                "city_type": null,
                "city_type_full": null,
                "city": null,
                "city_district_fias_id": null,
                "city_district_kladr_id": null,
                "city_district_with_type": null,
                "city_district_type": null,
                "city_district_type_full": null,
                "city_district": null,
                "settlement_fias_id": null,
                "settlement_kladr_id": null,
                "settlement_with_type": null,
                "settlement_type": null,
                "settlement_type_full": null,
                "settlement": null,
                "planning_structure_fias_id": null,
                "planning_structure_kladr_id": null,
                "planning_structure_with_type": null,
                "planning_structure_type": null,
                "planning_structure_type_full": null,
                "planning_structure": null,
                "street_fias_id": "6fe35e69-360a-4d75-8061-066a5c9e669c",
                "street_kladr_id": "77000000000702000",
                "street_with_type": "пл Серпуховская",
                "street_type": "пл",
                "street_type_full": "площадь",
                "street": "Серпуховская",
                "house_fias_id": null,
                "house_kladr_id": null,
                "house_type": null,
                "house": null,
                "block": null,
                "building_type": null,
                "building": null,
                "fias_id": "6fe35e69-360a-4d75-8061-066a5c9e669c",
                "fias_code": "7700000000000007020",
                "fias_level": "7",
                "fias_actuality_state": "0",
                "kladr_id": "77000000000702000",
                "capital_marker": "0",
                "okato": "45286560000",
                "oktmo": "45376000",
                "cadastral_number": null,
                "tax_office": "7705",
                "tax_office_legal": "7705",
                "history_values": [
                    "пл Добрынинская"
                ],
                "source": null,
                "qc": null
            }
        }
    ]
}