xref: /aosp_15_r20/external/googleapis/google/cloud/eventarc/v1/discovery.proto (revision d5c09012810ac0c9f33fe448fb6da8260d444cc9)
1// Copyright 2022 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.eventarc.v1;
18
19import "google/api/field_behavior.proto";
20import "google/api/resource.proto";
21
22option go_package = "cloud.google.com/go/eventarc/apiv1/eventarcpb;eventarcpb";
23option java_multiple_files = true;
24option java_outer_classname = "DiscoveryProto";
25option java_package = "com.google.cloud.eventarc.v1";
26
27// A representation of the Provider resource.
28message Provider {
29  option (google.api.resource) = {
30    type: "eventarc.googleapis.com/Provider"
31    pattern: "projects/{project}/locations/{location}/providers/{provider}"
32    plural: "providers"
33    singular: "provider"
34  };
35
36  // Output only. In `projects/{project}/locations/{location}/providers/{provider_id}`
37  // format.
38  string name = 1 [(google.api.field_behavior) = OUTPUT_ONLY];
39
40  // Output only. Human friendly name for the Provider. For example "Cloud Storage".
41  string display_name = 2 [(google.api.field_behavior) = OUTPUT_ONLY];
42
43  // Output only. Event types for this provider.
44  repeated EventType event_types = 3 [(google.api.field_behavior) = OUTPUT_ONLY];
45}
46
47// A representation of the event type resource.
48message EventType {
49  // Output only. The full name of the event type (for example,
50  // "google.cloud.storage.object.v1.finalized"). In the form of
51  // {provider-specific-prefix}.{resource}.{version}.{verb}. Types MUST be
52  // versioned and event schemas are guaranteed to remain backward compatible
53  // within one version. Note that event type versions and API versions do not
54  // need to match.
55  string type = 1 [(google.api.field_behavior) = OUTPUT_ONLY];
56
57  // Output only. Human friendly description of what the event type is about.
58  // For example "Bucket created in Cloud Storage".
59  string description = 2 [(google.api.field_behavior) = OUTPUT_ONLY];
60
61  // Output only. Filtering attributes for the event type.
62  repeated FilteringAttribute filtering_attributes = 3 [(google.api.field_behavior) = OUTPUT_ONLY];
63
64  // Output only. URI for the event schema.
65  // For example
66  // "https://github.com/googleapis/google-cloudevents/blob/master/proto/google/events/cloud/storage/v1/events.proto"
67  string event_schema_uri = 4 [(google.api.field_behavior) = OUTPUT_ONLY];
68}
69
70// A representation of the FilteringAttribute resource.
71// Filtering attributes are per event type.
72message FilteringAttribute {
73  // Output only. Attribute used for filtering the event type.
74  string attribute = 1 [(google.api.field_behavior) = OUTPUT_ONLY];
75
76  // Output only. Description of the purpose of the attribute.
77  string description = 2 [(google.api.field_behavior) = OUTPUT_ONLY];
78
79  // Output only. If true, the triggers for this provider should always specify a filter
80  // on these attributes. Trigger creation will fail otherwise.
81  bool required = 3 [(google.api.field_behavior) = OUTPUT_ONLY];
82
83  // Output only. If true, the attribute accepts matching expressions in the Eventarc
84  // PathPattern format.
85  bool path_pattern_supported = 4 [(google.api.field_behavior) = OUTPUT_ONLY];
86}
87