diff --git a/google/cloud/irm/irm_v1alpha2.yaml b/google/cloud/irm/irm_v1alpha2.yaml index ad25d24b..114308b3 100644 --- a/google/cloud/irm/irm_v1alpha2.yaml +++ b/google/cloud/irm/irm_v1alpha2.yaml @@ -4,7 +4,13 @@ name: irm.googleapis.com title: Stackdriver Incident Response & Management API apis: -- name: google.cloud.irm.v1alpha2.IncidentService + - name: google.cloud.irm.v1alpha2.IncidentService + +types: + - name: google.cloud.irm.v1alpha2.User + - name: google.cloud.irm.v1alpha2.Synopsis + - name: google.cloud.irm.v1alpha2.IncidentRole + - name: google.cloud.irm.v1alpha2.CommunicationChannel documentation: overview: |- @@ -13,6 +19,7 @@ documentation: authentication: rules: - - selector: '*' - oauth: - canonical_scopes: https://www.googleapis.com/auth/cloud-platform + - selector: '*' + oauth: + canonical_scopes: |- + https://www.googleapis.com/auth/cloud-platform diff --git a/google/cloud/irm/v1alpha2/incidents.proto b/google/cloud/irm/v1alpha2/incidents.proto index 4397a998..af258ddb 100644 --- a/google/cloud/irm/v1alpha2/incidents.proto +++ b/google/cloud/irm/v1alpha2/incidents.proto @@ -19,6 +19,7 @@ package google.cloud.irm.v1alpha2; import "google/api/annotations.proto"; import "google/monitoring/v3/metric_service.proto"; +import "google/protobuf/duration.proto"; import "google/protobuf/timestamp.proto"; option cc_enable_arenas = true; @@ -26,14 +27,13 @@ option go_package = "google.golang.org/genproto/googleapis/cloud/irm/v1alpha2;ir option java_multiple_files = true; option java_package = "com.google.irm.service.v1alpha2.api"; - // A user of the IRM app. message User { // One of several ways to uniquely identify a user. oneof user { // Output only. User id that will allow to get additional information from // People API. This field will be populated implicitly if the caller creates - // or edits a resource (e.g. posts an annotation). + // or edits a resource (for example, posts an annotation). string user_id = 1; // Email address of the user. This must be associated with a Google account. @@ -46,8 +46,19 @@ message User { // A signal is a message calling attention to a (potential) incident. An example // is a page based on a Stackdriver Alerting policy. -// go/irm-glossary#signal message Signal { + // An artifact associated with the Signal. + message SignalArtifact { + // The type of resource linked to + oneof artifact_type { + // A custom user type + string user_type = 2; + } + + // The URI for the artifact. + string uri = 3; + } + // Describes whether the alerting condition is still firing. enum State { // Unspecified @@ -60,7 +71,7 @@ message Signal { STATE_CLOSED = 2; } - // Resource name of the signal, e.g. + // Resource name of the signal, for example, // "projects/{project_id}/signals/{signal_id}". string name = 1; @@ -75,29 +86,43 @@ message Signal { // Output only. Time this signal was created. google.protobuf.Timestamp create_time = 4; + // Output only. Time this signal was closed. This field is not populated + // while the signal is still firing. + google.protobuf.Timestamp close_time = 10; + + // The time this Signal was first detected. This is identical to create_time + // for Signals created by Stackdriver Alerting. + google.protobuf.Timestamp detect_time = 15; + // Output only. The user that created this signal for manually created - // signals. Empty if this signal was generated by a system (e.g. an - // alerting system). + // signals. Empty if this signal was generated by a system (for example, + // Stackdriver Alerting). User creator = 5; // One-line summary of the signal. // Immutable. string title = 6; - // Content type string, e.g. 'text/plain' or'text/html'. + // Content type string, for example, 'text/plain' or'text/html'. string content_type = 7; // Full message of the signal. - // Immutable. + // Immutable for Signals created by Stackdriver Alerting. string content = 8; - // Output only. The state of this signal. + // The state of this signal. + // For Signals created by Stackdriver Alerting this field is output only. State signal_state = 9; + + // A set of artifacts to additional resources for this Signal. For example, a + // link to Stackdriver logging for the Signal. + // Immutable for Signals created by Stackdriver Alerting. + repeated SignalArtifact signal_artifacts = 16; } // A text annotation by a user. message Annotation { - // Resource name of the annotation, e.g. + // Resource name of the annotation, for example, // "projects/{project_id}/incidents/{incident_id}/annotations/{annotation_id}". string name = 1; @@ -113,22 +138,18 @@ message Annotation { // A tag by a user. message Tag { - // Resource name of a tag, e.g., + // Resource name of a tag, for example, // "projects/{project_id}/incidents/{incident_id}/tags/{tag_id}" string name = 1; - // Display name of the resource (e.g., "cause:rollout"). Immutable. + // Display name of the resource (for example, "cause:rollout"). Immutable. string display_name = 2; - - // Output only. For some tags (e.g., "bug:123"), provide a link to the - // underlying resource. Optional. - string url = 3; } // Synopsis is a summary of an incident and it contains a textual content, // an author and a last updated timestamp. message Synopsis { - // Content type string, e.g. 'text/plain' or 'text/html'. + // Content type string, for example, 'text/plain' or 'text/html'. string content_type = 1; // Textual content of the synopsis. It can be plain text or markdown as @@ -144,6 +165,31 @@ message Synopsis { // Representation of an incident. message Incident { + // CommunicationVenue is a record of where conversations about an incident + // are happening. + message CommunicationVenue { + // The type of channel/venue for incident communications. + enum ChannelType { + // An unspecified communication channel. + CHANNEL_TYPE_UNSPECIFIED = 0; + + // A communication channel that is represented by a generic URI. + CHANNEL_TYPE_URI = 1; + + // A communication channel that represents a Slack channel. + CHANNEL_TYPE_SLACK = 5; + } + + // A URI to the web interface of the channel. + string uri = 1; + + // A name representing the channel in IRM UI. + string display_name = 2; + + // The type of channel/venue for incident communications. + ChannelType channel_type = 3; + } + // Specifies the escalation level of this incident, within the IRM protocol // for handling incidents. enum EscalationLevel { @@ -200,9 +246,14 @@ message Incident { // Postmortem for the incident was written. STAGE_DOCUMENTED = 5; + + // Stage for an incident with `duplicate_incident`. This incident is not + // authoritative anymore and the `duplicate_incident` should be used to + // determine the stage. + STAGE_DUPLICATE = 6; } - // Output only. Resource name of the incident, e.g. + // Output only. Resource name of the incident, for example, // "projects/{project_id}/incidents/{incident_id}". string name = 1; @@ -222,6 +273,14 @@ message Incident { // Stage of the incident. Stage stage = 6; + // Resource name of the incident this incident is a duplicate of. Empty if + // this incident is not a duplicate. + // An incident can only be a duplicate of an incident that is not marked as a + // duplicate already. Setting this to a non-empty value must also set the + // stage to `STAGE_DUPLICATE`. Unsetting this value value must also update + // `stage` to a value other than `STAGE_DUPLICATE`. + string duplicate_incident = 9; + // Output only. Time this incident started. Used to measure the 'elapsed // time'. Start time of an incident is the earliest creation time of any of // its Signals or the create time of the incident if no Signals are assigned. @@ -229,6 +288,10 @@ message Incident { // Output only. Synopsis of this incident. Synopsis synopsis = 8; + + // Location of communications for this incident. This is informational + // only; IRM does not use this to send messages. + CommunicationVenue communication_venue = 10; } // Describes a role that can be assigned to an incident. @@ -310,8 +373,8 @@ message IncidentRoleAssignment { // If she cancels, then the RoleAssignment is deleted. // Let's say Alice has the role. Then the fields are: // `assignee`: Alice, `proposed_assignee`: nil - // If Alice is hit by a bus and Bob requests Carol to take over, then the - // fields are: + // If Alice becomes incapacitated and Bob requests Carol to take over, then + // the fields are: // `assignee`: Alice, `proposed_assignee`: Carol // After Carol accepts the handover, the fields are: // `assignee`: Carol, `proposed_assignee`: nil @@ -330,12 +393,6 @@ message Artifact { // URL. TYPE_URL = 1; - // An issue. - TYPE_ISSUE = 2; - - // A source control change. - TYPE_SOURCE_CONTROL_CHANGE = 3; - // A JIRA issue. TYPE_JIRA_ISSUE = 4; } @@ -364,7 +421,7 @@ message Artifact { message CommunicationChannel { // A communication channel that delivers messages to an email address. message Email { - // The email address, e.g. "user@example.com". + // The email address, for example, "user@example.com". string address = 1; } diff --git a/google/cloud/irm/v1alpha2/incidents_service.proto b/google/cloud/irm/v1alpha2/incidents_service.proto index b6c89393..e6cf4407 100644 --- a/google/cloud/irm/v1alpha2/incidents_service.proto +++ b/google/cloud/irm/v1alpha2/incidents_service.proto @@ -28,7 +28,6 @@ option go_package = "google.golang.org/genproto/googleapis/cloud/irm/v1alpha2;ir option java_multiple_files = true; option java_package = "com.google.irm.service.v1alpha2.api"; - // The Incident API for Incident Response & Management. service IncidentService { // Creates a new incident. @@ -48,7 +47,8 @@ service IncidentService { // Returns a list of incidents. // Incidents are ordered by start time, with the most recent incidents first. - rpc SearchIncidents(SearchIncidentsRequest) returns (SearchIncidentsResponse) { + rpc SearchIncidents(SearchIncidentsRequest) + returns (SearchIncidentsResponse) { option (google.api.http) = { get: "/v1alpha2/{parent=projects/*}/incidents:search" }; @@ -65,7 +65,8 @@ service IncidentService { // Returns a list of incidents that are "similar" to the specified incident // or signal. This functionality is provided on a best-effort basis and the // definition of "similar" is subject to change. - rpc SearchSimilarIncidents(SearchSimilarIncidentsRequest) returns (SearchSimilarIncidentsResponse) { + rpc SearchSimilarIncidents(SearchSimilarIncidentsRequest) + returns (SearchSimilarIncidentsResponse) { option (google.api.http) = { get: "/v1alpha2/{name=projects/*/incidents/*}:searchSimilar" additional_bindings { @@ -85,20 +86,13 @@ service IncidentService { // Lists annotations that are part of an incident. No assumptions should be // made on the content-type of the annotation returned. - rpc ListAnnotations(ListAnnotationsRequest) returns (ListAnnotationsResponse) { + rpc ListAnnotations(ListAnnotationsRequest) + returns (ListAnnotationsResponse) { option (google.api.http) = { get: "/v1alpha2/{parent=projects/*/incidents/*}/annotations" }; } - // Updates an annotation on an existing incident. - rpc UpdateAnnotation(UpdateAnnotationRequest) returns (Annotation) { - option (google.api.http) = { - patch: "/v1alpha2/{annotation.name=projects/*/incidents/*/annotations/*}" - body: "annotation" - }; - } - // Creates a tag on an existing incident. rpc CreateTag(CreateTagRequest) returns (Tag) { option (google.api.http) = { @@ -131,9 +125,9 @@ service IncidentService { // Lists signals that are part of an incident. // Signals are returned in reverse chronological order. - rpc ListSignals(ListSignalsRequest) returns (ListSignalsResponse) { + rpc SearchSignals(SearchSignalsRequest) returns (SearchSignalsResponse) { option (google.api.http) = { - get: "/v1alpha2/{parent=projects/*}/signals" + get: "/v1alpha2/{parent=projects/*}/signals:search" }; } @@ -144,7 +138,7 @@ service IncidentService { }; } - // Updates an existing signal (e.g. to assign/unassign it to an + // Updates an existing signal (for example, to assign/unassign it to an // incident). rpc UpdateSignal(UpdateSignalRequest) returns (Signal) { option (google.api.http) = { @@ -153,17 +147,9 @@ service IncidentService { }; } - // Acks a signal. This acknowledges the signal in the underlying system, - // indicating that the caller takes responsibility for looking into this. - rpc AcknowledgeSignal(AcknowledgeSignalRequest) returns (AcknowledgeSignalResponse) { - option (google.api.http) = { - post: "/v1alpha2/{name=projects/*/signals/*}:ack" - body: "*" - }; - } - // Escalates an incident. - rpc EscalateIncident(EscalateIncidentRequest) returns (EscalateIncidentResponse) { + rpc EscalateIncident(EscalateIncidentRequest) + returns (EscalateIncidentResponse) { option (google.api.http) = { post: "/v1alpha2/{incident.name=projects/*/incidents/*}:escalate" body: "*" @@ -200,16 +186,9 @@ service IncidentService { }; } - // Returns "presets" specific to shift handoff (see SendShiftHandoff), e.g. - // default values for handoff message fields. - rpc GetShiftHandoffPresets(GetShiftHandoffPresetsRequest) returns (ShiftHandoffPresets) { - option (google.api.http) = { - get: "/v1alpha2/{parent=projects/*}/shiftHandoffPresets" - }; - } - // Sends a summary of the shift for oncall handoff. - rpc SendShiftHandoff(SendShiftHandoffRequest) returns (SendShiftHandoffResponse) { + rpc SendShiftHandoff(SendShiftHandoffRequest) + returns (SendShiftHandoffResponse) { option (google.api.http) = { post: "/v1alpha2/{parent=projects/*}/shiftHandoff:send" body: "*" @@ -227,15 +206,25 @@ service IncidentService { }; } + // Updates a subscription. + rpc UpdateSubscription(UpdateSubscriptionRequest) returns (Subscription) { + option (google.api.http) = { + patch: "/v1alpha2/{subscription.name=projects/*/incidents/*/subscriptions/*}" + body: "subscription" + }; + } + // Returns a list of subscriptions for an incident. - rpc ListSubscriptions(ListSubscriptionsRequest) returns (ListSubscriptionsResponse) { + rpc ListSubscriptions(ListSubscriptionsRequest) + returns (ListSubscriptionsResponse) { option (google.api.http) = { get: "/v1alpha2/{parent=projects/*/incidents/*}/subscriptions" }; } // Deletes an existing subscription. - rpc DeleteSubscription(DeleteSubscriptionRequest) returns (google.protobuf.Empty) { + rpc DeleteSubscription(DeleteSubscriptionRequest) + returns (google.protobuf.Empty) { option (google.api.http) = { delete: "/v1alpha2/{name=projects/*/incidents/*/subscriptions/*}" }; @@ -246,7 +235,8 @@ service IncidentService { // set when proposing another user as the assignee. Setting the next field // directly to a user other than oneself is equivalent to proposing and // force-assigning the role to the user. - rpc CreateIncidentRoleAssignment(CreateIncidentRoleAssignmentRequest) returns (IncidentRoleAssignment) { + rpc CreateIncidentRoleAssignment(CreateIncidentRoleAssignmentRequest) + returns (IncidentRoleAssignment) { option (google.api.http) = { post: "/v1alpha2/{parent=projects/*/incidents/*}/roleAssignments" body: "*" @@ -254,14 +244,16 @@ service IncidentService { } // Deletes an existing role assignment. - rpc DeleteIncidentRoleAssignment(DeleteIncidentRoleAssignmentRequest) returns (google.protobuf.Empty) { + rpc DeleteIncidentRoleAssignment(DeleteIncidentRoleAssignmentRequest) + returns (google.protobuf.Empty) { option (google.api.http) = { delete: "/v1alpha2/{name=projects/*/incidents/*/roleAssignments/*}" }; } // Lists role assignments that are part of an incident. - rpc ListIncidentRoleAssignments(ListIncidentRoleAssignmentsRequest) returns (ListIncidentRoleAssignmentsResponse) { + rpc ListIncidentRoleAssignments(ListIncidentRoleAssignmentsRequest) + returns (ListIncidentRoleAssignmentsResponse) { option (google.api.http) = { get: "/v1alpha2/{parent=projects/*/incidents/*}/roleAssignments" }; @@ -270,7 +262,8 @@ service IncidentService { // Starts a role handover. The proposed assignee will receive an email // notifying them of the assignment. This will fail if a role handover is // already pending. - rpc RequestIncidentRoleHandover(RequestIncidentRoleHandoverRequest) returns (IncidentRoleAssignment) { + rpc RequestIncidentRoleHandover(RequestIncidentRoleHandoverRequest) + returns (IncidentRoleAssignment) { option (google.api.http) = { post: "/v1alpha2/{name=projects/*/incidents/*/roleAssignments/*}:requestHandover" body: "*" @@ -281,7 +274,8 @@ service IncidentService { // of the IncidentRoleAssignment is not equal to the 'new_assignee' field of // the request. If the caller is not the new_assignee, // ForceIncidentRoleHandover should be used instead. - rpc ConfirmIncidentRoleHandover(ConfirmIncidentRoleHandoverRequest) returns (IncidentRoleAssignment) { + rpc ConfirmIncidentRoleHandover(ConfirmIncidentRoleHandoverRequest) + returns (IncidentRoleAssignment) { option (google.api.http) = { post: "/v1alpha2/{name=projects/*/incidents/*/roleAssignments/*}:confirmHandover" body: "*" @@ -292,7 +286,8 @@ service IncidentService { // the IncidentRoleAssignment is not equal to the 'new_assignee' field of the // request. If the caller is the new_assignee, ConfirmIncidentRoleHandover // should be used instead. - rpc ForceIncidentRoleHandover(ForceIncidentRoleHandoverRequest) returns (IncidentRoleAssignment) { + rpc ForceIncidentRoleHandover(ForceIncidentRoleHandoverRequest) + returns (IncidentRoleAssignment) { option (google.api.http) = { post: "/v1alpha2/{name=projects/*/incidents/*/roleAssignments/*}:forceHandover" body: "*" @@ -302,7 +297,8 @@ service IncidentService { // Cancels a role handover. This will fail if the 'proposed_assignee' field of // the IncidentRoleAssignment is not equal to the 'new_assignee' field of the // request. - rpc CancelIncidentRoleHandover(CancelIncidentRoleHandoverRequest) returns (IncidentRoleAssignment) { + rpc CancelIncidentRoleHandover(CancelIncidentRoleHandoverRequest) + returns (IncidentRoleAssignment) { option (google.api.http) = { post: "/v1alpha2/{name=projects/*/incidents/*/roleAssignments/*}:cancelHandover" body: "*" @@ -324,7 +320,7 @@ message CreateIncidentRequest { // Request for the GetIncident method. message GetIncidentRequest { - // Resource name of the incident, e.g. + // Resource name of the incident, for example, // "projects/{project_id}/incidents/{incident_id}". string name = 1; } @@ -340,7 +336,7 @@ message UpdateIncidentRequest { // Request for the SearchSimilarIncidents method. message SearchSimilarIncidentsRequest { - // Resource name of the incident or signal, e.g. + // Resource name of the incident or signal, for example, // "projects/{project_id}/incidents/{incident_id}". string name = 1; @@ -370,7 +366,7 @@ message SearchSimilarIncidentsResponse { // Request for the CreateAnnotation method. message CreateAnnotationRequest { - // Resource name of the incident, e.g. + // Resource name of the incident, for example, // "projects/{project_id}/incidents/{incident_id}". string parent = 1; @@ -380,7 +376,7 @@ message CreateAnnotationRequest { // Request for the ListAnnotations method. message ListAnnotationsRequest { - // Resource name of the incident, e.g. + // Resource name of the incident, for example, // "projects/{project_id}/incidents/{incident_id}". string parent = 1; @@ -402,7 +398,7 @@ message ListAnnotationsResponse { // Request for the CreateTag method. message CreateTagRequest { - // Resource name of the incident, e.g. + // Resource name of the incident, for example, // "projects/{project_id}/incidents/{incident_id}". string parent = 1; @@ -418,7 +414,7 @@ message DeleteTagRequest { // Request for the ListTagsForIncident method. message ListTagsRequest { - // Resource name of the incident, e.g. + // Resource name of the incident, for example, // "projects/{project_id}/incidents/{incident_id}". string parent = 1; @@ -438,15 +434,6 @@ message ListTagsResponse { string next_page_token = 2; } -// Request for the UpdateAnnotation method. -message UpdateAnnotationRequest { - // The annotation to update with the new values. - Annotation annotation = 1; - - // List of fields that should be updated. - google.protobuf.FieldMask update_mask = 2; -} - // Request for the CreateSignal method. message CreateSignalRequest { // The resource name of the hosting Stackdriver project which requested @@ -457,14 +444,14 @@ message CreateSignalRequest { Signal signal = 2; } -// Request for the ListSignals method. -message ListSignalsRequest { +// Request for the SearchSignals method. +message SearchSignalsRequest { // The resource name of the hosting Stackdriver project which requested // incidents belong to. string parent = 1; - // Filter to specify which signals should be returned. - string filter = 2; + // Query to specify which signals should be returned. + string query = 2; // Maximum number of `signals` to return in the response. int32 page_size = 3; @@ -475,9 +462,9 @@ message ListSignalsRequest { string page_token = 4; } -// Response for the ListSignals method. -message ListSignalsResponse { - // List of signals that have not been moved into an incident yet. +// Response for the SearchSignals method. +message SearchSignalsResponse { + // Signals that matched the query in the request. repeated Signal signals = 1; // Page token to fetch the next set of signals. @@ -486,7 +473,7 @@ message ListSignalsResponse { // Request for the GetSignal method. message GetSignalRequest { - // Resource name of the Signal resource, e.g. + // Resource name of the Signal resource, for example, // "projects/{project_id}/signals/{signal_id}". string name = 1; } @@ -500,18 +487,6 @@ message UpdateSignalRequest { google.protobuf.FieldMask update_mask = 2; } -// Request for the AcknowledgeSignal method. -message AcknowledgeSignalRequest { - // Resource name of the Signal resource, e.g. - // "projects/{project_id}/signals/{signal_id}". - string name = 1; -} - -// Response of the AcknowledgeSignal method. -message AcknowledgeSignalResponse { - -} - // Request for the SearchIncidents method. message SearchIncidentsRequest { // The resource name of the hosting Stackdriver project which requested @@ -530,20 +505,22 @@ message SearchIncidentsRequest { // Incident.Stage enum). These are ordered, so `stagemedium`, `severity<=minor`, etc.). + // + Supports matching on a specific severity (for example, + // `severity:major`) or on a range (for example, `severity>medium`, + // `severity<=minor`, etc.). // // Timestamp formats: // * yyyy-MM-dd - an absolute date, treated as a calendar-day-wide window. // In other words, the "<" operator will match dates before that date, the // ">" operator will match dates after that date, and the ":" or "=" // operators will match the entire day. - // * Nd (e.g. 7d) - a relative number of days ago, treated as a moment in time - // (as opposed to a day-wide span) a multiple of 24 hours ago (as opposed to - // calendar days). In the case of daylight savings time, it will apply the - // current timezone to both ends of the range. Note that exact matching - // (e.g. `start:7d`) is unlikely to be useful because that would only match - // incidents created precisely at a particular instant in time. + // * Nd (for example, 7d) - a relative number of days ago, treated as a moment + // in time (as opposed to a day-wide span). A multiple of 24 hours ago (as + // opposed to calendar days). In the case of daylight savings time, it will + // apply the current timezone to both ends of the range. Note that exact + // matching (for example, `start:7d`) is unlikely to be useful because that + // would only match incidents created precisely at a particular instant in + // time. // // Examples: // @@ -634,7 +611,7 @@ message EscalateIncidentResponse { // Request for the CreateArtifact method. message CreateArtifactRequest { - // Resource name of the incident, e.g. + // Resource name of the incident, for example, // "projects/{project_id}/incidents/{incident_id}". string parent = 1; @@ -644,7 +621,7 @@ message CreateArtifactRequest { // Request for the ListArtifacts method. message ListArtifactsRequest { - // Resource name of the incident, e.g. + // Resource name of the incident, for example, // "projects/{project_id}/incidents/{incident_id}". string parent = 1; @@ -679,44 +656,23 @@ message DeleteArtifactRequest { string name = 1; } -// GetShiftHandoffPresets RPC request. -message GetShiftHandoffPresetsRequest { - // Resource name of the Stackdriver project that the presets belong to. e.g. - // `projects/{project_id}` - string parent = 1; -} - -// GetShiftHandoffPresets RPC response. -message ShiftHandoffPresets { - // The recipients that the user might want to send the shift handoff to, in - // the form of email addresses, e.g. "user@example.com". Can be empty. - repeated string recipients = 1; - - // The recipients that the user might want to CC on the shift handoff, in the - // form of email addresses, e.g. "user@example.com". Can be empty. - repeated string cc = 2; - - // A suggested subject for the shift handoff email. Can be empty. - string subject = 3; -} - // SendShiftHandoff and PreviewShiftHandoff RPC request. message SendShiftHandoffRequest { // Describes an incident for inclusion in the handoff. // This is wrapped in a message to provide flexibility for potentially // attaching additional data to each incident in the future. message Incident { - // Resource name of the incident, e.g. + // Resource name of the incident, for example, // "projects/{project_id}/incidents/{incident_id}". string name = 1; } // The resource name of the Stackdriver project that the handoff is being sent - // from. e.g. `projects/{project_id}` + // from. for example, `projects/{project_id}` string parent = 1; - // Email addresses of the recipients of the handoff, e.g. "user@example.com". - // Must contain at least one entry. + // Email addresses of the recipients of the handoff, for example, + // "user@example.com". Must contain at least one entry. repeated string recipients = 2; // Email addresses that should be CC'd on the handoff. Optional. @@ -725,7 +681,7 @@ message SendShiftHandoffRequest { // The subject of the email. Required. string subject = 4; - // Content type string, e.g. 'text/plain' or 'text/html'. + // Content type string, for example, 'text/plain' or 'text/html'. string notes_content_type = 5; // Additional notes to be included in the handoff. Optional. @@ -741,7 +697,7 @@ message SendShiftHandoffRequest { // SendShiftHandoff and PreviewShiftHandoff RPC response. message SendShiftHandoffResponse { - // Content type string, e.g. 'text/plain' or 'text/html'. + // Content type string, for example, 'text/plain' or 'text/html'. string content_type = 1; // The contents of the handoff that was sent or would have been sent (if the @@ -752,7 +708,7 @@ message SendShiftHandoffResponse { // Request for the CreateSubscription method. message CreateSubscriptionRequest { - // Resource name of the incident, e.g. + // Resource name of the incident, for example, // "projects/{project_id}/incidents/{incident_id}". string parent = 1; @@ -760,9 +716,18 @@ message CreateSubscriptionRequest { Subscription subscription = 2; } +// Request for the UpdateSubscription method. +message UpdateSubscriptionRequest { + // The subscription to update, with new values. + Subscription subscription = 1; + + // List of fields that should be updated. + google.protobuf.FieldMask update_mask = 2; +} + // Request for the ListSubscriptions method. message ListSubscriptionsRequest { - // Resource name of the incident, e.g. + // Resource name of the incident, for example, // "projects/{project_id}/incidents/{incident_id}". string parent = 1; @@ -790,7 +755,7 @@ message DeleteSubscriptionRequest { // Request for creating a role assignment. message CreateIncidentRoleAssignmentRequest { - // Resource name of the incident, e.g. + // Resource name of the incident, for example, // "projects/{project_id}/incidents/{incident_id}". string parent = 1; @@ -806,7 +771,7 @@ message DeleteIncidentRoleAssignmentRequest { // Request to list role assignments of an incident. message ListIncidentRoleAssignmentsRequest { - // Resource name of the incident, e.g. + // Resource name of the incident, for example, // "projects/{project_id}/incidents/{incident_id}". string parent = 1; diff --git a/google/cloud/irm/v1alpha2/irm_gapic.yaml b/google/cloud/irm/v1alpha2/irm_gapic.yaml index df51cf4d..cf5de02d 100644 --- a/google/cloud/irm/v1alpha2/irm_gapic.yaml +++ b/google/cloud/irm/v1alpha2/irm_gapic.yaml @@ -45,8 +45,6 @@ interfaces: common_resource_name: Google.Api.Gax.ResourceNames.ProjectName - name_pattern: projects/{project}/incidents/{incident} entity_name: incident - - name_pattern: projects/{project}/incidents/{incident}/annotations/{annotation} - entity_name: annotation - name_pattern: projects/{project}/incidents/{incident}/artifacts/{artifact} entity_name: artifact - name_pattern: projects/{project}/incidents/{incident}/roleAssignments/{role_assignment} @@ -131,6 +129,7 @@ interfaces: # the call is retrying, refer to retry_params_name instead. methods: - name: CreateIncident + resource_name_treatment: STATIC_TYPES flattening: groups: - parameters: @@ -145,6 +144,7 @@ interfaces: parent: project timeout_millis: 60000 - name: GetIncident + resource_name_treatment: STATIC_TYPES flattening: groups: - parameters: @@ -157,6 +157,7 @@ interfaces: name: incident timeout_millis: 60000 - name: SearchIncidents + resource_name_treatment: STATIC_TYPES flattening: groups: - parameters: @@ -178,6 +179,7 @@ interfaces: parent: project timeout_millis: 60000 - name: UpdateIncident + resource_name_treatment: STATIC_TYPES flattening: groups: - parameters: @@ -210,6 +212,7 @@ interfaces: name: incident timeout_millis: 60000 - name: CreateAnnotation + resource_name_treatment: STATIC_TYPES flattening: groups: - parameters: @@ -224,6 +227,7 @@ interfaces: parent: incident timeout_millis: 60000 - name: ListAnnotations + resource_name_treatment: STATIC_TYPES flattening: groups: - parameters: @@ -242,20 +246,8 @@ interfaces: field_name_patterns: parent: incident timeout_millis: 60000 - - name: UpdateAnnotation - flattening: - groups: - - parameters: - - annotation - - update_mask - required_fields: - - annotation - retry_codes_name: non_idempotent - retry_params_name: default - field_name_patterns: - annotation.name: annotation - timeout_millis: 60000 - name: CreateTag + resource_name_treatment: STATIC_TYPES flattening: groups: - parameters: @@ -270,6 +262,7 @@ interfaces: parent: incident timeout_millis: 60000 - name: DeleteTag + resource_name_treatment: STATIC_TYPES flattening: groups: - parameters: @@ -282,6 +275,7 @@ interfaces: name: tag timeout_millis: 60000 - name: ListTags + resource_name_treatment: STATIC_TYPES flattening: groups: - parameters: @@ -301,6 +295,7 @@ interfaces: parent: incident timeout_millis: 60000 - name: CreateSignal + resource_name_treatment: STATIC_TYPES flattening: groups: - parameters: @@ -314,12 +309,13 @@ interfaces: field_name_patterns: parent: project timeout_millis: 60000 - - name: ListSignals + - name: SearchSignals + resource_name_treatment: STATIC_TYPES flattening: groups: - parameters: - parent - - filter + - query required_fields: - parent page_streaming: @@ -335,6 +331,7 @@ interfaces: parent: project timeout_millis: 60000 - name: GetSignal + resource_name_treatment: STATIC_TYPES flattening: groups: - parameters: @@ -347,6 +344,7 @@ interfaces: name: signal timeout_millis: 60000 - name: UpdateSignal + resource_name_treatment: STATIC_TYPES flattening: groups: - parameters: @@ -359,19 +357,8 @@ interfaces: field_name_patterns: signal.name: signal timeout_millis: 60000 - - name: AcknowledgeSignal - flattening: - groups: - - parameters: - - name - required_fields: - - name - retry_codes_name: non_idempotent - retry_params_name: default - field_name_patterns: - name: signal - timeout_millis: 60000 - name: EscalateIncident + resource_name_treatment: STATIC_TYPES required_fields: - incident retry_codes_name: non_idempotent @@ -380,6 +367,7 @@ interfaces: incident.name: incident timeout_millis: 60000 - name: CreateArtifact + resource_name_treatment: STATIC_TYPES flattening: groups: - parameters: @@ -394,6 +382,7 @@ interfaces: parent: incident timeout_millis: 60000 - name: ListArtifacts + resource_name_treatment: STATIC_TYPES flattening: groups: - parameters: @@ -413,6 +402,7 @@ interfaces: parent: incident timeout_millis: 60000 - name: UpdateArtifact + resource_name_treatment: STATIC_TYPES flattening: groups: - parameters: @@ -426,6 +416,7 @@ interfaces: artifact.name: artifact timeout_millis: 60000 - name: DeleteArtifact + resource_name_treatment: STATIC_TYPES flattening: groups: - parameters: @@ -437,19 +428,8 @@ interfaces: field_name_patterns: name: artifact timeout_millis: 60000 - - name: GetShiftHandoffPresets - flattening: - groups: - - parameters: - - parent - required_fields: - - parent - retry_codes_name: idempotent - retry_params_name: default - field_name_patterns: - parent: project - timeout_millis: 60000 - name: SendShiftHandoff + resource_name_treatment: STATIC_TYPES required_fields: - parent - recipients @@ -460,6 +440,7 @@ interfaces: parent: project timeout_millis: 60000 - name: CreateSubscription + resource_name_treatment: STATIC_TYPES flattening: groups: - parameters: @@ -473,7 +454,22 @@ interfaces: field_name_patterns: parent: incident timeout_millis: 60000 + - name: UpdateSubscription + resource_name_treatment: STATIC_TYPES + flattening: + groups: + - parameters: + - subscription + - update_mask + required_fields: + - subscription + retry_codes_name: non_idempotent + retry_params_name: default + field_name_patterns: + subscription.name: subscription + timeout_millis: 60000 - name: ListSubscriptions + resource_name_treatment: STATIC_TYPES flattening: groups: - parameters: @@ -493,6 +489,7 @@ interfaces: parent: incident timeout_millis: 60000 - name: DeleteSubscription + resource_name_treatment: STATIC_TYPES flattening: groups: - parameters: @@ -505,6 +502,7 @@ interfaces: name: subscription timeout_millis: 60000 - name: CreateIncidentRoleAssignment + resource_name_treatment: STATIC_TYPES flattening: groups: - parameters: @@ -519,6 +517,7 @@ interfaces: parent: incident timeout_millis: 60000 - name: DeleteIncidentRoleAssignment + resource_name_treatment: STATIC_TYPES flattening: groups: - parameters: @@ -531,6 +530,7 @@ interfaces: name: role_assignment timeout_millis: 60000 - name: ListIncidentRoleAssignments + resource_name_treatment: STATIC_TYPES flattening: groups: - parameters: @@ -550,6 +550,7 @@ interfaces: parent: incident timeout_millis: 60000 - name: RequestIncidentRoleHandover + resource_name_treatment: STATIC_TYPES flattening: groups: - parameters: @@ -564,6 +565,7 @@ interfaces: name: role_assignment timeout_millis: 60000 - name: ConfirmIncidentRoleHandover + resource_name_treatment: STATIC_TYPES flattening: groups: - parameters: @@ -578,6 +580,7 @@ interfaces: name: role_assignment timeout_millis: 60000 - name: ForceIncidentRoleHandover + resource_name_treatment: STATIC_TYPES flattening: groups: - parameters: @@ -592,6 +595,7 @@ interfaces: name: role_assignment timeout_millis: 60000 - name: CancelIncidentRoleHandover + resource_name_treatment: STATIC_TYPES flattening: groups: - parameters: @@ -605,3 +609,94 @@ interfaces: field_name_patterns: name: role_assignment timeout_millis: 60000 +resource_name_generation: +- message_name: CreateIncidentRequest + field_entity_map: + parent: project +- message_name: GetIncidentRequest + field_entity_map: + name: incident +- message_name: SearchIncidentsRequest + field_entity_map: + parent: project +- message_name: UpdateIncidentRequest + field_entity_map: + incident.name: incident +- message_name: EscalateIncidentRequest + field_entity_map: + incident.name: incident +- message_name: CreateSignalRequest + field_entity_map: + parent: project +- message_name: GetSignalRequest + field_entity_map: + name: signal +- message_name: SearchSignalsRequest + field_entity_map: + parent: project +- message_name: UpdateSignalRequest + field_entity_map: + signal.name: signal +- message_name: CreateArtifactRequest + field_entity_map: + parent: incident +- message_name: ListArtifactsRequest + field_entity_map: + parent: incident +- message_name: UpdateArtifactRequest + field_entity_map: + artifact.name: artifact +- message_name: DeleteArtifactRequest + field_entity_map: + name: artifact +- message_name: CreateIncidentRoleAssignmentRequest + field_entity_map: + parent: incident +- message_name: ListIncidentRoleAssignmentsRequest + field_entity_map: + parent: incident +- message_name: DeleteIncidentRoleAssignmentRequest + field_entity_map: + name: role_assignment +- message_name: RequestIncidentRoleHandoverRequest + field_entity_map: + name: role_assignment +- message_name: ConfirmIncidentRoleHandoverRequest + field_entity_map: + name: role_assignment +- message_name: ForceIncidentRoleHandoverRequest + field_entity_map: + name: role_assignment +- message_name: CancelIncidentRoleHandoverRequest + field_entity_map: + name: role_assignment +- message_name: CreateSubscriptionRequest + field_entity_map: + parent: incident +- message_name: ListSubscriptionsRequest + field_entity_map: + parent: incident +- message_name: UpdateSubscriptionRequest + field_entity_map: + subscription.name: subscription +- message_name: DeleteSubscriptionRequest + field_entity_map: + name: subscription +- message_name: CreateTagRequest + field_entity_map: + parent: incident +- message_name: ListTagsRequest + field_entity_map: + parent: incident +- message_name: DeleteTagRequest + field_entity_map: + name: tag +- message_name: CreateAnnotationRequest + field_entity_map: + parent: incident +- message_name: ListAnnotationsRequest + field_entity_map: + parent: incident +- message_name: SendShiftHandoffRequest + field_entity_map: + parent: project