{"id":45029,"library":"google-cloud-dialogflow","title":"Google Cloud Dialogflow","description":"Google Cloud Dialogflow API client library (v2.48.0) for building conversational interfaces (chatbots, IVR). Released monthly. Requires Python >=3.10.","status":"active","version":"2.48.0","language":"python","source_language":"en","source_url":"https://github.com/googleapis/google-cloud-python/tree/main/packages/google-cloud-dialogflow","tags":["dialogflow","chatbot","nlp","conversational-ai"],"install":[{"cmd":"pip install google-cloud-dialogflow","lang":"bash","label":"Install with pip"}],"dependencies":[{"reason":"Core Google API infrastructure","package":"google-api-core","optional":false},{"reason":"gRPC transport for API calls","package":"grpcio","optional":false},{"reason":"Storing audio files for streaming recognition","package":"google-cloud-storage","optional":true}],"imports":[{"note":"Direct import of client classes from submodule avoids ambiguity.","wrong":"from google.cloud import dialogflow_v2","symbol":"SessionsClient","correct":"from google.cloud.dialogflow_v2 import SessionsClient"},{"note":"","wrong":"","symbol":"QueryResult","correct":"from google.cloud.dialogflow_v2.types import QueryResult"},{"note":"","wrong":"","symbol":"IntentsClient","correct":"from google.cloud.dialogflow_v2 import IntentsClient"}],"quickstart":{"code":"import os\nfrom google.cloud.dialogflow_v2 import SessionsClient\n\nproject_id = os.environ.get('GOOGLE_CLOUD_PROJECT', 'my-project')\nsession_id = 'test-session'\ntext = 'Hello'\nlanguage_code = 'en'\n\nclient = SessionsClient()\nsession = client.session_path(project_id, session_id)\ntext_input = {'text': {'text': text, 'language_code': language_code}}\nquery_input = {'text': text_input['text']}\nresponse = client.detect_intent(request={'session': session, 'query_input': query_input})\nprint('Query:', response.query_result.query_text)\nprint('Response:', response.query_result.fulfillment_text)","lang":"python","description":"Detect intent from a text query. Ensure GOOGLE_CLOUD_PROJECT env var is set and credentials configured (gcloud auth application-default-login)."},"warnings":[{"fix":"Update imports to from google.cloud.dialogflow_v2 import ... and update method signatures.","message":"google-cloud-dialogflow v2 uses the v2 API; v1 is deprecated and will be removed. Migrate from v1 imports (google.cloud.dialogflow) to v2 (google.cloud.dialogflow_v2).","severity":"breaking","affected_versions":"<=1.x"},{"fix":"Ensure agent is deployed in the same region as the client endpoint (default: global).","message":"region and language_code parameters in detect_intent must match globally available agent; otherwise request fails with 400 INVALID_ARGUMENT.","severity":"gotcha","affected_versions":"all"},{"fix":"Import from google.cloud.dialogflow_v2 instead.","message":"Using google.cloud.dialogflow (without version) is deprecated; always specify the version (v2) in imports.","severity":"deprecated","affected_versions":">=2.0"}],"env_vars":null,"search_vec":"'3.10':21 'ai':27 'api':7 'build':12 'chatbot':15,23 'client':8 'cloud':2,5 'convers':13,26 'conversational-ai':25 'dialogflow':3,6,22 'googl':1,4 'interfac':14 'ivr':16 'librari':9 'month':18 'nlp':24 'python':20 'releas':17 'requir':19 'v2.48.0':10","created_at":"2026-06-07T12:53:00.980431+00:00","updated_at":"2026-06-07T12:53:00.980431+00:00","problems":[{"fix":"Set environment variable GOOGLE_APPLICATION_CREDENTIALS to a service account JSON file with 'Dialogflow API Client' role.","cause":"Default application credentials (ADC) do not include Dialogflow API scope.","error":"google.api_core.exceptions.PermissionDenied: 403 Request had insufficient authentication scopes."},{"fix":"Use a simple alphanumeric session ID (e.g., 'test-session-1') without special characters.","cause":"The session_id does not exist; sessions are created on-the-fly but must be alphanumeric.","error":"google.api_core.exceptions.InvalidArgument: 400 Session path not found."},{"fix":"Pass request as a keyword argument: client.detect_intent(request={'session': ..., 'query_input': ...})","cause":"Using old-style positional arguments instead of dict-based request parameter.","error":"TypeError: __init__() got an unexpected keyword argument 'request'"}],"ecosystem":"pypi","meta_description":null,"install_score":null,"quickstart_score":null,"quickstart_tag":null,"pypi_latest":null,"cli_name":null,"cli_version":null,"type":"library","homepage":"https://github.com/googleapis/google-cloud-python/tree/main/packages/google-cloud-dialogflow","github":"https://github.com/googleapis/google-cloud-python/tree/main/packages/google-cloud-dialogflow","docs":null,"changelog":null,"pypi":null,"npm":null,"openapi_spec":null,"status_page":null,"smithery":null,"categories":["ai-ml"],"base_url":null,"auth_type":null,"provenance":{"verified_status":"passing","verified_at":"2026-06-29","last_verified":"2026-06-29","next_check":"2026-07-29","install_tag":null}}