Bing News API

The Bing News API uses the /api/v1/search?engine=bing_news endpoint to fetch real-time news results.

This API allows to access the latest news articles from various sources, offering detailed coverage of current events based on news category or query. The API delivers real-time information on trending topics, breaking news, and detailed reports.

API Parameters

Search Query

  • Name
    q
    Required
    Required
    Description

    Parameter defines the query you want to search. You can use anything that you would use in a regular Bing News search. e.g. inurl:, site:, intitle:.

    Note: search query q parameter is not required if category parameter is used. If both are used, the category parameter is prioritized.

  • Name
    category
    Required
    Optional
    Description

    Parameter defines the category you want to search. You can find these categories in the Bing News URL as nvaug parameter value. For example: nvaug=%5bNewsVertical+Category%3d"rt_CATEGORY"%5d.

    To retrieve Top Stories category, it is required to set category parameter to MaxClass. Most categories can be found in Bing News official documentation.

Device

  • Name
    device
    Required
    Optional
    Description

    The default parameter desktop defines the search on a desktop device. The mobile parameter defines the search on a mobile device. The tablet parameter defines the search on a tablet device.

Geographic Location

  • Name
    market_code
    Required
    Optional
    Description

    Defines the country for search results. Format is language-country, like en-US (Default value). For a list of market values, check the full list of supported Bing market_code codes.

    Note: the market_code parameter can't be used together with country_code parameter.

Localization

  • Name
    country_code
    Required
    Optional
    Description

    Specifies the country for the search results if market_code is not specified. Check the full list of supported Bing coutry_code countries.

    Note: the country_code parameter can't be used together with market_code parameter.

  • Name
    language
    Required
    Optional
    Description

    Sets the language for user interface text. Use 2-letter (ISO 639-1) or 4-letter codes ('-'). Defaults to en (English) if unspecified or unsupported. Check the full list of supported Bing language languages.

Filters

  • Name
    time_period
    Required
    Optional
    Description

    This parameter filters the search results by time period. By default, it returns all articles without any time period. The time_period parameter can be set to:

    • last_minute - Past minute
    • last_5_minutes - Past 5 minutes
    • last_15_minutes - Past 15 minutes
    • last_30_minutes - Past 30 minutes
    • last_hour - Past hour
    • last_4_hours - Past 4 hours
    • last_6_hours - Past 6 hours
    • last_24_hours - Past 24 hours
    • last_7_days - Past 7 days
    • last_30_days - Past 30 days

  • Name
    sort_by
    Required
    Optional
    Description

    By default, news results are sorted by relevance. To get the most recent articles, set it to most_recent.

Pagination

  • Name
    num
    Required
    Optional
    Description

    This parameter specifies the number of results to display per page. Maximum number - 50. Use in combination with the page parameter to implement pagination functionality.

  • Name
    page
    Required
    Optional
    Description

    This parameter indicates which page of results to return. By default, it is set to 1. Use in combination with the num parameter to implement pagination.

Engine

  • Name
    engine
    Required
    Required
    Description

    Parameter defines an engine that will be used to retrieve real-time data. It must be set to bing_news.

API key

  • Name
    api_key
    Required
    Required
    Description

    The api_key authenticates your requests. Use it as a query parameter (https://www.searchapi.io/api/v1/search?api_key=YOUR_API_KEY) or in the Authorization header (Bearer YOUR_API_KEY).

API Examples

Organic Results

Organic Results
GET
https://www.searchapi.io/api/v1/search?engine=bing_news&q=OpenAI
Request
import requests

url = "https://www.searchapi.io/api/v1/search"
params = {
  "engine": "bing_news",
  "q": "OpenAI"
}

response = requests.get(url, params = params)
print(response.text)
Response
{
  "organic_results": [
    {
      "position": 1,
      "title": "Report: Apple isn’t paying OpenAI for ChatGPT integration into OSes",
      "link": "https://arstechnica.com/information-technology/2024/06/report-apple-isnt-paying-openai-for-chatgpt-integration-into-oses/",
      "source": "Ars Technica",
      "date": "9m",
      "snippet": "\"Apple isn’t paying OpenAI as part of the partnership,\" writes Bloomberg reporter Mark Gurman, citing people familiar with the matter who wish to remain anonymous. \"Instead, Apple believes pushing OpenAI’s brand and technology to hundreds of millions of its devices is of equal or greater value than monetary payments.\"",
      "favicon": "data:image/png;base64,iVBORw...",
      "thumbnail": "https://th.bing.com/th?id=OVFT.4g6k7gmLceCSj5SugbTr0S&pid=News&w=304&h=217&c=14&rs=2&qlt=90"
    },
    {
      "position": 2,
      "title": "Apple isn't even paying OpenAI to put ChatGPT on iPhones, report says",
      "link": "https://www.msn.com/en-us/news/technology/apple-isn-t-even-paying-openai-to-put-chatgpt-on-iphones-report-says/ar-BB1oarZg?ocid=BingNewsSearch",
      "source": "Quartz on MSN",
      "date": "2h",
      "snippet": "Apple finally unveiled its generative artificial intelligence plans that include a partnership with an industry leader — but it reportedly doesn’t plan to pay for the technology, at least not with money.",
      "favicon": "data:image/png;base64,iVBORw0...",
      "thumbnail": "https://th.bing.com/th?id=OVFT.sc7Pb4FqDLrJlgIOPOFjii&pid=News&w=304&h=217&c=14&rs=2&qlt=90"
    },
    ...
  ]
}
Category Search

Development tips:

  • To retrieve Top Stories category, it is required to use category=MaxClass

GET
https://www.searchapi.io/api/v1/search?category=Sports&engine=bing_news
Request
import requests

url = "https://www.searchapi.io/api/v1/search"
params = {
  "engine": "bing_news",
  "category": "Sports"
}

response = requests.get(url, params = params)
print(response.text)
Response
{
  "organic_results": [
    {
      "position": 1,
      "title": "Colts LB E.J. Speed has 'bone to pick' with Texans, C.J. Stroud",
      "link": "https://www.msn.com/en-us/sports/nfl/colts-lb-ej-speed-has-bone-to-pick-with-texans-cj-stroud/ar-BB1oaRyS?ocid=BingNews",
      "source": "USA TODAY Touchdown Wire",
      "date": "28m",
      "snippet": "For those wondering, the Indianapolis Colts are moving up the list for the Houston Texans' top rival every time linebacker E.J. Speed utters something on a podcast.",
      "favicon": "https://www.bing.com/th?id=ODF.1sU-oZWFTn9peu0QLnaxKw&pid=news&w=16&h=16&c=14&rs=2",
      "thumbnail": "https://www.bing.com/th?id=OVFT.ghPosDgYhz9iiyUJdd0siS&pid=News&w=308&h=178&c=14&rs=2&qlt=90"
    },
    {
      "position": 2,
      "title": "Rafael Nadal will skip Wimbledon so he doesn’t have to switch from grass to clay for the Olympics",
      "link": "https://www.msn.com/en-us/sports/tennis/rafael-nadal-will-skip-wimbledon-so-he-doesn-t-have-to-switch-from-grass-to-clay-for-the-olympics/ar-BB1oavtQ?ocid=BingNews",
      "source": "NBC Sports",
      "date": "1h",
      "snippet": "Rafael Nadal is going to skip Wimbledon, as expected, and instead prepare for the Paris Olympics by entering a clay-court tournament in Bastad, Sweden, he hasn’t been to in 19 years. The 22-time",
      "favicon": "data:image/png;base64,iVBORw0KG..."
    },
    ...
  ]
}
Trending
GET
https://www.searchapi.io/api/v1/search?category=MaxClass&engine=bing_news
Request
import requests

url = "https://www.searchapi.io/api/v1/search"
params = {
  "engine": "bing_news",
  "category": "MaxClass"
}

response = requests.get(url, params = params)
print(response.text)
Response
{
  "trending": [
    {
      "topic": "Chevron decision overturned",
      "link": "https://www.bing.com/news/topicview?q=Supreme+Court+overturns+Chevron&filters=tnTID%3d%229083F26D-0B26-4d30-9CA7-4F6D977839D5%22+tnVersion%3d%225692802%22+Segment%3d%22popularnow.carousel%22+article%3d%221%22+tnCol%3d%220%22+tnOrder%3d%22579d88cd-550a-4094-8458-15a44bcbec74%22&nvaug=%5bNewsVertical+topicviewtype%3d\"2\"%5d&form=NWBTTC",
      "thumbnail": "https://www.bing.com/th?id=OPN.RTNews_vOYdZ9XI6_-C3DvJECdy0g&rs=2&qlt=80&pid=1.11&w=154&h=77&c=7&rs=2&qlt=90"
    },
    {
      "topic": "Sues OpenAI, Microsoft",
      "link": "https://www.bing.com/news/topicview?q=News+nonprofit+sues+OpenAI%2c+Microsoft&filters=tnTID%3d%22FE25D48F-29C6-41ca-B484-91C7F8F4D39E%22+tnVersion%3d%225692802%22+Segment%3d%22popularnow.carousel%22+article%3d%221%22+tnCol%3d%221%22+tnOrder%3d%22579d88cd-550a-4094-8458-15a44bcbec74%22&nvaug=%5bNewsVertical+topicviewtype%3d\"2\"%5d&form=NWBTTC",
      "thumbnail": "https://www.bing.com/th?id=OPN.RTNews_UgBmC8FHAI5AD6xVjmVDsA&rs=2&qlt=80&pid=1.11&w=154&h=77&c=7&rs=2&qlt=90"
    },
    ...
  ]
}
Related Topics
GET
https://www.searchapi.io/api/v1/search?engine=bing_news&q=Amazon
Request
import requests

url = "https://www.searchapi.io/api/v1/search"
params = {
  "engine": "bing_news",
  "q": "Amazon"
}

response = requests.get(url, params = params)
print(response.text)
Response
{
  "related_topics": [
    {
      "query": "Artificial intelligence",
      "link": "https://www.bing.com/news/search?q=artificial+intelligence+news&FORM=000009"
    },
    {
      "query": "Ai",
      "link": "https://www.bing.com/news/search?q=ai+amazon+news&FORM=000009"
    },
    ...
  ]
}