1// Copyright 2023 Google LLC 2// 3// Licensed under the Apache License, Version 2.0 (the "License"); 4// you may not use this file except in compliance with the License. 5// You may obtain a copy of the License at 6// 7// http://www.apache.org/licenses/LICENSE-2.0 8// 9// Unless required by applicable law or agreed to in writing, software 10// distributed under the License is distributed on an "AS IS" BASIS, 11// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12// See the License for the specific language governing permissions and 13// limitations under the License. 14 15syntax = "proto3"; 16 17package google.cloud.servicehealth.v1; 18 19import "google/api/annotations.proto"; 20import "google/api/client.proto"; 21import "google/cloud/servicehealth/v1/event_resources.proto"; 22 23option csharp_namespace = "Google.Cloud.ServiceHealth.V1"; 24option go_package = "cloud.google.com/go/servicehealth/apiv1/servicehealthpb;servicehealthpb"; 25option java_multiple_files = true; 26option java_outer_classname = "EventServiceProto"; 27option java_package = "com.google.cloud.servicehealth.v1"; 28option php_namespace = "Google\\Cloud\\ServiceHealth\\V1"; 29option ruby_package = "Google::Cloud::ServiceHealth::V1"; 30 31// Request service health events relevant to your Google Cloud project. 32service ServiceHealth { 33 option (google.api.default_host) = "servicehealth.googleapis.com"; 34 option (google.api.oauth_scopes) = 35 "https://www.googleapis.com/auth/cloud-platform"; 36 37 // Lists events under a given project and location. 38 rpc ListEvents(ListEventsRequest) returns (ListEventsResponse) { 39 option (google.api.http) = { 40 get: "/v1/{parent=projects/*/locations/*}/events" 41 }; 42 option (google.api.method_signature) = "parent"; 43 } 44 45 // Retrieves a resource containing information about an event. 46 rpc GetEvent(GetEventRequest) returns (Event) { 47 option (google.api.http) = { 48 get: "/v1/{name=projects/*/locations/*/events/*}" 49 }; 50 option (google.api.method_signature) = "name"; 51 } 52 53 // Lists organization events under a given organization and location. 54 rpc ListOrganizationEvents(ListOrganizationEventsRequest) 55 returns (ListOrganizationEventsResponse) { 56 option (google.api.http) = { 57 get: "/v1/{parent=organizations/*/locations/*}/organizationEvents" 58 }; 59 option (google.api.method_signature) = "parent"; 60 } 61 62 // Retrieves a resource containing information about an event affecting an 63 // organization . 64 rpc GetOrganizationEvent(GetOrganizationEventRequest) 65 returns (OrganizationEvent) { 66 option (google.api.http) = { 67 get: "/v1/{name=organizations/*/locations/*/organizationEvents/*}" 68 }; 69 option (google.api.method_signature) = "name"; 70 } 71 72 // Lists assets impacted by organization events under a given organization and 73 // location. 74 rpc ListOrganizationImpacts(ListOrganizationImpactsRequest) 75 returns (ListOrganizationImpactsResponse) { 76 option (google.api.http) = { 77 get: "/v1/{parent=organizations/*/locations/*}/organizationImpacts" 78 }; 79 option (google.api.method_signature) = "parent"; 80 } 81 82 // Retrieves a resource containing information about impact to an asset under 83 // an organization affected by a service health event. 84 rpc GetOrganizationImpact(GetOrganizationImpactRequest) 85 returns (OrganizationImpact) { 86 option (google.api.http) = { 87 get: "/v1/{name=organizations/*/locations/*/organizationImpacts/*}" 88 }; 89 option (google.api.method_signature) = "name"; 90 } 91} 92