Skip to content
This repository was archived by the owner on Oct 16, 2023. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .github/release-please.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
releaseType: python
handleGHRelease: true
manifest: true
# NOTE: this section is generated by synthtool.languages.python
# See https://github.com/googleapis/synthtool/blob/master/synthtool/languages/python.py
branches:
Expand Down
3 changes: 3 additions & 0 deletions .release-please-manifest.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
".": "2.9.0"
}
1 change: 0 additions & 1 deletion docs/iam_credentials_v1/types.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,4 @@ Types for Google Cloud Iam Credentials v1 API

.. automodule:: google.cloud.iam_credentials_v1.types
:members:
:undoc-members:
:show-inheritance:
1 change: 0 additions & 1 deletion docs/iam_v2/types.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,4 @@ Types for Google Cloud Iam v2 API

.. automodule:: google.cloud.iam_v2.types
:members:
:undoc-members:
:show-inheritance:
1 change: 0 additions & 1 deletion docs/iam_v2beta/types.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,4 @@ Types for Google Cloud Iam v2beta API

.. automodule:: google.cloud.iam_v2beta.types
:members:
:undoc-members:
:show-inheritance:
49 changes: 49 additions & 0 deletions google/cloud/iam/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
# -*- coding: utf-8 -*-
# Copyright 2022 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.
#
from google.cloud.iam import gapic_version as package_version

__version__ = package_version.__version__


from google.cloud.iam_v2.services.policies.async_client import PoliciesAsyncClient
from google.cloud.iam_v2.services.policies.client import PoliciesClient
from google.cloud.iam_v2.types.deny import DenyRule
from google.cloud.iam_v2.types.policy import (
CreatePolicyRequest,
DeletePolicyRequest,
GetPolicyRequest,
ListPoliciesRequest,
ListPoliciesResponse,
Policy,
PolicyOperationMetadata,
PolicyRule,
UpdatePolicyRequest,
)

__all__ = (
"PoliciesClient",
"PoliciesAsyncClient",
"DenyRule",
"CreatePolicyRequest",
"DeletePolicyRequest",
"GetPolicyRequest",
"ListPoliciesRequest",
"ListPoliciesResponse",
"Policy",
"PolicyOperationMetadata",
"PolicyRule",
"UpdatePolicyRequest",
)
16 changes: 16 additions & 0 deletions google/cloud/iam/gapic_version.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# -*- coding: utf-8 -*-
# Copyright 2022 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.
#
__version__ = "2.9.0" # {x-release-please-version}
2 changes: 2 additions & 0 deletions google/cloud/iam/py.typed
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
# Marker file for PEP 561.
# The google-cloud-iam package uses inline types.
4 changes: 4 additions & 0 deletions google/cloud/iam_credentials/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,10 @@
# See the License for the specific language governing permissions and
# limitations under the License.
#
from google.cloud.iam_credentials import gapic_version as package_version

__version__ = package_version.__version__


from google.cloud.iam_credentials_v1.services.iam_credentials.async_client import (
IAMCredentialsAsyncClient,
Expand Down
16 changes: 16 additions & 0 deletions google/cloud/iam_credentials/gapic_version.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# -*- coding: utf-8 -*-
# Copyright 2022 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.
#
__version__ = "2.9.0" # {x-release-please-version}
4 changes: 4 additions & 0 deletions google/cloud/iam_credentials_v1/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,10 @@
# See the License for the specific language governing permissions and
# limitations under the License.
#
from google.cloud.iam_credentials import gapic_version as package_version

__version__ = package_version.__version__


from .services.iam_credentials import IAMCredentialsAsyncClient, IAMCredentialsClient
from .types.common import (
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,17 @@
from collections import OrderedDict
import functools
import re
from typing import Dict, Mapping, Optional, Sequence, Tuple, Type, Union
from typing import (
Dict,
Mapping,
MutableMapping,
MutableSequence,
Optional,
Sequence,
Tuple,
Type,
Union,
)

from google.api_core import exceptions as core_exceptions
from google.api_core import gapic_v1
Expand Down Expand Up @@ -173,9 +183,9 @@ def transport(self) -> IAMCredentialsTransport:
def __init__(
self,
*,
credentials: ga_credentials.Credentials = None,
credentials: Optional[ga_credentials.Credentials] = None,
transport: Union[str, IAMCredentialsTransport] = "grpc_asyncio",
client_options: ClientOptions = None,
client_options: Optional[ClientOptions] = None,
client_info: gapic_v1.client_info.ClientInfo = DEFAULT_CLIENT_INFO,
) -> None:
"""Instantiates the iam credentials client.
Expand Down Expand Up @@ -219,14 +229,14 @@ def __init__(

async def generate_access_token(
self,
request: Union[common.GenerateAccessTokenRequest, dict] = None,
request: Optional[Union[common.GenerateAccessTokenRequest, dict]] = None,
*,
name: str = None,
delegates: Sequence[str] = None,
scope: Sequence[str] = None,
lifetime: duration_pb2.Duration = None,
name: Optional[str] = None,
delegates: Optional[MutableSequence[str]] = None,
scope: Optional[MutableSequence[str]] = None,
lifetime: Optional[duration_pb2.Duration] = None,
retry: OptionalRetry = gapic_v1.method.DEFAULT,
timeout: float = None,
timeout: Optional[float] = None,
metadata: Sequence[Tuple[str, str]] = (),
) -> common.GenerateAccessTokenResponse:
r"""Generates an OAuth 2.0 access token for a service
Expand Down Expand Up @@ -260,7 +270,7 @@ async def sample_generate_access_token():
print(response)

Args:
request (Union[google.cloud.iam_credentials_v1.types.GenerateAccessTokenRequest, dict]):
request (Optional[Union[google.cloud.iam_credentials_v1.types.GenerateAccessTokenRequest, dict]]):
The request object.
name (:class:`str`):
Required. The resource name of the service account for
Expand All @@ -273,7 +283,7 @@ async def sample_generate_access_token():
This corresponds to the ``name`` field
on the ``request`` instance; if ``request`` is provided, this
should not be set.
delegates (:class:`Sequence[str]`):
delegates (:class:`MutableSequence[str]`):
The sequence of service accounts in a delegation chain.
Each service account must be granted the
``roles/iam.serviceAccountTokenCreator`` role on its
Expand All @@ -291,7 +301,7 @@ async def sample_generate_access_token():
This corresponds to the ``delegates`` field
on the ``request`` instance; if ``request`` is provided, this
should not be set.
scope (:class:`Sequence[str]`):
scope (:class:`MutableSequence[str]`):
Required. Code to identify the scopes
to be included in the OAuth 2.0 access
token. See
Expand Down Expand Up @@ -383,14 +393,14 @@ async def sample_generate_access_token():

async def generate_id_token(
self,
request: Union[common.GenerateIdTokenRequest, dict] = None,
request: Optional[Union[common.GenerateIdTokenRequest, dict]] = None,
*,
name: str = None,
delegates: Sequence[str] = None,
audience: str = None,
include_email: bool = None,
name: Optional[str] = None,
delegates: Optional[MutableSequence[str]] = None,
audience: Optional[str] = None,
include_email: Optional[bool] = None,
retry: OptionalRetry = gapic_v1.method.DEFAULT,
timeout: float = None,
timeout: Optional[float] = None,
metadata: Sequence[Tuple[str, str]] = (),
) -> common.GenerateIdTokenResponse:
r"""Generates an OpenID Connect ID token for a service
Expand Down Expand Up @@ -424,7 +434,7 @@ async def sample_generate_id_token():
print(response)

Args:
request (Union[google.cloud.iam_credentials_v1.types.GenerateIdTokenRequest, dict]):
request (Optional[Union[google.cloud.iam_credentials_v1.types.GenerateIdTokenRequest, dict]]):
The request object.
name (:class:`str`):
Required. The resource name of the service account for
Expand All @@ -437,7 +447,7 @@ async def sample_generate_id_token():
This corresponds to the ``name`` field
on the ``request`` instance; if ``request`` is provided, this
should not be set.
delegates (:class:`Sequence[str]`):
delegates (:class:`MutableSequence[str]`):
The sequence of service accounts in a delegation chain.
Each service account must be granted the
``roles/iam.serviceAccountTokenCreator`` role on its
Expand Down Expand Up @@ -541,13 +551,13 @@ async def sample_generate_id_token():

async def sign_blob(
self,
request: Union[common.SignBlobRequest, dict] = None,
request: Optional[Union[common.SignBlobRequest, dict]] = None,
*,
name: str = None,
delegates: Sequence[str] = None,
payload: bytes = None,
name: Optional[str] = None,
delegates: Optional[MutableSequence[str]] = None,
payload: Optional[bytes] = None,
retry: OptionalRetry = gapic_v1.method.DEFAULT,
timeout: float = None,
timeout: Optional[float] = None,
metadata: Sequence[Tuple[str, str]] = (),
) -> common.SignBlobResponse:
r"""Signs a blob using a service account's system-managed
Expand Down Expand Up @@ -581,7 +591,7 @@ async def sample_sign_blob():
print(response)

Args:
request (Union[google.cloud.iam_credentials_v1.types.SignBlobRequest, dict]):
request (Optional[Union[google.cloud.iam_credentials_v1.types.SignBlobRequest, dict]]):
The request object.
name (:class:`str`):
Required. The resource name of the service account for
Expand All @@ -594,7 +604,7 @@ async def sample_sign_blob():
This corresponds to the ``name`` field
on the ``request`` instance; if ``request`` is provided, this
should not be set.
delegates (:class:`Sequence[str]`):
delegates (:class:`MutableSequence[str]`):
The sequence of service accounts in a delegation chain.
Each service account must be granted the
``roles/iam.serviceAccountTokenCreator`` role on its
Expand Down Expand Up @@ -685,13 +695,13 @@ async def sample_sign_blob():

async def sign_jwt(
self,
request: Union[common.SignJwtRequest, dict] = None,
request: Optional[Union[common.SignJwtRequest, dict]] = None,
*,
name: str = None,
delegates: Sequence[str] = None,
payload: str = None,
name: Optional[str] = None,
delegates: Optional[MutableSequence[str]] = None,
payload: Optional[str] = None,
retry: OptionalRetry = gapic_v1.method.DEFAULT,
timeout: float = None,
timeout: Optional[float] = None,
metadata: Sequence[Tuple[str, str]] = (),
) -> common.SignJwtResponse:
r"""Signs a JWT using a service account's system-managed
Expand Down Expand Up @@ -725,7 +735,7 @@ async def sample_sign_jwt():
print(response)

Args:
request (Union[google.cloud.iam_credentials_v1.types.SignJwtRequest, dict]):
request (Optional[Union[google.cloud.iam_credentials_v1.types.SignJwtRequest, dict]]):
The request object.
name (:class:`str`):
Required. The resource name of the service account for
Expand All @@ -738,7 +748,7 @@ async def sample_sign_jwt():
This corresponds to the ``name`` field
on the ``request`` instance; if ``request`` is provided, this
should not be set.
delegates (:class:`Sequence[str]`):
delegates (:class:`MutableSequence[str]`):
The sequence of service accounts in a delegation chain.
Each service account must be granted the
``roles/iam.serviceAccountTokenCreator`` role on its
Expand Down
Loading