How to use azure-cognitiveservices-search-customsearch - 10 common examples

To help you get started, we’ve selected a few azure-cognitiveservices-search-customsearch examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github Azure / azure-sdk-for-python / azure-cognitiveservices-search-customsearch / azure / cognitiveservices / search / customsearch / models / response.py View on Github external
def __init__(self, **kwargs):
        super(Response, self).__init__(**kwargs)
        self.web_search_url = None
        self._type = 'Response'
github Azure / azure-sdk-for-python / azure-cognitiveservices-search-customsearch / azure / cognitiveservices / search / customsearch / models / search_response.py View on Github external
# coding=utf-8
# --------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for
# license information.
#
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes may cause incorrect behavior and will be lost if the code is
# regenerated.
# --------------------------------------------------------------------------

from .response import Response


class SearchResponse(Response):
    """Defines the top-level object that the response includes when the request
    succeeds.

    Variables are only populated by the server, and will be ignored when
    sending a request.

    All required parameters must be populated in order to send to Azure.

    :param _type: Required. Constant filled by server.
    :type _type: str
    :ivar id: A String identifier.
    :vartype id: str
    :ivar web_search_url: The URL To Bing's search result for this item.
    :vartype web_search_url: str
    :ivar query_context: An object that contains the query string that Bing
     used for the request. This object contains the query string as entered by
github Azure / azure-sdk-for-python / azure-cognitiveservices-search-customsearch / azure / cognitiveservices / search / customsearch / models / answer.py View on Github external
# coding=utf-8
# --------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for
# license information.
#
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes may cause incorrect behavior and will be lost if the code is
# regenerated.
# --------------------------------------------------------------------------

from .response import Response


class Answer(Response):
    """Answer.

    You probably want to use the sub-classes and not this class directly. Known
    sub-classes are: SearchResultsAnswer

    Variables are only populated by the server, and will be ignored when
    sending a request.

    All required parameters must be populated in order to send to Azure.

    :param _type: Required. Constant filled by server.
    :type _type: str
    :ivar id: A String identifier.
    :vartype id: str
    :ivar web_search_url: The URL To Bing's search result for this item.
    :vartype web_search_url: str
github Azure / azure-sdk-for-python / azure-cognitiveservices-search-customsearch / azure / cognitiveservices / search / customsearch / models / thing.py View on Github external
# coding=utf-8
# --------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for
# license information.
#
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes may cause incorrect behavior and will be lost if the code is
# regenerated.
# --------------------------------------------------------------------------

from .response import Response


class Thing(Response):
    """Thing.

    You probably want to use the sub-classes and not this class directly. Known
    sub-classes are: CreativeWork

    Variables are only populated by the server, and will be ignored when
    sending a request.

    All required parameters must be populated in order to send to Azure.

    :param _type: Required. Constant filled by server.
    :type _type: str
    :ivar id: A String identifier.
    :vartype id: str
    :ivar web_search_url: The URL To Bing's search result for this item.
    :vartype web_search_url: str
github Azure / azure-sdk-for-python / azure-cognitiveservices-search-customsearch / azure / cognitiveservices / search / customsearch / custom_search_client.py View on Github external
def __init__(
            self, credentials, base_url=None):

        self.config = CustomSearchClientConfiguration(credentials, base_url)
        super(CustomSearchClient, self).__init__(self.config.credentials, self.config)

        client_models = {k: v for k, v in models.__dict__.items() if isinstance(v, type)}
        self.api_version = '1.0'
        self._serialize = Serializer(client_models)
        self._deserialize = Deserializer(client_models)

        self.custom_instance = CustomInstanceOperations(
            self._client, self.config, self._serialize, self._deserialize)
github Azure / azure-sdk-for-python / azure-cognitiveservices-search-customsearch / azure / cognitiveservices / search / customsearch / custom_search_client.py View on Github external
def __init__(
            self, credentials, base_url=None):

        if credentials is None:
            raise ValueError("Parameter 'credentials' must not be None.")
        if not base_url:
            base_url = 'https://api.cognitive.microsoft.com/bingcustomsearch/v7.0'

        super(CustomSearchClientConfiguration, self).__init__(base_url)

        self.add_user_agent('azure-cognitiveservices-search-customsearch/{}'.format(VERSION))

        self.credentials = credentials
github Azure / azure-sdk-for-python / azure-cognitiveservices-search-customsearch / azure / cognitiveservices / search / customsearch / custom_search_client.py View on Github external
def __init__(
            self, credentials, base_url=None):

        self.config = CustomSearchClientConfiguration(credentials, base_url)
        super(CustomSearchClient, self).__init__(self.config.credentials, self.config)

        client_models = {k: v for k, v in models.__dict__.items() if isinstance(v, type)}
        self.api_version = '1.0'
        self._serialize = Serializer(client_models)
        self._deserialize = Deserializer(client_models)

        self.custom_instance = CustomInstanceOperations(
            self._client, self.config, self._serialize, self._deserialize)
github Azure / azure-sdk-for-python / azure-cognitiveservices-search-customsearch / azure / cognitiveservices / search / customsearch / models / answer.py View on Github external
def __init__(self, **kwargs):
        super(Answer, self).__init__(**kwargs)
        self.follow_up_queries = None
        self._type = 'Answer'
github Azure / azure-sdk-for-python / azure-cognitiveservices-search-customsearch / azure / cognitiveservices / search / customsearch / models / search_results_answer.py View on Github external
# coding=utf-8
# --------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for
# license information.
#
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes may cause incorrect behavior and will be lost if the code is
# regenerated.
# --------------------------------------------------------------------------

from .answer import Answer


class SearchResultsAnswer(Answer):
    """SearchResultsAnswer.

    You probably want to use the sub-classes and not this class directly. Known
    sub-classes are: WebWebAnswer

    Variables are only populated by the server, and will be ignored when
    sending a request.

    All required parameters must be populated in order to send to Azure.

    :param _type: Required. Constant filled by server.
    :type _type: str
    :ivar id: A String identifier.
    :vartype id: str
    :ivar web_search_url: The URL To Bing's search result for this item.
    :vartype web_search_url: str
github Azure / azure-sdk-for-python / azure-cognitiveservices-search-customsearch / azure / cognitiveservices / search / customsearch / models / creative_work.py View on Github external
def __init__(self, **kwargs):
        super(CreativeWork, self).__init__(**kwargs)
        self.thumbnail_url = None
        self.provider = None
        self.text = None
        self._type = 'CreativeWork'

azure-cognitiveservices-search-customsearch

Microsoft Azure Cognitive Services Custom Search Client Library for Python

MIT
Latest version published 5 months ago

Package Health Score

78 / 100
Full package analysis

Popular azure-cognitiveservices-search-customsearch functions

Similar packages