Skip to content

Commit

Permalink
feat: Automated regeneration of ServiceManagement client
Browse files Browse the repository at this point in the history
  • Loading branch information
yoshi-automation committed Mar 12, 2024
1 parent 9e554ee commit 84c3274
Show file tree
Hide file tree
Showing 29 changed files with 847 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ defmodule GoogleApi.ServiceManagement.V1 do
API client metadata for GoogleApi.ServiceManagement.V1.
"""

@discovery_revision "20220913"
@discovery_revision "20240301"

def discovery_revision(), do: @discovery_revision
end
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,9 @@ defmodule GoogleApi.ServiceManagement.V1.Model.BackendRule do
* `deadline` (*type:* `float()`, *default:* `nil`) - The number of seconds to wait for a response from a request. The default varies based on the request protocol and deployment environment.
* `disableAuth` (*type:* `boolean()`, *default:* `nil`) - When disable_auth is true, a JWT ID token won't be generated and the original "Authorization" HTTP header will be preserved. If the header is used to carry the original token and is expected by the backend, this field must be set to true to preserve the header.
* `jwtAudience` (*type:* `String.t`, *default:* `nil`) - The JWT audience is used when generating a JWT ID token for the backend. This ID token will be added in the HTTP "authorization" header, and sent to the backend.
* `minDeadline` (*type:* `float()`, *default:* `nil`) - Deprecated, do not use.
* `operationDeadline` (*type:* `float()`, *default:* `nil`) - The number of seconds to wait for the completion of a long running operation. The default is no deadline.
* `overridesByRequestProtocol` (*type:* `%{optional(String.t) => GoogleApi.ServiceManagement.V1.Model.BackendRule.t}`, *default:* `nil`) - The map between request protocol and the backend address.
* `pathTranslation` (*type:* `String.t`, *default:* `nil`) -
* `protocol` (*type:* `String.t`, *default:* `nil`) - The protocol used for sending a request to the backend. The supported values are "http/1.1" and "h2". The default value is inferred from the scheme in the address field: SCHEME PROTOCOL http:// http/1.1 https:// http/1.1 grpc:// h2 grpcs:// h2 For secure HTTP backends (https://) that support HTTP/2, set this field to "h2" for improved performance. Configuring this field to non-default values is only supported for secure HTTP backends. This field will be ignored for all other backends. See https://www.iana.org/assignments/tls-extensiontype-values/tls-extensiontype-values.xhtml#alpn-protocol-ids for more details on the supported values.
* `selector` (*type:* `String.t`, *default:* `nil`) - Selects the methods to which this rule applies. Refer to selector for syntax details.
Expand All @@ -38,7 +40,10 @@ defmodule GoogleApi.ServiceManagement.V1.Model.BackendRule do
:deadline => float() | nil,
:disableAuth => boolean() | nil,
:jwtAudience => String.t() | nil,
:minDeadline => float() | nil,
:operationDeadline => float() | nil,
:overridesByRequestProtocol =>
%{optional(String.t()) => GoogleApi.ServiceManagement.V1.Model.BackendRule.t()} | nil,
:pathTranslation => String.t() | nil,
:protocol => String.t() | nil,
:selector => String.t() | nil
Expand All @@ -48,7 +53,14 @@ defmodule GoogleApi.ServiceManagement.V1.Model.BackendRule do
field(:deadline)
field(:disableAuth)
field(:jwtAudience)
field(:minDeadline)
field(:operationDeadline)

field(:overridesByRequestProtocol,
as: GoogleApi.ServiceManagement.V1.Model.BackendRule,
type: :map
)

field(:pathTranslation)
field(:protocol)
field(:selector)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@ defmodule GoogleApi.ServiceManagement.V1.Model.Binding do
## Attributes
* `condition` (*type:* `GoogleApi.ServiceManagement.V1.Model.Expr.t`, *default:* `nil`) - The condition that is associated with this binding. If the condition evaluates to `true`, then this binding applies to the current request. If the condition evaluates to `false`, then this binding does not apply to the current request. However, a different role binding might grant the same role to one or more of the principals in this binding. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies).
* `members` (*type:* `list(String.t)`, *default:* `nil`) - Specifies the principals requesting access for a Google Cloud resource. `members` can have the following values: * `allUsers`: A special identifier that represents anyone who is on the internet; with or without a Google account. * `allAuthenticatedUsers`: A special identifier that represents anyone who is authenticated with a Google account or a service account. Does not include identities that come from external identity providers (IdPs) through identity federation. * `user:{emailid}`: An email address that represents a specific Google account. For example, `[email protected]` . * `serviceAccount:{emailid}`: An email address that represents a Google service account. For example, `[email protected]`. * `serviceAccount:{projectid}.svc.id.goog[{namespace}/{kubernetes-sa}]`: An identifier for a [Kubernetes service account](https://cloud.google.com/kubernetes-engine/docs/how-to/kubernetes-service-accounts). For example, `my-project.svc.id.goog[my-namespace/my-kubernetes-sa]`. * `group:{emailid}`: An email address that represents a Google group. For example, `[email protected]`. * `deleted:user:{emailid}?uid={uniqueid}`: An email address (plus unique identifier) representing a user that has been recently deleted. For example, `[email protected]?uid=123456789012345678901`. If the user is recovered, this value reverts to `user:{emailid}` and the recovered user retains the role in the binding. * `deleted:serviceAccount:{emailid}?uid={uniqueid}`: An email address (plus unique identifier) representing a service account that has been recently deleted. For example, `[email protected]?uid=123456789012345678901`. If the service account is undeleted, this value reverts to `serviceAccount:{emailid}` and the undeleted service account retains the role in the binding. * `deleted:group:{emailid}?uid={uniqueid}`: An email address (plus unique identifier) representing a Google group that has been recently deleted. For example, `[email protected]?uid=123456789012345678901`. If the group is recovered, this value reverts to `group:{emailid}` and the recovered group retains the role in the binding. * `domain:{domain}`: The G Suite domain (primary) that represents all the users of that domain. For example, `google.com` or `example.com`.
* `role` (*type:* `String.t`, *default:* `nil`) - Role that is assigned to the list of `members`, or principals. For example, `roles/viewer`, `roles/editor`, or `roles/owner`.
* `members` (*type:* `list(String.t)`, *default:* `nil`) - Specifies the principals requesting access for a Google Cloud resource. `members` can have the following values: * `allUsers`: A special identifier that represents anyone who is on the internet; with or without a Google account. * `allAuthenticatedUsers`: A special identifier that represents anyone who is authenticated with a Google account or a service account. Does not include identities that come from external identity providers (IdPs) through identity federation. * `user:{emailid}`: An email address that represents a specific Google account. For example, `[email protected]` . * `serviceAccount:{emailid}`: An email address that represents a Google service account. For example, `[email protected]`. * `serviceAccount:{projectid}.svc.id.goog[{namespace}/{kubernetes-sa}]`: An identifier for a [Kubernetes service account](https://cloud.google.com/kubernetes-engine/docs/how-to/kubernetes-service-accounts). For example, `my-project.svc.id.goog[my-namespace/my-kubernetes-sa]`. * `group:{emailid}`: An email address that represents a Google group. For example, `[email protected]`. * `domain:{domain}`: The G Suite domain (primary) that represents all the users of that domain. For example, `google.com` or `example.com`. * `principal://iam.googleapis.com/locations/global/workforcePools/{pool_id}/subject/{subject_attribute_value}`: A single identity in a workforce identity pool. * `principalSet://iam.googleapis.com/locations/global/workforcePools/{pool_id}/group/{group_id}`: All workforce identities in a group. * `principalSet://iam.googleapis.com/locations/global/workforcePools/{pool_id}/attribute.{attribute_name}/{attribute_value}`: All workforce identities with a specific attribute value. * `principalSet://iam.googleapis.com/locations/global/workforcePools/{pool_id}/*`: All identities in a workforce identity pool. * `principal://iam.googleapis.com/projects/{project_number}/locations/global/workloadIdentityPools/{pool_id}/subject/{subject_attribute_value}`: A single identity in a workload identity pool. * `principalSet://iam.googleapis.com/projects/{project_number}/locations/global/workloadIdentityPools/{pool_id}/group/{group_id}`: A workload identity pool group. * `principalSet://iam.googleapis.com/projects/{project_number}/locations/global/workloadIdentityPools/{pool_id}/attribute.{attribute_name}/{attribute_value}`: All identities in a workload identity pool with a certain attribute. * `principalSet://iam.googleapis.com/projects/{project_number}/locations/global/workloadIdentityPools/{pool_id}/*`: All identities in a workload identity pool. * `deleted:user:{emailid}?uid={uniqueid}`: An email address (plus unique identifier) representing a user that has been recently deleted. For example, `[email protected]?uid=123456789012345678901`. If the user is recovered, this value reverts to `user:{emailid}` and the recovered user retains the role in the binding. * `deleted:serviceAccount:{emailid}?uid={uniqueid}`: An email address (plus unique identifier) representing a service account that has been recently deleted. For example, `[email protected]?uid=123456789012345678901`. If the service account is undeleted, this value reverts to `serviceAccount:{emailid}` and the undeleted service account retains the role in the binding. * `deleted:group:{emailid}?uid={uniqueid}`: An email address (plus unique identifier) representing a Google group that has been recently deleted. For example, `[email protected]?uid=123456789012345678901`. If the group is recovered, this value reverts to `group:{emailid}` and the recovered group retains the role in the binding. * `deleted:principal://iam.googleapis.com/locations/global/workforcePools/{pool_id}/subject/{subject_attribute_value}`: Deleted single identity in a workforce identity pool. For example, `deleted:principal://iam.googleapis.com/locations/global/workforcePools/my-pool-id/subject/my-subject-attribute-value`.
* `role` (*type:* `String.t`, *default:* `nil`) - Role that is assigned to the list of `members`, or principals. For example, `roles/viewer`, `roles/editor`, or `roles/owner`. For an overview of the IAM roles and permissions, see the [IAM documentation](https://cloud.google.com/iam/docs/roles-overview). For a list of the available pre-defined roles, see [here](https://cloud.google.com/iam/docs/understanding-roles).
"""

use GoogleApi.Gax.ModelBase
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,76 @@
# Copyright 2019 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

# NOTE: This file is auto generated by the elixir code generator program.
# Do not edit this file manually.

defmodule GoogleApi.ServiceManagement.V1.Model.ClientLibrarySettings do
@moduledoc """
Details about how and where to publish client libraries.
## Attributes
* `cppSettings` (*type:* `GoogleApi.ServiceManagement.V1.Model.CppSettings.t`, *default:* `nil`) - Settings for C++ client libraries.
* `dotnetSettings` (*type:* `GoogleApi.ServiceManagement.V1.Model.DotnetSettings.t`, *default:* `nil`) - Settings for .NET client libraries.
* `goSettings` (*type:* `GoogleApi.ServiceManagement.V1.Model.GoSettings.t`, *default:* `nil`) - Settings for Go client libraries.
* `javaSettings` (*type:* `GoogleApi.ServiceManagement.V1.Model.JavaSettings.t`, *default:* `nil`) - Settings for legacy Java features, supported in the Service YAML.
* `launchStage` (*type:* `String.t`, *default:* `nil`) - Launch stage of this version of the API.
* `nodeSettings` (*type:* `GoogleApi.ServiceManagement.V1.Model.NodeSettings.t`, *default:* `nil`) - Settings for Node client libraries.
* `phpSettings` (*type:* `GoogleApi.ServiceManagement.V1.Model.PhpSettings.t`, *default:* `nil`) - Settings for PHP client libraries.
* `pythonSettings` (*type:* `GoogleApi.ServiceManagement.V1.Model.PythonSettings.t`, *default:* `nil`) - Settings for Python client libraries.
* `restNumericEnums` (*type:* `boolean()`, *default:* `nil`) - When using transport=rest, the client request will encode enums as numbers rather than strings.
* `rubySettings` (*type:* `GoogleApi.ServiceManagement.V1.Model.RubySettings.t`, *default:* `nil`) - Settings for Ruby client libraries.
* `version` (*type:* `String.t`, *default:* `nil`) - Version of the API to apply these settings to. This is the full protobuf package for the API, ending in the version element. Examples: "google.cloud.speech.v1" and "google.spanner.admin.database.v1".
"""

use GoogleApi.Gax.ModelBase

@type t :: %__MODULE__{
:cppSettings => GoogleApi.ServiceManagement.V1.Model.CppSettings.t() | nil,
:dotnetSettings => GoogleApi.ServiceManagement.V1.Model.DotnetSettings.t() | nil,
:goSettings => GoogleApi.ServiceManagement.V1.Model.GoSettings.t() | nil,
:javaSettings => GoogleApi.ServiceManagement.V1.Model.JavaSettings.t() | nil,
:launchStage => String.t() | nil,
:nodeSettings => GoogleApi.ServiceManagement.V1.Model.NodeSettings.t() | nil,
:phpSettings => GoogleApi.ServiceManagement.V1.Model.PhpSettings.t() | nil,
:pythonSettings => GoogleApi.ServiceManagement.V1.Model.PythonSettings.t() | nil,
:restNumericEnums => boolean() | nil,
:rubySettings => GoogleApi.ServiceManagement.V1.Model.RubySettings.t() | nil,
:version => String.t() | nil
}

field(:cppSettings, as: GoogleApi.ServiceManagement.V1.Model.CppSettings)
field(:dotnetSettings, as: GoogleApi.ServiceManagement.V1.Model.DotnetSettings)
field(:goSettings, as: GoogleApi.ServiceManagement.V1.Model.GoSettings)
field(:javaSettings, as: GoogleApi.ServiceManagement.V1.Model.JavaSettings)
field(:launchStage)
field(:nodeSettings, as: GoogleApi.ServiceManagement.V1.Model.NodeSettings)
field(:phpSettings, as: GoogleApi.ServiceManagement.V1.Model.PhpSettings)
field(:pythonSettings, as: GoogleApi.ServiceManagement.V1.Model.PythonSettings)
field(:restNumericEnums)
field(:rubySettings, as: GoogleApi.ServiceManagement.V1.Model.RubySettings)
field(:version)
end

defimpl Poison.Decoder, for: GoogleApi.ServiceManagement.V1.Model.ClientLibrarySettings do
def decode(value, options) do
GoogleApi.ServiceManagement.V1.Model.ClientLibrarySettings.decode(value, options)
end
end

defimpl Poison.Encoder, for: GoogleApi.ServiceManagement.V1.Model.ClientLibrarySettings do
def encode(value, options) do
GoogleApi.Gax.ModelBase.encode(value, options)
end
end
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
# Copyright 2019 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

# NOTE: This file is auto generated by the elixir code generator program.
# Do not edit this file manually.

defmodule GoogleApi.ServiceManagement.V1.Model.CommonLanguageSettings do
@moduledoc """
Required information for every language.
## Attributes
* `destinations` (*type:* `list(String.t)`, *default:* `nil`) - The destination where API teams want this client library to be published.
* `referenceDocsUri` (*type:* `String.t`, *default:* `nil`) - Link to automatically generated reference documentation. Example: https://cloud.google.com/nodejs/docs/reference/asset/latest
"""

use GoogleApi.Gax.ModelBase

@type t :: %__MODULE__{
:destinations => list(String.t()) | nil,
:referenceDocsUri => String.t() | nil
}

field(:destinations, type: :list)
field(:referenceDocsUri)
end

defimpl Poison.Decoder, for: GoogleApi.ServiceManagement.V1.Model.CommonLanguageSettings do
def decode(value, options) do
GoogleApi.ServiceManagement.V1.Model.CommonLanguageSettings.decode(value, options)
end
end

defimpl Poison.Encoder, for: GoogleApi.ServiceManagement.V1.Model.CommonLanguageSettings do
def encode(value, options) do
GoogleApi.Gax.ModelBase.encode(value, options)
end
end
Original file line number Diff line number Diff line change
Expand Up @@ -17,20 +17,23 @@

defmodule GoogleApi.ServiceManagement.V1.Model.Control do
@moduledoc """
Selects and configures the service controller used by the service. The service controller handles two things: - **What is allowed:** for each API request, Chemist checks the project status, activation status, abuse status, billing status, service status, location restrictions, VPC Service Controls, SuperQuota, and other policies. - **What has happened:** for each API response, Chemist reports the telemetry data to analytics, auditing, billing, eventing, logging, monitoring, sawmill, and tracing. Chemist also accepts telemetry data not associated with API traffic, such as billing metrics. Example: control: environment: servicecontrol.googleapis.com
Selects and configures the service controller used by the service. Example: control: environment: servicecontrol.googleapis.com
## Attributes
* `environment` (*type:* `String.t`, *default:* `nil`) - The service controller environment to use. If empty, no control plane feature (like quota and billing) will be enabled. The recommended value for most services is servicecontrol.googleapis.com
* `methodPolicies` (*type:* `list(GoogleApi.ServiceManagement.V1.Model.MethodPolicy.t)`, *default:* `nil`) - Defines policies applying to the API methods of the service.
"""

use GoogleApi.Gax.ModelBase

@type t :: %__MODULE__{
:environment => String.t() | nil
:environment => String.t() | nil,
:methodPolicies => list(GoogleApi.ServiceManagement.V1.Model.MethodPolicy.t()) | nil
}

field(:environment)
field(:methodPolicies, as: GoogleApi.ServiceManagement.V1.Model.MethodPolicy, type: :list)
end

defimpl Poison.Decoder, for: GoogleApi.ServiceManagement.V1.Model.Control do
Expand Down
Loading

0 comments on commit 84c3274

Please sign in to comment.