Skip to content

Dialogflow tool new - #18235

Open
matt-degraffenreid wants to merge 11 commits into
GoogleCloudPlatform:mainfrom
matt-degraffenreid:dialogflow-tool-new
Open

Dialogflow tool new#18235
matt-degraffenreid wants to merge 11 commits into
GoogleCloudPlatform:mainfrom
matt-degraffenreid:dialogflow-tool-new

Conversation

@matt-degraffenreid

@matt-degraffenreid matt-degraffenreid commented Jul 9, 2026

Copy link
Copy Markdown

Release Note Template for Downstream PRs (will be copied)

See Write release notes for guidance.

`google_dialogflow_tool`

Added support for freeFormContext, agentCoachingContext, translationContext, agentFeedbackContext, and customerMessageGenerationContext.

Enforced mutual exclusivity using exactly_one_of.

Made summarizationContext optional (non-breaking).

Added timeouts and tunedModel support.
Added 'tools' property to Generator.yaml and updated samples to demonstrate linkage.

Fixed pre-existing errors in Tool connector and datastore samples.
- Update summarizationContext.version candidates in Generator.yaml to 5.0 and 6.0
- Update versions in samples to 6.0
- Update versions in handwritten tests to 5.0 and 6.0
- Add valid path to dialogflow_generator_with_tools OpenAPI spec
@modular-magician modular-magician added the awaiting-approval Pull requests that need reviewer's approval to run presubmit tests label Jul 9, 2026
@matt-degraffenreid
matt-degraffenreid marked this pull request as ready for review July 9, 2026 17:44
@github-actions
github-actions Bot requested a review from SirGitsalot July 9, 2026 17:44
@github-actions

github-actions Bot commented Jul 9, 2026

Copy link
Copy Markdown

Googlers: For automatic test runs see go/terraform-auto-test-runs.

@SirGitsalot, a repository maintainer, has been assigned to review your changes. If you have not received review feedback within 2 business days, please leave a comment on this PR asking them to take a look.

You can help make sure that review is quick by doing a self-review and by running impacted tests locally.

@github-actions

Copy link
Copy Markdown

@SirGitsalot This PR has been waiting for review for 3 weekdays. Please take a look! Use the label disable-review-reminders to disable these notifications.

@SirGitsalot SirGitsalot left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seems generally sound, but you need to add some sample tests

@github-actions

Copy link
Copy Markdown

@matt-degraffenreid, this PR is waiting for action from you. If no action is taken, this PR will be closed in 28 days.

Please address any comments or change requests, or re-request review from a core reviewer if no action is required.

Image showing the re-request review button

This notification can be disabled with the disable-automatic-closure label.

@github-actions

Copy link
Copy Markdown

@matt-degraffenreid, this PR is waiting for action from you. If no action is taken, this PR will be closed in 14 days.

Please address any comments or change requests, or re-request review from a core reviewer if no action is required.

Image showing the re-request review button

This notification can be disabled with the disable-automatic-closure label.

@github-actions
github-actions Bot requested a review from SirGitsalot August 11, 2026 19:51
@modular-magician modular-magician removed the awaiting-approval Pull requests that need reviewer's approval to run presubmit tests label Aug 11, 2026
Implemented google_dialogflow_tool resource in MMv1 with support for open_api_spec.
Added function_spec, connector_spec, and data_store_spec to Tool.yaml. Configured authentication options and marked sensitive fields. Also recorded
@modular-magician

modular-magician commented Aug 11, 2026

Copy link
Copy Markdown
Collaborator

Hi there, I'm the Modular magician. I've detected the following information about your changes for commit 6e5b0e2:

Diff report

Your PR generated the following diffs in downstream repositories:

Repository Diff Link Changes
google provider View Diff 3 files changed, 2132 insertions(+)
google-beta provider View Diff 3 files changed, 2132 insertions(+)
terraform-google-conversion View Diff 1 file changed, 653 insertions(+)

Missing test report

Your PR includes resource fields which are not covered by any test.

Resource: google_dialogflow_tool (0 total tests)
Please add an acceptance test which includes these fields. The test should include the following:

resource "google_dialogflow_tool" "primary" {
  connector_spec {
    actions {
      connection_action_id = # value needed
      entity_operation {
        entity_id = # value needed
        operation = # value needed
      }
      input_fields  = # value needed
      output_fields = # value needed
    }
    name = # value needed
  }
  data_store_spec {
    data_store_connections {
      data_store               = # value needed
      data_store_type          = # value needed
      document_processing_mode = # value needed
    }
  }
  description  = # value needed
  display_name = # value needed
  function_spec {
    input_schema  = # value needed
    output_schema = # value needed
  }
  location = # value needed
  open_api_spec {
    authentication {
      api_key_config {
        api_key          = # value needed
        key_name         = # value needed
        request_location = # value needed
      }
      bearer_token_config {
        token = # value needed
      }
      oauth_config {
        client_id        = # value needed
        client_secret    = # value needed
        oauth_grant_type = # value needed
        scopes           = # value needed
        token_endpoint   = # value needed
      }
      service_agent_auth_config {
        service_agent_auth = # value needed
      }
    }
    text_schema = # value needed
  }
  tool_key = # value needed
}

Missing service labels

The following new resources do not have corresponding service labels:

  • google_dialogflow_tool

If you believe this detection to be incorrect please raise the concern with your reviewer. Googlers: This error is safe to ignore once you've completed go/fix-missing-service-labels.
An override-missing-service-label label can be added to allow merging.

Test report

Analytics

Total Tests Passed Skipped Affected
22 22 0 0
Affected Service Packages
  • dialogflow

Learn how VCR tests work


Step 1: Replaying Mode

🟢 All tests passed in Replaying mode! No Recording was needed.

View the replaying VCR build log

@matt-degraffenreid, @SirGitsalot VCR tests complete for 6e5b0e2!

Added a basic sample template for Dialogflow Tool and updated existing samples with the required tool_key. Added the basic sample to Tool.yaml.
Added samples covering all branches of specification and authentication unions for Dialogflow Tool. Added google_dialogflow_tool to service/dialogflow-cx in enrolled_teams.yml to fix missing service label.
@modular-magician modular-magician added awaiting-approval Pull requests that need reviewer's approval to run presubmit tests service/dialogflow-cx labels Aug 11, 2026
@modular-magician

modular-magician commented Aug 11, 2026

Copy link
Copy Markdown
Collaborator

Hi there, I'm the Modular magician. I've detected the following information about your changes for commit dae1c34:

Diff report

Your PR generated the following diffs in downstream repositories:

Repository Diff Link Changes
google provider View Diff 8 files changed, 4140 insertions(+), 252 deletions(-)
google-beta provider View Diff 9 files changed, 4295 insertions(+), 252 deletions(-)
terraform-google-conversion View Diff 2 files changed, 1252 insertions(+)
Open in Cloud Shell View Diff 9 files changed, 243 insertions(+), 1 deletion(-)

Breaking Change(s) Detected

The following breaking change(s) were detected within your pull request.

  • Field published_model within resource google_dialogflow_generator was added to exactly one of - reference
  • Field tuned_model within resource google_dialogflow_generator was added to exactly one of - reference

If you believe this detection to be incorrect please raise the concern with your reviewer.
If you intend to make this change you will need to wait for a major release window.
An override-breaking-change label can be added to allow merging.

Missing test report

Your PR includes resource fields which are not covered by any test.

Resource: google_dialogflow_generator (6 total tests)
Please add an acceptance test which includes these fields. The test should include the following:

resource "google_dialogflow_generator" "primary" {
  agent_coaching_context {
    instructions {
      agent_action     = # value needed
      condition        = # value needed
      display_details  = # value needed
      display_name     = # value needed
      system_action    = # value needed
      triggering_event = # value needed
    }
    output_language_code = # value needed
    search_config {
      datastores    = # value needed
      search_engine = # value needed
    }
  }
  agent_feedback_context {
    instructions {
      agent_action     = # value needed
      condition        = # value needed
      display_details  = # value needed
      display_name     = # value needed
      system_action    = # value needed
      triggering_event = # value needed
    }
    version = # value needed
  }
  customer_message_generation_context {
    customization {
      scenario = # value needed
    }
    version = # value needed
  }
  free_form_context {
    text = # value needed
  }
  translation_context {
    agent_language_code    = # value needed
    customer_language_code = # value needed
    translation_customization {
      glossary_terms {
        agent_language_glossary    = # value needed
        customer_language_glossary = # value needed
      }
      sentence_translations {
        agent_language_sentence    = # value needed
        customer_language_sentence = # value needed
      }
    }
    version = # value needed
  }
  tuned_model = # value needed
}

Resource: google_dialogflow_tool (2 total tests)
Please add an acceptance test which includes these fields. The test should include the following:

resource "google_dialogflow_tool" "primary" {
  connector_spec {
    actions {
      connection_action_id = # value needed
      entity_operation {
        entity_id = # value needed
        operation = # value needed
      }
      input_fields  = # value needed
      output_fields = # value needed
    }
    name = # value needed
  }
  data_store_spec {
    data_store_connections {
      data_store               = # value needed
      data_store_type          = # value needed
      document_processing_mode = # value needed
    }
  }
  function_spec {
    input_schema  = # value needed
    output_schema = # value needed
  }
  open_api_spec {
    authentication {
      api_key_config {
        api_key          = # value needed
        key_name         = # value needed
        request_location = # value needed
      }
      bearer_token_config {
        token = # value needed
      }
      oauth_config {
        client_id        = # value needed
        client_secret    = # value needed
        oauth_grant_type = # value needed
        scopes           = # value needed
        token_endpoint   = # value needed
      }
      service_agent_auth_config {
        service_agent_auth = # value needed
      }
    }
  }
}

Missing service labels

The following new resources do not have corresponding service labels:

  • google_dialogflow_tool

If you believe this detection to be incorrect please raise the concern with your reviewer. Googlers: This error is safe to ignore once you've completed go/fix-missing-service-labels.
An override-missing-service-label label can be added to allow merging.

Test report

Analytics

Total Tests Passed Skipped Affected
25 19 0 6
Affected Service Packages
  • dialogflow

Learn how VCR tests work


Step 1: Replaying Mode

Action taken

Found 6 affected test(s) by replaying old test recordings. Starting RECORDING based on the most recent commit.

Click here to see the affected tests
  • TestAccDialogflowGenerator_dialogflowGeneratorAgentCoachingExample
  • TestAccDialogflowGenerator_dialogflowGeneratorBasicExample
  • TestAccDialogflowGenerator_dialogflowGeneratorWithToolsExample
  • TestAccDialogflowGenerator_regional
  • TestAccDialogflowGenerator_update
  • TestAccDialogflowTool_dialogflowToolBasicExample

View the replaying VCR build log


Step 2: Recording Mode

Recording Mode Replaying Rerun Test Name
✅ Log TestAccDialogflowGenerator_update
❌ Error · Log - TestAccDialogflowGenerator_dialogflowGeneratorAgentCoachingExample
❌ Error · Log - TestAccDialogflowGenerator_dialogflowGeneratorBasicExample
❌ Error · Log - TestAccDialogflowGenerator_dialogflowGeneratorWithToolsExample
❌ Error · Log - TestAccDialogflowGenerator_regional
❌ Error · Log - TestAccDialogflowTool_dialogflowToolBasicExample

Caution

Issues requiring attention before PR completion

🔴 Initial Recording Failed: Some tests failed during the recording step. See the table above for details.

Please address these issues to complete your PR. If you believe these detections are incorrect or unrelated to your change, please raise the concern with your reviewer.

View the recording VCR build log or the debug logs folder for detailed results.

@matt-degraffenreid, @SirGitsalot VCR tests complete for dae1c34!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

awaiting-approval Pull requests that need reviewer's approval to run presubmit tests service/dialogflow-cx

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants