Bing API: Image & Video Search

6 minutes
Share the link to this page
Copied
  Completed

Transcript

Hello guys, welcome to the 45th session of using Microsoft Word framework Lewis and cognitive services tutorials for beginners. In this session, we will learn how to use Bing image and video Search API. Here I have downloaded and you get packages for image and video search and added those in our helpers. That is copy method signature. And change the name to search image. create an instance of Image Search API.

Here we need to get a fully qualified name because these classes present in image web and video namespace like the web, by using image dot searches in method, we can search images If we got any result, then the screaming comedy message. Here I am passing query create a new message. Change Layout to the carousels. Let us look through each result. Created aka that title. Inside content URL in the image and add a button high view image The content and these Hirokazu message attachment and send this message using context.

Let us update our dialogue and run the project. Select image search that is search box Yeah, we got images of dogs Let us try with another query. Guys. Here we got images of cars. First your sync method takes several parameters. For example, image type has line.

An image a sprite will describe the final testes. That is search for cats again. Here we got a different result from previous one. All images are square, and all our line drawing instead of cars photo now I'm going to add video search That is copy method of image search. Change me and use video search. Here I've displayed top three videos.

To cut for image we need to use coming UI update dialog to see all the files underneath Select video search. Enter diamonds. Here we got three cards containing a thumbnail image of the room that is open anyway. It is open in YouTube. Like imagine web search video search takes several parameters, such as length, and freshness. So we can check return data a new conversation.

Use the same query. Here we got different thumbnail images. That is caught we are learning this session. To perform image search, we need to use slash dot image slash and you get package. Create an instance of Image Search API. And using such a sync method returns the result.

Look through each result and display it as a hero card. Here we see image type and aspect parameter for such a safe method. Here is video search example is similar to Image Search. Here we have used search dot video search and you get package and create client of video Search API. Here we see length and freshness parameters for such a simple method. Thanks for watching this video.

If you have any doubts, please feel free to contact me. Have a nice day.

Sign Up

Share

Share with friends, get 20% off
Invite your friends to LearnDesk learning marketplace. For each purchase they make, you get 20% off (upto $10) on your next purchase.