From b1b6902aa42b078168264b317de635a2c43488ce Mon Sep 17 00:00:00 2001 From: Yoshi Automation Bot Date: Tue, 12 Mar 2024 01:18:12 +0000 Subject: [PATCH] feat: Automated regeneration of ServiceControl client --- .../google_api/service_control/v1/metadata.ex | 2 +- .../v1/model/authentication_info.ex | 4 ++ .../service_control/v1/model/check_info.ex | 3 ++ .../service_control/v1/model/resource.ex | 2 +- .../v1/model/service_delegation_history.ex | 49 +++++++++++++++++ .../v1/model/service_metadata.ex | 52 +++++++++++++++++++ .../google_api/service_control/v2/metadata.ex | 2 +- .../v2/model/authentication_info.ex | 4 ++ .../v2/model/report_response.ex | 2 +- .../service_control/v2/model/resource.ex | 2 +- .../service_control/v2/model/resource_info.ex | 4 +- .../v2/model/service_delegation_history.ex | 49 +++++++++++++++++ .../v2/model/service_metadata.ex | 52 +++++++++++++++++++ 13 files changed, 220 insertions(+), 7 deletions(-) create mode 100644 clients/service_control/lib/google_api/service_control/v1/model/service_delegation_history.ex create mode 100644 clients/service_control/lib/google_api/service_control/v1/model/service_metadata.ex create mode 100644 clients/service_control/lib/google_api/service_control/v2/model/service_delegation_history.ex create mode 100644 clients/service_control/lib/google_api/service_control/v2/model/service_metadata.ex diff --git a/clients/service_control/lib/google_api/service_control/v1/metadata.ex b/clients/service_control/lib/google_api/service_control/v1/metadata.ex index 304c17138f..555bf42add 100644 --- a/clients/service_control/lib/google_api/service_control/v1/metadata.ex +++ b/clients/service_control/lib/google_api/service_control/v1/metadata.ex @@ -20,7 +20,7 @@ defmodule GoogleApi.ServiceControl.V1 do API client metadata for GoogleApi.ServiceControl.V1. """ - @discovery_revision "20221014" + @discovery_revision "20240301" def discovery_revision(), do: @discovery_revision end diff --git a/clients/service_control/lib/google_api/service_control/v1/model/authentication_info.ex b/clients/service_control/lib/google_api/service_control/v1/model/authentication_info.ex index 576c1e2b54..5777115001 100644 --- a/clients/service_control/lib/google_api/service_control/v1/model/authentication_info.ex +++ b/clients/service_control/lib/google_api/service_control/v1/model/authentication_info.ex @@ -26,6 +26,7 @@ defmodule GoogleApi.ServiceControl.V1.Model.AuthenticationInfo do * `principalSubject` (*type:* `String.t`, *default:* `nil`) - String representation of identity of requesting party. Populated for both first and third party identities. * `serviceAccountDelegationInfo` (*type:* `list(GoogleApi.ServiceControl.V1.Model.ServiceAccountDelegationInfo.t)`, *default:* `nil`) - Identity delegation history of an authenticated service account that makes the request. It contains information on the real authorities that try to access GCP resources by delegating on a service account. When multiple authorities present, they are guaranteed to be sorted based on the original ordering of the identity delegation events. * `serviceAccountKeyName` (*type:* `String.t`, *default:* `nil`) - The name of the service account key used to create or exchange credentials for authenticating the service account making the request. This is a scheme-less URI full resource name. For example: "//iam.googleapis.com/projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}/keys/{key}" + * `serviceDelegationHistory` (*type:* `GoogleApi.ServiceControl.V1.Model.ServiceDelegationHistory.t`, *default:* `nil`) - Records the history of delegated resource access across Google services. * `thirdPartyPrincipal` (*type:* `map()`, *default:* `nil`) - The third party identification (if any) of the authenticated user making the request. When the JSON object represented here has a proto equivalent, the proto name will be indicated in the `@type` property. """ @@ -38,6 +39,8 @@ defmodule GoogleApi.ServiceControl.V1.Model.AuthenticationInfo do :serviceAccountDelegationInfo => list(GoogleApi.ServiceControl.V1.Model.ServiceAccountDelegationInfo.t()) | nil, :serviceAccountKeyName => String.t() | nil, + :serviceDelegationHistory => + GoogleApi.ServiceControl.V1.Model.ServiceDelegationHistory.t() | nil, :thirdPartyPrincipal => map() | nil } @@ -51,6 +54,7 @@ defmodule GoogleApi.ServiceControl.V1.Model.AuthenticationInfo do ) field(:serviceAccountKeyName) + field(:serviceDelegationHistory, as: GoogleApi.ServiceControl.V1.Model.ServiceDelegationHistory) field(:thirdPartyPrincipal, type: :map) end diff --git a/clients/service_control/lib/google_api/service_control/v1/model/check_info.ex b/clients/service_control/lib/google_api/service_control/v1/model/check_info.ex index 3bcfbb8614..bde8aa0b6c 100644 --- a/clients/service_control/lib/google_api/service_control/v1/model/check_info.ex +++ b/clients/service_control/lib/google_api/service_control/v1/model/check_info.ex @@ -21,6 +21,7 @@ defmodule GoogleApi.ServiceControl.V1.Model.CheckInfo do ## Attributes + * `apiKeyUid` (*type:* `String.t`, *default:* `nil`) - The unique id of the api key in the format of "apikey:". This field will be populated when the consumer passed to Chemist is an API key and all the API key related validations are successful. * `consumerInfo` (*type:* `GoogleApi.ServiceControl.V1.Model.ConsumerInfo.t`, *default:* `nil`) - Consumer info of this check. * `unusedArguments` (*type:* `list(String.t)`, *default:* `nil`) - A list of fields and label keys that are ignored by the server. The client doesn't need to send them for following requests to improve performance and allow better aggregation. """ @@ -28,10 +29,12 @@ defmodule GoogleApi.ServiceControl.V1.Model.CheckInfo do use GoogleApi.Gax.ModelBase @type t :: %__MODULE__{ + :apiKeyUid => String.t() | nil, :consumerInfo => GoogleApi.ServiceControl.V1.Model.ConsumerInfo.t() | nil, :unusedArguments => list(String.t()) | nil } + field(:apiKeyUid) field(:consumerInfo, as: GoogleApi.ServiceControl.V1.Model.ConsumerInfo) field(:unusedArguments, type: :list) end diff --git a/clients/service_control/lib/google_api/service_control/v1/model/resource.ex b/clients/service_control/lib/google_api/service_control/v1/model/resource.ex index 5d74867b45..c04bb19a0d 100644 --- a/clients/service_control/lib/google_api/service_control/v1/model/resource.ex +++ b/clients/service_control/lib/google_api/service_control/v1/model/resource.ex @@ -21,7 +21,7 @@ defmodule GoogleApi.ServiceControl.V1.Model.Resource do ## Attributes - * `annotations` (*type:* `map()`, *default:* `nil`) - Annotations is an unstructured key-value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: https://kubernetes.io/docs/user-guide/annotations + * `annotations` (*type:* `map()`, *default:* `nil`) - Annotations is an unstructured key-value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/annotations/ * `createTime` (*type:* `DateTime.t`, *default:* `nil`) - Output only. The timestamp when the resource was created. This may be either the time creation was initiated or when it was completed. * `deleteTime` (*type:* `DateTime.t`, *default:* `nil`) - Output only. The timestamp when the resource was deleted. If the resource is not deleted, this must be empty. * `displayName` (*type:* `String.t`, *default:* `nil`) - Mutable. The display name set by clients. Must be <= 63 characters. diff --git a/clients/service_control/lib/google_api/service_control/v1/model/service_delegation_history.ex b/clients/service_control/lib/google_api/service_control/v1/model/service_delegation_history.ex new file mode 100644 index 0000000000..8f410c7083 --- /dev/null +++ b/clients/service_control/lib/google_api/service_control/v1/model/service_delegation_history.ex @@ -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.ServiceControl.V1.Model.ServiceDelegationHistory do + @moduledoc """ + The history of delegation across multiple services as the result of the original user's action. Such as "service A uses its own account to do something for user B". This differs from ServiceAccountDelegationInfo, which only tracks the history of direct token exchanges (impersonation). + + ## Attributes + + * `originalPrincipal` (*type:* `String.t`, *default:* `nil`) - The original end user who initiated the request to GCP. + * `serviceMetadata` (*type:* `list(GoogleApi.ServiceControl.V1.Model.ServiceMetadata.t)`, *default:* `nil`) - Data identifying the service specific jobs or units of work that were involved in a chain of service calls. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :originalPrincipal => String.t() | nil, + :serviceMetadata => list(GoogleApi.ServiceControl.V1.Model.ServiceMetadata.t()) | nil + } + + field(:originalPrincipal) + field(:serviceMetadata, as: GoogleApi.ServiceControl.V1.Model.ServiceMetadata, type: :list) +end + +defimpl Poison.Decoder, for: GoogleApi.ServiceControl.V1.Model.ServiceDelegationHistory do + def decode(value, options) do + GoogleApi.ServiceControl.V1.Model.ServiceDelegationHistory.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.ServiceControl.V1.Model.ServiceDelegationHistory do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/service_control/lib/google_api/service_control/v1/model/service_metadata.ex b/clients/service_control/lib/google_api/service_control/v1/model/service_metadata.ex new file mode 100644 index 0000000000..41fff1d524 --- /dev/null +++ b/clients/service_control/lib/google_api/service_control/v1/model/service_metadata.ex @@ -0,0 +1,52 @@ +# 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.ServiceControl.V1.Model.ServiceMetadata do + @moduledoc """ + Metadata describing the service and additional service specific information used to identify the job or unit of work at hand. + + ## Attributes + + * `jobMetadata` (*type:* `map()`, *default:* `nil`) - Additional metadata provided by service teams to describe service specific job information that was triggered by the original principal. + * `principalSubject` (*type:* `String.t`, *default:* `nil`) - A string representing the principal_subject associated with the identity. For most identities, the format will be `principal://iam.googleapis.com/{identity pool name}/subject/{subject)` except for some GKE identities (GKE_WORKLOAD, FREEFORM, GKE_HUB_WORKLOAD) that are still in the legacy format `serviceAccount:{identity pool name}[{subject}]` If the identity is a Google account (e.g. workspace user account or service account), this will be the email of the prefixed by `serviceAccount:`. For example: `serviceAccount:my-service-account@project-1.iam.gserviceaccount.com`. If the identity is an individual user, the identity will be formatted as: `user:user_ABC@email.com`. + * `serviceDomain` (*type:* `String.t`, *default:* `nil`) - The service's fully qualified domain name, e.g. "dataproc.googleapis.com". + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :jobMetadata => map() | nil, + :principalSubject => String.t() | nil, + :serviceDomain => String.t() | nil + } + + field(:jobMetadata, type: :map) + field(:principalSubject) + field(:serviceDomain) +end + +defimpl Poison.Decoder, for: GoogleApi.ServiceControl.V1.Model.ServiceMetadata do + def decode(value, options) do + GoogleApi.ServiceControl.V1.Model.ServiceMetadata.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.ServiceControl.V1.Model.ServiceMetadata do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/service_control/lib/google_api/service_control/v2/metadata.ex b/clients/service_control/lib/google_api/service_control/v2/metadata.ex index c42519838c..e0b2829138 100644 --- a/clients/service_control/lib/google_api/service_control/v2/metadata.ex +++ b/clients/service_control/lib/google_api/service_control/v2/metadata.ex @@ -20,7 +20,7 @@ defmodule GoogleApi.ServiceControl.V2 do API client metadata for GoogleApi.ServiceControl.V2. """ - @discovery_revision "20221014" + @discovery_revision "20240301" def discovery_revision(), do: @discovery_revision end diff --git a/clients/service_control/lib/google_api/service_control/v2/model/authentication_info.ex b/clients/service_control/lib/google_api/service_control/v2/model/authentication_info.ex index 786eeb5903..fdb37a9dd1 100644 --- a/clients/service_control/lib/google_api/service_control/v2/model/authentication_info.ex +++ b/clients/service_control/lib/google_api/service_control/v2/model/authentication_info.ex @@ -26,6 +26,7 @@ defmodule GoogleApi.ServiceControl.V2.Model.AuthenticationInfo do * `principalSubject` (*type:* `String.t`, *default:* `nil`) - String representation of identity of requesting party. Populated for both first and third party identities. * `serviceAccountDelegationInfo` (*type:* `list(GoogleApi.ServiceControl.V2.Model.ServiceAccountDelegationInfo.t)`, *default:* `nil`) - Identity delegation history of an authenticated service account that makes the request. It contains information on the real authorities that try to access GCP resources by delegating on a service account. When multiple authorities present, they are guaranteed to be sorted based on the original ordering of the identity delegation events. * `serviceAccountKeyName` (*type:* `String.t`, *default:* `nil`) - The name of the service account key used to create or exchange credentials for authenticating the service account making the request. This is a scheme-less URI full resource name. For example: "//iam.googleapis.com/projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}/keys/{key}" + * `serviceDelegationHistory` (*type:* `GoogleApi.ServiceControl.V2.Model.ServiceDelegationHistory.t`, *default:* `nil`) - Records the history of delegated resource access across Google services. * `thirdPartyPrincipal` (*type:* `map()`, *default:* `nil`) - The third party identification (if any) of the authenticated user making the request. When the JSON object represented here has a proto equivalent, the proto name will be indicated in the `@type` property. """ @@ -38,6 +39,8 @@ defmodule GoogleApi.ServiceControl.V2.Model.AuthenticationInfo do :serviceAccountDelegationInfo => list(GoogleApi.ServiceControl.V2.Model.ServiceAccountDelegationInfo.t()) | nil, :serviceAccountKeyName => String.t() | nil, + :serviceDelegationHistory => + GoogleApi.ServiceControl.V2.Model.ServiceDelegationHistory.t() | nil, :thirdPartyPrincipal => map() | nil } @@ -51,6 +54,7 @@ defmodule GoogleApi.ServiceControl.V2.Model.AuthenticationInfo do ) field(:serviceAccountKeyName) + field(:serviceDelegationHistory, as: GoogleApi.ServiceControl.V2.Model.ServiceDelegationHistory) field(:thirdPartyPrincipal, type: :map) end diff --git a/clients/service_control/lib/google_api/service_control/v2/model/report_response.ex b/clients/service_control/lib/google_api/service_control/v2/model/report_response.ex index 857a5ccd10..d02cb99530 100644 --- a/clients/service_control/lib/google_api/service_control/v2/model/report_response.ex +++ b/clients/service_control/lib/google_api/service_control/v2/model/report_response.ex @@ -17,7 +17,7 @@ defmodule GoogleApi.ServiceControl.V2.Model.ReportResponse do @moduledoc """ - Response message for the Report method. If the request contains any invalid data, the server returns an RPC error. + Response message for the Report method. ## Attributes diff --git a/clients/service_control/lib/google_api/service_control/v2/model/resource.ex b/clients/service_control/lib/google_api/service_control/v2/model/resource.ex index 8456c465ba..0e340340ce 100644 --- a/clients/service_control/lib/google_api/service_control/v2/model/resource.ex +++ b/clients/service_control/lib/google_api/service_control/v2/model/resource.ex @@ -21,7 +21,7 @@ defmodule GoogleApi.ServiceControl.V2.Model.Resource do ## Attributes - * `annotations` (*type:* `map()`, *default:* `nil`) - Annotations is an unstructured key-value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: https://kubernetes.io/docs/user-guide/annotations + * `annotations` (*type:* `map()`, *default:* `nil`) - Annotations is an unstructured key-value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/annotations/ * `createTime` (*type:* `DateTime.t`, *default:* `nil`) - Output only. The timestamp when the resource was created. This may be either the time creation was initiated or when it was completed. * `deleteTime` (*type:* `DateTime.t`, *default:* `nil`) - Output only. The timestamp when the resource was deleted. If the resource is not deleted, this must be empty. * `displayName` (*type:* `String.t`, *default:* `nil`) - Mutable. The display name set by clients. Must be <= 63 characters. diff --git a/clients/service_control/lib/google_api/service_control/v2/model/resource_info.ex b/clients/service_control/lib/google_api/service_control/v2/model/resource_info.ex index 87186272f8..b7967332c3 100644 --- a/clients/service_control/lib/google_api/service_control/v2/model/resource_info.ex +++ b/clients/service_control/lib/google_api/service_control/v2/model/resource_info.ex @@ -21,8 +21,8 @@ defmodule GoogleApi.ServiceControl.V2.Model.ResourceInfo do ## Attributes - * `container` (*type:* `String.t`, *default:* `nil`) - Optional. The identifier of the container of this resource. For Google Cloud APIs, the resource container must be one of the following formats: - `projects/` - `folders/` - `organizations/` For the policy enforcement on the container level (VPCSC and Location Policy check), this field takes precedence on the container extracted from name when presents. - * `location` (*type:* `String.t`, *default:* `nil`) - Optional. The location of the resource. The value must be a valid zone, region or multiregion. For example: "europe-west4" or "northamerica-northeast1-a" + * `container` (*type:* `String.t`, *default:* `nil`) - Optional. The identifier of the container of this resource. For Google Cloud APIs, the resource container must be one of the following formats: - `projects/` - `folders/` - `organizations/` Required for the policy enforcement on the container level (e.g. VPCSC, Location Policy check, Org Policy check). + * `location` (*type:* `String.t`, *default:* `nil`) - Optional. The location of the resource, it must be a valid zone, region or multiregion, for example: "europe-west4", "northamerica-northeast1-a". Required for location policy check. * `name` (*type:* `String.t`, *default:* `nil`) - The name of the resource referenced in the request. * `permission` (*type:* `String.t`, *default:* `nil`) - The resource permission needed for this request. The format must be "{service}/{plural}.{verb}". * `type` (*type:* `String.t`, *default:* `nil`) - The resource type in the format of "{service}/{kind}". diff --git a/clients/service_control/lib/google_api/service_control/v2/model/service_delegation_history.ex b/clients/service_control/lib/google_api/service_control/v2/model/service_delegation_history.ex new file mode 100644 index 0000000000..5a33bc25ee --- /dev/null +++ b/clients/service_control/lib/google_api/service_control/v2/model/service_delegation_history.ex @@ -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.ServiceControl.V2.Model.ServiceDelegationHistory do + @moduledoc """ + The history of delegation across multiple services as the result of the original user's action. Such as "service A uses its own account to do something for user B". This differs from ServiceAccountDelegationInfo, which only tracks the history of direct token exchanges (impersonation). + + ## Attributes + + * `originalPrincipal` (*type:* `String.t`, *default:* `nil`) - The original end user who initiated the request to GCP. + * `serviceMetadata` (*type:* `list(GoogleApi.ServiceControl.V2.Model.ServiceMetadata.t)`, *default:* `nil`) - Data identifying the service specific jobs or units of work that were involved in a chain of service calls. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :originalPrincipal => String.t() | nil, + :serviceMetadata => list(GoogleApi.ServiceControl.V2.Model.ServiceMetadata.t()) | nil + } + + field(:originalPrincipal) + field(:serviceMetadata, as: GoogleApi.ServiceControl.V2.Model.ServiceMetadata, type: :list) +end + +defimpl Poison.Decoder, for: GoogleApi.ServiceControl.V2.Model.ServiceDelegationHistory do + def decode(value, options) do + GoogleApi.ServiceControl.V2.Model.ServiceDelegationHistory.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.ServiceControl.V2.Model.ServiceDelegationHistory do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/service_control/lib/google_api/service_control/v2/model/service_metadata.ex b/clients/service_control/lib/google_api/service_control/v2/model/service_metadata.ex new file mode 100644 index 0000000000..53c79906f2 --- /dev/null +++ b/clients/service_control/lib/google_api/service_control/v2/model/service_metadata.ex @@ -0,0 +1,52 @@ +# 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.ServiceControl.V2.Model.ServiceMetadata do + @moduledoc """ + Metadata describing the service and additional service specific information used to identify the job or unit of work at hand. + + ## Attributes + + * `jobMetadata` (*type:* `map()`, *default:* `nil`) - Additional metadata provided by service teams to describe service specific job information that was triggered by the original principal. + * `principalSubject` (*type:* `String.t`, *default:* `nil`) - A string representing the principal_subject associated with the identity. For most identities, the format will be `principal://iam.googleapis.com/{identity pool name}/subject/{subject)` except for some GKE identities (GKE_WORKLOAD, FREEFORM, GKE_HUB_WORKLOAD) that are still in the legacy format `serviceAccount:{identity pool name}[{subject}]` If the identity is a Google account (e.g. workspace user account or service account), this will be the email of the prefixed by `serviceAccount:`. For example: `serviceAccount:my-service-account@project-1.iam.gserviceaccount.com`. If the identity is an individual user, the identity will be formatted as: `user:user_ABC@email.com`. + * `serviceDomain` (*type:* `String.t`, *default:* `nil`) - The service's fully qualified domain name, e.g. "dataproc.googleapis.com". + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :jobMetadata => map() | nil, + :principalSubject => String.t() | nil, + :serviceDomain => String.t() | nil + } + + field(:jobMetadata, type: :map) + field(:principalSubject) + field(:serviceDomain) +end + +defimpl Poison.Decoder, for: GoogleApi.ServiceControl.V2.Model.ServiceMetadata do + def decode(value, options) do + GoogleApi.ServiceControl.V2.Model.ServiceMetadata.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.ServiceControl.V2.Model.ServiceMetadata do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end