IAMServiceResource
Auto-generated documentation for IAM type annotations stubs module mypy-boto3-iam.
IAMServiceResource
Type annotations and code completion for boto3.resource("iam"), included resources and collections.
boto3 documentation
from mypy_boto3_iam.service_resource import IAMServiceResource
def get_iam_resource() -> IAMServiceResource:
return boto3.resource("iam")
Attributes
-
meta: IAMResourceMeta -
groups: ServiceResourceGroupsCollection -
instance_profiles: ServiceResourceInstanceProfilesCollection -
policies: ServiceResourcePoliciesCollection -
saml_providers: ServiceResourceSamlProvidersCollection -
server_certificates: ServiceResourceServerCertificatesCollection -
virtual_mfa_devices: ServiceResourceVirtualMfaDevicesCollection
Collections
ServiceResourceGroupsCollection
Provides access to Group resource.
Type annotations and code completion for boto3.resource("iam").groups collection.
boto3 documentation
from mypy_boto3_iam.service_resource import ServiceResourceGroupsCollection
def get_collection() -> ServiceResourceGroupsCollection:
return boto3.resource("iam").groups
ServiceResourceInstanceProfilesCollection
Provides access to InstanceProfile resource.
Type annotations and code completion for boto3.resource("iam").instance_profiles collection.
boto3 documentation
from mypy_boto3_iam.service_resource import ServiceResourceInstanceProfilesCollection
def get_collection() -> ServiceResourceInstanceProfilesCollection:
return boto3.resource("iam").instance_profiles
ServiceResourcePoliciesCollection
Provides access to Policy resource.
Type annotations and code completion for boto3.resource("iam").policies collection.
boto3 documentation
from mypy_boto3_iam.service_resource import ServiceResourcePoliciesCollection
def get_collection() -> ServiceResourcePoliciesCollection:
return boto3.resource("iam").policies
ServiceResourceRolesCollection
Provides access to Role resource.
Type annotations and code completion for boto3.resource("iam").roles collection.
boto3 documentation
from mypy_boto3_iam.service_resource import ServiceResourceRolesCollection
def get_collection() -> ServiceResourceRolesCollection:
return boto3.resource("iam").roles
ServiceResourceSamlProvidersCollection
Provides access to SamlProvider resource.
Type annotations and code completion for boto3.resource("iam").saml_providers collection.
boto3 documentation
from mypy_boto3_iam.service_resource import ServiceResourceSamlProvidersCollection
def get_collection() -> ServiceResourceSamlProvidersCollection:
return boto3.resource("iam").saml_providers
ServiceResourceServerCertificatesCollection
Provides access to ServerCertificate resource.
Type annotations and code completion for boto3.resource("iam").server_certificates collection.
boto3 documentation
from mypy_boto3_iam.service_resource import ServiceResourceServerCertificatesCollection
def get_collection() -> ServiceResourceServerCertificatesCollection:
return boto3.resource("iam").server_certificates
ServiceResourceUsersCollection
Provides access to User resource.
Type annotations and code completion for boto3.resource("iam").users collection.
boto3 documentation
from mypy_boto3_iam.service_resource import ServiceResourceUsersCollection
def get_collection() -> ServiceResourceUsersCollection:
return boto3.resource("iam").users
ServiceResourceVirtualMfaDevicesCollection
Provides access to VirtualMfaDevice resource.
Type annotations and code completion for boto3.resource("iam").virtual_mfa_devices collection.
boto3 documentation
from mypy_boto3_iam.service_resource import ServiceResourceVirtualMfaDevicesCollection
def get_collection() -> ServiceResourceVirtualMfaDevicesCollection:
return boto3.resource("iam").virtual_mfa_devices
Methods
IAMServiceResource.AccessKey method
Creates a AccessKey resource.
Type annotations and code completion for boto3.resource("iam").AccessKey method.
boto3 documentation
kwargs: ServiceResourceAccessKeyRequestTypeDef = { # (1)
"user_name": ...,
"id": ...,
}
parent.AccessKey(**kwargs)
IAMServiceResource.AccessKeyPair method
Creates a AccessKeyPair resource.
Type annotations and code completion for boto3.resource("iam").AccessKeyPair method.
boto3 documentation
def AccessKeyPair(
self,
user_name: str,
id: str,
secret: str,
) -> AccessKeyPair:
...
kwargs: ServiceResourceAccessKeyPairRequestTypeDef = { # (1)
"user_name": ...,
"id": ...,
"secret": ...,
}
parent.AccessKeyPair(**kwargs)
IAMServiceResource.AccountPasswordPolicy method
Creates a AccountPasswordPolicy resource.
Type annotations and code completion for boto3.resource("iam").AccountPasswordPolicy method.
boto3 documentation
IAMServiceResource.AccountSummary method
Creates a AccountSummary resource.
Type annotations and code completion for boto3.resource("iam").AccountSummary method.
boto3 documentation
IAMServiceResource.AssumeRolePolicy method
Creates a AssumeRolePolicy resource.
Type annotations and code completion for boto3.resource("iam").AssumeRolePolicy method.
boto3 documentation
kwargs: ServiceResourceAssumeRolePolicyRequestTypeDef = { # (1)
"role_name": ...,
}
parent.AssumeRolePolicy(**kwargs)
IAMServiceResource.CurrentUser method
Creates a CurrentUser resource.
Type annotations and code completion for boto3.resource("iam").CurrentUser method.
boto3 documentation
IAMServiceResource.Group method
Creates a Group resource.
Type annotations and code completion for boto3.resource("iam").Group method.
boto3 documentation
kwargs: ServiceResourceGroupRequestTypeDef = { # (1)
"name": ...,
}
parent.Group(**kwargs)
IAMServiceResource.GroupPolicy method
Creates a GroupPolicy resource.
Type annotations and code completion for boto3.resource("iam").GroupPolicy method.
boto3 documentation
kwargs: ServiceResourceGroupPolicyRequestTypeDef = { # (1)
"group_name": ...,
"name": ...,
}
parent.GroupPolicy(**kwargs)
IAMServiceResource.InstanceProfile method
Creates a InstanceProfile resource.
Type annotations and code completion for boto3.resource("iam").InstanceProfile method.
boto3 documentation
kwargs: ServiceResourceInstanceProfileRequestTypeDef = { # (1)
"name": ...,
}
parent.InstanceProfile(**kwargs)
IAMServiceResource.LoginProfile method
Creates a LoginProfile resource.
Type annotations and code completion for boto3.resource("iam").LoginProfile method.
boto3 documentation
kwargs: ServiceResourceLoginProfileRequestTypeDef = { # (1)
"user_name": ...,
}
parent.LoginProfile(**kwargs)
IAMServiceResource.MfaDevice method
Creates a MfaDevice resource.
Type annotations and code completion for boto3.resource("iam").MfaDevice method.
boto3 documentation
kwargs: ServiceResourceMfaDeviceRequestTypeDef = { # (1)
"user_name": ...,
"serial_number": ...,
}
parent.MfaDevice(**kwargs)
IAMServiceResource.Policy method
Creates a Policy resource.
Type annotations and code completion for boto3.resource("iam").Policy method.
boto3 documentation
kwargs: ServiceResourcePolicyRequestTypeDef = { # (1)
"policy_arn": ...,
}
parent.Policy(**kwargs)
IAMServiceResource.PolicyVersion method
Creates a PolicyVersion resource.
Type annotations and code completion for boto3.resource("iam").PolicyVersion method.
boto3 documentation
kwargs: ServiceResourcePolicyVersionRequestTypeDef = { # (1)
"arn": ...,
"version_id": ...,
}
parent.PolicyVersion(**kwargs)
IAMServiceResource.Role method
Creates a Role resource.
Type annotations and code completion for boto3.resource("iam").Role method.
boto3 documentation
kwargs: ServiceResourceRoleRequestTypeDef = { # (1)
"name": ...,
}
parent.Role(**kwargs)
IAMServiceResource.RolePolicy method
Creates a RolePolicy resource.
Type annotations and code completion for boto3.resource("iam").RolePolicy method.
boto3 documentation
kwargs: ServiceResourceRolePolicyRequestTypeDef = { # (1)
"role_name": ...,
"name": ...,
}
parent.RolePolicy(**kwargs)
IAMServiceResource.SamlProvider method
Creates a SamlProvider resource.
Type annotations and code completion for boto3.resource("iam").SamlProvider method.
boto3 documentation
kwargs: ServiceResourceSamlProviderRequestTypeDef = { # (1)
"arn": ...,
}
parent.SamlProvider(**kwargs)
IAMServiceResource.ServerCertificate method
Creates a ServerCertificate resource.
Type annotations and code completion for boto3.resource("iam").ServerCertificate method.
boto3 documentation
kwargs: ServiceResourceServerCertificateRequestTypeDef = { # (1)
"name": ...,
}
parent.ServerCertificate(**kwargs)
IAMServiceResource.SigningCertificate method
Creates a SigningCertificate resource.
Type annotations and code completion for boto3.resource("iam").SigningCertificate method.
boto3 documentation
def SigningCertificate(
self,
user_name: str,
id: str,
) -> SigningCertificate:
...
kwargs: ServiceResourceSigningCertificateRequestTypeDef = { # (1)
"user_name": ...,
"id": ...,
}
parent.SigningCertificate(**kwargs)
IAMServiceResource.User method
Creates a User resource.
Type annotations and code completion for boto3.resource("iam").User method.
boto3 documentation
kwargs: ServiceResourceUserRequestTypeDef = { # (1)
"name": ...,
}
parent.User(**kwargs)
IAMServiceResource.UserPolicy method
Creates a UserPolicy resource.
Type annotations and code completion for boto3.resource("iam").UserPolicy method.
boto3 documentation
kwargs: ServiceResourceUserPolicyRequestTypeDef = { # (1)
"user_name": ...,
"name": ...,
}
parent.UserPolicy(**kwargs)
IAMServiceResource.VirtualMfaDevice method
Creates a VirtualMfaDevice resource.
Type annotations and code completion for boto3.resource("iam").VirtualMfaDevice method.
boto3 documentation
kwargs: ServiceResourceVirtualMfaDeviceRequestTypeDef = { # (1)
"serial_number": ...,
}
parent.VirtualMfaDevice(**kwargs)
IAMServiceResource.change_password method
Changes the password of the IAM user who is calling this operation.
Type annotations and code completion for boto3.resource("iam").change_password method.
boto3 documentation
kwargs: ChangePasswordRequestServiceResourceChangePasswordTypeDef = { # (1)
"OldPassword": ...,
"NewPassword": ...,
}
parent.change_password(**kwargs)
IAMServiceResource.create_account_alias method
Creates an alias for your Amazon Web Services account.
Type annotations and code completion for boto3.resource("iam").create_account_alias method.
boto3 documentation
kwargs: CreateAccountAliasRequestServiceResourceCreateAccountAliasTypeDef = { # (1)
"AccountAlias": ...,
}
parent.create_account_alias(**kwargs)
IAMServiceResource.create_account_password_policy method
Updates the password policy settings for the Amazon Web Services account.
Type annotations and code completion for boto3.resource("iam").create_account_password_policy method.
boto3 documentation
def create_account_password_policy(
self,
*,
MinimumPasswordLength: int = ...,
RequireSymbols: bool = ...,
RequireNumbers: bool = ...,
RequireUppercaseCharacters: bool = ...,
RequireLowercaseCharacters: bool = ...,
AllowUsersToChangePassword: bool = ...,
MaxPasswordAge: int = ...,
PasswordReusePrevention: int = ...,
HardExpiry: bool = ...,
) -> AccountPasswordPolicy:
...
kwargs: UpdateAccountPasswordPolicyRequestServiceResourceCreateAccountPasswordPolicyTypeDef = { # (1)
"MinimumPasswordLength": ...,
}
parent.create_account_password_policy(**kwargs)
IAMServiceResource.create_group method
Creates a new group.
Type annotations and code completion for boto3.resource("iam").create_group method.
boto3 documentation
kwargs: CreateGroupRequestServiceResourceCreateGroupTypeDef = { # (1)
"GroupName": ...,
}
parent.create_group(**kwargs)
IAMServiceResource.create_instance_profile method
Creates a new instance profile.
Type annotations and code completion for boto3.resource("iam").create_instance_profile method.
boto3 documentation
def create_instance_profile(
self,
*,
InstanceProfileName: str,
Path: str = ...,
Tags: Sequence[TagTypeDef] = ..., # (1)
) -> InstanceProfile:
...
- See TagTypeDef
kwargs: CreateInstanceProfileRequestServiceResourceCreateInstanceProfileTypeDef = { # (1)
"InstanceProfileName": ...,
}
parent.create_instance_profile(**kwargs)
IAMServiceResource.create_policy method
Creates a new managed policy for your Amazon Web Services account.
Type annotations and code completion for boto3.resource("iam").create_policy method.
boto3 documentation
def create_policy(
self,
*,
PolicyName: str,
PolicyDocument: str,
Path: str = ...,
Description: str = ...,
Tags: Sequence[TagTypeDef] = ..., # (1)
) -> Policy:
...
- See TagTypeDef
kwargs: CreatePolicyRequestServiceResourceCreatePolicyTypeDef = { # (1)
"PolicyName": ...,
"PolicyDocument": ...,
}
parent.create_policy(**kwargs)
IAMServiceResource.create_role method
Creates a new role for your Amazon Web Services account.
Type annotations and code completion for boto3.resource("iam").create_role method.
boto3 documentation
def create_role(
self,
*,
RoleName: str,
AssumeRolePolicyDocument: str,
Path: str = ...,
Description: str = ...,
MaxSessionDuration: int = ...,
PermissionsBoundary: str = ...,
Tags: Sequence[TagTypeDef] = ..., # (1)
) -> Role:
...
- See TagTypeDef
kwargs: CreateRoleRequestServiceResourceCreateRoleTypeDef = { # (1)
"RoleName": ...,
"AssumeRolePolicyDocument": ...,
}
parent.create_role(**kwargs)
IAMServiceResource.create_saml_provider method
Creates an IAM resource that describes an identity provider (IdP) that supports SAML 2.0.
Type annotations and code completion for boto3.resource("iam").create_saml_provider method.
boto3 documentation
def create_saml_provider(
self,
*,
SAMLMetadataDocument: str,
Name: str,
Tags: Sequence[TagTypeDef] = ..., # (1)
) -> SamlProvider:
...
- See TagTypeDef
kwargs: CreateSAMLProviderRequestServiceResourceCreateSamlProviderTypeDef = { # (1)
"SAMLMetadataDocument": ...,
"Name": ...,
}
parent.create_saml_provider(**kwargs)
IAMServiceResource.create_server_certificate method
Uploads a server certificate entity for the Amazon Web Services account.
Type annotations and code completion for boto3.resource("iam").create_server_certificate method.
boto3 documentation
def create_server_certificate(
self,
*,
ServerCertificateName: str,
CertificateBody: str,
PrivateKey: str,
Path: str = ...,
CertificateChain: str = ...,
Tags: Sequence[TagTypeDef] = ..., # (1)
) -> ServerCertificate:
...
- See TagTypeDef
kwargs: UploadServerCertificateRequestServiceResourceCreateServerCertificateTypeDef = { # (1)
"ServerCertificateName": ...,
"CertificateBody": ...,
"PrivateKey": ...,
}
parent.create_server_certificate(**kwargs)
IAMServiceResource.create_signing_certificate method
Uploads an X.509 signing certificate and associates it with the specified IAM user.
Type annotations and code completion for boto3.resource("iam").create_signing_certificate method.
boto3 documentation
def create_signing_certificate(
self,
*,
CertificateBody: str,
UserName: str = ...,
) -> SigningCertificate:
...
kwargs: UploadSigningCertificateRequestServiceResourceCreateSigningCertificateTypeDef = { # (1)
"CertificateBody": ...,
}
parent.create_signing_certificate(**kwargs)
IAMServiceResource.create_user method
Creates a new IAM user for your Amazon Web Services account.
Type annotations and code completion for boto3.resource("iam").create_user method.
boto3 documentation
def create_user(
self,
*,
UserName: str,
Path: str = ...,
PermissionsBoundary: str = ...,
Tags: Sequence[TagTypeDef] = ..., # (1)
) -> User:
...
- See TagTypeDef
kwargs: CreateUserRequestServiceResourceCreateUserTypeDef = { # (1)
"UserName": ...,
}
parent.create_user(**kwargs)
IAMServiceResource.create_virtual_mfa_device method
Creates a new virtual MFA device for the Amazon Web Services account.
Type annotations and code completion for boto3.resource("iam").create_virtual_mfa_device method.
boto3 documentation
def create_virtual_mfa_device(
self,
*,
VirtualMFADeviceName: str,
Path: str = ...,
Tags: Sequence[TagTypeDef] = ..., # (1)
) -> VirtualMfaDevice:
...
- See TagTypeDef
kwargs: CreateVirtualMFADeviceRequestServiceResourceCreateVirtualMfaDeviceTypeDef = { # (1)
"VirtualMFADeviceName": ...,
}
parent.create_virtual_mfa_device(**kwargs)
IAMServiceResource.get_available_subresources method
Returns a list of all the available sub-resources for this Resource.
Type annotations and code completion for boto3.resource("iam").get_available_subresources method.
boto3 documentation
AccessKey
Type annotations and code completion for boto3.resource("iam").AccessKey class.
boto3 documentation
from mypy_boto3_iam.service_resource import AccessKey
def get_resource() -> AccessKey:
return boto3.resource("iam").AccessKey(...)
AccessKey attributes
access_key_id:strstatus: statusTypeTypecreate_date:datetimeuser_name:strid:str
AccessKey methods
AccessKey.User method
Creates a User resource.
Type annotations and code completion for boto3.resource("iam").User method.
boto3 documentation
AccessKey.activate method
Changes the status of the specified access key from Active to Inactive, or vice versa.
Type annotations and code completion for boto3.resource("iam").activate method.
boto3 documentation
- See statusTypeType
kwargs: UpdateAccessKeyRequestAccessKeyActivateTypeDef = { # (1)
"Status": ...,
}
parent.activate(**kwargs)
AccessKey.deactivate method
Changes the status of the specified access key from Active to Inactive, or vice versa.
Type annotations and code completion for boto3.resource("iam").deactivate method.
boto3 documentation
- See statusTypeType
kwargs: UpdateAccessKeyRequestAccessKeyDeactivateTypeDef = { # (1)
"Status": ...,
}
parent.deactivate(**kwargs)
AccessKey.delete method
Deletes the access key pair associated with the specified IAM user.
Type annotations and code completion for boto3.resource("iam").delete method.
boto3 documentation
AccessKey.get_available_subresources method
Returns a list of all the available sub-resources for this Resource.
Type annotations and code completion for boto3.resource("iam").get_available_subresources method.
boto3 documentation
AccessKeyPair
Type annotations and code completion for boto3.resource("iam").AccessKeyPair class.
boto3 documentation
from mypy_boto3_iam.service_resource import AccessKeyPair
def get_resource() -> AccessKeyPair:
return boto3.resource("iam").AccessKeyPair(...)
AccessKeyPair attributes
access_key_id:strstatus: statusTypeTypesecret_access_key:strcreate_date:datetimeuser_name:strid:strsecret:str
AccessKeyPair methods
AccessKeyPair.activate method
Changes the status of the specified access key from Active to Inactive, or vice versa.
Type annotations and code completion for boto3.resource("iam").activate method.
boto3 documentation
- See statusTypeType
kwargs: UpdateAccessKeyRequestAccessKeyPairActivateTypeDef = { # (1)
"Status": ...,
}
parent.activate(**kwargs)
AccessKeyPair.deactivate method
Changes the status of the specified access key from Active to Inactive, or vice versa.
Type annotations and code completion for boto3.resource("iam").deactivate method.
boto3 documentation
- See statusTypeType
kwargs: UpdateAccessKeyRequestAccessKeyPairDeactivateTypeDef = { # (1)
"Status": ...,
}
parent.deactivate(**kwargs)
AccessKeyPair.delete method
Deletes the access key pair associated with the specified IAM user.
Type annotations and code completion for boto3.resource("iam").delete method.
boto3 documentation
AccessKeyPair.get_available_subresources method
Returns a list of all the available sub-resources for this Resource.
Type annotations and code completion for boto3.resource("iam").get_available_subresources method.
boto3 documentation
AccountPasswordPolicy
Type annotations and code completion for boto3.resource("iam").AccountPasswordPolicy class.
boto3 documentation
from mypy_boto3_iam.service_resource import AccountPasswordPolicy
def get_resource() -> AccountPasswordPolicy:
return boto3.resource("iam").AccountPasswordPolicy(...)
AccountPasswordPolicy attributes
minimum_password_length:intrequire_symbols:boolrequire_numbers:boolrequire_uppercase_characters:boolrequire_lowercase_characters:boolallow_users_to_change_password:boolexpire_passwords:boolmax_password_age:intpassword_reuse_prevention:inthard_expiry:bool
AccountPasswordPolicy methods
AccountPasswordPolicy.delete method
Deletes the password policy for the Amazon Web Services account.
Type annotations and code completion for boto3.resource("iam").delete method.
boto3 documentation
AccountPasswordPolicy.get_available_subresources method
Returns a list of all the available sub-resources for this Resource.
Type annotations and code completion for boto3.resource("iam").get_available_subresources method.
boto3 documentation
AccountPasswordPolicy.load method
Calls meth:
IAM.Client.get_account_password_policy to update the attributes
of the AccountPasswordPolicy resource.
Type annotations and code completion for boto3.resource("iam").load method.
boto3 documentation
AccountPasswordPolicy.reload method
Calls meth:
IAM.Client.get_account_password_policy to update the attributes
of the AccountPasswordPolicy resource.
Type annotations and code completion for boto3.resource("iam").reload method.
boto3 documentation
AccountPasswordPolicy.update method
Updates the password policy settings for the Amazon Web Services account.
Type annotations and code completion for boto3.resource("iam").update method.
boto3 documentation
def update(
self,
*,
MinimumPasswordLength: int = ...,
RequireSymbols: bool = ...,
RequireNumbers: bool = ...,
RequireUppercaseCharacters: bool = ...,
RequireLowercaseCharacters: bool = ...,
AllowUsersToChangePassword: bool = ...,
MaxPasswordAge: int = ...,
PasswordReusePrevention: int = ...,
HardExpiry: bool = ...,
) -> None:
...
kwargs: UpdateAccountPasswordPolicyRequestAccountPasswordPolicyUpdateTypeDef = { # (1)
"MinimumPasswordLength": ...,
}
parent.update(**kwargs)
AccountSummary
Type annotations and code completion for boto3.resource("iam").AccountSummary class.
boto3 documentation
from mypy_boto3_iam.service_resource import AccountSummary
def get_resource() -> AccountSummary:
return boto3.resource("iam").AccountSummary(...)
AccountSummary attributes
summary_map:Dict[summaryKeyTypeType,int]
AccountSummary methods
AccountSummary.get_available_subresources method
Returns a list of all the available sub-resources for this Resource.
Type annotations and code completion for boto3.resource("iam").get_available_subresources method.
boto3 documentation
AccountSummary.load method
Calls meth:
IAM.Client.get_account_summary to update the attributes of the
AccountSummary resource.
Type annotations and code completion for boto3.resource("iam").load method.
boto3 documentation
AccountSummary.reload method
Calls meth:
IAM.Client.get_account_summary to update the attributes of the
AccountSummary resource.
Type annotations and code completion for boto3.resource("iam").reload method.
boto3 documentation
AssumeRolePolicy
Type annotations and code completion for boto3.resource("iam").AssumeRolePolicy class.
boto3 documentation
from mypy_boto3_iam.service_resource import AssumeRolePolicy
def get_resource() -> AssumeRolePolicy:
return boto3.resource("iam").AssumeRolePolicy(...)
AssumeRolePolicy attributes
role_name:str
AssumeRolePolicy methods
AssumeRolePolicy.Role method
Creates a Role resource.
Type annotations and code completion for boto3.resource("iam").Role method.
boto3 documentation
AssumeRolePolicy.get_available_subresources method
Returns a list of all the available sub-resources for this Resource.
Type annotations and code completion for boto3.resource("iam").get_available_subresources method.
boto3 documentation
AssumeRolePolicy.update method
Updates the policy that grants an IAM entity permission to assume a role.
Type annotations and code completion for boto3.resource("iam").update method.
boto3 documentation
kwargs: UpdateAssumeRolePolicyRequestAssumeRolePolicyUpdateTypeDef = { # (1)
"PolicyDocument": ...,
}
parent.update(**kwargs)
CurrentUser
Type annotations and code completion for boto3.resource("iam").CurrentUser class.
boto3 documentation
from mypy_boto3_iam.service_resource import CurrentUser
def get_resource() -> CurrentUser:
return boto3.resource("iam").CurrentUser(...)
CurrentUser attributes
path:struser_name:struser_id:strarn:strcreate_date:datetimepassword_last_used:datetimepermissions_boundary: AttachedPermissionsBoundaryResponseMetadataTypeDeftags:List[TagTypeDef]user: Useraccess_keys: CurrentUserAccessKeysCollectionmfa_devices: CurrentUserMfaDevicesCollectionsigning_certificates: CurrentUserSigningCertificatesCollection
CurrentUser collections
CurrentUser.access_keys
Provides access to AccessKey resource.
Type annotations and code completion for boto3.resource("iam").CurrentUser(...).access_keys collection.
boto3 documentation
from mypy_boto3_iam.service_resource import CurrentUserAccessKeysCollection
def get_collection() -> CurrentUserAccessKeysCollection:
resource = boto3.resource("iam").CurrentUser(...)
return resource.access_keys
CurrentUser.mfa_devices
Provides access to MfaDevice resource.
Type annotations and code completion for boto3.resource("iam").CurrentUser(...).mfa_devices collection.
boto3 documentation
from mypy_boto3_iam.service_resource import CurrentUserMfaDevicesCollection
def get_collection() -> CurrentUserMfaDevicesCollection:
resource = boto3.resource("iam").CurrentUser(...)
return resource.mfa_devices
CurrentUser.signing_certificates
Provides access to SigningCertificate resource.
Type annotations and code completion for boto3.resource("iam").CurrentUser(...).signing_certificates collection.
boto3 documentation
from mypy_boto3_iam.service_resource import CurrentUserSigningCertificatesCollection
def get_collection() -> CurrentUserSigningCertificatesCollection:
resource = boto3.resource("iam").CurrentUser(...)
return resource.signing_certificates
CurrentUser methods
CurrentUser.get_available_subresources method
Returns a list of all the available sub-resources for this Resource.
Type annotations and code completion for boto3.resource("iam").get_available_subresources method.
boto3 documentation
CurrentUser.load method
Calls meth:
IAM.Client.get_user to update the attributes of the CurrentUser
resource.
Type annotations and code completion for boto3.resource("iam").load method.
boto3 documentation
CurrentUser.reload method
Calls meth:
IAM.Client.get_user to update the attributes of the CurrentUser
resource.
Type annotations and code completion for boto3.resource("iam").reload method.
boto3 documentation
Group
Type annotations and code completion for boto3.resource("iam").Group class.
boto3 documentation
from mypy_boto3_iam.service_resource import Group
def get_resource() -> Group:
return boto3.resource("iam").Group(...)
Group attributes
path:strgroup_name:strgroup_id:strarn:strcreate_date:datetimename:strattached_policies: GroupAttachedPoliciesCollectionpolicies: GroupPoliciesCollectionusers: GroupUsersCollection
Group collections
Group.attached_policies
Provides access to Policy resource.
Type annotations and code completion for boto3.resource("iam").Group(...).attached_policies collection.
boto3 documentation
from mypy_boto3_iam.service_resource import GroupAttachedPoliciesCollection
def get_collection() -> GroupAttachedPoliciesCollection:
resource = boto3.resource("iam").Group(...)
return resource.attached_policies
Group.policies
Provides access to GroupPolicy resource.
Type annotations and code completion for boto3.resource("iam").Group(...).policies collection.
boto3 documentation
from mypy_boto3_iam.service_resource import GroupPoliciesCollection
def get_collection() -> GroupPoliciesCollection:
resource = boto3.resource("iam").Group(...)
return resource.policies
Group.users
Provides access to User resource.
Type annotations and code completion for boto3.resource("iam").Group(...).users collection.
boto3 documentation
from mypy_boto3_iam.service_resource import GroupUsersCollection
def get_collection() -> GroupUsersCollection:
resource = boto3.resource("iam").Group(...)
return resource.users
Group methods
Group.Policy method
Creates a GroupPolicy resource.
Type annotations and code completion for boto3.resource("iam").Policy method.
boto3 documentation
kwargs: GroupPolicyRequestTypeDef = { # (1)
"name": ...,
}
parent.Policy(**kwargs)
Group.add_user method
Adds the specified user to the specified group.
Type annotations and code completion for boto3.resource("iam").add_user method.
boto3 documentation
kwargs: AddUserToGroupRequestGroupAddUserTypeDef = { # (1)
"UserName": ...,
}
parent.add_user(**kwargs)
Group.attach_policy method
Attaches the specified managed policy to the specified IAM group.
Type annotations and code completion for boto3.resource("iam").attach_policy method.
boto3 documentation
kwargs: AttachGroupPolicyRequestGroupAttachPolicyTypeDef = { # (1)
"PolicyArn": ...,
}
parent.attach_policy(**kwargs)
Group.create method
Creates a new group.
Type annotations and code completion for boto3.resource("iam").create method.
boto3 documentation
kwargs: CreateGroupRequestGroupCreateTypeDef = { # (1)
"Path": ...,
}
parent.create(**kwargs)
Group.create_policy method
Adds or updates an inline policy document that is embedded in the specified IAM group.
Type annotations and code completion for boto3.resource("iam").create_policy method.
boto3 documentation
def create_policy(
self,
*,
PolicyName: str,
PolicyDocument: str,
) -> GroupPolicy:
...
kwargs: PutGroupPolicyRequestGroupCreatePolicyTypeDef = { # (1)
"PolicyName": ...,
"PolicyDocument": ...,
}
parent.create_policy(**kwargs)
Group.delete method
Deletes the specified IAM group.
Type annotations and code completion for boto3.resource("iam").delete method.
boto3 documentation
Group.detach_policy method
Removes the specified managed policy from the specified IAM group.
Type annotations and code completion for boto3.resource("iam").detach_policy method.
boto3 documentation
kwargs: DetachGroupPolicyRequestGroupDetachPolicyTypeDef = { # (1)
"PolicyArn": ...,
}
parent.detach_policy(**kwargs)
Group.get_available_subresources method
Returns a list of all the available sub-resources for this Resource.
Type annotations and code completion for boto3.resource("iam").get_available_subresources method.
boto3 documentation
Group.load method
Calls meth:
IAM.Client.get_group to update the attributes of the Group
resource.
Type annotations and code completion for boto3.resource("iam").load method.
boto3 documentation
Group.reload method
Calls meth:
IAM.Client.get_group to update the attributes of the Group
resource.
Type annotations and code completion for boto3.resource("iam").reload method.
boto3 documentation
Group.remove_user method
Removes the specified user from the specified group.
Type annotations and code completion for boto3.resource("iam").remove_user method.
boto3 documentation
kwargs: RemoveUserFromGroupRequestGroupRemoveUserTypeDef = { # (1)
"UserName": ...,
}
parent.remove_user(**kwargs)
Group.update method
Updates the name and/or the path of the specified IAM group.
Type annotations and code completion for boto3.resource("iam").update method.
boto3 documentation
kwargs: UpdateGroupRequestGroupUpdateTypeDef = { # (1)
"NewPath": ...,
}
parent.update(**kwargs)
GroupPolicy
Type annotations and code completion for boto3.resource("iam").GroupPolicy class.
boto3 documentation
from mypy_boto3_iam.service_resource import GroupPolicy
def get_resource() -> GroupPolicy:
return boto3.resource("iam").GroupPolicy(...)
GroupPolicy attributes
policy_name:strpolicy_document:strgroup_name:strname:str
GroupPolicy methods
GroupPolicy.Group method
Creates a Group resource.
Type annotations and code completion for boto3.resource("iam").Group method.
boto3 documentation
GroupPolicy.delete method
Deletes the specified inline policy that is embedded in the specified IAM group.
Type annotations and code completion for boto3.resource("iam").delete method.
boto3 documentation
GroupPolicy.get_available_subresources method
Returns a list of all the available sub-resources for this Resource.
Type annotations and code completion for boto3.resource("iam").get_available_subresources method.
boto3 documentation
GroupPolicy.load method
Calls meth:
IAM.Client.get_group_policy to update the attributes of the
GroupPolicy resource.
Type annotations and code completion for boto3.resource("iam").load method.
boto3 documentation
GroupPolicy.put method
Adds or updates an inline policy document that is embedded in the specified IAM group.
Type annotations and code completion for boto3.resource("iam").put method.
boto3 documentation
kwargs: PutGroupPolicyRequestGroupPolicyPutTypeDef = { # (1)
"PolicyDocument": ...,
}
parent.put(**kwargs)
GroupPolicy.reload method
Calls meth:
IAM.Client.get_group_policy to update the attributes of the
GroupPolicy resource.
Type annotations and code completion for boto3.resource("iam").reload method.
boto3 documentation
InstanceProfile
Type annotations and code completion for boto3.resource("iam").InstanceProfile class.
boto3 documentation
from mypy_boto3_iam.service_resource import InstanceProfile
def get_resource() -> InstanceProfile:
return boto3.resource("iam").InstanceProfile(...)
InstanceProfile attributes
path:strinstance_profile_name:strinstance_profile_id:strarn:strcreate_date:datetimeroles_attribute:List[RoleTypeDef]tags:List[TagTypeDef]name:strroles:List[Role]
InstanceProfile methods
InstanceProfile.add_role method
Adds the specified IAM role to the specified instance profile.
Type annotations and code completion for boto3.resource("iam").add_role method.
boto3 documentation
kwargs: AddRoleToInstanceProfileRequestInstanceProfileAddRoleTypeDef = { # (1)
"RoleName": ...,
}
parent.add_role(**kwargs)
InstanceProfile.delete method
Deletes the specified instance profile.
Type annotations and code completion for boto3.resource("iam").delete method.
boto3 documentation
InstanceProfile.get_available_subresources method
Returns a list of all the available sub-resources for this Resource.
Type annotations and code completion for boto3.resource("iam").get_available_subresources method.
boto3 documentation
InstanceProfile.load method
Calls meth:
IAM.Client.get_instance_profile to update the attributes of the
InstanceProfile resource.
Type annotations and code completion for boto3.resource("iam").load method.
boto3 documentation
InstanceProfile.reload method
Calls meth:
IAM.Client.get_instance_profile to update the attributes of the
InstanceProfile resource.
Type annotations and code completion for boto3.resource("iam").reload method.
boto3 documentation
InstanceProfile.remove_role method
Removes the specified IAM role from the specified EC2 instance profile.
Type annotations and code completion for boto3.resource("iam").remove_role method.
boto3 documentation
kwargs: RemoveRoleFromInstanceProfileRequestInstanceProfileRemoveRoleTypeDef = { # (1)
"RoleName": ...,
}
parent.remove_role(**kwargs)
LoginProfile
Type annotations and code completion for boto3.resource("iam").LoginProfile class.
boto3 documentation
from mypy_boto3_iam.service_resource import LoginProfile
def get_resource() -> LoginProfile:
return boto3.resource("iam").LoginProfile(...)
LoginProfile attributes
create_date:datetimepassword_reset_required:booluser_name:str
LoginProfile methods
LoginProfile.User method
Creates a User resource.
Type annotations and code completion for boto3.resource("iam").User method.
boto3 documentation
LoginProfile.create method
Creates a password for the specified IAM user.
Type annotations and code completion for boto3.resource("iam").create method.
boto3 documentation
def create(
self,
*,
Password: str,
PasswordResetRequired: bool = ...,
) -> LoginProfile:
...
kwargs: CreateLoginProfileRequestLoginProfileCreateTypeDef = { # (1)
"Password": ...,
}
parent.create(**kwargs)
LoginProfile.delete method
Deletes the password for the specified IAM user, For more information, see Managing passwords for IAM users_.
Type annotations and code completion for boto3.resource("iam").delete method.
boto3 documentation
LoginProfile.get_available_subresources method
Returns a list of all the available sub-resources for this Resource.
Type annotations and code completion for boto3.resource("iam").get_available_subresources method.
boto3 documentation
LoginProfile.load method
Calls meth:
IAM.Client.get_login_profile to update the attributes of the
LoginProfile resource.
Type annotations and code completion for boto3.resource("iam").load method.
boto3 documentation
LoginProfile.reload method
Calls meth:
IAM.Client.get_login_profile to update the attributes of the
LoginProfile resource.
Type annotations and code completion for boto3.resource("iam").reload method.
boto3 documentation
LoginProfile.update method
Changes the password for the specified IAM user.
Type annotations and code completion for boto3.resource("iam").update method.
boto3 documentation
def update(
self,
*,
Password: str = ...,
PasswordResetRequired: bool = ...,
) -> None:
...
kwargs: UpdateLoginProfileRequestLoginProfileUpdateTypeDef = { # (1)
"Password": ...,
}
parent.update(**kwargs)
MfaDevice
Type annotations and code completion for boto3.resource("iam").MfaDevice class.
boto3 documentation
from mypy_boto3_iam.service_resource import MfaDevice
def get_resource() -> MfaDevice:
return boto3.resource("iam").MfaDevice(...)
MfaDevice attributes
enable_date:datetimeuser_name:strserial_number:str
MfaDevice methods
MfaDevice.User method
Creates a User resource.
Type annotations and code completion for boto3.resource("iam").User method.
boto3 documentation
MfaDevice.associate method
Enables the specified MFA device and associates it with the specified IAM user.
Type annotations and code completion for boto3.resource("iam").associate method.
boto3 documentation
def associate(
self,
*,
AuthenticationCode1: str,
AuthenticationCode2: str,
) -> None:
...
kwargs: EnableMFADeviceRequestMfaDeviceAssociateTypeDef = { # (1)
"AuthenticationCode1": ...,
"AuthenticationCode2": ...,
}
parent.associate(**kwargs)
MfaDevice.disassociate method
Deactivates the specified MFA device and removes it from association with the user name for which it was originally enabled.
Type annotations and code completion for boto3.resource("iam").disassociate method.
boto3 documentation
MfaDevice.get_available_subresources method
Returns a list of all the available sub-resources for this Resource.
Type annotations and code completion for boto3.resource("iam").get_available_subresources method.
boto3 documentation
MfaDevice.resync method
Synchronizes the specified MFA device with its IAM resource object on the Amazon Web Services servers.
Type annotations and code completion for boto3.resource("iam").resync method.
boto3 documentation
def resync(
self,
*,
AuthenticationCode1: str,
AuthenticationCode2: str,
) -> None:
...
kwargs: ResyncMFADeviceRequestMfaDeviceResyncTypeDef = { # (1)
"AuthenticationCode1": ...,
"AuthenticationCode2": ...,
}
parent.resync(**kwargs)
Policy
Type annotations and code completion for boto3.resource("iam").Policy class.
boto3 documentation
from mypy_boto3_iam.service_resource import Policy
def get_resource() -> Policy:
return boto3.resource("iam").Policy(...)
Policy attributes
policy_name:strpolicy_id:strpath:strdefault_version_id:strattachment_count:intpermissions_boundary_usage_count:intis_attachable:booldescription:strcreate_date:datetimeupdate_date:datetimetags:List[TagTypeDef]arn:strdefault_version: PolicyVersionattached_groups: PolicyAttachedGroupsCollectionattached_roles: PolicyAttachedRolesCollectionattached_users: PolicyAttachedUsersCollectionversions: PolicyVersionsCollection
Policy collections
Policy.attached_groups
Provides access to Group resource.
Type annotations and code completion for boto3.resource("iam").Policy(...).attached_groups collection.
boto3 documentation
from mypy_boto3_iam.service_resource import PolicyAttachedGroupsCollection
def get_collection() -> PolicyAttachedGroupsCollection:
resource = boto3.resource("iam").Policy(...)
return resource.attached_groups
Policy.attached_roles
Provides access to Role resource.
Type annotations and code completion for boto3.resource("iam").Policy(...).attached_roles collection.
boto3 documentation
from mypy_boto3_iam.service_resource import PolicyAttachedRolesCollection
def get_collection() -> PolicyAttachedRolesCollection:
resource = boto3.resource("iam").Policy(...)
return resource.attached_roles
Policy.attached_users
Provides access to User resource.
Type annotations and code completion for boto3.resource("iam").Policy(...).attached_users collection.
boto3 documentation
from mypy_boto3_iam.service_resource import PolicyAttachedUsersCollection
def get_collection() -> PolicyAttachedUsersCollection:
resource = boto3.resource("iam").Policy(...)
return resource.attached_users
Policy.versions
Provides access to PolicyVersion resource.
Type annotations and code completion for boto3.resource("iam").Policy(...).versions collection.
boto3 documentation
from mypy_boto3_iam.service_resource import PolicyVersionsCollection
def get_collection() -> PolicyVersionsCollection:
resource = boto3.resource("iam").Policy(...)
return resource.versions
Policy methods
Policy.attach_group method
Attaches the specified managed policy to the specified IAM group.
Type annotations and code completion for boto3.resource("iam").attach_group method.
boto3 documentation
kwargs: AttachGroupPolicyRequestPolicyAttachGroupTypeDef = { # (1)
"GroupName": ...,
}
parent.attach_group(**kwargs)
Policy.attach_role method
Attaches the specified managed policy to the specified IAM role.
Type annotations and code completion for boto3.resource("iam").attach_role method.
boto3 documentation
kwargs: AttachRolePolicyRequestPolicyAttachRoleTypeDef = { # (1)
"RoleName": ...,
}
parent.attach_role(**kwargs)
Policy.attach_user method
Attaches the specified managed policy to the specified user.
Type annotations and code completion for boto3.resource("iam").attach_user method.
boto3 documentation
kwargs: AttachUserPolicyRequestPolicyAttachUserTypeDef = { # (1)
"UserName": ...,
}
parent.attach_user(**kwargs)
Policy.create_version method
Creates a new version of the specified managed policy.
Type annotations and code completion for boto3.resource("iam").create_version method.
boto3 documentation
def create_version(
self,
*,
PolicyDocument: str,
SetAsDefault: bool = ...,
) -> PolicyVersion:
...
kwargs: CreatePolicyVersionRequestPolicyCreateVersionTypeDef = { # (1)
"PolicyDocument": ...,
}
parent.create_version(**kwargs)
Policy.delete method
Deletes the specified managed policy.
Type annotations and code completion for boto3.resource("iam").delete method.
boto3 documentation
Policy.detach_group method
Removes the specified managed policy from the specified IAM group.
Type annotations and code completion for boto3.resource("iam").detach_group method.
boto3 documentation
kwargs: DetachGroupPolicyRequestPolicyDetachGroupTypeDef = { # (1)
"GroupName": ...,
}
parent.detach_group(**kwargs)
Policy.detach_role method
Removes the specified managed policy from the specified role.
Type annotations and code completion for boto3.resource("iam").detach_role method.
boto3 documentation
kwargs: DetachRolePolicyRequestPolicyDetachRoleTypeDef = { # (1)
"RoleName": ...,
}
parent.detach_role(**kwargs)
Policy.detach_user method
Removes the specified managed policy from the specified user.
Type annotations and code completion for boto3.resource("iam").detach_user method.
boto3 documentation
kwargs: DetachUserPolicyRequestPolicyDetachUserTypeDef = { # (1)
"UserName": ...,
}
parent.detach_user(**kwargs)
Policy.get_available_subresources method
Returns a list of all the available sub-resources for this Resource.
Type annotations and code completion for boto3.resource("iam").get_available_subresources method.
boto3 documentation
Policy.load method
Calls meth:
IAM.Client.get_policy to update the attributes of the Policy
resource.
Type annotations and code completion for boto3.resource("iam").load method.
boto3 documentation
Policy.reload method
Calls meth:
IAM.Client.get_policy to update the attributes of the Policy
resource.
Type annotations and code completion for boto3.resource("iam").reload method.
boto3 documentation
PolicyVersion
Type annotations and code completion for boto3.resource("iam").PolicyVersion class.
boto3 documentation
from mypy_boto3_iam.service_resource import PolicyVersion
def get_resource() -> PolicyVersion:
return boto3.resource("iam").PolicyVersion(...)
PolicyVersion attributes
document:stris_default_version:boolcreate_date:datetimearn:strversion_id:str
PolicyVersion methods
PolicyVersion.delete method
Deletes the specified version from the specified managed policy.
Type annotations and code completion for boto3.resource("iam").delete method.
boto3 documentation
PolicyVersion.get_available_subresources method
Returns a list of all the available sub-resources for this Resource.
Type annotations and code completion for boto3.resource("iam").get_available_subresources method.
boto3 documentation
PolicyVersion.load method
Calls meth:
IAM.Client.get_policy_version to update the attributes of the
PolicyVersion resource.
Type annotations and code completion for boto3.resource("iam").load method.
boto3 documentation
PolicyVersion.reload method
Calls meth:
IAM.Client.get_policy_version to update the attributes of the
PolicyVersion resource.
Type annotations and code completion for boto3.resource("iam").reload method.
boto3 documentation
PolicyVersion.set_as_default method
Sets the specified version of the specified policy as the policy's default (operative) version.
Type annotations and code completion for boto3.resource("iam").set_as_default method.
boto3 documentation
Role
Type annotations and code completion for boto3.resource("iam").Role class.
boto3 documentation
from mypy_boto3_iam.service_resource import Role
def get_resource() -> Role:
return boto3.resource("iam").Role(...)
Role attributes
path:strrole_name:strrole_id:strarn:strcreate_date:datetimeassume_role_policy_document:strdescription:strmax_session_duration:intpermissions_boundary: AttachedPermissionsBoundaryResponseMetadataTypeDeftags:List[TagTypeDef]role_last_used: RoleLastUsedResponseMetadataTypeDefname:strattached_policies: RoleAttachedPoliciesCollectioninstance_profiles: RoleInstanceProfilesCollectionpolicies: RolePoliciesCollection
Role collections
Role.attached_policies
Provides access to Policy resource.
Type annotations and code completion for boto3.resource("iam").Role(...).attached_policies collection.
boto3 documentation
from mypy_boto3_iam.service_resource import RoleAttachedPoliciesCollection
def get_collection() -> RoleAttachedPoliciesCollection:
resource = boto3.resource("iam").Role(...)
return resource.attached_policies
Role.instance_profiles
Provides access to InstanceProfile resource.
Type annotations and code completion for boto3.resource("iam").Role(...).instance_profiles collection.
boto3 documentation
from mypy_boto3_iam.service_resource import RoleInstanceProfilesCollection
def get_collection() -> RoleInstanceProfilesCollection:
resource = boto3.resource("iam").Role(...)
return resource.instance_profiles
Role.policies
Provides access to RolePolicy resource.
Type annotations and code completion for boto3.resource("iam").Role(...).policies collection.
boto3 documentation
from mypy_boto3_iam.service_resource import RolePoliciesCollection
def get_collection() -> RolePoliciesCollection:
resource = boto3.resource("iam").Role(...)
return resource.policies
Role methods
Role.AssumeRolePolicy method
Creates a AssumeRolePolicy resource.
Type annotations and code completion for boto3.resource("iam").AssumeRolePolicy method.
boto3 documentation
Role.Policy method
Creates a RolePolicy resource.
Type annotations and code completion for boto3.resource("iam").Policy method.
boto3 documentation
kwargs: RolePolicyRequestTypeDef = { # (1)
"name": ...,
}
parent.Policy(**kwargs)
Role.attach_policy method
Attaches the specified managed policy to the specified IAM role.
Type annotations and code completion for boto3.resource("iam").attach_policy method.
boto3 documentation
kwargs: AttachRolePolicyRequestRoleAttachPolicyTypeDef = { # (1)
"PolicyArn": ...,
}
parent.attach_policy(**kwargs)
Role.delete method
Deletes the specified role.
Type annotations and code completion for boto3.resource("iam").delete method.
boto3 documentation
Role.detach_policy method
Removes the specified managed policy from the specified role.
Type annotations and code completion for boto3.resource("iam").detach_policy method.
boto3 documentation
kwargs: DetachRolePolicyRequestRoleDetachPolicyTypeDef = { # (1)
"PolicyArn": ...,
}
parent.detach_policy(**kwargs)
Role.get_available_subresources method
Returns a list of all the available sub-resources for this Resource.
Type annotations and code completion for boto3.resource("iam").get_available_subresources method.
boto3 documentation
Role.load method
Calls meth:
IAM.Client.get_role to update the attributes of the Role
resource.
Type annotations and code completion for boto3.resource("iam").load method.
boto3 documentation
Role.reload method
Calls meth:
IAM.Client.get_role to update the attributes of the Role
resource.
Type annotations and code completion for boto3.resource("iam").reload method.
boto3 documentation
RolePolicy
Type annotations and code completion for boto3.resource("iam").RolePolicy class.
boto3 documentation
from mypy_boto3_iam.service_resource import RolePolicy
def get_resource() -> RolePolicy:
return boto3.resource("iam").RolePolicy(...)
RolePolicy attributes
policy_name:strpolicy_document:strrole_name:strname:str
RolePolicy methods
RolePolicy.Role method
Creates a Role resource.
Type annotations and code completion for boto3.resource("iam").Role method.
boto3 documentation
RolePolicy.delete method
Deletes the specified inline policy that is embedded in the specified IAM role.
Type annotations and code completion for boto3.resource("iam").delete method.
boto3 documentation
RolePolicy.get_available_subresources method
Returns a list of all the available sub-resources for this Resource.
Type annotations and code completion for boto3.resource("iam").get_available_subresources method.
boto3 documentation
RolePolicy.load method
Calls meth:
IAM.Client.get_role_policy to update the attributes of the
RolePolicy resource.
Type annotations and code completion for boto3.resource("iam").load method.
boto3 documentation
RolePolicy.put method
Adds or updates an inline policy document that is embedded in the specified IAM role.
Type annotations and code completion for boto3.resource("iam").put method.
boto3 documentation
kwargs: PutRolePolicyRequestRolePolicyPutTypeDef = { # (1)
"PolicyDocument": ...,
}
parent.put(**kwargs)
RolePolicy.reload method
Calls meth:
IAM.Client.get_role_policy to update the attributes of the
RolePolicy resource.
Type annotations and code completion for boto3.resource("iam").reload method.
boto3 documentation
SamlProvider
Type annotations and code completion for boto3.resource("iam").SamlProvider class.
boto3 documentation
from mypy_boto3_iam.service_resource import SamlProvider
def get_resource() -> SamlProvider:
return boto3.resource("iam").SamlProvider(...)
SamlProvider attributes
saml_metadata_document:strcreate_date:datetimevalid_until:datetimetags:List[TagTypeDef]arn:str
SamlProvider methods
SamlProvider.delete method
Deletes a SAML provider resource in IAM.
Type annotations and code completion for boto3.resource("iam").delete method.
boto3 documentation
SamlProvider.get_available_subresources method
Returns a list of all the available sub-resources for this Resource.
Type annotations and code completion for boto3.resource("iam").get_available_subresources method.
boto3 documentation
SamlProvider.load method
Calls meth:
IAM.Client.get_saml_provider to update the attributes of the
SamlProvider resource.
Type annotations and code completion for boto3.resource("iam").load method.
boto3 documentation
SamlProvider.reload method
Calls meth:
IAM.Client.get_saml_provider to update the attributes of the
SamlProvider resource.
Type annotations and code completion for boto3.resource("iam").reload method.
boto3 documentation
SamlProvider.update method
Updates the metadata document for an existing SAML provider resource object.
Type annotations and code completion for boto3.resource("iam").update method.
boto3 documentation
def update(
self,
*,
SAMLMetadataDocument: str,
) -> UpdateSAMLProviderResponseTypeDef: # (1)
...
kwargs: UpdateSAMLProviderRequestSamlProviderUpdateTypeDef = { # (1)
"SAMLMetadataDocument": ...,
}
parent.update(**kwargs)
ServerCertificate
Type annotations and code completion for boto3.resource("iam").ServerCertificate class.
boto3 documentation
from mypy_boto3_iam.service_resource import ServerCertificate
def get_resource() -> ServerCertificate:
return boto3.resource("iam").ServerCertificate(...)
ServerCertificate attributes
server_certificate_metadata: ServerCertificateMetadataResponseMetadataTypeDefcertificate_body:strcertificate_chain:strtags:List[TagTypeDef]name:str
ServerCertificate methods
ServerCertificate.delete method
Deletes the specified server certificate.
Type annotations and code completion for boto3.resource("iam").delete method.
boto3 documentation
ServerCertificate.get_available_subresources method
Returns a list of all the available sub-resources for this Resource.
Type annotations and code completion for boto3.resource("iam").get_available_subresources method.
boto3 documentation
ServerCertificate.load method
Calls meth:
IAM.Client.get_server_certificate to update the attributes of
the ServerCertificate resource.
Type annotations and code completion for boto3.resource("iam").load method.
boto3 documentation
ServerCertificate.reload method
Calls meth:
IAM.Client.get_server_certificate to update the attributes of
the ServerCertificate resource.
Type annotations and code completion for boto3.resource("iam").reload method.
boto3 documentation
ServerCertificate.update method
Updates the name and/or the path of the specified server certificate stored in IAM.
Type annotations and code completion for boto3.resource("iam").update method.
boto3 documentation
def update(
self,
*,
NewPath: str = ...,
NewServerCertificateName: str = ...,
) -> ServerCertificate:
...
kwargs: UpdateServerCertificateRequestServerCertificateUpdateTypeDef = { # (1)
"NewPath": ...,
}
parent.update(**kwargs)
SigningCertificate
Type annotations and code completion for boto3.resource("iam").SigningCertificate class.
boto3 documentation
from mypy_boto3_iam.service_resource import SigningCertificate
def get_resource() -> SigningCertificate:
return boto3.resource("iam").SigningCertificate(...)
SigningCertificate attributes
certificate_id:strcertificate_body:strstatus: statusTypeTypeupload_date:datetimeuser_name:strid:str
SigningCertificate methods
SigningCertificate.User method
Creates a User resource.
Type annotations and code completion for boto3.resource("iam").User method.
boto3 documentation
SigningCertificate.activate method
Changes the status of the specified user signing certificate from active to disabled, or vice versa.
Type annotations and code completion for boto3.resource("iam").activate method.
boto3 documentation
- See statusTypeType
kwargs: UpdateSigningCertificateRequestSigningCertificateActivateTypeDef = { # (1)
"Status": ...,
}
parent.activate(**kwargs)
SigningCertificate.deactivate method
Changes the status of the specified user signing certificate from active to disabled, or vice versa.
Type annotations and code completion for boto3.resource("iam").deactivate method.
boto3 documentation
- See statusTypeType
kwargs: UpdateSigningCertificateRequestSigningCertificateDeactivateTypeDef = { # (1)
"Status": ...,
}
parent.deactivate(**kwargs)
SigningCertificate.delete method
Deletes a signing certificate associated with the specified IAM user.
Type annotations and code completion for boto3.resource("iam").delete method.
boto3 documentation
SigningCertificate.get_available_subresources method
Returns a list of all the available sub-resources for this Resource.
Type annotations and code completion for boto3.resource("iam").get_available_subresources method.
boto3 documentation
User
Type annotations and code completion for boto3.resource("iam").User class.
boto3 documentation
from mypy_boto3_iam.service_resource import User
def get_resource() -> User:
return boto3.resource("iam").User(...)
User attributes
path:struser_name:struser_id:strarn:strcreate_date:datetimepassword_last_used:datetimepermissions_boundary: AttachedPermissionsBoundaryResponseMetadataTypeDeftags:List[TagTypeDef]name:straccess_keys: UserAccessKeysCollectionattached_policies: UserAttachedPoliciesCollectiongroups: UserGroupsCollectionmfa_devices: UserMfaDevicesCollectionpolicies: UserPoliciesCollectionsigning_certificates: UserSigningCertificatesCollection
User collections
User.access_keys
Provides access to AccessKey resource.
Type annotations and code completion for boto3.resource("iam").User(...).access_keys collection.
boto3 documentation
from mypy_boto3_iam.service_resource import UserAccessKeysCollection
def get_collection() -> UserAccessKeysCollection:
resource = boto3.resource("iam").User(...)
return resource.access_keys
User.attached_policies
Provides access to Policy resource.
Type annotations and code completion for boto3.resource("iam").User(...).attached_policies collection.
boto3 documentation
from mypy_boto3_iam.service_resource import UserAttachedPoliciesCollection
def get_collection() -> UserAttachedPoliciesCollection:
resource = boto3.resource("iam").User(...)
return resource.attached_policies
User.groups
Provides access to Group resource.
Type annotations and code completion for boto3.resource("iam").User(...).groups collection.
boto3 documentation
from mypy_boto3_iam.service_resource import UserGroupsCollection
def get_collection() -> UserGroupsCollection:
resource = boto3.resource("iam").User(...)
return resource.groups
User.mfa_devices
Provides access to MfaDevice resource.
Type annotations and code completion for boto3.resource("iam").User(...).mfa_devices collection.
boto3 documentation
from mypy_boto3_iam.service_resource import UserMfaDevicesCollection
def get_collection() -> UserMfaDevicesCollection:
resource = boto3.resource("iam").User(...)
return resource.mfa_devices
User.policies
Provides access to UserPolicy resource.
Type annotations and code completion for boto3.resource("iam").User(...).policies collection.
boto3 documentation
from mypy_boto3_iam.service_resource import UserPoliciesCollection
def get_collection() -> UserPoliciesCollection:
resource = boto3.resource("iam").User(...)
return resource.policies
User.signing_certificates
Provides access to SigningCertificate resource.
Type annotations and code completion for boto3.resource("iam").User(...).signing_certificates collection.
boto3 documentation
from mypy_boto3_iam.service_resource import UserSigningCertificatesCollection
def get_collection() -> UserSigningCertificatesCollection:
resource = boto3.resource("iam").User(...)
return resource.signing_certificates
User methods
User.AccessKey method
Creates a AccessKey resource.
Type annotations and code completion for boto3.resource("iam").AccessKey method.
boto3 documentation
kwargs: UserAccessKeyRequestTypeDef = { # (1)
"id": ...,
}
parent.AccessKey(**kwargs)
User.LoginProfile method
Creates a LoginProfile resource.
Type annotations and code completion for boto3.resource("iam").LoginProfile method.
boto3 documentation
User.MfaDevice method
Creates a MfaDevice resource.
Type annotations and code completion for boto3.resource("iam").MfaDevice method.
boto3 documentation
kwargs: UserMfaDeviceRequestTypeDef = { # (1)
"serial_number": ...,
}
parent.MfaDevice(**kwargs)
User.Policy method
Creates a UserPolicy resource.
Type annotations and code completion for boto3.resource("iam").Policy method.
boto3 documentation
kwargs: UserPolicyRequestTypeDef = { # (1)
"name": ...,
}
parent.Policy(**kwargs)
User.SigningCertificate method
Creates a SigningCertificate resource.
Type annotations and code completion for boto3.resource("iam").SigningCertificate method.
boto3 documentation
kwargs: UserSigningCertificateRequestTypeDef = { # (1)
"id": ...,
}
parent.SigningCertificate(**kwargs)
User.add_group method
Adds the specified user to the specified group.
Type annotations and code completion for boto3.resource("iam").add_group method.
boto3 documentation
kwargs: AddUserToGroupRequestUserAddGroupTypeDef = { # (1)
"GroupName": ...,
}
parent.add_group(**kwargs)
User.attach_policy method
Attaches the specified managed policy to the specified user.
Type annotations and code completion for boto3.resource("iam").attach_policy method.
boto3 documentation
kwargs: AttachUserPolicyRequestUserAttachPolicyTypeDef = { # (1)
"PolicyArn": ...,
}
parent.attach_policy(**kwargs)
User.create method
Creates a new IAM user for your Amazon Web Services account.
Type annotations and code completion for boto3.resource("iam").create method.
boto3 documentation
def create(
self,
*,
Path: str = ...,
PermissionsBoundary: str = ...,
Tags: Sequence[TagTypeDef] = ..., # (1)
) -> User:
...
- See TagTypeDef
kwargs: CreateUserRequestUserCreateTypeDef = { # (1)
"Path": ...,
}
parent.create(**kwargs)
User.create_access_key_pair method
Creates a new Amazon Web Services secret access key and corresponding Amazon Web Services access key ID for the specified user.
Type annotations and code completion for boto3.resource("iam").create_access_key_pair method.
boto3 documentation
User.create_login_profile method
Creates a password for the specified IAM user.
Type annotations and code completion for boto3.resource("iam").create_login_profile method.
boto3 documentation
def create_login_profile(
self,
*,
Password: str,
PasswordResetRequired: bool = ...,
) -> LoginProfile:
...
kwargs: CreateLoginProfileRequestUserCreateLoginProfileTypeDef = { # (1)
"Password": ...,
}
parent.create_login_profile(**kwargs)
User.create_policy method
Adds or updates an inline policy document that is embedded in the specified IAM user.
Type annotations and code completion for boto3.resource("iam").create_policy method.
boto3 documentation
def create_policy(
self,
*,
PolicyName: str,
PolicyDocument: str,
) -> UserPolicy:
...
kwargs: PutUserPolicyRequestUserCreatePolicyTypeDef = { # (1)
"PolicyName": ...,
"PolicyDocument": ...,
}
parent.create_policy(**kwargs)
User.delete method
Deletes the specified IAM user.
Type annotations and code completion for boto3.resource("iam").delete method.
boto3 documentation
User.detach_policy method
Removes the specified managed policy from the specified user.
Type annotations and code completion for boto3.resource("iam").detach_policy method.
boto3 documentation
kwargs: DetachUserPolicyRequestUserDetachPolicyTypeDef = { # (1)
"PolicyArn": ...,
}
parent.detach_policy(**kwargs)
User.enable_mfa method
Enables the specified MFA device and associates it with the specified IAM user.
Type annotations and code completion for boto3.resource("iam").enable_mfa method.
boto3 documentation
def enable_mfa(
self,
*,
SerialNumber: str,
AuthenticationCode1: str,
AuthenticationCode2: str,
) -> MfaDevice:
...
kwargs: EnableMFADeviceRequestUserEnableMfaTypeDef = { # (1)
"SerialNumber": ...,
"AuthenticationCode1": ...,
"AuthenticationCode2": ...,
}
parent.enable_mfa(**kwargs)
User.get_available_subresources method
Returns a list of all the available sub-resources for this Resource.
Type annotations and code completion for boto3.resource("iam").get_available_subresources method.
boto3 documentation
User.load method
Calls meth:
IAM.Client.get_user to update the attributes of the User
resource.
Type annotations and code completion for boto3.resource("iam").load method.
boto3 documentation
User.reload method
Calls meth:
IAM.Client.get_user to update the attributes of the User
resource.
Type annotations and code completion for boto3.resource("iam").reload method.
boto3 documentation
User.remove_group method
Removes the specified user from the specified group.
Type annotations and code completion for boto3.resource("iam").remove_group method.
boto3 documentation
kwargs: RemoveUserFromGroupRequestUserRemoveGroupTypeDef = { # (1)
"GroupName": ...,
}
parent.remove_group(**kwargs)
User.update method
Updates the name and/or the path of the specified IAM user.
Type annotations and code completion for boto3.resource("iam").update method.
boto3 documentation
kwargs: UpdateUserRequestUserUpdateTypeDef = { # (1)
"NewPath": ...,
}
parent.update(**kwargs)
UserPolicy
Type annotations and code completion for boto3.resource("iam").UserPolicy class.
boto3 documentation
from mypy_boto3_iam.service_resource import UserPolicy
def get_resource() -> UserPolicy:
return boto3.resource("iam").UserPolicy(...)
UserPolicy attributes
policy_name:strpolicy_document:struser_name:strname:str
UserPolicy methods
UserPolicy.User method
Creates a User resource.
Type annotations and code completion for boto3.resource("iam").User method.
boto3 documentation
UserPolicy.delete method
Deletes the specified inline policy that is embedded in the specified IAM user.
Type annotations and code completion for boto3.resource("iam").delete method.
boto3 documentation
UserPolicy.get_available_subresources method
Returns a list of all the available sub-resources for this Resource.
Type annotations and code completion for boto3.resource("iam").get_available_subresources method.
boto3 documentation
UserPolicy.load method
Calls meth:
IAM.Client.get_user_policy to update the attributes of the
UserPolicy resource.
Type annotations and code completion for boto3.resource("iam").load method.
boto3 documentation
UserPolicy.put method
Adds or updates an inline policy document that is embedded in the specified IAM user.
Type annotations and code completion for boto3.resource("iam").put method.
boto3 documentation
kwargs: PutUserPolicyRequestUserPolicyPutTypeDef = { # (1)
"PolicyDocument": ...,
}
parent.put(**kwargs)
UserPolicy.reload method
Calls meth:
IAM.Client.get_user_policy to update the attributes of the
UserPolicy resource.
Type annotations and code completion for boto3.resource("iam").reload method.
boto3 documentation
VirtualMfaDevice
Type annotations and code completion for boto3.resource("iam").VirtualMfaDevice class.
boto3 documentation
from mypy_boto3_iam.service_resource import VirtualMfaDevice
def get_resource() -> VirtualMfaDevice:
return boto3.resource("iam").VirtualMfaDevice(...)
VirtualMfaDevice attributes
base32_string_seed:bytesqr_code_png:bytesuser_attribute: UserResponseMetadataTypeDefenable_date:datetimetags:List[TagTypeDef]serial_number:struser: User
VirtualMfaDevice methods
VirtualMfaDevice.delete method
Deletes a virtual MFA device.
Type annotations and code completion for boto3.resource("iam").delete method.
boto3 documentation
VirtualMfaDevice.get_available_subresources method
Returns a list of all the available sub-resources for this Resource.
Type annotations and code completion for boto3.resource("iam").get_available_subresources method.
boto3 documentation