Azure Maps Search Service (preview:1.0)

2025/04/29 • 5 updated methods

Search_GetSearchAddressReverse (updated)
Description The `Get Search Address Reverse` API is and HTTP `GET` request that returns a street address or location when given latitude and longitude coordinates. There may be times when you need to translate a coordinate (example: 37.786505, -122.3862) into a human understandable street address. Most often this is needed in tracking applications where you receive a GPS feed from the device or asset and wish to know what address where the coordinate is located. This endpoint will return address information for a given coordinate.
Reference Link ¶

⚶ Changes

{
  "#id": "Search_GetSearchAddressReverse",
  "Description": {
    "new": "\n\nThe `Get Search Address Reverse` API is and HTTP `GET` request that returns a street address or location when given latitude and longitude coordinates.\n\nThere may be times when you need to translate a  coordinate (example: 37.786505, -122.3862) into a human understandable street address. Most often  this is needed in tracking applications where you  receive a GPS feed from the device or asset and  wish to know what address where the coordinate is  located. This endpoint will return address  information for a given coordinate.",
    "old": "The `Get Search Address Reverse` API is and HTTP `GET` request that returns a street address or location when given latitude and longitude coordinates.\n\nThere may be times when you need to translate a  coordinate (example: 37.786505, -122.3862) into a human understandable street address. Most often  this is needed in tracking applications where you  receive a GPS feed from the device or asset and  wish to know what address where the coordinate is  located. This endpoint will return address  information for a given coordinate."
  }
}

⚼ Request

GET:  /search/address/reverse/{format}
{
x-ms-client-id: string ,
api-version: string ,
format: string ,
query: array ,
language: string ,
returnSpeedLimit: boolean ,
heading: integer ,
radius: integer ,
number: string ,
returnRoadUse: boolean ,
roadUse: array ,
allowFreeformNewline: boolean ,
returnMatchType: boolean ,
entityType: string ,
view: string ,
}

⚐ Response (200)

{
summary:
{
query: string ,
queryType: enum ,
queryTime: integer ,
numResults: integer ,
limit: integer ,
offset: integer ,
totalResults: integer ,
fuzzyLevel: integer ,
geoBias:
{
lat: number ,
lon: number ,
}
,
}
,
addresses:
[
{
address:
{
buildingNumber: string ,
street: string ,
crossStreet: string ,
streetNumber: string ,
routeNumbers:
[
string ,
]
,
streetName: string ,
streetNameAndNumber: string ,
neighbourhood: string ,
municipality: string ,
municipalitySubdivision: string ,
countrySubdivision: string ,
countrySubdivisionCode: string ,
countryTertiarySubdivision: string ,
countrySecondarySubdivision: string ,
postalCode: string ,
extendedPostalCode: string ,
countryCode: string ,
country: string ,
countryCodeISO3: string ,
freeformAddress: string ,
countrySubdivisionName: string ,
localName: string ,
boundingBox:
{
northEast: string ,
southWest: string ,
entity: enum ,
}
,
}
,
position: string ,
roadUse:
[
string ,
]
,
matchType: enum ,
}
,
]
,
}

⚐ Response (default)

{
error:
{
code: string ,
message: string ,
target: string ,
details:
[
string ,
]
,
additionalInfo:
[
{
type: string ,
info: object ,
}
,
]
,
}
,
}
Search_PostSearchInsideGeometry (updated)
Description The `Post Search Inside Geometry` API is and HTTP `POST` request that allows you to perform a free form search inside a single geometry or multiple geometries. The search results that fall inside the geometry/geometries will be returned.

To send the geometry you will use a POST request where the request body will contain the `geometry` object represented as GeoJSON and the **Content-Type** header will be set to _application/json_. The geographical features to be searched can be modeled as Polygon and/or Circle geometries represented using any one of the following GeoJSON types:
  • **GeoJSON FeatureCollection**
    The `geometry` can be represented as a GeoJSON `FeatureCollection` object. This is the recommended option if the geometry contains both Polygons and Circles. The `FeatureCollection` can contain up to 50 GeoJSON `Feature` objects. Each `Feature` object should represent either a Polygon or a Circle with the following conditions:
    • A `Feature` object for the Polygon geometry can have up to 50 coordinates and it's properties must be empty.
    • A `Feature` object for the Circle geometry is composed of a _center_ represented using a GeoJSON `Point` type and a _radius_ value (in meters) which must be specified in the object's properties along with the _subType_ property whose value should be 'Circle'.

    See the [Examples](#examples) for a sample `FeatureCollection` representation.

  • **GeoJSON GeometryCollection**
    The `geometry` can be represented as a GeoJSON `GeometryCollection` object. This is the recommended option if the geometry contains a list of Polygons only. The `GeometryCollection` can contain up to 50 GeoJSON `Polygon` objects. Each `Polygon` object can have up to 50 coordinates. See the [Examples](#examples) for a sample `GeometryCollection` representation.

  • **GeoJSON Polygon**
    The `geometry` can be represented as a GeoJSON `Polygon` object. This is the recommended option if the geometry contains a single Polygon. The `Polygon` object can have up to 50 coordinates. See the [Examples](#examples) for a sample `Polygon` representation.

.

Reference Link ¶

⚶ Changes

{
  "#id": "Search_PostSearchInsideGeometry",
  "Description": {
    "new": "\n\nThe `Post Search Inside Geometry` API is and HTTP `POST` request that allows you to perform a free form search inside a single geometry or multiple geometries. The search results that fall inside the geometry/geometries will be returned.

To send the geometry you will use a POST request where the request body will contain the `geometry` object represented as GeoJSON and the **Content-Type** header will be set to _application/json_. The geographical features to be searched can be modeled as Polygon and/or Circle geometries represented using any one of the following GeoJSON types:
  • **GeoJSON FeatureCollection**
    The `geometry` can be represented as a GeoJSON `FeatureCollection` object. This is the recommended option if the geometry contains both Polygons and Circles. The `FeatureCollection` can contain up to 50 GeoJSON `Feature` objects. Each `Feature` object should represent either a Polygon or a Circle with the following conditions:
    • A `Feature` object for the Polygon geometry can have up to 50 coordinates and it's properties must be empty.
    • A `Feature` object for the Circle geometry is composed of a _center_ represented using a GeoJSON `Point` type and a _radius_ value (in meters) which must be specified in the object's properties along with the _subType_ property whose value should be 'Circle'.

    See the [Examples](#examples) for a sample `FeatureCollection` representation.

  • **GeoJSON GeometryCollection**
    The `geometry` can be represented as a GeoJSON `GeometryCollection` object. This is the recommended option if the geometry contains a list of Polygons only. The `GeometryCollection` can contain up to 50 GeoJSON `Polygon` objects. Each `Polygon` object can have up to 50 coordinates. See the [Examples](#examples) for a sample `GeometryCollection` representation.

  • **GeoJSON Polygon**
    The `geometry` can be represented as a GeoJSON `Polygon` object. This is the recommended option if the geometry contains a single Polygon. The `Polygon` object can have up to 50 coordinates. See the [Examples](#examples) for a sample `Polygon` representation.

.

", "old": "\n\nThe `Post Search Inside Geometry` API is and HTTP `POST request that allows you to perform a free form search inside a single geometry or multiple geometries. The search results that fall inside the geometry/geometries will be returned.

To send the geometry you will use a `POST` request where the request body will contain the `geometry` object represented as a `GeoJSON` type and the `Content-Type` header will be set to `application/json`. The geographical features to be searched can be modeled as Polygon and/or Circle geometries represented using any one of the following `GeoJSON` types:
  • **GeoJSON FeatureCollection**
    The `geometry` can be represented as a `GeoJSON FeatureCollection` object. This is the recommended option if the geometry contains both Polygons and Circles. The `FeatureCollection` can contain a max of 50 `GeoJSON Feature` objects. Each `Feature` object should represent either a Polygon or a Circle with the following conditions:
    • A `Feature` object for the Polygon geometry can have a max of 50 coordinates and it's properties must be empty.
    • A `Feature` object for the Circle geometry is composed of a _center_ represented using a `GeoJSON Point` type and a _radius_ value (in meters) which must be specified in the object's properties along with the _subType_ property whose value should be 'Circle'.

    Please see the Examples section below for a sample `FeatureCollection` representation.

  • **GeoJSON GeometryCollection**
    The `geometry` can be represented as a `GeoJSON GeometryCollection` object. This is the recommended option if the geometry contains a list of Polygons only. The `GeometryCollection` can contain a max of 50 `GeoJSON Polygon` objects. Each `Polygon` object can have a max of 50 coordinates. Please see the Examples section below for a sample `GeometryCollection` representation.

  • **GeoJSON Polygon**
    The `geometry` can be represented as a `GeoJSON Polygon` object. This is the recommended option if the geometry contains a single Polygon. The `Polygon` object can have a max of 50 coordinates. Please see the Examples section below for a sample `Polygon` representation.

.

" } }

⚼ Request

POST:  /search/geometry/{format}
{
x-ms-client-id: string ,
api-version: string ,
format: string ,
query: string ,
limit: integer ,
language: string ,
categorySet: array ,
extendedPostalCodesFor: array ,
idxSet: array ,
searchInsideGeometryRequestBody:
{
geometry:
{
type: enum ,
}
,
}
,
view: string ,
openingHours: string ,
}

⚐ Response (200)

{
summary:
{
query: string ,
queryType: enum ,
queryTime: integer ,
numResults: integer ,
limit: integer ,
offset: integer ,
totalResults: integer ,
fuzzyLevel: integer ,
geoBias:
{
lat: number ,
lon: number ,
}
,
}
,
results:
[
{
type: enum ,
id: string ,
score: number ,
dist: number ,
info: string ,
entityType: enum ,
poi:
{
name: string ,
phone: string ,
url: string ,
categorySet:
[
{
id: integer ,
}
,
]
,
categories:
[
string ,
]
,
classifications:
[
{
code: string ,
names:
[
{
nameLocale: string ,
name: string ,
}
,
]
,
}
,
]
,
brands:
[
{
name: string ,
}
,
]
,
openingHours:
{
mode: string ,
timeRanges:
[
{
startTime:
{
date: string ,
hour: integer ,
minute: integer ,
}
,
endTime:
{
date: string ,
hour: integer ,
minute: integer ,
}
,
}
,
]
,
}
,
}
,
address:
{
buildingNumber: string ,
street: string ,
crossStreet: string ,
streetNumber: string ,
routeNumbers:
[
string ,
]
,
streetName: string ,
streetNameAndNumber: string ,
neighbourhood: string ,
municipality: string ,
municipalitySubdivision: string ,
countrySubdivision: string ,
countrySubdivisionCode: string ,
countryTertiarySubdivision: string ,
countrySecondarySubdivision: string ,
postalCode: string ,
extendedPostalCode: string ,
countryCode: string ,
country: string ,
countryCodeISO3: string ,
freeformAddress: string ,
countrySubdivisionName: string ,
localName: string ,
boundingBox:
{
northEast: string ,
southWest: string ,
entity: enum ,
}
,
}
,
position:
{
lat: number ,
lon: number ,
}
,
viewport:
{
topLeftPoint:
{
lat: number ,
lon: number ,
}
,
btmRightPoint:
{
lat: number ,
lon: number ,
}
,
}
,
entryPoints:
[
{
type: enum ,
position:
{
lat: number ,
lon: number ,
}
,
}
,
]
,
addressRanges:
{
rangeLeft: string ,
rangeRight: string ,
from:
{
lat: number ,
lon: number ,
}
,
to:
{
lat: number ,
lon: number ,
}
,
}
,
dataSources:
{
geometry:
{
id: string ,
}
,
}
,
matchType: enum ,
detourTime: integer ,
}
,
]
,
}

⚐ Response (default)

{
error:
{
code: string ,
message: string ,
target: string ,
details:
[
string ,
]
,
additionalInfo:
[
{
type: string ,
info: object ,
}
,
]
,
}
,
}
Search_PostSearchFuzzyBatch (updated)
Description The `Post Search Fuzzy Batch` API is an HTTP `POST` request that sends batches of queries to [Search Fuzzy](/rest/api/maps/search/get-search-fuzzy?view=rest-maps-1.0) API in a single asynchronous call. You can call Search Fuzzy Batch API to run either asynchronously (async) or synchronously (sync). The async API allows caller to batch up to **10,000** queries and sync API up to **100** queries. ### Submit Synchronous Batch Request The Synchronous API is recommended for lightweight batch requests. When the service receives a request, it will respond as soon as the batch items are calculated and there will be no possibility to retrieve the results later. The Synchronous API will return a timeout error (a 408 response) if the request takes longer than 60 seconds. The number of batch items is limited to **100** for this API. ``` POST https://atlas.microsoft.com/search/fuzzy/batch/sync/json?api-version=1.0&subscription-key={subscription-key} ``` ### Submit Asynchronous Batch Request The Asynchronous API is appropriate for processing big volumes of relatively complex search requests - It allows the retrieval of results in a separate call (multiple downloads are possible). - The asynchronous API is optimized for reliability and is not expected to run into a timeout. - The number of batch items is limited to **10,000** for this API. When you make a request by using async request, by default the service returns a 202 response code along a redirect URL in the Location field of the response header. This URL should be checked periodically until the response data or error information is available. The asynchronous responses are stored for **14** days. The redirect URL returns a 404 response if used after the expiration period. Please note that asynchronous batch request is a long-running operation. Here's a typical sequence of operations: 1. Client sends a Search Fuzzy Batch `POST` request to Azure Maps. ``` POST https://atlas.microsoft.com/search/fuzzy/batch/json?api-version=1.0&subscription-key={subscription-key} ``` 2. The server will respond with one of the following: > HTTP `202 Accepted` - Batch request has been accepted. > HTTP `Error` - There was an error processing your Batch request. This could either be a `400 Bad Request` or any other `Error` status code. 3. If the batch request was accepted successfully, the `Location` header in the response contains the URL to download the results of the batch request. This status URI looks like following: ``` GET https://atlas.microsoft.com/search/fuzzy/batch/{batch-id}?api-version=1.0&subscription-key={subscription-key} ``` 4. Client issues a `GET` request on the _download URL_ obtained in Step 3 to download the batch results. ### POST Body for Batch Request To send the _search fuzzy_ queries you will use a `POST` request where the request body will contain the `batchItems` array in `json` format and the `Content-Type` header will be set to `application/json`. Here's a sample request body containing 5 _search fuzzy_ queries: ```json { "batchItems": [ {"query": "?query=atm&lat=47.639769&lon=-122.128362&radius=5000&limit=5"}, {"query": "?query=Statue Of Liberty&limit=2"}, {"query": "?query=Starbucks&lat=47.639769&lon=-122.128362&radius=5000"}, {"query": "?query=Space Needle"}, {"query": "?query=pizza&limit=10"} ] } ``` A _search fuzzy_ query in a batch is just a partial URL _without_ the protocol, base URL, path, api-version and subscription-key. It can accept any of the supported _search fuzzy_ [URI parameters](/rest/api/maps/search/get-search-fuzzy?view=rest-maps-1.0#uri-parameters). The string values in the _search fuzzy_ query must be properly escaped (e.g. " character should be escaped with \\ ) and it should also be properly URL-encoded. The async API allows caller to batch up to **10,000** queries and sync API up to **100** queries, and the batch should contain at least **1** query. ### Download Asynchronous Batch Results To download the async batch results you will issue a `GET` request to the batch download endpoint. This _download URL_ can be obtained from the `Location` header of a successful `POST` batch request and looks like the following: ``` https://atlas.microsoft.com/search/fuzzy/batch/{batch-id}?api-version=1.0&subscription-key={subscription-key} ``` Here's the typical sequence of operations for downloading the batch results: 1. Client sends a `GET` request using the _download URL_. 2. The server will respond with one of the following: > HTTP `202 Accepted` - Batch request was accepted but is still being processed. Please try again in some time. > HTTP `200 OK` - Batch request successfully processed. The response body contains all the batch results. ### Batch Response Model The returned data content is similar for async and sync requests. When downloading the results of an async batch request, if the batch has finished processing, the response body contains the batch response. This batch response contains a `summary` component that indicates the `totalRequests` that were part of the original batch request and `successfulRequests`i.e. queries which were executed successfully. The batch response also includes a `batchItems` array which contains a response for each and every query in the batch request. The `batchItems` will contain the results in the exact same order the original queries were sent in the batch request. Each item in `batchItems` contains `statusCode` and `response` fields. Each `response` in `batchItems` is of one of the following types: - [`SearchAddressResult`](/rest/api/maps/search/get-search-fuzzy?view=rest-maps-1.0#searchaddressresult) - If the query completed successfully. - `Error` - If the query failed. The response will contain a `code` and a `message` in this case. Here's a sample Batch Response with 2 _successful_ and 1 _failed_ result: ```json { "summary": { "successfulRequests": 2, "totalRequests": 3 }, "batchItems": [ { "statusCode": 200, "response": { "summary": { "query": "atm" }, "results": [ { "type": "POI", "poi": { "name": "ATM at Wells Fargo" }, "address": { "country": "United States Of America", "freeformAddress": "3240 157th Ave NE, Redmond, WA 98052" } } ] } }, { "statusCode": 200, "response": { "summary": { "query": "statue of liberty" }, "results": [ { "type": "POI", "poi": { "name": "Statue of Liberty" }, "address": { "country": "United States Of America", "freeformAddress": "New York, NY 10004" } } ] } }, { "statusCode": 400, "response": { "error": { "code": "400 BadRequest", "message": "Bad request: one or more parameters were incorrectly specified or are mutually exclusive." } } } ] } ```
Reference Link ¶

⚶ Changes

{
  "#id": "Search_PostSearchFuzzyBatch",
  "Description": {
    "new": "\n\nThe `Post Search Fuzzy Batch` API is an HTTP `POST` request that sends batches of queries to [Search Fuzzy](/rest/api/maps/search/get-search-fuzzy?view=rest-maps-1.0) API in a single asynchronous call. You can call Search Fuzzy Batch API to run either asynchronously (async) or synchronously (sync). The async API allows caller to batch up to **10,000** queries and sync API up to **100** queries.\n### Submit Synchronous Batch Request\nThe Synchronous API is recommended for lightweight batch requests. When the service receives a request, it will respond as soon as the batch items are calculated and there will be no possibility to retrieve the results later. The Synchronous API will return a timeout error (a 408 response) if the request takes longer than 60 seconds. The number of batch items is limited to **100** for this API.\n```\nPOST https://atlas.microsoft.com/search/fuzzy/batch/sync/json?api-version=1.0&subscription-key={subscription-key}\n```\n### Submit Asynchronous Batch Request\nThe Asynchronous API is appropriate for processing big volumes of relatively complex search requests\n- It allows the retrieval of results in a separate call (multiple downloads are possible).\n- The asynchronous API is optimized for reliability and is not expected to run into a timeout.\n- The number of batch items is limited to **10,000** for this API.\n\nWhen you make a request by using async request, by default the service returns a 202 response code along a redirect URL in the Location field of the response header. This URL should be checked periodically until the response data or error information is available.\nThe asynchronous responses are stored for **14** days. The redirect URL returns a 404 response if used after the expiration period.\n\nPlease note that asynchronous batch request is a long-running operation. Here's a typical sequence of operations:\n1. Client sends a Search Fuzzy Batch `POST` request to Azure Maps. \n\r```\nPOST https://atlas.microsoft.com/search/fuzzy/batch/json?api-version=1.0&subscription-key={subscription-key}\n```\n\n2. The server will respond with one of the following:\n\n    > HTTP `202 Accepted` - Batch request has been accepted.\n\n    > HTTP `Error` - There was an error processing your Batch request. This could either be a `400 Bad Request` or any other `Error` status code.\n\n3. If the batch request was accepted successfully, the `Location` header in the response contains the URL to download the results of the batch request.\n    This status URI looks like following:\n\n```\n    GET https://atlas.microsoft.com/search/fuzzy/batch/{batch-id}?api-version=1.0&subscription-key={subscription-key}\n```\n4. Client issues a `GET` request on the _download URL_ obtained in Step 3 to download the batch results.\n\n### POST Body for Batch Request\nTo send the _search fuzzy_ queries you will use a `POST` request where the request body will contain the `batchItems` array in `json` format and the `Content-Type` header will be set to `application/json`. Here's a sample request body containing 5 _search fuzzy_ queries:\n\n\n```json\n{\n    \"batchItems\": [\n        {\"query\": \"?query=atm&lat=47.639769&lon=-122.128362&radius=5000&limit=5\"},\n        {\"query\": \"?query=Statue Of Liberty&limit=2\"},\n        {\"query\": \"?query=Starbucks&lat=47.639769&lon=-122.128362&radius=5000\"},\n        {\"query\": \"?query=Space Needle\"},\n        {\"query\": \"?query=pizza&limit=10\"}\n    ]\n}\n```\n\nA _search fuzzy_ query in a batch is just a partial URL _without_ the protocol, base URL, path, api-version and subscription-key. It can accept any of the supported _search fuzzy_ [URI parameters](/rest/api/maps/search/get-search-fuzzy?view=rest-maps-1.0#uri-parameters). The string values in the _search fuzzy_ query must be properly escaped (e.g. \" character should be escaped with \\\\ ) and it should also be properly URL-encoded.\n\n\nThe async API allows caller to batch up to **10,000** queries and sync API up to **100** queries, and the batch should contain at least **1** query.\n\n\n### Download Asynchronous Batch Results\nTo download the async batch results you will issue a `GET` request to the batch download endpoint. This _download URL_ can be obtained from the `Location` header of a successful `POST` batch request and looks like the following:\n\n```\nhttps://atlas.microsoft.com/search/fuzzy/batch/{batch-id}?api-version=1.0&subscription-key={subscription-key}\n```\nHere's the typical sequence of operations for downloading the batch results:\n1. Client sends a `GET` request using the _download URL_.\n2. The server will respond with one of the following:\n\n    > HTTP `202 Accepted` - Batch request was accepted but is still being processed. Please try again in some time.\n\n    > HTTP `200 OK` - Batch request successfully processed. The response body contains all the batch results.\n\n\n\n### Batch Response Model\nThe returned data content is similar for async and sync requests. When downloading the results of an async batch request, if the batch has finished processing, the response body contains the batch response. This batch response contains a `summary` component that indicates the `totalRequests` that were part of the original batch request and `successfulRequests`i.e. queries which were executed successfully. The batch response also includes a `batchItems` array which contains a response for each and every query in the batch request. The `batchItems` will contain the results in the exact same order the original queries were sent in the batch request. Each item in `batchItems` contains `statusCode` and `response` fields. Each `response` in `batchItems` is of one of the following types:\n\n  - [`SearchAddressResult`](/rest/api/maps/search/get-search-fuzzy?view=rest-maps-1.0#searchaddressresult) - If the query completed successfully.\n\n  - `Error` - If the query failed. The response will contain a `code` and a `message` in this case.\n\n\nHere's a sample Batch Response with 2 _successful_ and 1 _failed_ result:\n\n\n```json\n{\n    \"summary\": {\n        \"successfulRequests\": 2,\n        \"totalRequests\": 3\n    },\n    \"batchItems\": [\n        {\n            \"statusCode\": 200,\n            \"response\":\n            {\n                \"summary\": {\n                    \"query\": \"atm\"\n                },\n                \"results\": [\n                    {\n                        \"type\": \"POI\",\n                        \"poi\": {\n                            \"name\": \"ATM at Wells Fargo\"\n                        },\n                        \"address\": {\n                            \"country\": \"United States Of America\",\n                            \"freeformAddress\": \"3240 157th Ave NE, Redmond, WA 98052\"\n                        }\n                    }\n                ]\n            }\n        },\n        {\n            \"statusCode\": 200,\n            \"response\":\n            {\n                \"summary\": {\n                    \"query\": \"statue of liberty\"\n                },\n                \"results\": [\n                    {\n                        \"type\": \"POI\",\n                        \"poi\": {\n                            \"name\": \"Statue of Liberty\"\n                        },\n                        \"address\": {\n                            \"country\": \"United States Of America\",\n                            \"freeformAddress\": \"New York, NY 10004\"\n                        }\n                    }\n                ]\n            }\n        },\n        {\n            \"statusCode\": 400,\n            \"response\":\n            {\n                \"error\":\n                {\n                    \"code\": \"400 BadRequest\",\n                    \"message\": \"Bad request: one or more parameters were incorrectly specified or are mutually exclusive.\"\n                }\n            }\n        }\n    ]\n}\n```",
    "old": "The `Post Search Fuzzy Batch` API is an HTTP `POST` request that sends batches of queries to [Search Fuzzy](/rest/api/maps/search/get-search-fuzzy?view=rest-maps-1.0) API in a single asynchronous call. You can call Search Fuzzy Batch API to run either asynchronously (async) or synchronously (sync). The async API allows caller to batch up to **10,000** queries and sync API up to **100** queries.\n### Submit Synchronous Batch Request\nThe Synchronous API is recommended for lightweight batch requests. When the service receives a request, it will respond as soon as the batch items are calculated and there will be no possibility to retrieve the results later. The Synchronous API will return a timeout error (a 408 response) if the request takes longer than 60 seconds. The number of batch items is limited to **100** for this API.\n```\nPOST https://atlas.microsoft.com/search/fuzzy/batch/sync/json?api-version=1.0&subscription-key={subscription-key}\n```\n### Submit Asynchronous Batch Request\nThe Asynchronous API is appropriate for processing big volumes of relatively complex search requests\n- It allows the retrieval of results in a separate call (multiple downloads are possible).\n- The asynchronous API is optimized for reliability and is not expected to run into a timeout.\n- The number of batch items is limited to **10,000** for this API.\n\nWhen you make a request by using async request, by default the service returns a 202 response code along a redirect URL in the Location field of the response header. This URL should be checked periodically until the response data or error information is available.\nThe asynchronous responses are stored for **14** days. The redirect URL returns a 404 response if used after the expiration period.\n\nPlease note that asynchronous batch request is a long-running operation. Here's a typical sequence of operations:\n1. Client sends a Search Fuzzy Batch `POST` request to Azure Maps. \n\r```\nPOST https://atlas.microsoft.com/search/fuzzy/batch/json?api-version=1.0&subscription-key={subscription-key}\n```\n\n2. The server will respond with one of the following:\n\n    > HTTP `202 Accepted` - Batch request has been accepted.\n\n    > HTTP `Error` - There was an error processing your Batch request. This could either be a `400 Bad Request` or any other `Error` status code.\n\n3. If the batch request was accepted successfully, the `Location` header in the response contains the URL to download the results of the batch request.\n    This status URI looks like following:\n\n```\n    GET https://atlas.microsoft.com/search/fuzzy/batch/{batch-id}?api-version=1.0&subscription-key={subscription-key}\n```\n4. Client issues a `GET` request on the _download URL_ obtained in Step 3 to download the batch results.\n\n### POST Body for Batch Request\nTo send the _search fuzzy_ queries you will use a `POST` request where the request body will contain the `batchItems` array in `json` format and the `Content-Type` header will be set to `application/json`. Here's a sample request body containing 5 _search fuzzy_ queries:\n\n\n```json\n{\n    \"batchItems\": [\n        {\"query\": \"?query=atm&lat=47.639769&lon=-122.128362&radius=5000&limit=5\"},\n        {\"query\": \"?query=Statue Of Liberty&limit=2\"},\n        {\"query\": \"?query=Starbucks&lat=47.639769&lon=-122.128362&radius=5000\"},\n        {\"query\": \"?query=Space Needle\"},\n        {\"query\": \"?query=pizza&limit=10\"}\n    ]\n}\n```\n\nA _search fuzzy_ query in a batch is just a partial URL _without_ the protocol, base URL, path, api-version and subscription-key. It can accept any of the supported _search fuzzy_ [URI parameters](/rest/api/maps/search/get-search-fuzzy?view=rest-maps-1.0#uri-parameters). The string values in the _search fuzzy_ query must be properly escaped (e.g. \" character should be escaped with \\\\ ) and it should also be properly URL-encoded.\n\n\nThe async API allows caller to batch up to **10,000** queries and sync API up to **100** queries, and the batch should contain at least **1** query.\n\n\n### Download Asynchronous Batch Results\nTo download the async batch results you will issue a `GET` request to the batch download endpoint. This _download URL_ can be obtained from the `Location` header of a successful `POST` batch request and looks like the following:\n\n```\nhttps://atlas.microsoft.com/search/fuzzy/batch/{batch-id}?api-version=1.0&subscription-key={subscription-key}\n```\nHere's the typical sequence of operations for downloading the batch results:\n1. Client sends a `GET` request using the _download URL_.\n2. The server will respond with one of the following:\n\n    > HTTP `202 Accepted` - Batch request was accepted but is still being processed. Please try again in some time.\n\n    > HTTP `200 OK` - Batch request successfully processed. The response body contains all the batch results.\n\n\n\n### Batch Response Model\nThe returned data content is similar for async and sync requests. When downloading the results of an async batch request, if the batch has finished processing, the response body contains the batch response. This batch response contains a `summary` component that indicates the `totalRequests` that were part of the original batch request and `successfulRequests`i.e. queries which were executed successfully. The batch response also includes a `batchItems` array which contains a response for each and every query in the batch request. The `batchItems` will contain the results in the exact same order the original queries were sent in the batch request. Each item in `batchItems` contains `statusCode` and `response` fields. Each `response` in `batchItems` is of one of the following types:\n\n  - [`SearchAddressResult`](/rest/api/maps/search/get-search-fuzzy?view=rest-maps-1.0#searchaddressresult) - If the query completed successfully.\n\n  - `Error` - If the query failed. The response will contain a `code` and a `message` in this case.\n\n\nHere's a sample Batch Response with 2 _successful_ and 1 _failed_ result:\n\n\n```json\n{\n    \"summary\": {\n        \"successfulRequests\": 2,\n        \"totalRequests\": 3\n    },\n    \"batchItems\": [\n        {\n            \"statusCode\": 200,\n            \"response\":\n            {\n                \"summary\": {\n                    \"query\": \"atm\"\n                },\n                \"results\": [\n                    {\n                        \"type\": \"POI\",\n                        \"poi\": {\n                            \"name\": \"ATM at Wells Fargo\"\n                        },\n                        \"address\": {\n                            \"country\": \"United States Of America\",\n                            \"freeformAddress\": \"3240 157th Ave NE, Redmond, WA 98052\"\n                        }\n                    }\n                ]\n            }\n        },\n        {\n            \"statusCode\": 200,\n            \"response\":\n            {\n                \"summary\": {\n                    \"query\": \"statue of liberty\"\n                },\n                \"results\": [\n                    {\n                        \"type\": \"POI\",\n                        \"poi\": {\n                            \"name\": \"Statue of Liberty\"\n                        },\n                        \"address\": {\n                            \"country\": \"United States Of America\",\n                            \"freeformAddress\": \"New York, NY 10004\"\n                        }\n                    }\n                ]\n            }\n        },\n        {\n            \"statusCode\": 400,\n            \"response\":\n            {\n                \"error\":\n                {\n                    \"code\": \"400 BadRequest\",\n                    \"message\": \"Bad request: one or more parameters were incorrectly specified or are mutually exclusive.\"\n                }\n            }\n        }\n    ]\n}\n```"
  }
}

⚼ Request

POST:  /search/fuzzy/batch/{format}
{
x-ms-client-id: string ,
api-version: string ,
format: string ,
searchFuzzyBatchRequestBody:
{
batchItems:
[
{
query: string ,
}
,
]
,
}
,
}

⚐ Response (200)

{
batchItems:
[
{
response: object ,
}
,
]
,
}

⚐ Response (202)

{
location: string ,
}

⚐ Response (default)

{
error:
{
code: string ,
message: string ,
target: string ,
details:
[
string ,
]
,
additionalInfo:
[
{
type: string ,
info: object ,
}
,
]
,
}
,
}
Search_GetSearchFuzzyBatch (updated)
Description The `Get Search Fuzzy Batch` API is and HTTP `GET` request that sends batches of queries to [Search Fuzzy](/rest/api/maps/search/get-search-fuzzy?view=rest-maps-1.0) API in a single asynchronous API call. You can call Search Fuzzy Batch API to run either asynchronously (async) or synchronously (sync). The async API allows caller to batch up to **10,000** queries and sync API up to **100** queries. ### Submit Synchronous Batch Request The Synchronous API is recommended for lightweight batch requests. When the service receives a request, it will respond as soon as the batch items are calculated and there will be no possibility to retrieve the results later. The Synchronous API will return a timeout error (a 408 response) if the request takes longer than 60 seconds. The number of batch items is limited to **100** for this API. ``` POST https://atlas.microsoft.com/search/fuzzy/batch/sync/json?api-version=1.0&subscription-key={subscription-key} ``` ### Submit Asynchronous Batch Request The Asynchronous API is appropriate for processing big volumes of relatively complex search requests - It allows the retrieval of results in a separate call (multiple downloads are possible). - The asynchronous API is optimized for reliability and is not expected to run into a timeout. - The number of batch items is limited to **10,000** for this API. When you make a request by using async request, by default the service returns a 202 response code along a redirect URL in the Location field of the response header. This URL should be checked periodically until the response data or error information is available. The asynchronous responses are stored for **14** days. The redirect URL returns a 404 response if used after the expiration period. Please note that asynchronous batch request is a long-running operation. Here's a typical sequence of operations: 1. Client sends a Search Fuzzy Batch `POST` request to Azure Maps. ``` POST https://atlas.microsoft.com/search/fuzzy/batch/json?api-version=1.0&subscription-key={subscription-key} ``` 2. The server will respond with one of the following: > HTTP `202 Accepted` - Batch request has been accepted. > HTTP `Error` - There was an error processing your Batch request. This could either be a `400 Bad Request` or any other `Error` status code. 3. If the batch request was accepted successfully, the `Location` header in the response contains the URL to download the results of the batch request. This status URI looks like following: ``` GET https://atlas.microsoft.com/search/fuzzy/batch/{batch-id}?api-version=1.0&subscription-key={subscription-key} ``` 4. Client issues a `GET` request on the _download URL_ obtained in Step 3 to download the batch results. ### POST Body for Batch Request To send the _search fuzzy_ queries you will use a `POST` request where the request body will contain the `batchItems` array in `json` format and the `Content-Type` header will be set to `application/json`. Here's a sample request body containing 5 _search fuzzy_ queries: ```json { "batchItems": [ {"query": "?query=atm&lat=47.639769&lon=-122.128362&radius=5000&limit=5"}, {"query": "?query=Statue Of Liberty&limit=2"}, {"query": "?query=Starbucks&lat=47.639769&lon=-122.128362&radius=5000"}, {"query": "?query=Space Needle"}, {"query": "?query=pizza&limit=10"} ] } ``` A _search fuzzy_ query in a batch is just a partial URL _without_ the protocol, base URL, path, api-version and subscription-key. It can accept any of the supported _search fuzzy_ [URI parameters](/rest/api/maps/search/get-search-fuzzy?view=rest-maps-1.0#uri-parameters). The string values in the _search fuzzy_ query must be properly escaped (e.g. " character should be escaped with \\ ) and it should also be properly URL-encoded. The async API allows caller to batch up to **10,000** queries and sync API up to **100** queries, and the batch should contain at least **1** query. ### Download Asynchronous Batch Results To download the async batch results you will issue a `GET` request to the batch download endpoint. This _download URL_ can be obtained from the `Location` header of a successful `POST` batch request and looks like the following: ``` https://atlas.microsoft.com/search/fuzzy/batch/{batch-id}?api-version=1.0&subscription-key={subscription-key} ``` Here's the typical sequence of operations for downloading the batch results: 1. Client sends a `GET` request using the _download URL_. 2. The server will respond with one of the following: > HTTP `202 Accepted` - Batch request was accepted but is still being processed. Please try again in some time. > HTTP `200 OK` - Batch request successfully processed. The response body contains all the batch results. ### Batch Response Model The returned data content is similar for async and sync requests. When downloading the results of an async batch request, if the batch has finished processing, the response body contains the batch response. This batch response contains a `summary` component that indicates the `totalRequests` that were part of the original batch request and `successfulRequests`i.e. queries which were executed successfully. The batch response also includes a `batchItems` array which contains a response for each and every query in the batch request. The `batchItems` will contain the results in the exact same order the original queries were sent in the batch request. Each item in `batchItems` contains `statusCode` and `response` fields. Each `response` in `batchItems` is of one of the following types: - [`SearchAddressResult`](/rest/api/maps/search/get-search-fuzzy?view=rest-maps-1.0#searchaddressresult) - If the query completed successfully. - `Error` - If the query failed. The response will contain a `code` and a `message` in this case. Here's a sample Batch Response with 2 _successful_ and 1 _failed_ result: ```json { "summary": { "successfulRequests": 2, "totalRequests": 3 }, "batchItems": [ { "statusCode": 200, "response": { "summary": { "query": "atm" }, "results": [ { "type": "POI", "poi": { "name": "ATM at Wells Fargo" }, "address": { "country": "United States Of America", "freeformAddress": "3240 157th Ave NE, Redmond, WA 98052" } } ] } }, { "statusCode": 200, "response": { "summary": { "query": "statue of liberty" }, "results": [ { "type": "POI", "poi": { "name": "Statue of Liberty" }, "address": { "country": "United States Of America", "freeformAddress": "New York, NY 10004" } } ] } }, { "statusCode": 400, "response": { "error": { "code": "400 BadRequest", "message": "Bad request: one or more parameters were incorrectly specified or are mutually exclusive." } } } ] } ```
Reference Link ¶

⚶ Changes

{
  "#id": "Search_GetSearchFuzzyBatch",
  "Description": {
    "new": "\n\nThe `Get Search Fuzzy Batch` API is and HTTP `GET` request that sends batches of queries to [Search Fuzzy](/rest/api/maps/search/get-search-fuzzy?view=rest-maps-1.0) API in a single asynchronous API call. You can call Search Fuzzy Batch API to run either asynchronously (async) or synchronously (sync). The async API allows caller to batch up to **10,000** queries and sync API up to **100** queries.\n### Submit Synchronous Batch Request\nThe Synchronous API is recommended for lightweight batch requests. When the service receives a request, it will respond as soon as the batch items are calculated and there will be no possibility to retrieve the results later. The Synchronous API will return a timeout error (a 408 response) if the request takes longer than 60 seconds. The number of batch items is limited to **100** for this API.\n```\nPOST https://atlas.microsoft.com/search/fuzzy/batch/sync/json?api-version=1.0&subscription-key={subscription-key}\n```\n### Submit Asynchronous Batch Request\nThe Asynchronous API is appropriate for processing big volumes of relatively complex search requests\n- It allows the retrieval of results in a separate call (multiple downloads are possible).\n- The asynchronous API is optimized for reliability and is not expected to run into a timeout.\n- The number of batch items is limited to **10,000** for this API.\n\nWhen you make a request by using async request, by default the service returns a 202 response code along a redirect URL in the Location field of the response header. This URL should be checked periodically until the response data or error information is available.\nThe asynchronous responses are stored for **14** days. The redirect URL returns a 404 response if used after the expiration period.\n\nPlease note that asynchronous batch request is a long-running operation. Here's a typical sequence of operations:\n1. Client sends a Search Fuzzy Batch `POST` request to Azure Maps. \n\r```\nPOST https://atlas.microsoft.com/search/fuzzy/batch/json?api-version=1.0&subscription-key={subscription-key}\n```\n\n2. The server will respond with one of the following:\n\n    > HTTP `202 Accepted` - Batch request has been accepted.\n\n    > HTTP `Error` - There was an error processing your Batch request. This could either be a `400 Bad Request` or any other `Error` status code.\n\n3. If the batch request was accepted successfully, the `Location` header in the response contains the URL to download the results of the batch request.\n    This status URI looks like following:\n\n```\n    GET https://atlas.microsoft.com/search/fuzzy/batch/{batch-id}?api-version=1.0&subscription-key={subscription-key}\n```\n4. Client issues a `GET` request on the _download URL_ obtained in Step 3 to download the batch results.\n\n### POST Body for Batch Request\nTo send the _search fuzzy_ queries you will use a `POST` request where the request body will contain the `batchItems` array in `json` format and the `Content-Type` header will be set to `application/json`. Here's a sample request body containing 5 _search fuzzy_ queries:\n\n\n```json\n{\n    \"batchItems\": [\n        {\"query\": \"?query=atm&lat=47.639769&lon=-122.128362&radius=5000&limit=5\"},\n        {\"query\": \"?query=Statue Of Liberty&limit=2\"},\n        {\"query\": \"?query=Starbucks&lat=47.639769&lon=-122.128362&radius=5000\"},\n        {\"query\": \"?query=Space Needle\"},\n        {\"query\": \"?query=pizza&limit=10\"}\n    ]\n}\n```\n\nA _search fuzzy_ query in a batch is just a partial URL _without_ the protocol, base URL, path, api-version and subscription-key. It can accept any of the supported _search fuzzy_ [URI parameters](/rest/api/maps/search/get-search-fuzzy?view=rest-maps-1.0#uri-parameters). The string values in the _search fuzzy_ query must be properly escaped (e.g. \" character should be escaped with \\\\ ) and it should also be properly URL-encoded.\n\n\nThe async API allows caller to batch up to **10,000** queries and sync API up to **100** queries, and the batch should contain at least **1** query.\n\n\n### Download Asynchronous Batch Results\nTo download the async batch results you will issue a `GET` request to the batch download endpoint. This _download URL_ can be obtained from the `Location` header of a successful `POST` batch request and looks like the following:\n\n```\nhttps://atlas.microsoft.com/search/fuzzy/batch/{batch-id}?api-version=1.0&subscription-key={subscription-key}\n```\nHere's the typical sequence of operations for downloading the batch results:\n1. Client sends a `GET` request using the _download URL_.\n2. The server will respond with one of the following:\n\n    > HTTP `202 Accepted` - Batch request was accepted but is still being processed. Please try again in some time.\n\n    > HTTP `200 OK` - Batch request successfully processed. The response body contains all the batch results.\n\n\n\n### Batch Response Model\nThe returned data content is similar for async and sync requests. When downloading the results of an async batch request, if the batch has finished processing, the response body contains the batch response. This batch response contains a `summary` component that indicates the `totalRequests` that were part of the original batch request and `successfulRequests`i.e. queries which were executed successfully. The batch response also includes a `batchItems` array which contains a response for each and every query in the batch request. The `batchItems` will contain the results in the exact same order the original queries were sent in the batch request. Each item in `batchItems` contains `statusCode` and `response` fields. Each `response` in `batchItems` is of one of the following types:\n\n  - [`SearchAddressResult`](/rest/api/maps/search/get-search-fuzzy?view=rest-maps-1.0#searchaddressresult) - If the query completed successfully.\n\n  - `Error` - If the query failed. The response will contain a `code` and a `message` in this case.\n\n\nHere's a sample Batch Response with 2 _successful_ and 1 _failed_ result:\n\n\n```json\n{\n    \"summary\": {\n        \"successfulRequests\": 2,\n        \"totalRequests\": 3\n    },\n    \"batchItems\": [\n        {\n            \"statusCode\": 200,\n            \"response\":\n            {\n                \"summary\": {\n                    \"query\": \"atm\"\n                },\n                \"results\": [\n                    {\n                        \"type\": \"POI\",\n                        \"poi\": {\n                            \"name\": \"ATM at Wells Fargo\"\n                        },\n                        \"address\": {\n                            \"country\": \"United States Of America\",\n                            \"freeformAddress\": \"3240 157th Ave NE, Redmond, WA 98052\"\n                        }\n                    }\n                ]\n            }\n        },\n        {\n            \"statusCode\": 200,\n            \"response\":\n            {\n                \"summary\": {\n                    \"query\": \"statue of liberty\"\n                },\n                \"results\": [\n                    {\n                        \"type\": \"POI\",\n                        \"poi\": {\n                            \"name\": \"Statue of Liberty\"\n                        },\n                        \"address\": {\n                            \"country\": \"United States Of America\",\n                            \"freeformAddress\": \"New York, NY 10004\"\n                        }\n                    }\n                ]\n            }\n        },\n        {\n            \"statusCode\": 400,\n            \"response\":\n            {\n                \"error\":\n                {\n                    \"code\": \"400 BadRequest\",\n                    \"message\": \"Bad request: one or more parameters were incorrectly specified or are mutually exclusive.\"\n                }\n            }\n        }\n    ]\n}\n```",
    "old": "The `Get Search Fuzzy Batch` API is and HTTP `GET` request that sends batches of queries to [Search Fuzzy](/rest/api/maps/search/get-search-fuzzy?view=rest-maps-1.0) API in a single asynchronous API call. You can call Search Fuzzy Batch API to run either asynchronously (async) or synchronously (sync). The async API allows caller to batch up to **10,000** queries and sync API up to **100** queries.\n### Submit Synchronous Batch Request\nThe Synchronous API is recommended for lightweight batch requests. When the service receives a request, it will respond as soon as the batch items are calculated and there will be no possibility to retrieve the results later. The Synchronous API will return a timeout error (a 408 response) if the request takes longer than 60 seconds. The number of batch items is limited to **100** for this API.\n```\nPOST https://atlas.microsoft.com/search/fuzzy/batch/sync/json?api-version=1.0&subscription-key={subscription-key}\n```\n### Submit Asynchronous Batch Request\nThe Asynchronous API is appropriate for processing big volumes of relatively complex search requests\n- It allows the retrieval of results in a separate call (multiple downloads are possible).\n- The asynchronous API is optimized for reliability and is not expected to run into a timeout.\n- The number of batch items is limited to **10,000** for this API.\n\nWhen you make a request by using async request, by default the service returns a 202 response code along a redirect URL in the Location field of the response header. This URL should be checked periodically until the response data or error information is available.\nThe asynchronous responses are stored for **14** days. The redirect URL returns a 404 response if used after the expiration period.\n\nPlease note that asynchronous batch request is a long-running operation. Here's a typical sequence of operations:\n1. Client sends a Search Fuzzy Batch `POST` request to Azure Maps. \n\r```\nPOST https://atlas.microsoft.com/search/fuzzy/batch/json?api-version=1.0&subscription-key={subscription-key}\n```\n\n2. The server will respond with one of the following:\n\n    > HTTP `202 Accepted` - Batch request has been accepted.\n\n    > HTTP `Error` - There was an error processing your Batch request. This could either be a `400 Bad Request` or any other `Error` status code.\n\n3. If the batch request was accepted successfully, the `Location` header in the response contains the URL to download the results of the batch request.\n    This status URI looks like following:\n\n```\n    GET https://atlas.microsoft.com/search/fuzzy/batch/{batch-id}?api-version=1.0&subscription-key={subscription-key}\n```\n4. Client issues a `GET` request on the _download URL_ obtained in Step 3 to download the batch results.\n\n### POST Body for Batch Request\nTo send the _search fuzzy_ queries you will use a `POST` request where the request body will contain the `batchItems` array in `json` format and the `Content-Type` header will be set to `application/json`. Here's a sample request body containing 5 _search fuzzy_ queries:\n\n\n```json\n{\n    \"batchItems\": [\n        {\"query\": \"?query=atm&lat=47.639769&lon=-122.128362&radius=5000&limit=5\"},\n        {\"query\": \"?query=Statue Of Liberty&limit=2\"},\n        {\"query\": \"?query=Starbucks&lat=47.639769&lon=-122.128362&radius=5000\"},\n        {\"query\": \"?query=Space Needle\"},\n        {\"query\": \"?query=pizza&limit=10\"}\n    ]\n}\n```\n\nA _search fuzzy_ query in a batch is just a partial URL _without_ the protocol, base URL, path, api-version and subscription-key. It can accept any of the supported _search fuzzy_ [URI parameters](/rest/api/maps/search/get-search-fuzzy?view=rest-maps-1.0#uri-parameters). The string values in the _search fuzzy_ query must be properly escaped (e.g. \" character should be escaped with \\\\ ) and it should also be properly URL-encoded.\n\n\nThe async API allows caller to batch up to **10,000** queries and sync API up to **100** queries, and the batch should contain at least **1** query.\n\n\n### Download Asynchronous Batch Results\nTo download the async batch results you will issue a `GET` request to the batch download endpoint. This _download URL_ can be obtained from the `Location` header of a successful `POST` batch request and looks like the following:\n\n```\nhttps://atlas.microsoft.com/search/fuzzy/batch/{batch-id}?api-version=1.0&subscription-key={subscription-key}\n```\nHere's the typical sequence of operations for downloading the batch results:\n1. Client sends a `GET` request using the _download URL_.\n2. The server will respond with one of the following:\n\n    > HTTP `202 Accepted` - Batch request was accepted but is still being processed. Please try again in some time.\n\n    > HTTP `200 OK` - Batch request successfully processed. The response body contains all the batch results.\n\n\n\n### Batch Response Model\nThe returned data content is similar for async and sync requests. When downloading the results of an async batch request, if the batch has finished processing, the response body contains the batch response. This batch response contains a `summary` component that indicates the `totalRequests` that were part of the original batch request and `successfulRequests`i.e. queries which were executed successfully. The batch response also includes a `batchItems` array which contains a response for each and every query in the batch request. The `batchItems` will contain the results in the exact same order the original queries were sent in the batch request. Each item in `batchItems` contains `statusCode` and `response` fields. Each `response` in `batchItems` is of one of the following types:\n\n  - [`SearchAddressResult`](/rest/api/maps/search/get-search-fuzzy?view=rest-maps-1.0#searchaddressresult) - If the query completed successfully.\n\n  - `Error` - If the query failed. The response will contain a `code` and a `message` in this case.\n\n\nHere's a sample Batch Response with 2 _successful_ and 1 _failed_ result:\n\n\n```json\n{\n    \"summary\": {\n        \"successfulRequests\": 2,\n        \"totalRequests\": 3\n    },\n    \"batchItems\": [\n        {\n            \"statusCode\": 200,\n            \"response\":\n            {\n                \"summary\": {\n                    \"query\": \"atm\"\n                },\n                \"results\": [\n                    {\n                        \"type\": \"POI\",\n                        \"poi\": {\n                            \"name\": \"ATM at Wells Fargo\"\n                        },\n                        \"address\": {\n                            \"country\": \"United States Of America\",\n                            \"freeformAddress\": \"3240 157th Ave NE, Redmond, WA 98052\"\n                        }\n                    }\n                ]\n            }\n        },\n        {\n            \"statusCode\": 200,\n            \"response\":\n            {\n                \"summary\": {\n                    \"query\": \"statue of liberty\"\n                },\n                \"results\": [\n                    {\n                        \"type\": \"POI\",\n                        \"poi\": {\n                            \"name\": \"Statue of Liberty\"\n                        },\n                        \"address\": {\n                            \"country\": \"United States Of America\",\n                            \"freeformAddress\": \"New York, NY 10004\"\n                        }\n                    }\n                ]\n            }\n        },\n        {\n            \"statusCode\": 400,\n            \"response\":\n            {\n                \"error\":\n                {\n                    \"code\": \"400 BadRequest\",\n                    \"message\": \"Bad request: one or more parameters were incorrectly specified or are mutually exclusive.\"\n                }\n            }\n        }\n    ]\n}\n```"
  }
}

⚼ Request

GET:  /search/fuzzy/batch/{format}
{
x-ms-client-id: string ,
api-version: string ,
format: string ,
}

⚐ Response (200)

{
batchItems:
[
{
response: object ,
}
,
]
,
}

⚐ Response (202)

{
location: string ,
}

⚐ Response (default)

{
error:
{
code: string ,
message: string ,
target: string ,
details:
[
string ,
]
,
additionalInfo:
[
{
type: string ,
info: object ,
}
,
]
,
}
,
}
Search_GetSearchAddressBatch (updated)
Description The `Get Search Address Batch` API is an HTTP `GET` request that sends batches of queries to [Search Address](/rest/api/maps/search/get-search-address?view=rest-maps-1.0) API in a single asynchronous API call. You can call Search Address Batch API to run either asynchronously (async) or synchronously (sync). The async API allows caller to batch up to **10,000** queries and sync API up to **100** queries. ### Submit Synchronous Batch Request The Synchronous API is recommended for lightweight batch requests. When the service receives a request, it will respond as soon as the batch items are calculated and there will be no possibility to retrieve the results later. The Synchronous API will return a timeout error (a 408 response) if the request takes longer than 60 seconds. The number of batch items is limited to **100** for this API. ``` POST https://atlas.microsoft.com/search/address/batch/sync/json?api-version=1.0&subscription-key={subscription-key} ``` ### Submit Asynchronous Batch Request The Asynchronous API is appropriate for processing big volumes of relatively complex search requests - It allows the retrieval of results in a separate call (multiple downloads are possible). - The asynchronous API is optimized for reliability and is not expected to run into a timeout. - The number of batch items is limited to **10,000** for this API. When you make a request by using async request, by default the service returns a 202 response code along a redirect URL in the Location field of the response header. This URL should be checked periodically until the response data or error information is available. The asynchronous responses are stored for **14** days. The redirect URL returns a 404 response if used after the expiration period. Please note that asynchronous batch request is a long-running operation. Here's a typical sequence of operations: 1. Client sends a Search Address Batch `POST` request to Azure Maps. ``` POST https://atlas.microsoft.com/search/address/batch/json?api-version=1.0&subscription-key={subscription-key} ``` 2. The server will respond with one of the following: > HTTP `202 Accepted` - Batch request has been accepted. > HTTP `Error` - There was an error processing your Batch request. This could either be a `400 Bad Request` or any other `Error` status code. 3. If the batch request was accepted successfully, the `Location` header in the response contains the URL to download the results of the batch request. This status URI looks like following: ``` GET https://atlas.microsoft.com/search/address/batch/{batch-id}?api-version=1.0&subscription-key={subscription-key} ``` 4. Client issues a `GET` request on the _download URL_ obtained in Step 3 to download the batch results. ### POST Body for Batch Request To send the _search address_ queries you will use a `POST` request where the request body will contain the `batchItems` array in `json` format and the `Content-Type` header will be set to `application/json`. Here's a sample request body containing 5 _search address_ queries: ```json { "batchItems": [ {"query": "?query=400 Broad St, Seattle, WA 98109&limit=3"}, {"query": "?query=One, Microsoft Way, Redmond, WA 98052&limit=3"}, {"query": "?query=350 5th Ave, New York, NY 10118&limit=1"}, {"query": "?query=Pike Pl, Seattle, WA 98101&lat=47.610970&lon=-122.342469&radius=1000"}, {"query": "?query=Champ de Mars, 5 Avenue Anatole France, 75007 Paris, France&limit=1"} ] } ``` A _search address_ query in a batch is just a partial URL _without_ the protocol, base URL, path, api-version and subscription-key. It can accept any of the supported _search address_ [URI parameters](/rest/api/maps/search/get-search-address?view=rest-maps-1.0#uri-parameters). The string values in the _search address_ query must be properly escaped (e.g. " character should be escaped with \\ ) and it should also be properly URL-encoded. The async API allows caller to batch up to **10,000** queries and sync API up to **100** queries, and the batch should contain at least **1** query. ### Download Asynchronous Batch Results To download the async batch results you will issue a `GET` request to the batch download endpoint. This _download URL_ can be obtained from the `Location` header of a successful `POST` batch request and looks like the following: ``` https://atlas.microsoft.com/search/address/batch/{batch-id}?api-version=1.0&subscription-key={subscription-key} ``` Here's the typical sequence of operations for downloading the batch results: 1. Client sends a `GET` request using the _download URL_. 2. The server will respond with one of the following: > HTTP `202 Accepted` - Batch request was accepted but is still being processed. Please try again in some time. > HTTP `200 OK` - Batch request successfully processed. The response body contains all the batch results. ### Batch Response Model The returned data content is similar for async and sync requests. When downloading the results of an async batch request, if the batch has finished processing, the response body contains the batch response. This batch response contains a `summary` component that indicates the `totalRequests` that were part of the original batch request and `successfulRequests`i.e. queries which were executed successfully. The batch response also includes a `batchItems` array which contains a response for each and every query in the batch request. The `batchItems` will contain the results in the exact same order the original queries were sent in the batch request. Each item in `batchItems` contains `statusCode` and `response` fields. Each `response` in `batchItems` is of one of the following types: - [`SearchAddressResult`](/rest/api/maps/search/get-search-address?view=rest-maps-1.0#SearchAddressResult) - If the query completed successfully. - `Error` - If the query failed. The response will contain a `code` and a `message` in this case. Here's a sample Batch Response with 2 _successful_ and 1 _failed_ result: ```json { "summary": { "successfulRequests": 2, "totalRequests": 3 }, "batchItems": [ { "statusCode": 200, "response": { "summary": { "query": "one microsoft way redmond wa 98052" }, "results": [ { "position": { "lat": 47.63989, "lon": -122.12509 } } ] } }, { "statusCode": 200, "response": { "summary": { "query": "pike pl seattle wa 98101" }, "results": [ { "position": { "lat": 47.60963, "lon": -122.34215 } } ] } }, { "statusCode": 400, "response": { "error": { "code": "400 BadRequest", "message": "Bad request: one or more parameters were incorrectly specified or are mutually exclusive." } } } ] } ```
Reference Link ¶

⚶ Changes

{
  "#id": "Search_GetSearchAddressBatch",
  "Description": {
    "new": "\n\nThe `Get Search Address Batch` API is an HTTP `GET` request that sends batches of queries to [Search Address](/rest/api/maps/search/get-search-address?view=rest-maps-1.0) API in a single asynchronous API call. You can call Search Address Batch API to run either asynchronously (async) or synchronously (sync). The async API allows caller to batch up to **10,000** queries and sync API up to **100** queries.\n### Submit Synchronous Batch Request\nThe Synchronous API is recommended for lightweight batch requests. When the service receives a request, it will respond as soon as the batch items are calculated and there will be no possibility to retrieve the results later. The Synchronous API will return a timeout error (a 408 response) if the request takes longer than 60 seconds. The number of batch items is limited to **100** for this API.\n```\nPOST https://atlas.microsoft.com/search/address/batch/sync/json?api-version=1.0&subscription-key={subscription-key}\n```\n### Submit Asynchronous Batch Request\nThe Asynchronous API is appropriate for processing big volumes of relatively complex search requests\n- It allows the retrieval of results in a separate call (multiple downloads are possible).\n- The asynchronous API is optimized for reliability and is not expected to run into a timeout.\n- The number of batch items is limited to **10,000** for this API.\n\nWhen you make a request by using async request, by default the service returns a 202 response code along a redirect URL in the Location field of the response header. This URL should be checked periodically until the response data or error information is available.\nThe asynchronous responses are stored for **14** days. The redirect URL returns a 404 response if used after the expiration period.\n\nPlease note that asynchronous batch request is a long-running operation. Here's a typical sequence of operations:\n1. Client sends a Search Address Batch `POST` request to Azure Maps. \n\r```\nPOST https://atlas.microsoft.com/search/address/batch/json?api-version=1.0&subscription-key={subscription-key}\n```\n\n2. The server will respond with one of the following:\n\n    > HTTP `202 Accepted` - Batch request has been accepted.\n\n    > HTTP `Error` - There was an error processing your Batch request. This could either be a `400 Bad Request` or any other `Error` status code.\n\n3. If the batch request was accepted successfully, the `Location` header in the response contains the URL to download the results of the batch request.\n    This status URI looks like following:\n\n```\n    GET https://atlas.microsoft.com/search/address/batch/{batch-id}?api-version=1.0&subscription-key={subscription-key}\n```\n4. Client issues a `GET` request on the _download URL_ obtained in Step 3 to download the batch results.\n\n### POST Body for Batch Request\nTo send the _search address_ queries you will use a `POST` request where the request body will contain the `batchItems` array in `json` format and the `Content-Type` header will be set to `application/json`. Here's a sample request body containing 5 _search address_ queries:\n\n\n```json\n{\n    \"batchItems\": [\n        {\"query\": \"?query=400 Broad St, Seattle, WA 98109&limit=3\"},\n        {\"query\": \"?query=One, Microsoft Way, Redmond, WA 98052&limit=3\"},\n        {\"query\": \"?query=350 5th Ave, New York, NY 10118&limit=1\"},\n        {\"query\": \"?query=Pike Pl, Seattle, WA 98101&lat=47.610970&lon=-122.342469&radius=1000\"},\n        {\"query\": \"?query=Champ de Mars, 5 Avenue Anatole France, 75007 Paris, France&limit=1\"}\n    ]\n}\n```\n\nA _search address_ query in a batch is just a partial URL _without_ the protocol, base URL, path, api-version and subscription-key. It can accept any of the supported _search address_ [URI parameters](/rest/api/maps/search/get-search-address?view=rest-maps-1.0#uri-parameters). The string values in the _search address_ query must be properly escaped (e.g. \" character should be escaped with \\\\ ) and it should also be properly URL-encoded.\n\n\nThe async API allows caller to batch up to **10,000** queries and sync API up to **100** queries, and the batch should contain at least **1** query.\n\n\n### Download Asynchronous Batch Results\nTo download the async batch results you will issue a `GET` request to the batch download endpoint. This _download URL_ can be obtained from the `Location` header of a successful `POST` batch request and looks like the following:\n\n```\nhttps://atlas.microsoft.com/search/address/batch/{batch-id}?api-version=1.0&subscription-key={subscription-key}\n```\nHere's the typical sequence of operations for downloading the batch results:\n1. Client sends a `GET` request using the _download URL_.\n2. The server will respond with one of the following:\n\n    > HTTP `202 Accepted` - Batch request was accepted but is still being processed. Please try again in some time.\n\n    > HTTP `200 OK` - Batch request successfully processed. The response body contains all the batch results.\n\n\n\n### Batch Response Model\nThe returned data content is similar for async and sync requests. When downloading the results of an async batch request, if the batch has finished processing, the response body contains the batch response. This batch response contains a `summary` component that indicates the `totalRequests` that were part of the original batch request and `successfulRequests`i.e. queries which were executed successfully. The batch response also includes a `batchItems` array which contains a response for each and every query in the batch request. The `batchItems` will contain the results in the exact same order the original queries were sent in the batch request. Each item in `batchItems` contains `statusCode` and `response` fields. Each `response` in `batchItems` is of one of the following types:\n\n  - [`SearchAddressResult`](/rest/api/maps/search/get-search-address?view=rest-maps-1.0#SearchAddressResult) - If the query completed successfully.\n\n  - `Error` - If the query failed. The response will contain a `code` and a `message` in this case.\n\n\nHere's a sample Batch Response with 2 _successful_ and 1 _failed_ result:\n\n\n```json\n{\n    \"summary\": {\n        \"successfulRequests\": 2,\n        \"totalRequests\": 3\n    },\n    \"batchItems\": [\n        {\n            \"statusCode\": 200,\n            \"response\":\n            {\n                \"summary\": {\n                    \"query\": \"one microsoft way redmond wa 98052\"\n                },\n                \"results\": [\n                    {\n                        \"position\": {\n                            \"lat\": 47.63989,\n                            \"lon\": -122.12509\n                        }\n                    }\n                ]\n            }\n        },\n        {\n            \"statusCode\": 200,\n            \"response\":\n            {\n                \"summary\": {\n                    \"query\": \"pike pl seattle wa 98101\"\n                },\n                \"results\": [\n                    {\n                        \"position\": {\n                            \"lat\": 47.60963,\n                            \"lon\": -122.34215\n                        }\n                    }\n                ]\n            }\n        },\n        {\n            \"statusCode\": 400,\n            \"response\":\n            {\n                \"error\":\n                {\n                    \"code\": \"400 BadRequest\",\n                    \"message\": \"Bad request: one or more parameters were incorrectly specified or are mutually exclusive.\"\n                }\n            }\n        }\n    ]\n}\n```",
    "old": "The `Get Search Address Batch` API is an HTTP `GET` request that sends batches of queries to [Search Address](/rest/api/maps/search/get-search-address?view=rest-maps-1.0) API in a single asynchronous API call. You can call Search Address Batch API to run either asynchronously (async) or synchronously (sync). The async API allows caller to batch up to **10,000** queries and sync API up to **100** queries.\n### Submit Synchronous Batch Request\nThe Synchronous API is recommended for lightweight batch requests. When the service receives a request, it will respond as soon as the batch items are calculated and there will be no possibility to retrieve the results later. The Synchronous API will return a timeout error (a 408 response) if the request takes longer than 60 seconds. The number of batch items is limited to **100** for this API.\n```\nPOST https://atlas.microsoft.com/search/address/batch/sync/json?api-version=1.0&subscription-key={subscription-key}\n```\n### Submit Asynchronous Batch Request\nThe Asynchronous API is appropriate for processing big volumes of relatively complex search requests\n- It allows the retrieval of results in a separate call (multiple downloads are possible).\n- The asynchronous API is optimized for reliability and is not expected to run into a timeout.\n- The number of batch items is limited to **10,000** for this API.\n\nWhen you make a request by using async request, by default the service returns a 202 response code along a redirect URL in the Location field of the response header. This URL should be checked periodically until the response data or error information is available.\nThe asynchronous responses are stored for **14** days. The redirect URL returns a 404 response if used after the expiration period.\n\nPlease note that asynchronous batch request is a long-running operation. Here's a typical sequence of operations:\n1. Client sends a Search Address Batch `POST` request to Azure Maps. \n\r```\nPOST https://atlas.microsoft.com/search/address/batch/json?api-version=1.0&subscription-key={subscription-key}\n```\n\n2. The server will respond with one of the following:\n\n    > HTTP `202 Accepted` - Batch request has been accepted.\n\n    > HTTP `Error` - There was an error processing your Batch request. This could either be a `400 Bad Request` or any other `Error` status code.\n\n3. If the batch request was accepted successfully, the `Location` header in the response contains the URL to download the results of the batch request.\n    This status URI looks like following:\n\n```\n    GET https://atlas.microsoft.com/search/address/batch/{batch-id}?api-version=1.0&subscription-key={subscription-key}\n```\n4. Client issues a `GET` request on the _download URL_ obtained in Step 3 to download the batch results.\n\n### POST Body for Batch Request\nTo send the _search address_ queries you will use a `POST` request where the request body will contain the `batchItems` array in `json` format and the `Content-Type` header will be set to `application/json`. Here's a sample request body containing 5 _search address_ queries:\n\n\n```json\n{\n    \"batchItems\": [\n        {\"query\": \"?query=400 Broad St, Seattle, WA 98109&limit=3\"},\n        {\"query\": \"?query=One, Microsoft Way, Redmond, WA 98052&limit=3\"},\n        {\"query\": \"?query=350 5th Ave, New York, NY 10118&limit=1\"},\n        {\"query\": \"?query=Pike Pl, Seattle, WA 98101&lat=47.610970&lon=-122.342469&radius=1000\"},\n        {\"query\": \"?query=Champ de Mars, 5 Avenue Anatole France, 75007 Paris, France&limit=1\"}\n    ]\n}\n```\n\nA _search address_ query in a batch is just a partial URL _without_ the protocol, base URL, path, api-version and subscription-key. It can accept any of the supported _search address_ [URI parameters](/rest/api/maps/search/get-search-address?view=rest-maps-1.0#uri-parameters). The string values in the _search address_ query must be properly escaped (e.g. \" character should be escaped with \\\\ ) and it should also be properly URL-encoded.\n\n\nThe async API allows caller to batch up to **10,000** queries and sync API up to **100** queries, and the batch should contain at least **1** query.\n\n\n### Download Asynchronous Batch Results\nTo download the async batch results you will issue a `GET` request to the batch download endpoint. This _download URL_ can be obtained from the `Location` header of a successful `POST` batch request and looks like the following:\n\n```\nhttps://atlas.microsoft.com/search/address/batch/{batch-id}?api-version=1.0&subscription-key={subscription-key}\n```\nHere's the typical sequence of operations for downloading the batch results:\n1. Client sends a `GET` request using the _download URL_.\n2. The server will respond with one of the following:\n\n    > HTTP `202 Accepted` - Batch request was accepted but is still being processed. Please try again in some time.\n\n    > HTTP `200 OK` - Batch request successfully processed. The response body contains all the batch results.\n\n\n\n### Batch Response Model\nThe returned data content is similar for async and sync requests. When downloading the results of an async batch request, if the batch has finished processing, the response body contains the batch response. This batch response contains a `summary` component that indicates the `totalRequests` that were part of the original batch request and `successfulRequests`i.e. queries which were executed successfully. The batch response also includes a `batchItems` array which contains a response for each and every query in the batch request. The `batchItems` will contain the results in the exact same order the original queries were sent in the batch request. Each item in `batchItems` contains `statusCode` and `response` fields. Each `response` in `batchItems` is of one of the following types:\n\n  - [`SearchAddressResult`](/rest/api/maps/search/get-search-address?view=rest-maps-1.0#SearchAddressResult) - If the query completed successfully.\n\n  - `Error` - If the query failed. The response will contain a `code` and a `message` in this case.\n\n\nHere's a sample Batch Response with 2 _successful_ and 1 _failed_ result:\n\n\n```json\n{\n    \"summary\": {\n        \"successfulRequests\": 2,\n        \"totalRequests\": 3\n    },\n    \"batchItems\": [\n        {\n            \"statusCode\": 200,\n            \"response\":\n            {\n                \"summary\": {\n                    \"query\": \"one microsoft way redmond wa 98052\"\n                },\n                \"results\": [\n                    {\n                        \"position\": {\n                            \"lat\": 47.63989,\n                            \"lon\": -122.12509\n                        }\n                    }\n                ]\n            }\n        },\n        {\n            \"statusCode\": 200,\n            \"response\":\n            {\n                \"summary\": {\n                    \"query\": \"pike pl seattle wa 98101\"\n                },\n                \"results\": [\n                    {\n                        \"position\": {\n                            \"lat\": 47.60963,\n                            \"lon\": -122.34215\n                        }\n                    }\n                ]\n            }\n        },\n        {\n            \"statusCode\": 400,\n            \"response\":\n            {\n                \"error\":\n                {\n                    \"code\": \"400 BadRequest\",\n                    \"message\": \"Bad request: one or more parameters were incorrectly specified or are mutually exclusive.\"\n                }\n            }\n        }\n    ]\n}\n```"
  }
}

⚼ Request

GET:  /search/address/batch/{format}
{
x-ms-client-id: string ,
api-version: string ,
format: string ,
}

⚐ Response (200)

{
batchItems:
[
{
response: object ,
}
,
]
,
}

⚐ Response (202)

{
location: string ,
}

⚐ Response (default)

{
error:
{
code: string ,
message: string ,
target: string ,
details:
[
string ,
]
,
additionalInfo:
[
{
type: string ,
info: object ,
}
,
]
,
}
,
}