Bing Entity Search API v7 reference

The Entity Search API lets you send a search query to Bing and get back search results that include entities and places. Place results include restaurants, hotel, or other local businesses. For places, the query can specify the name of the local business or it can ask for a list (for example, restaurants near me). Entity results include persons, places, or things. Place in this context is tourist attractions, states, countries, etc.

Note

Entity responses support multiple markets, but the Places response supports only US Business locations.

This section provides technical details about the response objects, and the query parameters and headers that affect the search results. For examples that show how to make requests, see Search the web for entities and places.

For information about headers that requests should include, see Headers.

For information about query parameters that requests should include, see Query parameters.

For information about the JSON objects that the response includes, see Response objects.

For information about permitted use and display of results, see Use and display requirements.

Note

Because URL formats and parameters are subject to change without notice, use all URLs as-is. You should not take dependencies on the URL format or parameters except where noted.

Endpoint

To request entity search results, send a GET request to:

https://api.cognitive.microsoft.com/bing/v7.0/entities

For multi-service subscriptions, you must include the region in the URL. For example: westus.api.cognitive.microsoft.com. See Supported Regions.

The request must use the HTTPS protocol.

Note

The maximum URL length is 2,048 characters. To ensure that your URL length does not exceed the limit, the maximum length of your query parameters should be less than 1,500 characters. If the URL exceeds 2,048 characters, the server returns 404 Not found.

Headers

The following are the headers that a request and response may include.

Header Description
Accept Optional request header.

The default media type is application/json. To specify that the response use JSON-LD, set the Accept header to application/ld+json.
Accept-Language Optional request header.

A comma-delimited list of languages to use for user interface strings. The list is in decreasing order of preference. For more information, including expected format, see RFC2616.

This header and the setLang query parameter are mutually exclusive—do not specify both.

If you set this header, you must also specify the cc query parameter. To determine the market to return results for, Bing uses the first supported language it finds from the list and combines it with the cc parameter value. If the list does not include a supported language, Bing finds the closest language and market that supports the request or it uses an aggregated or default market for the results. To determine the market that Bing used, see the BingAPIs-Market header.

Use this header and the cc query parameter only if you specify multiple languages. Otherwise, use the mkt and setLang query parameters.

A user interface string is a string that's used as a label in a user interface. There are few user interface strings in the JSON response objects. Any links to Bing.com properties in the response objects apply the specified language.
BingAPIs-Market Response header.

The market used by the request. The form is <languageCode>-<countryCode>. For example, en-US.
BingAPIs-TraceId Response header.

The ID of the log entry that contains the details of the request. When an error occurs, capture this ID. If you are not able to determine and resolve the issue, include this ID along with the other information that you provide the Support team.
Ocp-Apim-Subscription-Key Required request header.

The subscription key that you received when you signed up for this service in Cognitive Services.
Pragma Optional request header

By default, Bing returns cached content, if available. To prevent Bing from returning cached content, set the Pragma header to no-cache (for example, Pragma: no-cache).
User-Agent Optional request header.

The user agent originating the request. Bing uses the user agent to provide mobile users with an optimized experience. Although optional, you are encouraged to always specify this header.

The user-agent should be the same string that any commonly used browser sends. For information about user agents, see RFC 2616.

The following are examples of user-agent strings.
  • Windows Phone—Mozilla/5.0 (compatible; MSIE 10.0; Windows Phone 8.0; Trident/6.0; IEMobile/10.0; ARM; Touch; NOKIA; Lumia 822)

  • Android—Mozilla/5.0 (Linux; U; Android 2.3.5; en-us; SCH-I500 Build/GINGERBREAD) AppleWebKit/533.1 (KHTML; like Gecko) Version/4.0 Mobile Safari/533.1

  • iPhone—Mozilla/5.0 (iPhone; CPU iPhone OS 6_1 like Mac OS X) AppleWebKit/536.26 (KHTML; like Gecko) Mobile/10B142 iPhone4;1 BingWeb/3.03.1428.20120423

  • PC—Mozilla/5.0 (Windows NT 6.3; WOW64; Trident/7.0; Touch; rv:11.0) like Gecko

  • iPad—Mozilla/5.0 (iPad; CPU OS 7_0 like Mac OS X) AppleWebKit/537.51.1 (KHTML, like Gecko) Version/7.0 Mobile/11A465 Safari/9537.53
X-MSEdge-ClientID Optional request and response header.

Bing uses this header to provide users with consistent behavior across Bing API calls. Bing often flights new features and improvements, and it uses the client ID as a key for assigning traffic on different flights. If you do not use the same client ID for a user across multiple requests, then Bing may assign the user to multiple conflicting flights. Being assigned to multiple conflicting flights can lead to an inconsistent user experience. For example, if the second request has a different flight assignment than the first, the experience may be unexpected. Also, Bing can use the client ID to tailor web results to that client ID’s search history, providing a richer experience for the user.

Bing also uses this header to help improve result rankings by analyzing the activity generated by a client ID. The relevance improvements help with better quality of results delivered by Bing APIs and in turn enables higher click-through rates for the API consumer.

IMPORTANT: Although optional, you should consider this header required. Persisting the client ID across multiple requests for the same end user and device combination enables 1) the API consumer to receive a consistent user experience, and 2) higher click-through rates via better quality of results from the Bing APIs.

The following are the basic usage rules that apply to this header.
  • Each user that uses your application on the device must have a unique, Bing generated client ID.

    If you do not include this header in the request, Bing generates an ID and returns it in the X-MSEdge-ClientID response header. The only time that you should NOT include this header in a request is the first time the user uses your app on that device.

  • Use the client ID for each Bing API request that your app makes for this user on the device.

  • ATTENTION: You must ensure that this Client ID is not linkable to any authenticatable user account information.

  • Persist the client ID. To persist the ID in a browser app, use a persistent HTTP cookie to ensure the ID is used across all sessions. Do not use a session cookie. For other apps such as mobile apps, use the device's persistent storage to persist the ID.

    The next time the user uses your app on that device, get the client ID that you persisted.

NOTE: Bing responses may or may not include this header. If the response includes this header, capture the client ID and use it for all subsequent Bing requests for the user on that device.

NOTE: If you include the X-MSEdge-ClientID, you must not include cookies in the request.
X-MSEdge-ClientIP Optional request header.

The IPv4 or IPv6 address of the client device. The IP address is used to discover the user's location. Bing uses the location information to determine safe search behavior.

NOTE: Although optional, you are encouraged to always specify this header and the X-Search-Location header.

Do not obfuscate the address (for example, by changing the last octet to 0). Obfuscating the address results in the location not being anywhere near the device's actual location, which may result in Bing serving erroneous results.
X-Search-Location Optional request header.

A semicolon-delimited list of key/value pairs that describe the client's geographical location. Bing uses the location information to determine safe search behavior and to return relevant local content. Specify the key/value pair as <key>:<value>. The following are the keys that you use to specify the user's location.

  • lat—The latitude of the client's location, in degrees. The latitude must be greater than or equal to -90.0 and less than or equal to +90.0. Negative values indicate southern latitudes and positive values indicate northern latitudes.

  • long—The longitude of the client's location, in degrees. The longitude must be greater than or equal to -180.0 and less than or equal to +180.0. Negative values indicate western longitudes and positive values indicate eastern longitudes.

  • re— The radius, in meters, which specifies the horizontal accuracy of the coordinates. Pass the value returned by the device's location service. Typical values might be 22m for GPS/Wi-Fi, 380m for cell tower triangulation, and 18,000m for reverse IP lookup.

  • ts— The UTC UNIX timestamp of when the client was at the location. (The UNIX timestamp is the number of seconds since January 1, 1970.)

  • head—Optional. The client's relative heading or direction of travel. Specify the direction of travel as degrees from 0 through 360, counting clockwise relative to true north. Specify this key only if the sp key is nonzero.

  • sp— The horizontal velocity (speed), in meters per second, that the client device is traveling.

  • alt— The altitude of the client device, in meters.

  • are—Optional. The radius, in meters, that specifies the vertical accuracy of the coordinates. Radius defaults to 50 Kilometers. Specify this key only if you specify the alt key.

NOTE: Although these keys are optional, the more information that you provide, the more accurate the location results are.

NOTE: You are encouraged to always specify the user's geographical location. Providing the location is especially important if the client's IP address does not accurately reflect the user's physical location (for example, if the client uses VPN). For optimal results, you should include this header and the X-MSEdge-ClientIP header, but at a minimum, you should include this header.

Note

Remember that the Terms of Use require compliance with all applicable laws, including regarding use of these headers. For example, in certain jurisdictions, such as Europe, there are requirements to obtain user consent before placing certain tracking devices on user devices.

Query parameters

The request may include the following query parameters. See the Required column for required parameters. You must URL encode the query parameters.

Name Value Type Required
mkt The market where the results come from.

For a list of possible market values, see Market Codes.

NOTE: The market code is required. Specifying the market helps Bing route the request and return an appropriate and optimal response.

String Yes
q The user's search term. String Yes
responseFilter A comma-delimited list of answers to include in the response. If you do not specify this parameter, the response includes all search answers for which there's relevant data.

The following are the possible filter values.

  • Entities
  • Places
String No
responseFormat The media type to use for the response. The following are the possible case-insensitive values.
  • JSON
  • JSONLD

The default is JSON. For information about the JSON objects that the response contains, see Response Objects.

If you specify JsonLd, the response body includes JSON-LD objects that contain the search results. For information about the JSON-LD, see JSON-LD.
String No
safeSearch A filter used to filter adult content. The following are the possible case-insensitive filter values.
  • Off—Return webpages with adult text, images, or videos.

  • Moderate—Return webpages with adult text, but not adult images or videos.

  • Strict—Do not return webpages with adult text, images, or videos.

The default is Moderate.

NOTE: If the request comes from a market that Bing's adult policy requires that safeSearch is set to Strict, Bing ignores the safeSearch value and uses Strict.

NOTE: If you use the site: query operator, there is the chance that the response may contain adult content regardless of what the safeSearch query parameter is set to. Use site: only if you are aware of the content on the site and your scenario supports the possibility of adult content.
String No
setLang The language to use for user interface strings. You may specify the language using either a 2-letter or 4-letter code. Using 4-letter codes is preferred.

For a list of supported language codes, see Bing supported languages.

Bing loads the localized strings if setlang contains a valid 2-letter neutral culture code (fr) or a valid 4-letter specific culture code (fr-ca). For example, for fr-ca, Bing loads the fr neutral culture code strings.

If setlang is not valid (for example, zh) or Bing doesn’t support the language (for example, af, af-na), Bing defaults to en (English).

To specify the 2-letter code, set this parameter to an ISO 639-1 language code.

To specify the 4-letter code, use the form -<country/region> where is an ISO 639-1 language code (neutral culture) and <country/region> is an ISO 3166 country/region (specific culture) code. For example, use en-US for United States English.

Although optional, you should always specify the language. Typically, you set setLang to the same language specified by mkt unless the user wants the user interface strings displayed in a different language.

This parameter and the Accept-Language header are mutually exclusive—do not specify both.

A user interface string is a string that's used as a label in a user interface. There are few user interface strings in the JSON response objects. Also, any links to Bing.com properties in the response objects apply the specified language.
String No

Response Objects

The following are the JSON response objects that the response may include. If the request succeeds, the top-level object in the response is the SearchResponse object. If the request fails, the top-level object is the ErrorResponse object.

Object Description
Entity Defines an entity such as a person, place, or thing.
EntityPresentationInfo Defines additional information about an entity such as type hints.
Error Defines an error that occurred.
ErrorResponse The top-level object that the response includes when the request fails.
Image Defines an image.
License Defines the license under which the text or photo may be used.
LicenseAttribution Defines a contractual rule for license attribution.
Link Defines the components of a hyperlink.
LinkAttribution Defines a contractual rule for link attribution.
MediaAttribution Defines a contractual rule for media attribution.
Organization Defines a publisher.
Place Defines information about a local entity such as a restaurant or hotel.
PostalAddress Defines a postal address.
QueryContext Defines the query context that Bing used for the request.
Identifiable A resource identifier
RankingGroup Defines a search results group, such as mainline.
RankingItem Defines a search result item to display.
RankingResponse Defines where on the search results page content should be placed and in what order.
SearchResponse The top-level object that the response includes when the request succeeds.
TextAttribution Defines a contractual rule for plain text attribution.

Entity

Defines an entity such as a person, place, or thing.

Name Value Type
bingId An ID that uniquely identifies this entity. String
contractualRules A list of rules that you must adhere to if you display the entity. For example, the rules may govern attributing the entity's description.

The following contractual rules may apply.


Not all entities include rules. If the entity provides contractual rules, you must abide by them. For more information about using contractual rules, see Attributing Data.
Object[]
description A short description of the entity. String
entityPresentationInfo Additional information about the entity such as hints that you can use to determine the entity's type. To determine the entity's type, use the entityScenario and entityTypeHint fields. For example, the fields help you determine whether the entity is a dominant or disambiguation entity and whether it's a person or movie. The entity is a dominant entity if Bing believes that only one entity satisfies the request. If multiple entities could satisfy the request, the entity is a disambiguation entity and the user needs to select the entity they're interested in. EntityPresentationInfo
image An image of the entity. Image
name The entity's name. String
webSearchUrl The URL that takes the user to the Bing search results page for this entity. String

EntityPresentationInfo

Defines additional information about an entity such as type hints.

Name Value Type
entityScenario The supported scenario. String
entityTypeDisplayHint A display version of the entity hint. For example, if entityTypeHints is Artist, this field may be set to American Singer. String
entityTypeHint A list of hints that indicate the entity's type. The list could contain a single hint such as Movie or a list of hints such as Place, LocalBusiness, Restaurant. Each successive hint in the array narrows the entity's type.

For a list of possible types, see Entity Types. If the object does not include this field, Generic is assumed.
String[]

Error

Defines the error that occurred.

Element Description Type
code The error code that identifies the category of error. For a list of possible codes, see Error Codes. String
message A description of the error. String
moreDetails A description that provides additional information about the error. String
parameter The query parameter in the request that caused the error. String
subCode The error code that identifies the error. For example, if code is InvalidRequest, subCode may be ParameterInvalid or ParameterInvalidValue. String
value The query parameter's value that was not valid. String

ErrorResponse

The top-level object that the response includes when the request fails.

Name Value Type
_type Type hint. String
errors A list of errors that describe the reasons why the request failed. Error[]

Image

Defines an image.

Note

Because the URL format and parameters are subject to change without notice, all image URLs should be used as-is; you should not take dependencies on the URL format or parameters. The exception is those parameters and values discussed by Resize and crop thumbnail images.

Name Value Type
height The height of the source image, in pixels. Unsigned Short
hostPageUrl The URL of the webpage that includes the image.

This URL and contentUrl may be the same URL.
String
name An optional text string that contains random information about the image. String
provider The source of the image. The array will contain a single item.

You must attribute the image to the provider. For example, you may display the provider's name as the cursor hovers over the image or make the image a click-through link to the provider's website where the image is found.
Organization[]
thumbnailUrl The URL to a thumbnail of the image. For information about resizing the image, see Resize and crop thumbnail images. String
width The width of the source image, in pixels. Unsigned Short

License

Defines the license under which the text or photo may be used.

Name Value Type
name The name of the license. String
url The URL to a website where the user can get more information about the license.

Use the name and URL to create a hyperlink.
String

LicenseAttribution

Defines a contractual rule for license attribution.

Name Value Type
_type A type hint, which is set to LicenseAttribution. String
license The license under which the content may be used. License
licenseNotice The license to display next to the targeted field. For example, "Text under CC-BY-SA license".

Use the license's name and URL in the license field to create a hyperlink to the website that describes the details of the license. Then, replace the license name in the licenseNotice string (for example, CC-BY-SA) with the hyperlink you just created.
String
mustBeCloseToContent A Boolean value that determines whether the contents of the rule must be placed in close proximity to the field that the rule applies to. If true, the contents must be placed in close proximity. If false, or this field does not exist, the contents may be placed at the caller's discretion. Boolean
targetPropertyName The name of the field that the rule applies to. String

Defines the components of a hyperlink.

Name Value Type
_type Type hint. String
text The display text. String
url A URL. Use the URL and display text to create a hyperlink. String

LinkAttribution

Defines a contractual rule for link attribution.

Name Value Type
_type A type hint, which is set to LinkAttribution. String
mustBeCloseToContent A Boolean value that determines whether the contents of the rule must be placed in close proximity to the field that the rule applies to. If true, the contents must be placed in close proximity. If false, or this field does not exist, the contents may be placed at the caller's discretion. Boolean
targetPropertyName The name of the field that the rule applies to.

If a target is not specified, the attribution applies to the entity as a whole and should be displayed immediately following the entity presentation. If there are multiple text and link attribution rules that do not specify a target, you should concatenate them and display them using a "Data from: " label. For example, “Data from <provider name1> | <provider name2>".
String
text The attribution text. String
url The URL to the provider's website. Use text and URL to create of hyperlink. String

MediaAttribution

Defines a contractual rule for media attribution.

Name Value Type
_type A type hint, which is set to MediaAttribution. String
mustBeCloseToContent A Boolean value that determines whether the contents of the rule must be placed in close proximity to the field that the rule applies to. If true, the contents must be placed in close proximity. If false, or this field does not exist, the contents may be placed at the caller's discretion. Boolean
targetPropertyName The name of the field that the rule applies to. String
url The URL that you use to create of hyperlink of the media content. For example, if the target is an image, you would use the URL to make the image clickable. String

Organization

Defines a publisher.

Note that a publisher may provide their name or their website or both.

Name Value Type
name The publisher's name. String
url The URL to the publisher's website.

Note that the publisher may not provide a website.
String

Place

Defines information about a local entity, such as a restaurant or hotel.

Note

Entity responses support multiple markets, but the Places response supports only US Business locations.

Name Value Type
_type Type hint, which may be set to one of the following:

  • Hotel
  • LocalBusiness
  • Restaurant
  • String
    address The postal address of where the entity is located. PostalAddress
    entityPresentationInfo Additional information about the entity such as hints that you can use to determine the entity's type. For example, whether it's a restaurant or hotel. The entityScenario field is set to ListItem. EntityPresentationInfo
    name The entity's name. String
    telephone The entity's telephone number. String
    url The URL to the entity's website.

    Use this URL along with the entity's name to create a hyperlink that when clicked takes the user to the entity's website.
    String
    webSearchUrl The URL to Bing's search result for this place. String

    PostalAddress

    Defines a postal address.

    Name Value Type
    addressCountry The country/region where the street address is located. This could be the two-letter ISO code (for example, US) or the full name (for example, United States). String
    addressLocality The city where the street address is located. For example, Seattle. String
    addressRegion The state or province code where the street address is located. This could be the two-letter code (for example, WA) or the full name (for example, Washington). String
    neighborhood The neighborhood where the street address is located. For example, Westlake. String
    postalCode The zip code or postal code where the street address is located. For example, 98052. String

    QueryContext

    Defines the query context that Bing used for the request.

    Element Description Type
    adultIntent A Boolean value that indicates whether the specified query has adult intent. The value is true if the query has adult intent; otherwise, false. Boolean
    alterationOverrideQuery The query string to use to force Bing to use the original string. For example, if the query string is saling downwind, the override query string will be +saling downwind. Remember to encode the query string which results in %2Bsaling+downwind.

    This field is included only if the original query string contains a spelling mistake.
    String
    alteredQuery The query string used by Bing to perform the query. Bing uses the altered query string if the original query string contained spelling mistakes. For example, if the query string is saling downwind, the altered query string will be sailing downwind.

    This field is included only if the original query string contains a spelling mistake.
    String
    askUserForLocation A Boolean value that indicates whether Bing requires the user's location to provide accurate results. If you specified the user's location by using the X-MSEdge-ClientIP and X-Search-Location headers, you can ignore this field.

    For location aware queries, such as "today's weather" or "restaurants near me" that need the user's location to provide accurate results, this field is set to true.

    For location aware queries that include the location (for example, "Seattle weather"), this field is set to false. This field is also set to false for queries that are not location aware, such as "best sellers".
    Boolean
    originalQuery The query string as specified in the request. String

    Identifiable

    Name Value Type
    id A resource identifier String

    RankingGroup

    Defines a search results group, such as mainline. |Name|Value|Type|
    |-------------|-----------------|----------| |items|A list of search results to display in the group.|RankingItem|

    RankingItem

    Defines a search result item to display. |Name|Value|Type|
    |-------------|-----------------|----------| |resultIndex|A zero-based index of the item in the answer to display. If the item does not include this field, display all items in the answer. For example, display all news articles in the News answer.|Integer| |answerType|The answer that contains the item to display. For example, News.

    Use the type to find the answer in the SearchResponse object. The type is the name of a SearchResponse field.

    However, use the answer type only if this object includes the value field; otherwise, ignore it.|String| |textualIndex|The index of the answer in textualAnswers to display.| Unsigned Integer| |value|The ID that identifies either an answer to display or an item of an answer to display. If the ID identifies an answer, display all items of the answer.|Identifiable|

    RankingResponse

    Defines where on the search results page content should be placed and in what order.

    Name Value
    mainline The search results to display in the mainline.
    pole The search results that should be afforded the most visible treatment (for example, displayed above the mainline and sidebar).
    sidebar The search results to display in the sidebar.

    SearchResponse

    Defines the top-level object that the response includes when the request succeeds.

    Note that if the service suspects a denial of service attack, the request will succeed (HTTP status code is 200 OK); however, the body of the response will be empty.

    Name Value Type
    _type Type hint, which is set to SearchResponse. String
    entities A list of entities that are relevant to the search query. Entity
    queryContext An object that contains the query string that Bing used for the request.

    This object contains the query string as entered by the user. It may also contain an altered query string that Bing used for the query if the query string contained a spelling mistake.
    QueryContext

    TextAttribution

    Defines a contractual rule for plain text attribution.

    Name Value Type
    _type A type hint, which is set to TextAttribution. String
    text The attribution text.

    Text attribution applies to the entity as a whole and should be displayed immediately following the entity presentation. If there are multiple text or link attribution rules that do not specify a target, you should concatenate them and display them using a "Data from: " label.
    String

    Entity Types

    This section contains the possible entity hints. The hints are grouped by category of entities.

    The following are the base entity types.

    • Generic
    • Person
    • Place
    • Media
    • Organization

    The following are the entity hints that fall under the Place base type.

    • Attraction
    • City
    • Continent
    • Country
    • Hotel
    • House
    • LocalBusiness
    • Locality
    • MinorRegion
    • Neighborhood
    • Other
    • PointOfInterest
    • PostalCode
    • RadioStation
    • Region
    • Restaurant
    • State
    • StreetAddress
    • SubRegion
    • TouristAttraction
    • Travel

    The following are the entity hints that fall under the Media base type.

    • Book
    • Movie
    • TelevisionSeason
    • TelevisionShow
    • VideoGame

    The following are the event-related entity hints.

    • Event

    The following are the profession-related entity hints.

    • Actor
    • Artist
    • Attorney

    The following are the education-related entity hints.

    • CollegeOrUniversity
    • School
    • Speciality

    The following are unrelated entity hints.

    • Animal
    • Car
    • Drug
    • Food
    • Product
    • SportsTeam

    Error codes

    The following are the possible HTTP status codes that a request returns.

    Status Code Description
    200 Success.
    400 One of the query parameters is missing or not valid.
    401 The subscription key is missing or is not valid.
    403 The user is authenticated (for example, they used a valid subscription key) but they don’t have permission to the requested resource.

    Bing may also return this status if the caller exceeded their queries per month quota.
    410 The request used HTTP instead of the HTTPS protocol. HTTPS is the only supported protocol.
    429 The caller exceeded their queries per second quota.
    500 Unexpected server error.

    If the request fails, the response contains an ErrorResponse object, which contains a list of Error objects that describe what caused of error. If the error is related to a parameter, the parameter field identifies the parameter that is the issue. And if the error is related to a parameter value, the value field identifies the value that is not valid.

    {
      "_type": "ErrorResponse", 
      "errors": [
        {
          "code": "InvalidRequest", 
          "subCode": "ParameterMissing", 
          "message": "Required parameter is missing.", 
          "parameter": "q" 
        }
      ]
    }
    
    {
      "_type": "ErrorResponse", 
      "errors": [
        {
          "code": "InvalidAuthorization", 
          "subCode": "AuthorizationMissing", 
          "message": "Authorization is required.", 
          "moreDetails": "Subscription key is not recognized."
        }
      ]
    }
    

    The following are the possible error code and sub-error code values.

    Code SubCode Description
    ServerError UnexpectedError
    ResourceError
    NotImplemented
    HTTP status code is 500.
    InvalidRequest ParameterMissing
    ParameterInvalidValue
    HttpNotAllowed
    Blocked
    Bing returns InvalidRequest whenever any part of the request is not valid. For example, a required parameter is missing or a parameter value is not valid.

    If the error is ParameterMissing or ParameterInvalidValue, the HTTP status code is 400.

    If you use the HTTP protocol instead of HTTPS, Bing returns HttpNotAllowed, and the HTTP status code is 410.
    RateLimitExceeded No sub-codes Bing returns RateLimitExceeded whenever you exceed your queries per second (QPS) or queries per month (QPM) quota.

    If you exceed QPS, Bing returns HTTP status code 429, and if you exceed QPM, Bing returns 403.
    InvalidAuthorization AuthorizationMissing
    AuthorizationRedundancy
    Bing returns InvalidAuthorization when Bing cannot authenticate the caller. For example, the Ocp-Apim-Subscription-Key header is missing or the subscription key is not valid.

    Redundancy occurs if you specify more than one authentication method.

    If the error is InvalidAuthorization, the HTTP status code is 401.
    InsufficientAuthorization AuthorizationDisabled
    AuthorizationExpired
    Bing returns InsufficientAuthorization when the caller does not have permissions to access the resource. This can occur if the subscription key has been disabled or has expired.

    If the error is InsufficientAuthorization, the HTTP status code is 403.

    Market codes

    The following table lists the market code values that you may use to specify the mkt query parameter. Bing returns content for only these markets. The list is subject to change.

    Note

    Entity responses support multiple markets, but the Places response supports only US Business locations.

    Country/Region Language Market code
    Australia English en-AU
    Canada English en-CA
    Canada French fr-CA
    France French fr-FR
    Germany German de-DE
    India English en-IN
    Italy Italian it-IT
    Mexico Spanish es-MX
    United Kingdom English en-GB
    United States English en-US
    United States Spanish es-US
    Spain Spanish es-ES
    Brazil Portuguese pt-BR

    Bing supported languages

    The following are the Bing supported languages that you may specify in the setLang query parameter. The list is subject to change.

    Supported Languages Language Code
    Arabic ar
    Basque eu
    Bengali bn
    Bulgarian bg
    Catalan ca
    Chinese (Simplified) zh-hans
    Chinese (Traditional) zh-hant
    Croatian hr
    Czech cs
    Danish​ da
    Dutch​ nl
    English en
    English-United Kingdom en-gb
    Estonian et
    Finnish fi
    French fr
    Galician gl
    German de
    Gujarati gu
    Hebrew he
    Hindi hi
    Hungarian hu
    Icelandic is
    Italian it
    Japanese jp
    Kannada kn
    Korean ko
    Latvian lv
    Lithuanian lt
    Malay ms
    Malayalam  ml
    Marathi mr
    Norwegian (Bokmål) nb
    Polish​ pl
    Portuguese (Brazil)​ pt-br
    Portuguese (Portugal)​ pt-pt
    Punjabi​ pa
    Romanian ro
    Russian ru
    Serbian (Cyrylic) sr
    Slovak​ sk
    Slovenian​ sl
    Spanish es
    Swedish sv
    Tamil ta
    Telugu te
    Thai th
    Turkish tr
    Ukrainian uk
    Vietnamese vi