Skip to content

Commit 5cfc6d1

Browse files
Google APIscopybara-github
authored andcommitted
feat: added GitIntegrationSettings to the Agent
PiperOrigin-RevId: 546946304
1 parent a04c947 commit 5cfc6d1

3 files changed

Lines changed: 64 additions & 4 deletions

File tree

google/cloud/dialogflow/cx/v3/agent.proto

Lines changed: 60 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -188,6 +188,34 @@ message Agent {
188188
pattern: "projects/{project}/locations/{location}/agents/{agent}"
189189
};
190190

191+
// Settings for connecting to Git repository for an agent.
192+
message GitIntegrationSettings {
193+
// Settings of integration with GitHub.
194+
message GithubSettings {
195+
// The unique repository display name for the GitHub repository.
196+
string display_name = 1;
197+
198+
// The GitHub repository URI related to the agent.
199+
string repository_uri = 2;
200+
201+
// The branch of GitHub repository tracked for this agent.
202+
string tracking_branch = 3;
203+
204+
// The access token used to authenticate the access to the GitHub
205+
// repository.
206+
string access_token = 4;
207+
208+
// A list of branches configured to be used from Dialogflow.
209+
repeated string branches = 5;
210+
}
211+
212+
// The git settings to specific systems.
213+
oneof git_settings {
214+
// GitHub settings.
215+
GithubSettings github_settings = 1;
216+
}
217+
}
218+
191219
// The unique identifier of the agent.
192220
// Required for the
193221
// [Agents.UpdateAgent][google.cloud.dialogflow.cx.v3.Agents.UpdateAgent]
@@ -269,6 +297,9 @@ message Agent {
269297
// lower level overrides the settings exposed at the higher level.
270298
AdvancedSettings advanced_settings = 22;
271299

300+
// Git integration settings for this agent.
301+
GitIntegrationSettings git_integration_settings = 30;
302+
272303
// Settings on instructing the speech synthesizer on how to generate the
273304
// output audio content.
274305
TextToSpeechSettings text_to_speech_settings = 31;
@@ -374,6 +405,15 @@ message ExportAgentRequest {
374405
JSON_PACKAGE = 4;
375406
}
376407

408+
// Settings for exporting to a git branch.
409+
message GitDestination {
410+
// Tracking branch for the git push.
411+
string tracking_branch = 1;
412+
413+
// Commit message for the git push.
414+
string commit_message = 2;
415+
}
416+
377417
// Required. The name of the agent to export.
378418
// Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent ID>`.
379419
string name = 1 [
@@ -409,6 +449,9 @@ message ExportAgentRequest {
409449
}
410450
];
411451

452+
// Optional. The Git branch to export the agent to.
453+
GitDestination git_destination = 6 [(google.api.field_behavior) = OPTIONAL];
454+
412455
// Optional. Whether to include BigQuery Export setting.
413456
bool include_bigquery_export_settings = 7
414457
[(google.api.field_behavior) = OPTIONAL];
@@ -424,14 +467,27 @@ message ExportAgentResponse {
424467
// [ExportAgentRequest][google.cloud.dialogflow.cx.v3.ExportAgentRequest].
425468
string agent_uri = 1;
426469

427-
// Uncompressed raw byte content for agent.
470+
// Uncompressed raw byte content for agent. This field is populated
471+
// if none of `agent_uri` and `git_destination` are specified in
472+
// [ExportAgentRequest][google.cloud.dialogflow.cx.v3.ExportAgentRequest].
428473
bytes agent_content = 2;
474+
475+
// Commit SHA of the git push. This field is populated if
476+
// `git_destination` are specified in
477+
// [ExportAgentRequest][google.cloud.dialogflow.cx.v3.ExportAgentRequest].
478+
string commit_sha = 3;
429479
}
430480
}
431481

432482
// The request message for
433483
// [Agents.RestoreAgent][google.cloud.dialogflow.cx.v3.Agents.RestoreAgent].
434484
message RestoreAgentRequest {
485+
// Settings for restoring from a git branch
486+
message GitSource {
487+
// tracking branch for the git pull
488+
string tracking_branch = 1;
489+
}
490+
435491
// Restore option.
436492
enum RestoreOption {
437493
// Unspecified. Treated as KEEP.
@@ -471,6 +527,9 @@ message RestoreAgentRequest {
471527

472528
// Uncompressed raw byte content for agent.
473529
bytes agent_content = 3;
530+
531+
// Setting for restoring from a git branch
532+
GitSource git_source = 6;
474533
}
475534

476535
// Agent restore mode. If not specified, `KEEP` is assumed.

google/cloud/dialogflow/cx/v3/test_case.proto

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -192,7 +192,8 @@ service TestCases {
192192
};
193193
}
194194

195-
// Fetches a list of results for a given test case.
195+
// Fetches the list of run results for the given test case. A maximum of 100
196+
// results are kept for each test case.
196197
rpc ListTestCaseResults(ListTestCaseResultsRequest)
197198
returns (ListTestCaseResultsResponse) {
198199
option (google.api.http) = {

google/cloud/dialogflow/cx/v3/webhook.proto

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -182,8 +182,8 @@ message Webhook {
182182

183183
// Optional. Maps the values extracted from specific fields of the flexible
184184
// webhook response into session parameters.
185-
// - Key: session parameter name
186-
// - Value: field path in the webhook response
185+
// - Key: session parameter name
186+
// - Value: field path in the webhook response
187187
map<string, string> parameter_mapping = 9
188188
[(google.api.field_behavior) = OPTIONAL];
189189
}

0 commit comments

Comments
 (0)