Beispiel #1
0
async def sample_delete_agent():
    # Create a client
    client = dialogflow_v2beta1.AgentsAsyncClient()

    # Initialize request argument(s)
    request = dialogflow_v2beta1.DeleteAgentRequest(parent="parent_value", )

    # Make the request
    await client.delete_agent(request=request)
async def sample_get_agent():
    # Create a client
    client = dialogflow_v2beta1.AgentsAsyncClient()

    # Initialize request argument(s)
    request = dialogflow_v2beta1.GetAgentRequest(parent="parent_value", )

    # Make the request
    response = await client.get_agent(request=request)

    # Handle the response
    print(response)
Beispiel #3
0
async def sample_search_agents():
    # Create a client
    client = dialogflow_v2beta1.AgentsAsyncClient()

    # Initialize request argument(s)
    request = dialogflow_v2beta1.SearchAgentsRequest(parent="parent_value", )

    # Make the request
    page_result = client.search_agents(request=request)

    # Handle the response
    async for response in page_result:
        print(response)
async def sample_export_agent():
    # Create a client
    client = dialogflow_v2beta1.AgentsAsyncClient()

    # Initialize request argument(s)
    request = dialogflow_v2beta1.ExportAgentRequest(parent="parent_value", )

    # Make the request
    operation = client.export_agent(request=request)

    print("Waiting for operation to complete...")

    response = await operation.result()

    # Handle the response
    print(response)