File tree Expand file tree Collapse file tree 1 file changed +9
-4
lines changed
Expand file tree Collapse file tree 1 file changed +9
-4
lines changed Original file line number Diff line number Diff line change 33
44# -*- coding: utf-8 -*-
55
6- import http .client , urllib .parse , json
6+ '''
7+ This sample uses the Bing Autosuggest API to check the spelling of query words and then suggests corrections.
8+ Bing Spell Check API: https://docs.microsoft.com/en-us/rest/api/cognitiveservices-bingsearch/bing-autosuggest-api-v7-reference57855119bca1df1c647bc358
9+ '''
710
8- # **********************************************
9- # *** Update or verify the following values. ***
10- # **********************************************
11+ import http .client
12+ import json
13+ import os
14+ import urllib .parse
1115
1216# Add your Bing Autosuggest subscription key to your environment variables.
1317subscriptionKey = os .environ ['BING_AUTOSUGGEST_SUBSCRIPTION_KEY' ]
1418
1519# Add your Bing Autosuggest endpoint to your environment variables.
1620host = os .environ ['BING_AUTOSUGGEST_ENDPOINT' ]
21+ host = host .replace ('https://' , '' )
1722path = '/bing/v7.0/Suggestions'
1823
1924mkt = 'en-US'
You can’t perform that action at this time.
0 commit comments