Skip to content
This repository has been archived by the owner on Jul 20, 2023. It is now read-only.

Commit

Permalink
feat: Add ability to update phrase matchers feat: Add issue model sta…
Browse files Browse the repository at this point in the history
…ts to time series feat: Add display name to issue model stats (#74)

* feat: Add ability to update phrase matchers feat: Add issue model stats to time series feat: Add display name to issue model stats

PiperOrigin-RevId: 407647313

Source-Link: googleapis/googleapis@33fd29d

Source-Link: https://github.com/googleapis/googleapis-gen/commit/6abc897d85d6d22d6c4bfa31d21d7acce4048c79
Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiNmFiYzg5N2Q4NWQ2ZDIyZDZjNGJmYTMxZDIxZDdhY2NlNDA0OGM3OSJ9

* 🦉 Updates from OwlBot

See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md

Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
  • Loading branch information
gcf-owl-bot[bot] and gcf-owl-bot[bot] authored Nov 8, 2021
1 parent be2465f commit 2b9db34
Show file tree
Hide file tree
Showing 11 changed files with 901 additions and 51 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -39,15 +39,17 @@ option ruby_package = "Google::Cloud::ContactCenterInsights::V1";
// An API that lets users analyze and explore their business conversation data.
service ContactCenterInsights {
option (google.api.default_host) = "contactcenterinsights.googleapis.com";
option (google.api.oauth_scopes) = "https://www.googleapis.com/auth/cloud-platform";
option (google.api.oauth_scopes) =
"https://www.googleapis.com/auth/cloud-platform";

// Creates a conversation.
rpc CreateConversation(CreateConversationRequest) returns (Conversation) {
option (google.api.http) = {
post: "/v1/{parent=projects/*/locations/*}/conversations"
body: "conversation"
};
option (google.api.method_signature) = "parent,conversation,conversation_id";
option (google.api.method_signature) =
"parent,conversation,conversation_id";
}

// Updates a conversation.
Expand All @@ -68,15 +70,17 @@ service ContactCenterInsights {
}

// Lists conversations.
rpc ListConversations(ListConversationsRequest) returns (ListConversationsResponse) {
rpc ListConversations(ListConversationsRequest)
returns (ListConversationsResponse) {
option (google.api.http) = {
get: "/v1/{parent=projects/*/locations/*}/conversations"
};
option (google.api.method_signature) = "parent";
}

// Deletes a conversation.
rpc DeleteConversation(DeleteConversationRequest) returns (google.protobuf.Empty) {
rpc DeleteConversation(DeleteConversationRequest)
returns (google.protobuf.Empty) {
option (google.api.http) = {
delete: "/v1/{name=projects/*/locations/*/conversations/*}"
};
Expand All @@ -85,7 +89,8 @@ service ContactCenterInsights {

// Creates an analysis. The long running operation is done when the analysis
// has completed.
rpc CreateAnalysis(CreateAnalysisRequest) returns (google.longrunning.Operation) {
rpc CreateAnalysis(CreateAnalysisRequest)
returns (google.longrunning.Operation) {
option (google.api.http) = {
post: "/v1/{parent=projects/*/locations/*/conversations/*}/analyses"
body: "analysis"
Expand Down Expand Up @@ -122,7 +127,8 @@ service ContactCenterInsights {
}

// Export insights data to a destination defined in the request body.
rpc ExportInsightsData(ExportInsightsDataRequest) returns (google.longrunning.Operation) {
rpc ExportInsightsData(ExportInsightsDataRequest)
returns (google.longrunning.Operation) {
option (google.api.http) = {
post: "/v1/{parent=projects/*/locations/*}/insightsdata:export"
body: "*"
Expand All @@ -135,7 +141,8 @@ service ContactCenterInsights {
}

// Creates an issue model.
rpc CreateIssueModel(CreateIssueModelRequest) returns (google.longrunning.Operation) {
rpc CreateIssueModel(CreateIssueModelRequest)
returns (google.longrunning.Operation) {
option (google.api.http) = {
post: "/v1/{parent=projects/*/locations/*}/issueModels"
body: "issue_model"
Expand Down Expand Up @@ -165,15 +172,17 @@ service ContactCenterInsights {
}

// Lists issue models.
rpc ListIssueModels(ListIssueModelsRequest) returns (ListIssueModelsResponse) {
rpc ListIssueModels(ListIssueModelsRequest)
returns (ListIssueModelsResponse) {
option (google.api.http) = {
get: "/v1/{parent=projects/*/locations/*}/issueModels"
};
option (google.api.method_signature) = "parent";
}

// Deletes an issue model.
rpc DeleteIssueModel(DeleteIssueModelRequest) returns (google.longrunning.Operation) {
rpc DeleteIssueModel(DeleteIssueModelRequest)
returns (google.longrunning.Operation) {
option (google.api.http) = {
delete: "/v1/{name=projects/*/locations/*/issueModels/*}"
};
Expand All @@ -186,7 +195,8 @@ service ContactCenterInsights {

// Deploys an issue model. Returns an error if a model is already deployed.
// An issue model can only be used in analysis after it has been deployed.
rpc DeployIssueModel(DeployIssueModelRequest) returns (google.longrunning.Operation) {
rpc DeployIssueModel(DeployIssueModelRequest)
returns (google.longrunning.Operation) {
option (google.api.http) = {
post: "/v1/{name=projects/*/locations/*/issueModels/*}:deploy"
body: "*"
Expand All @@ -200,7 +210,8 @@ service ContactCenterInsights {

// Undeploys an issue model.
// An issue model can not be used in analysis after it has been undeployed.
rpc UndeployIssueModel(UndeployIssueModelRequest) returns (google.longrunning.Operation) {
rpc UndeployIssueModel(UndeployIssueModelRequest)
returns (google.longrunning.Operation) {
option (google.api.http) = {
post: "/v1/{name=projects/*/locations/*/issueModels/*}:undeploy"
body: "*"
Expand Down Expand Up @@ -238,7 +249,8 @@ service ContactCenterInsights {
}

// Gets an issue model's statistics.
rpc CalculateIssueModelStats(CalculateIssueModelStatsRequest) returns (CalculateIssueModelStatsResponse) {
rpc CalculateIssueModelStats(CalculateIssueModelStatsRequest)
returns (CalculateIssueModelStatsResponse) {
option (google.api.http) = {
get: "/v1/{issue_model=projects/*/locations/*/issueModels/*}:calculateIssueModelStats"
};
Expand All @@ -263,21 +275,32 @@ service ContactCenterInsights {
}

// Lists phrase matchers.
rpc ListPhraseMatchers(ListPhraseMatchersRequest) returns (ListPhraseMatchersResponse) {
rpc ListPhraseMatchers(ListPhraseMatchersRequest)
returns (ListPhraseMatchersResponse) {
option (google.api.http) = {
get: "/v1/{parent=projects/*/locations/*}/phraseMatchers"
};
option (google.api.method_signature) = "parent";
}

// Deletes a phrase matcher.
rpc DeletePhraseMatcher(DeletePhraseMatcherRequest) returns (google.protobuf.Empty) {
rpc DeletePhraseMatcher(DeletePhraseMatcherRequest)
returns (google.protobuf.Empty) {
option (google.api.http) = {
delete: "/v1/{name=projects/*/locations/*/phraseMatchers/*}"
};
option (google.api.method_signature) = "name";
}

// Updates a phrase matcher.
rpc UpdatePhraseMatcher(UpdatePhraseMatcherRequest) returns (PhraseMatcher) {
option (google.api.http) = {
patch: "/v1/{phrase_matcher.name=projects/*/locations/*/phraseMatchers/*}"
body: "phrase_matcher"
};
option (google.api.method_signature) = "phrase_matcher,update_mask";
}

// Gets conversation statistics.
rpc CalculateStats(CalculateStatsRequest) returns (CalculateStatsResponse) {
option (google.api.http) = {
Expand Down Expand Up @@ -379,6 +402,11 @@ message CalculateStatsResponse {
// Deprecated, use `issue_matches_stats` field instead.
map<string, int32> issue_matches = 6 [deprecated = true];

// A map associating each issue resource name with its respective number of
// matches in the set of conversations. Key has the format:
// `projects/<ProjectID>/locations/<LocationID>/issueModels/<IssueModelID>/issues/<IssueID>`
map<string, IssueModelLabelStats.IssueStats> issue_matches_stats = 8;

// A time series representing the count of conversations created over time
// that match that requested filter criteria.
TimeSeries conversation_count_time_series = 7;
Expand All @@ -387,10 +415,12 @@ message CalculateStatsResponse {
// Metadata for a create analysis operation.
message CreateAnalysisOperationMetadata {
// Output only. The time the operation was created.
google.protobuf.Timestamp create_time = 1 [(google.api.field_behavior) = OUTPUT_ONLY];
google.protobuf.Timestamp create_time = 1
[(google.api.field_behavior) = OUTPUT_ONLY];

// Output only. The time the operation finished running.
google.protobuf.Timestamp end_time = 2 [(google.api.field_behavior) = OUTPUT_ONLY];
google.protobuf.Timestamp end_time = 2
[(google.api.field_behavior) = OUTPUT_ONLY];

// Output only. The Conversation that this Analysis Operation belongs to.
string conversation = 3 [
Expand Down Expand Up @@ -583,9 +613,9 @@ message ExportInsightsDataRequest {
// the resource project will be used.
string project_id = 3;

// Required. The name of the BigQuery dataset that the snapshot result should be
// exported to. If this dataset does not exist, the export call returns an
// INVALID_ARGUMENT error.
// Required. The name of the BigQuery dataset that the snapshot result
// should be exported to. If this dataset does not exist, the export call
// returns an INVALID_ARGUMENT error.
string dataset = 1 [(google.api.field_behavior) = REQUIRED];

// The BigQuery table name to which the insights data should be written.
Expand Down Expand Up @@ -621,10 +651,12 @@ message ExportInsightsDataRequest {
// Metadata for an export insights operation.
message ExportInsightsDataMetadata {
// Output only. The time the operation was created.
google.protobuf.Timestamp create_time = 1 [(google.api.field_behavior) = OUTPUT_ONLY];
google.protobuf.Timestamp create_time = 1
[(google.api.field_behavior) = OUTPUT_ONLY];

// Output only. The time the operation finished running.
google.protobuf.Timestamp end_time = 2 [(google.api.field_behavior) = OUTPUT_ONLY];
google.protobuf.Timestamp end_time = 2
[(google.api.field_behavior) = OUTPUT_ONLY];

// The original request for export.
ExportInsightsDataRequest request = 3;
Expand All @@ -635,9 +667,7 @@ message ExportInsightsDataMetadata {
}

// Response for an export insights operation.
message ExportInsightsDataResponse {

}
message ExportInsightsDataResponse {}

// The request to create an issue model.
message CreateIssueModelRequest {
Expand All @@ -656,10 +686,12 @@ message CreateIssueModelRequest {
// Metadata for creating an issue model.
message CreateIssueModelMetadata {
// Output only. The time the operation was created.
google.protobuf.Timestamp create_time = 1 [(google.api.field_behavior) = OUTPUT_ONLY];
google.protobuf.Timestamp create_time = 1
[(google.api.field_behavior) = OUTPUT_ONLY];

// Output only. The time the operation finished running.
google.protobuf.Timestamp end_time = 2 [(google.api.field_behavior) = OUTPUT_ONLY];
google.protobuf.Timestamp end_time = 2
[(google.api.field_behavior) = OUTPUT_ONLY];

// The original request for creation.
CreateIssueModelRequest request = 3;
Expand Down Expand Up @@ -716,10 +748,12 @@ message DeleteIssueModelRequest {
// Metadata for deleting an issue model.
message DeleteIssueModelMetadata {
// Output only. The time the operation was created.
google.protobuf.Timestamp create_time = 1 [(google.api.field_behavior) = OUTPUT_ONLY];
google.protobuf.Timestamp create_time = 1
[(google.api.field_behavior) = OUTPUT_ONLY];

// Output only. The time the operation finished running.
google.protobuf.Timestamp end_time = 2 [(google.api.field_behavior) = OUTPUT_ONLY];
google.protobuf.Timestamp end_time = 2
[(google.api.field_behavior) = OUTPUT_ONLY];

// The original request for deletion.
DeleteIssueModelRequest request = 3;
Expand All @@ -737,17 +771,17 @@ message DeployIssueModelRequest {
}

// The response to deploy an issue model.
message DeployIssueModelResponse {

}
message DeployIssueModelResponse {}

// Metadata for deploying an issue model.
message DeployIssueModelMetadata {
// Output only. The time the operation was created.
google.protobuf.Timestamp create_time = 1 [(google.api.field_behavior) = OUTPUT_ONLY];
google.protobuf.Timestamp create_time = 1
[(google.api.field_behavior) = OUTPUT_ONLY];

// Output only. The time the operation finished running.
google.protobuf.Timestamp end_time = 2 [(google.api.field_behavior) = OUTPUT_ONLY];
google.protobuf.Timestamp end_time = 2
[(google.api.field_behavior) = OUTPUT_ONLY];

// The original request for deployment.
DeployIssueModelRequest request = 3;
Expand All @@ -765,17 +799,17 @@ message UndeployIssueModelRequest {
}

// The response to undeploy an issue model.
message UndeployIssueModelResponse {

}
message UndeployIssueModelResponse {}

// Metadata for undeploying an issue model.
message UndeployIssueModelMetadata {
// Output only. The time the operation was created.
google.protobuf.Timestamp create_time = 1 [(google.api.field_behavior) = OUTPUT_ONLY];
google.protobuf.Timestamp create_time = 1
[(google.api.field_behavior) = OUTPUT_ONLY];

// Output only. The time the operation finished running.
google.protobuf.Timestamp end_time = 2 [(google.api.field_behavior) = OUTPUT_ONLY];
google.protobuf.Timestamp end_time = 2
[(google.api.field_behavior) = OUTPUT_ONLY];

// The original request for undeployment.
UndeployIssueModelRequest request = 3;
Expand Down Expand Up @@ -838,10 +872,10 @@ message CalculateIssueModelStatsResponse {

// Request to create a phrase matcher.
message CreatePhraseMatcherRequest {
// Required. The parent resource of the phrase matcher. Required. The location to create
// a phrase matcher for.
// Format: `projects/<Project ID>/locations/<Location ID>` or
// `projects/<Project Number>/locations/<Location ID>`
// Required. The parent resource of the phrase matcher. Required. The location
// to create a phrase matcher for. Format: `projects/<Project
// ID>/locations/<Location ID>` or `projects/<Project
// Number>/locations/<Location ID>`
string parent = 1 [
(google.api.field_behavior) = REQUIRED,
(google.api.resource_reference) = {
Expand Down Expand Up @@ -911,6 +945,15 @@ message DeletePhraseMatcherRequest {
];
}

// The request to update a phrase matcher.
message UpdatePhraseMatcherRequest {
// Required. The new values for the phrase matcher.
PhraseMatcher phrase_matcher = 1 [(google.api.field_behavior) = REQUIRED];

// The list of fields to be updated.
google.protobuf.FieldMask update_mask = 2;
}

// The request to get project-level settings.
message GetSettingsRequest {
// Required. The name of the settings resource to get.
Expand All @@ -928,5 +971,6 @@ message UpdateSettingsRequest {
Settings settings = 1 [(google.api.field_behavior) = REQUIRED];

// Required. The list of fields to be updated.
google.protobuf.FieldMask update_mask = 2 [(google.api.field_behavior) = REQUIRED];
google.protobuf.FieldMask update_mask = 2
[(google.api.field_behavior) = REQUIRED];
}
3 changes: 3 additions & 0 deletions protos/google/cloud/contactcenterinsights/v1/resources.proto
Original file line number Diff line number Diff line change
Expand Up @@ -678,6 +678,9 @@ message IssueModelLabelStats {

// Number of conversations attached to the issue at this point in time.
int64 labeled_conversations_count = 2;

// Display name of the issue.
string display_name = 3;
}

// Number of conversations the issue model has analyzed at this point in time.
Expand Down
Loading

0 comments on commit 2b9db34

Please sign in to comment.