Author – Akash Roy , Cloud Engineer
Often when we surf the internet we come across thousands of advertisements and unnecessary interruptions. We wish to find a solution that will prevent these advertisements to pop up on any page we surf.
There have been times when we have searched for one query and have been showed results of different query. Azure Cognitive service’s Bing Search API provides solution to these problems as well as a lot of other problems.
Azure Cognitive Service’s Bing API consists of many features that are required to create your own Search Engine. Bing Web Search API These APIs are
- Bing Image Search API
- Bing Video Search API
- Bing Visual Search API
- Bing Entity Search API
- Bing Autosuggest API
- Bing Spell Check API
- Bing Custom Search API
- Bing Web Search API
- Bing News API
Let’s discuss about them in detail.
APIs
Bing Search API is divided into three distinctive Sections,
- Content Specific Search API
- Bing Custom Search API
- Additional Bing Search API
Content Specific Search API- These APIs are specific to what we want and can be used to obtain specific results. These APIs are:
- Bing Image Search
- Bing Video Search
- Bing Entity Search
- Bing News Search
- Bing Visual Search
- Local Business Search
Bing Custom Search API- Bing Custom Search API can be used to create a specific search engine where you can specify the pages that you want to visit, and the API will extract data from these specific weblinks or pages.
Bing Additional Search API- The remaining APIs come under the additional Search APIs, Bing Autosuggest API provides the real time suggestions while searching for the query on the search engine.
Connect Bing Search API to your Application
In order to use the Bing Search APIs, you need to have a Bing search resource on your portal. This can either be created through the Azure portal or through PowerShell
Bing Search can be accessed using API, SDKs and through web portal. In order to access it through API or SDK, you have to connect the API to visual studio or any editor of your choice.
While creating the Bing Search Cognitive service on portal you will be provided with a key and an endpoint which will be required in the code in order to access Bing Search API.
Bing Image Search
Bing Image search returns the pictures that the user has searched for, The difference between the normal image search and Bing image search is that In Bing image search you can search for the images by passing a location based filter. i.e.: If you want to see the pictures only from Spain then you can pass the filter and get the results.
Another major difference between Bing image search and normal image search is that if you are searching for a png image then the results will only include png images and not the jpeg images.
Unlike normal image search engines that display both png as well as jpeg images
Bing Image search makes sure the image displayed are crystal clear and of high definition without having to mention it.
Bing Video Search
Just like Bing Image Search, Bing Video Search is also a content specific API. In this API you get the video and the capability to see the preview of the video and its contents by hovering on top of the video.
You can apply location filters to these video search. For example: If you want to search for a video that is found in Europe region, then you can pass the location filter and it will show you the videos that are present in Europe region
Bing Video Search also offers you with the option to enable Safe-search which will prevent any graphic content to be displayed as the search result so that young teens aren’t affected by it.
Bing Visual Search
There have been moments when we have loved an outfit but had no idea where to find it or which website offers the minimum price for the outfit.
Bing Visual Search offers a solution to such problem. In Bing visual search, you just have to upload the picture of the outfit, accessories, places etc and in return Bing visual search will give the weblinks that sell or provide the product whose image was uploaded.
Bing Visual Search also provides the prices of these products on all the sites for you to compare and choose the web page that provides the product for the lowest price.
Bing Entity Search
Bing Entity Search API identifies the most relevant entity based on your searched term and then searches the internet for that entity showing all the web pages that has the entity present in it. It will span multiple entity types such as famous people, places, movies, TV shows, video games, books, and even local businesses near you.
Bing News Search
The difference between Bing News Search and normal search engine news search is that Bing provides with the latest and recent news from all around the globe. Bing provides you with the feature to extract news based on region/location.
Bing’s News Search API version 7 has the latest features that provide more detailed authoritative image of the news article, related news and categories, provider info, article URL and date added. With the API v7, discover new sorting and filtering options that simplify finding specific results in trending news topics.
Bing Autosuggest API
There have often been times when you wanted to search about something but couldn’t recollect it and went on your search browser to see if that suggestion pops up so that you can recollect it.
Bing Autosuggest is the Additional Bing Search API, It provides you with real time suggestions so that it becomes easy for you to search for what you want.
Bing Spell Check
In a corporate world, writing a mail/document and making sure you don’t come out as offensive. In this case Bing’s Spell Check API helps by proofreading the entire content and check for the tone of the text.
There are 2 ways in which the proof reading takes place. They are:
- Proof
- Spell
Proof: It is a less aggressive spell check API. It basically puts missing semi-colons, Capitalises the first alphabets and add basic punctuations.
Spell: This is an aggressive Spell Check API. It basically returns the word correction while typing in order to help get better search results.
Bing Custom Search
Bing Custom Search API helps you to make a custom search engine of yourself. The benefit of having a custom search engine is that it allows us to specify the web pages and web links and provide the result from these specified web pages.
It also gives us the liberty to block any webpage you want so that information from that page will be blocked and won’t reach the user.
In Custom Search portal you call also use autosuggest feature that will help you in providing real time suggestions. You will have to put all the keywords that can be associated with the search query. For example: For a search query “Ferrari”, you will have to put the different types of Ferrari cars, such as Ferrari California etc.
Since Bing Custom Search can be accessed using APIs, SDKs and also through Web Portal, in order to connect it to an SDK you will have to pass the JavaScript code provided in the portal.
In order to use the Hosted UI provided through the portal, you will have to use the HTML Endpoint provided to you.
For additional reference, do check the documentation.