All Downloads are FREE. Search and download functionalities are using the official Maven repository.

zio.aws.workmail.WorkMail.scala Maven / Gradle / Ivy

There is a newer version: 7.28.29.5
Show newest version
package zio.aws.workmail
import zio.aws.workmail.model.ListAvailabilityConfigurationsResponse.ReadOnly
import zio.aws.core.config.AwsConfig
import zio.aws.workmail.model.{
  AssumeImpersonationRoleRequest,
  ListResourceDelegatesRequest,
  DeleteUserRequest,
  DeleteMobileDeviceAccessRuleRequest,
  AssociateDelegateToResourceRequest,
  DeleteAvailabilityConfigurationRequest,
  CreateAvailabilityConfigurationRequest,
  CreateMobileDeviceAccessRuleRequest,
  StartMailboxExportJobRequest,
  UpdatePrimaryEmailAddressRequest,
  DescribeUserRequest,
  UpdateAvailabilityConfigurationRequest,
  ListOrganizationsRequest,
  GetMobileDeviceAccessOverrideRequest,
  ListMailboxPermissionsRequest,
  UpdateImpersonationRoleRequest,
  CreateImpersonationRoleRequest,
  DescribeEntityRequest,
  ListImpersonationRolesRequest,
  DeleteMobileDeviceAccessOverrideRequest,
  CancelMailboxExportJobRequest,
  ListUsersRequest,
  RegisterMailDomainRequest,
  UpdateGroupRequest,
  CreateAliasRequest,
  DeregisterFromWorkMailRequest,
  DeleteImpersonationRoleRequest,
  CreateOrganizationRequest,
  DescribeOrganizationRequest,
  ListMobileDeviceAccessOverridesRequest,
  GetImpersonationRoleEffectRequest,
  AssociateMemberToGroupRequest,
  ListAccessControlRulesRequest,
  ListTagsForResourceRequest,
  TestAvailabilityConfigurationRequest,
  DescribeGroupRequest,
  DeleteAliasRequest,
  RegisterToWorkMailRequest,
  ListAliasesRequest,
  DeleteGroupRequest,
  PutEmailMonitoringConfigurationRequest,
  PutMailboxPermissionsRequest,
  ListAvailabilityConfigurationsRequest,
  PutAccessControlRuleRequest,
  GetMobileDeviceAccessEffectRequest,
  ListGroupsRequest,
  ListGroupMembersRequest,
  ListMobileDeviceAccessRulesRequest,
  GetAccessControlEffectRequest,
  DeleteResourceRequest,
  ListMailboxExportJobsRequest,
  ListResourcesRequest,
  CreateUserRequest,
  DeleteMailboxPermissionsRequest,
  DeleteAccessControlRuleRequest,
  ListGroupsForEntityRequest,
  DeleteRetentionPolicyRequest,
  DeleteEmailMonitoringConfigurationRequest,
  CreateResourceRequest,
  UntagResourceRequest,
  DescribeMailboxExportJobRequest,
  PutInboundDmarcSettingsRequest,
  CreateGroupRequest,
  ListMailDomainsRequest,
  DeregisterMailDomainRequest,
  UpdateUserRequest,
  UpdateDefaultMailDomainRequest,
  GetDefaultRetentionPolicyRequest,
  DescribeEmailMonitoringConfigurationRequest,
  DescribeInboundDmarcSettingsRequest,
  UpdateMobileDeviceAccessRuleRequest,
  ResetPasswordRequest,
  GetMailDomainRequest,
  DisassociateMemberFromGroupRequest,
  UpdateResourceRequest,
  GetMailboxDetailsRequest,
  DeleteOrganizationRequest,
  DescribeResourceRequest,
  TagResourceRequest,
  PutRetentionPolicyRequest,
  PutMobileDeviceAccessOverrideRequest,
  DisassociateDelegateFromResourceRequest,
  UpdateMailboxQuotaRequest,
  GetImpersonationRoleRequest
}
import software.amazon.awssdk.services.workmail.{
  WorkMailAsyncClientBuilder,
  WorkMailAsyncClient
}
import zio.aws.core.{AwsServiceBase, AwsError}
import zio.aws.core.aspects.{AwsCallAspect, AspectSupport}
import software.amazon.awssdk.services.workmail.model.{
  DeleteResourceResponse,
  DeleteGroupResponse,
  MobileDeviceAccessOverride,
  ListMobileDeviceAccessOverridesResponse,
  ListGroupsForEntityResponse,
  ListGroupMembersResponse,
  UpdateDefaultMailDomainResponse,
  ListAvailabilityConfigurationsResponse,
  UpdateResourceResponse,
  ResetPasswordResponse,
  DeregisterMailDomainResponse,
  DeleteAccessControlRuleResponse,
  CreateAvailabilityConfigurationResponse,
  PutEmailMonitoringConfigurationResponse,
  DescribeEntityResponse,
  DescribeInboundDmarcSettingsResponse,
  DescribeMailboxExportJobResponse,
  PutAccessControlRuleResponse,
  GetMailDomainResponse,
  DeleteAliasResponse,
  GetImpersonationRoleResponse,
  ListUsersResponse,
  UpdateMobileDeviceAccessRuleResponse,
  DescribeUserResponse,
  DeleteAvailabilityConfigurationResponse,
  User,
  ListMailboxExportJobsResponse,
  ListResourcesResponse,
  MailDomainSummary,
  RegisterToWorkMailResponse,
  CreateAliasResponse,
  DeleteRetentionPolicyResponse,
  PutMailboxPermissionsResponse,
  GetDefaultRetentionPolicyResponse,
  Group,
  UpdateImpersonationRoleResponse,
  DescribeGroupResponse,
  ListTagsForResourceResponse,
  GetMobileDeviceAccessOverrideResponse,
  UntagResourceResponse,
  ListAccessControlRulesResponse,
  ListMobileDeviceAccessRulesResponse,
  CreateResourceResponse,
  GetImpersonationRoleEffectResponse,
  Resource,
  DeleteImpersonationRoleResponse,
  DisassociateMemberFromGroupResponse,
  ImpersonationRole,
  CreateUserResponse,
  GroupIdentifier,
  DescribeOrganizationResponse,
  Permission,
  ListImpersonationRolesResponse,
  ListGroupsResponse,
  PutRetentionPolicyResponse,
  GetMobileDeviceAccessEffectResponse,
  TestAvailabilityConfigurationResponse,
  DisassociateDelegateFromResourceResponse,
  GetMailboxDetailsResponse,
  ListMailboxPermissionsResponse,
  AssociateMemberToGroupResponse,
  DeleteMobileDeviceAccessRuleResponse,
  CreateMobileDeviceAccessRuleResponse,
  MailboxExportJob,
  CreateGroupResponse,
  ListResourceDelegatesResponse,
  DeleteUserResponse,
  GetAccessControlEffectResponse,
  AssociateDelegateToResourceResponse,
  ListOrganizationsResponse,
  DeleteMailboxPermissionsResponse,
  CreateImpersonationRoleResponse,
  ListAliasesResponse,
  UpdateAvailabilityConfigurationResponse,
  UpdatePrimaryEmailAddressResponse,
  DeregisterFromWorkMailResponse,
  DescribeEmailMonitoringConfigurationResponse,
  PutInboundDmarcSettingsResponse,
  ListMailDomainsResponse,
  UpdateUserResponse,
  TagResourceResponse,
  StartMailboxExportJobResponse,
  PutMobileDeviceAccessOverrideResponse,
  DeleteOrganizationResponse,
  DeleteEmailMonitoringConfigurationResponse,
  AssumeImpersonationRoleResponse,
  Member,
  DeleteMobileDeviceAccessOverrideResponse,
  AvailabilityConfiguration,
  RegisterMailDomainResponse,
  DescribeResourceResponse,
  Delegate,
  CreateOrganizationResponse,
  UpdateGroupResponse,
  OrganizationSummary,
  UpdateMailboxQuotaResponse,
  CancelMailboxExportJobResponse
}
import zio.{ZEnvironment, IO, ZIO, ZLayer, Scope}
import zio.stream.ZStream
import zio.aws.workmail.model.primitives.EmailAddress
import scala.jdk.CollectionConverters._
trait WorkMail extends AspectSupport[WorkMail] {
  val api: WorkMailAsyncClient
  def deleteImpersonationRole(request: DeleteImpersonationRoleRequest): IO[
    AwsError,
    zio.aws.workmail.model.DeleteImpersonationRoleResponse.ReadOnly
  ]
  def deleteMailboxPermissions(request: DeleteMailboxPermissionsRequest): IO[
    AwsError,
    zio.aws.workmail.model.DeleteMailboxPermissionsResponse.ReadOnly
  ]
  def disassociateMemberFromGroup(
      request: DisassociateMemberFromGroupRequest
  ): IO[
    AwsError,
    zio.aws.workmail.model.DisassociateMemberFromGroupResponse.ReadOnly
  ]
  def listAccessControlRules(request: ListAccessControlRulesRequest): IO[
    AwsError,
    zio.aws.workmail.model.ListAccessControlRulesResponse.ReadOnly
  ]
  def updateImpersonationRole(request: UpdateImpersonationRoleRequest): IO[
    AwsError,
    zio.aws.workmail.model.UpdateImpersonationRoleResponse.ReadOnly
  ]
  def cancelMailboxExportJob(request: CancelMailboxExportJobRequest): IO[
    AwsError,
    zio.aws.workmail.model.CancelMailboxExportJobResponse.ReadOnly
  ]
  def createResource(
      request: CreateResourceRequest
  ): IO[AwsError, zio.aws.workmail.model.CreateResourceResponse.ReadOnly]
  def listUsers(
      request: ListUsersRequest
  ): ZStream[Any, AwsError, zio.aws.workmail.model.User.ReadOnly]
  def listUsersPaginated(
      request: ListUsersRequest
  ): IO[AwsError, zio.aws.workmail.model.ListUsersResponse.ReadOnly]
  def updateUser(
      request: UpdateUserRequest
  ): IO[AwsError, zio.aws.workmail.model.UpdateUserResponse.ReadOnly]
  def describeOrganization(
      request: DescribeOrganizationRequest
  ): IO[AwsError, zio.aws.workmail.model.DescribeOrganizationResponse.ReadOnly]
  def updateResource(
      request: UpdateResourceRequest
  ): IO[AwsError, zio.aws.workmail.model.UpdateResourceResponse.ReadOnly]
  def listImpersonationRoles(
      request: ListImpersonationRolesRequest
  ): ZStream[Any, AwsError, zio.aws.workmail.model.ImpersonationRole.ReadOnly]
  def listImpersonationRolesPaginated(
      request: ListImpersonationRolesRequest
  ): IO[
    AwsError,
    zio.aws.workmail.model.ListImpersonationRolesResponse.ReadOnly
  ]
  def listMailDomains(
      request: ListMailDomainsRequest
  ): ZStream[Any, AwsError, zio.aws.workmail.model.MailDomainSummary.ReadOnly]
  def listMailDomainsPaginated(
      request: ListMailDomainsRequest
  ): IO[AwsError, zio.aws.workmail.model.ListMailDomainsResponse.ReadOnly]
  def updateMobileDeviceAccessRule(
      request: UpdateMobileDeviceAccessRuleRequest
  ): IO[
    AwsError,
    zio.aws.workmail.model.UpdateMobileDeviceAccessRuleResponse.ReadOnly
  ]
  def associateDelegateToResource(
      request: AssociateDelegateToResourceRequest
  ): IO[
    AwsError,
    zio.aws.workmail.model.AssociateDelegateToResourceResponse.ReadOnly
  ]
  def deleteRetentionPolicy(
      request: DeleteRetentionPolicyRequest
  ): IO[AwsError, zio.aws.workmail.model.DeleteRetentionPolicyResponse.ReadOnly]
  def deregisterMailDomain(
      request: DeregisterMailDomainRequest
  ): IO[AwsError, zio.aws.workmail.model.DeregisterMailDomainResponse.ReadOnly]
  def listAvailabilityConfigurations(
      request: ListAvailabilityConfigurationsRequest
  ): ZStream[
    Any,
    AwsError,
    zio.aws.workmail.model.AvailabilityConfiguration.ReadOnly
  ]
  def listAvailabilityConfigurationsPaginated(
      request: ListAvailabilityConfigurationsRequest
  ): IO[AwsError, ReadOnly]
  def startMailboxExportJob(
      request: StartMailboxExportJobRequest
  ): IO[AwsError, zio.aws.workmail.model.StartMailboxExportJobResponse.ReadOnly]
  def listResourceDelegates(
      request: ListResourceDelegatesRequest
  ): ZStream[Any, AwsError, zio.aws.workmail.model.Delegate.ReadOnly]
  def listResourceDelegatesPaginated(
      request: ListResourceDelegatesRequest
  ): IO[AwsError, zio.aws.workmail.model.ListResourceDelegatesResponse.ReadOnly]
  def listMailboxExportJobs(
      request: ListMailboxExportJobsRequest
  ): ZStream[Any, AwsError, zio.aws.workmail.model.MailboxExportJob.ReadOnly]
  def listMailboxExportJobsPaginated(
      request: ListMailboxExportJobsRequest
  ): IO[AwsError, zio.aws.workmail.model.ListMailboxExportJobsResponse.ReadOnly]
  def deleteGroup(
      request: DeleteGroupRequest
  ): IO[AwsError, zio.aws.workmail.model.DeleteGroupResponse.ReadOnly]
  def associateMemberToGroup(request: AssociateMemberToGroupRequest): IO[
    AwsError,
    zio.aws.workmail.model.AssociateMemberToGroupResponse.ReadOnly
  ]
  def describeResource(
      request: DescribeResourceRequest
  ): IO[AwsError, zio.aws.workmail.model.DescribeResourceResponse.ReadOnly]
  def putAccessControlRule(
      request: PutAccessControlRuleRequest
  ): IO[AwsError, zio.aws.workmail.model.PutAccessControlRuleResponse.ReadOnly]
  def getMailboxDetails(
      request: GetMailboxDetailsRequest
  ): IO[AwsError, zio.aws.workmail.model.GetMailboxDetailsResponse.ReadOnly]
  def listOrganizations(
      request: ListOrganizationsRequest
  ): ZStream[Any, AwsError, zio.aws.workmail.model.OrganizationSummary.ReadOnly]
  def listOrganizationsPaginated(
      request: ListOrganizationsRequest
  ): IO[AwsError, zio.aws.workmail.model.ListOrganizationsResponse.ReadOnly]
  def deregisterFromWorkMail(request: DeregisterFromWorkMailRequest): IO[
    AwsError,
    zio.aws.workmail.model.DeregisterFromWorkMailResponse.ReadOnly
  ]
  def updateAvailabilityConfiguration(
      request: UpdateAvailabilityConfigurationRequest
  ): IO[
    AwsError,
    zio.aws.workmail.model.UpdateAvailabilityConfigurationResponse.ReadOnly
  ]
  def listMailboxPermissions(
      request: ListMailboxPermissionsRequest
  ): ZStream[Any, AwsError, zio.aws.workmail.model.Permission.ReadOnly]
  def listMailboxPermissionsPaginated(
      request: ListMailboxPermissionsRequest
  ): IO[
    AwsError,
    zio.aws.workmail.model.ListMailboxPermissionsResponse.ReadOnly
  ]
  def listGroups(
      request: ListGroupsRequest
  ): ZStream[Any, AwsError, zio.aws.workmail.model.Group.ReadOnly]
  def listGroupsPaginated(
      request: ListGroupsRequest
  ): IO[AwsError, zio.aws.workmail.model.ListGroupsResponse.ReadOnly]
  def getMobileDeviceAccessEffect(
      request: GetMobileDeviceAccessEffectRequest
  ): IO[
    AwsError,
    zio.aws.workmail.model.GetMobileDeviceAccessEffectResponse.ReadOnly
  ]
  def describeMailboxExportJob(request: DescribeMailboxExportJobRequest): IO[
    AwsError,
    zio.aws.workmail.model.DescribeMailboxExportJobResponse.ReadOnly
  ]
  def createUser(
      request: CreateUserRequest
  ): IO[AwsError, zio.aws.workmail.model.CreateUserResponse.ReadOnly]
  def deleteOrganization(
      request: DeleteOrganizationRequest
  ): IO[AwsError, zio.aws.workmail.model.DeleteOrganizationResponse.ReadOnly]
  def describeEmailMonitoringConfiguration(
      request: DescribeEmailMonitoringConfigurationRequest
  ): IO[
    AwsError,
    zio.aws.workmail.model.DescribeEmailMonitoringConfigurationResponse.ReadOnly
  ]
  def listGroupsForEntity(
      request: ListGroupsForEntityRequest
  ): ZStream[Any, AwsError, zio.aws.workmail.model.GroupIdentifier.ReadOnly]
  def listGroupsForEntityPaginated(
      request: ListGroupsForEntityRequest
  ): IO[AwsError, zio.aws.workmail.model.ListGroupsForEntityResponse.ReadOnly]
  def describeInboundDmarcSettings(
      request: DescribeInboundDmarcSettingsRequest
  ): IO[
    AwsError,
    zio.aws.workmail.model.DescribeInboundDmarcSettingsResponse.ReadOnly
  ]
  def assumeImpersonationRole(request: AssumeImpersonationRoleRequest): IO[
    AwsError,
    zio.aws.workmail.model.AssumeImpersonationRoleResponse.ReadOnly
  ]
  def listAliases(
      request: ListAliasesRequest
  ): ZStream[Any, AwsError, EmailAddress]
  def listAliasesPaginated(
      request: ListAliasesRequest
  ): IO[AwsError, zio.aws.workmail.model.ListAliasesResponse.ReadOnly]
  def listMobileDeviceAccessRules(
      request: ListMobileDeviceAccessRulesRequest
  ): IO[
    AwsError,
    zio.aws.workmail.model.ListMobileDeviceAccessRulesResponse.ReadOnly
  ]
  def testAvailabilityConfiguration(
      request: TestAvailabilityConfigurationRequest
  ): IO[
    AwsError,
    zio.aws.workmail.model.TestAvailabilityConfigurationResponse.ReadOnly
  ]
  def putMailboxPermissions(
      request: PutMailboxPermissionsRequest
  ): IO[AwsError, zio.aws.workmail.model.PutMailboxPermissionsResponse.ReadOnly]
  def deleteAccessControlRule(request: DeleteAccessControlRuleRequest): IO[
    AwsError,
    zio.aws.workmail.model.DeleteAccessControlRuleResponse.ReadOnly
  ]
  def createImpersonationRole(request: CreateImpersonationRoleRequest): IO[
    AwsError,
    zio.aws.workmail.model.CreateImpersonationRoleResponse.ReadOnly
  ]
  def putEmailMonitoringConfiguration(
      request: PutEmailMonitoringConfigurationRequest
  ): IO[
    AwsError,
    zio.aws.workmail.model.PutEmailMonitoringConfigurationResponse.ReadOnly
  ]
  def getAccessControlEffect(request: GetAccessControlEffectRequest): IO[
    AwsError,
    zio.aws.workmail.model.GetAccessControlEffectResponse.ReadOnly
  ]
  def getMailDomain(
      request: GetMailDomainRequest
  ): IO[AwsError, zio.aws.workmail.model.GetMailDomainResponse.ReadOnly]
  def untagResource(
      request: UntagResourceRequest
  ): IO[AwsError, zio.aws.workmail.model.UntagResourceResponse.ReadOnly]
  def createAlias(
      request: CreateAliasRequest
  ): IO[AwsError, zio.aws.workmail.model.CreateAliasResponse.ReadOnly]
  def listResources(
      request: ListResourcesRequest
  ): ZStream[Any, AwsError, zio.aws.workmail.model.Resource.ReadOnly]
  def listResourcesPaginated(
      request: ListResourcesRequest
  ): IO[AwsError, zio.aws.workmail.model.ListResourcesResponse.ReadOnly]
  def listGroupMembers(
      request: ListGroupMembersRequest
  ): ZStream[Any, AwsError, zio.aws.workmail.model.Member.ReadOnly]
  def listGroupMembersPaginated(
      request: ListGroupMembersRequest
  ): IO[AwsError, zio.aws.workmail.model.ListGroupMembersResponse.ReadOnly]
  def getDefaultRetentionPolicy(request: GetDefaultRetentionPolicyRequest): IO[
    AwsError,
    zio.aws.workmail.model.GetDefaultRetentionPolicyResponse.ReadOnly
  ]
  def createAvailabilityConfiguration(
      request: CreateAvailabilityConfigurationRequest
  ): IO[
    AwsError,
    zio.aws.workmail.model.CreateAvailabilityConfigurationResponse.ReadOnly
  ]
  def registerMailDomain(
      request: RegisterMailDomainRequest
  ): IO[AwsError, zio.aws.workmail.model.RegisterMailDomainResponse.ReadOnly]
  def listMobileDeviceAccessOverrides(
      request: ListMobileDeviceAccessOverridesRequest
  ): ZStream[
    Any,
    AwsError,
    zio.aws.workmail.model.MobileDeviceAccessOverride.ReadOnly
  ]
  def listMobileDeviceAccessOverridesPaginated(
      request: ListMobileDeviceAccessOverridesRequest
  ): IO[
    AwsError,
    zio.aws.workmail.model.ListMobileDeviceAccessOverridesResponse.ReadOnly
  ]
  def putInboundDmarcSettings(request: PutInboundDmarcSettingsRequest): IO[
    AwsError,
    zio.aws.workmail.model.PutInboundDmarcSettingsResponse.ReadOnly
  ]
  def describeGroup(
      request: DescribeGroupRequest
  ): IO[AwsError, zio.aws.workmail.model.DescribeGroupResponse.ReadOnly]
  def createGroup(
      request: CreateGroupRequest
  ): IO[AwsError, zio.aws.workmail.model.CreateGroupResponse.ReadOnly]
  def disassociateDelegateFromResource(
      request: DisassociateDelegateFromResourceRequest
  ): IO[
    AwsError,
    zio.aws.workmail.model.DisassociateDelegateFromResourceResponse.ReadOnly
  ]
  def describeUser(
      request: DescribeUserRequest
  ): IO[AwsError, zio.aws.workmail.model.DescribeUserResponse.ReadOnly]
  def listTagsForResource(
      request: ListTagsForResourceRequest
  ): IO[AwsError, zio.aws.workmail.model.ListTagsForResourceResponse.ReadOnly]
  def putRetentionPolicy(
      request: PutRetentionPolicyRequest
  ): IO[AwsError, zio.aws.workmail.model.PutRetentionPolicyResponse.ReadOnly]
  def updateGroup(
      request: UpdateGroupRequest
  ): IO[AwsError, zio.aws.workmail.model.UpdateGroupResponse.ReadOnly]
  def registerToWorkMail(
      request: RegisterToWorkMailRequest
  ): IO[AwsError, zio.aws.workmail.model.RegisterToWorkMailResponse.ReadOnly]
  def deleteMobileDeviceAccessRule(
      request: DeleteMobileDeviceAccessRuleRequest
  ): IO[
    AwsError,
    zio.aws.workmail.model.DeleteMobileDeviceAccessRuleResponse.ReadOnly
  ]
  def tagResource(
      request: TagResourceRequest
  ): IO[AwsError, zio.aws.workmail.model.TagResourceResponse.ReadOnly]
  def updatePrimaryEmailAddress(request: UpdatePrimaryEmailAddressRequest): IO[
    AwsError,
    zio.aws.workmail.model.UpdatePrimaryEmailAddressResponse.ReadOnly
  ]
  def resetPassword(
      request: ResetPasswordRequest
  ): IO[AwsError, zio.aws.workmail.model.ResetPasswordResponse.ReadOnly]
  def deleteAlias(
      request: DeleteAliasRequest
  ): IO[AwsError, zio.aws.workmail.model.DeleteAliasResponse.ReadOnly]
  def getImpersonationRole(
      request: GetImpersonationRoleRequest
  ): IO[AwsError, zio.aws.workmail.model.GetImpersonationRoleResponse.ReadOnly]
  def deleteUser(
      request: DeleteUserRequest
  ): IO[AwsError, zio.aws.workmail.model.DeleteUserResponse.ReadOnly]
  def deleteAvailabilityConfiguration(
      request: DeleteAvailabilityConfigurationRequest
  ): IO[
    AwsError,
    zio.aws.workmail.model.DeleteAvailabilityConfigurationResponse.ReadOnly
  ]
  def createMobileDeviceAccessRule(
      request: CreateMobileDeviceAccessRuleRequest
  ): IO[
    AwsError,
    zio.aws.workmail.model.CreateMobileDeviceAccessRuleResponse.ReadOnly
  ]
  def updateMailboxQuota(
      request: UpdateMailboxQuotaRequest
  ): IO[AwsError, zio.aws.workmail.model.UpdateMailboxQuotaResponse.ReadOnly]
  def deleteEmailMonitoringConfiguration(
      request: DeleteEmailMonitoringConfigurationRequest
  ): IO[
    AwsError,
    zio.aws.workmail.model.DeleteEmailMonitoringConfigurationResponse.ReadOnly
  ]
  def putMobileDeviceAccessOverride(
      request: PutMobileDeviceAccessOverrideRequest
  ): IO[
    AwsError,
    zio.aws.workmail.model.PutMobileDeviceAccessOverrideResponse.ReadOnly
  ]
  def deleteMobileDeviceAccessOverride(
      request: DeleteMobileDeviceAccessOverrideRequest
  ): IO[
    AwsError,
    zio.aws.workmail.model.DeleteMobileDeviceAccessOverrideResponse.ReadOnly
  ]
  def describeEntity(
      request: DescribeEntityRequest
  ): IO[AwsError, zio.aws.workmail.model.DescribeEntityResponse.ReadOnly]
  def getImpersonationRoleEffect(
      request: GetImpersonationRoleEffectRequest
  ): IO[
    AwsError,
    zio.aws.workmail.model.GetImpersonationRoleEffectResponse.ReadOnly
  ]
  def updateDefaultMailDomain(request: UpdateDefaultMailDomainRequest): IO[
    AwsError,
    zio.aws.workmail.model.UpdateDefaultMailDomainResponse.ReadOnly
  ]
  def getMobileDeviceAccessOverride(
      request: GetMobileDeviceAccessOverrideRequest
  ): IO[
    AwsError,
    zio.aws.workmail.model.GetMobileDeviceAccessOverrideResponse.ReadOnly
  ]
  def createOrganization(
      request: CreateOrganizationRequest
  ): IO[AwsError, zio.aws.workmail.model.CreateOrganizationResponse.ReadOnly]
  def deleteResource(
      request: DeleteResourceRequest
  ): IO[AwsError, zio.aws.workmail.model.DeleteResourceResponse.ReadOnly]
}
object WorkMail {
  val live: ZLayer[AwsConfig, java.lang.Throwable, WorkMail] = customized(
    identity
  )
  def customized(
      customization: WorkMailAsyncClientBuilder => WorkMailAsyncClientBuilder
  ): ZLayer[AwsConfig, java.lang.Throwable, WorkMail] =
    ZLayer.scoped(scoped(customization))
  def scoped(
      customization: WorkMailAsyncClientBuilder => WorkMailAsyncClientBuilder
  ): ZIO[AwsConfig with Scope, java.lang.Throwable, WorkMail] = for (
    awsConfig <- ZIO.service[AwsConfig]; executor <- ZIO.executor;
    builder = WorkMailAsyncClient
      .builder()
      .asyncConfiguration(
        software.amazon.awssdk.core.client.config.ClientAsyncConfiguration
          .builder()
          .advancedOption(
            software.amazon.awssdk.core.client.config.SdkAdvancedAsyncClientOption.FUTURE_COMPLETION_EXECUTOR,
            executor.asJava
          )
          .build()
      );
    b0 <- awsConfig.configure[WorkMailAsyncClient, WorkMailAsyncClientBuilder](
      builder
    );
    b1 <- awsConfig
      .configureHttpClient[WorkMailAsyncClient, WorkMailAsyncClientBuilder](
        b0,
        zio.aws.core.httpclient.ServiceHttpCapabilities(supportsHttp2 = false)
      ); client <- ZIO.attempt(customization(b1).build())
  ) yield new WorkMailImpl(client, AwsCallAspect.identity, ZEnvironment.empty)
  private class WorkMailImpl[R](
      override val api: WorkMailAsyncClient,
      override val aspect: AwsCallAspect[R],
      r: ZEnvironment[R]
  ) extends WorkMail
      with AwsServiceBase[R] {
    override val serviceName: String = "WorkMail"
    override def withAspect[R1](
        newAspect: AwsCallAspect[R1],
        r: ZEnvironment[R1]
    ): WorkMailImpl[R1] = new WorkMailImpl(api, newAspect, r)
    def deleteImpersonationRole(request: DeleteImpersonationRoleRequest): IO[
      AwsError,
      zio.aws.workmail.model.DeleteImpersonationRoleResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.DeleteImpersonationRoleRequest,
      DeleteImpersonationRoleResponse
    ]("deleteImpersonationRole", api.deleteImpersonationRole)(
      request.buildAwsValue()
    ).map(zio.aws.workmail.model.DeleteImpersonationRoleResponse.wrap)
      .provideEnvironment(r)
    def deleteMailboxPermissions(request: DeleteMailboxPermissionsRequest): IO[
      AwsError,
      zio.aws.workmail.model.DeleteMailboxPermissionsResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.DeleteMailboxPermissionsRequest,
      DeleteMailboxPermissionsResponse
    ]("deleteMailboxPermissions", api.deleteMailboxPermissions)(
      request.buildAwsValue()
    ).map(zio.aws.workmail.model.DeleteMailboxPermissionsResponse.wrap)
      .provideEnvironment(r)
    def disassociateMemberFromGroup(
        request: DisassociateMemberFromGroupRequest
    ): IO[
      AwsError,
      zio.aws.workmail.model.DisassociateMemberFromGroupResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.DisassociateMemberFromGroupRequest,
      DisassociateMemberFromGroupResponse
    ]("disassociateMemberFromGroup", api.disassociateMemberFromGroup)(
      request.buildAwsValue()
    ).map(zio.aws.workmail.model.DisassociateMemberFromGroupResponse.wrap)
      .provideEnvironment(r)
    def listAccessControlRules(request: ListAccessControlRulesRequest): IO[
      AwsError,
      zio.aws.workmail.model.ListAccessControlRulesResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.ListAccessControlRulesRequest,
      ListAccessControlRulesResponse
    ]("listAccessControlRules", api.listAccessControlRules)(
      request.buildAwsValue()
    ).map(zio.aws.workmail.model.ListAccessControlRulesResponse.wrap)
      .provideEnvironment(r)
    def updateImpersonationRole(request: UpdateImpersonationRoleRequest): IO[
      AwsError,
      zio.aws.workmail.model.UpdateImpersonationRoleResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.UpdateImpersonationRoleRequest,
      UpdateImpersonationRoleResponse
    ]("updateImpersonationRole", api.updateImpersonationRole)(
      request.buildAwsValue()
    ).map(zio.aws.workmail.model.UpdateImpersonationRoleResponse.wrap)
      .provideEnvironment(r)
    def cancelMailboxExportJob(request: CancelMailboxExportJobRequest): IO[
      AwsError,
      zio.aws.workmail.model.CancelMailboxExportJobResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.CancelMailboxExportJobRequest,
      CancelMailboxExportJobResponse
    ]("cancelMailboxExportJob", api.cancelMailboxExportJob)(
      request.buildAwsValue()
    ).map(zio.aws.workmail.model.CancelMailboxExportJobResponse.wrap)
      .provideEnvironment(r)
    def createResource(
        request: CreateResourceRequest
    ): IO[AwsError, zio.aws.workmail.model.CreateResourceResponse.ReadOnly] =
      asyncRequestResponse[
        software.amazon.awssdk.services.workmail.model.CreateResourceRequest,
        CreateResourceResponse
      ]("createResource", api.createResource)(request.buildAwsValue())
        .map(zio.aws.workmail.model.CreateResourceResponse.wrap)
        .provideEnvironment(r)
    def listUsers(
        request: ListUsersRequest
    ): ZStream[Any, AwsError, zio.aws.workmail.model.User.ReadOnly] =
      asyncSimplePaginatedRequest[
        software.amazon.awssdk.services.workmail.model.ListUsersRequest,
        ListUsersResponse,
        User
      ](
        "listUsers",
        api.listUsers,
        (r, token) => r.toBuilder().nextToken(token).build(),
        r => scala.Option(r.nextToken()),
        r => zio.Chunk.fromIterable(r.users().asScala)
      )(request.buildAwsValue())
        .map(item => zio.aws.workmail.model.User.wrap(item))
        .provideEnvironment(r)
    def listUsersPaginated(
        request: ListUsersRequest
    ): IO[AwsError, zio.aws.workmail.model.ListUsersResponse.ReadOnly] =
      asyncRequestResponse[
        software.amazon.awssdk.services.workmail.model.ListUsersRequest,
        ListUsersResponse
      ]("listUsers", api.listUsers)(request.buildAwsValue())
        .map(zio.aws.workmail.model.ListUsersResponse.wrap)
        .provideEnvironment(r)
    def updateUser(
        request: UpdateUserRequest
    ): IO[AwsError, zio.aws.workmail.model.UpdateUserResponse.ReadOnly] =
      asyncRequestResponse[
        software.amazon.awssdk.services.workmail.model.UpdateUserRequest,
        UpdateUserResponse
      ]("updateUser", api.updateUser)(request.buildAwsValue())
        .map(zio.aws.workmail.model.UpdateUserResponse.wrap)
        .provideEnvironment(r)
    def describeOrganization(request: DescribeOrganizationRequest): IO[
      AwsError,
      zio.aws.workmail.model.DescribeOrganizationResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.DescribeOrganizationRequest,
      DescribeOrganizationResponse
    ]("describeOrganization", api.describeOrganization)(request.buildAwsValue())
      .map(zio.aws.workmail.model.DescribeOrganizationResponse.wrap)
      .provideEnvironment(r)
    def updateResource(
        request: UpdateResourceRequest
    ): IO[AwsError, zio.aws.workmail.model.UpdateResourceResponse.ReadOnly] =
      asyncRequestResponse[
        software.amazon.awssdk.services.workmail.model.UpdateResourceRequest,
        UpdateResourceResponse
      ]("updateResource", api.updateResource)(request.buildAwsValue())
        .map(zio.aws.workmail.model.UpdateResourceResponse.wrap)
        .provideEnvironment(r)
    def listImpersonationRoles(request: ListImpersonationRolesRequest): ZStream[
      Any,
      AwsError,
      zio.aws.workmail.model.ImpersonationRole.ReadOnly
    ] = asyncSimplePaginatedRequest[
      software.amazon.awssdk.services.workmail.model.ListImpersonationRolesRequest,
      ListImpersonationRolesResponse,
      ImpersonationRole
    ](
      "listImpersonationRoles",
      api.listImpersonationRoles,
      (r, token) => r.toBuilder().nextToken(token).build(),
      r => scala.Option(r.nextToken()),
      r => zio.Chunk.fromIterable(r.roles().asScala)
    )(request.buildAwsValue())
      .map(item => zio.aws.workmail.model.ImpersonationRole.wrap(item))
      .provideEnvironment(r)
    def listImpersonationRolesPaginated(
        request: ListImpersonationRolesRequest
    ): IO[
      AwsError,
      zio.aws.workmail.model.ListImpersonationRolesResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.ListImpersonationRolesRequest,
      ListImpersonationRolesResponse
    ]("listImpersonationRoles", api.listImpersonationRoles)(
      request.buildAwsValue()
    ).map(zio.aws.workmail.model.ListImpersonationRolesResponse.wrap)
      .provideEnvironment(r)
    def listMailDomains(request: ListMailDomainsRequest): ZStream[
      Any,
      AwsError,
      zio.aws.workmail.model.MailDomainSummary.ReadOnly
    ] = asyncSimplePaginatedRequest[
      software.amazon.awssdk.services.workmail.model.ListMailDomainsRequest,
      ListMailDomainsResponse,
      MailDomainSummary
    ](
      "listMailDomains",
      api.listMailDomains,
      (r, token) => r.toBuilder().nextToken(token).build(),
      r => scala.Option(r.nextToken()),
      r => zio.Chunk.fromIterable(r.mailDomains().asScala)
    )(request.buildAwsValue())
      .map(item => zio.aws.workmail.model.MailDomainSummary.wrap(item))
      .provideEnvironment(r)
    def listMailDomainsPaginated(
        request: ListMailDomainsRequest
    ): IO[AwsError, zio.aws.workmail.model.ListMailDomainsResponse.ReadOnly] =
      asyncRequestResponse[
        software.amazon.awssdk.services.workmail.model.ListMailDomainsRequest,
        ListMailDomainsResponse
      ]("listMailDomains", api.listMailDomains)(request.buildAwsValue())
        .map(zio.aws.workmail.model.ListMailDomainsResponse.wrap)
        .provideEnvironment(r)
    def updateMobileDeviceAccessRule(
        request: UpdateMobileDeviceAccessRuleRequest
    ): IO[
      AwsError,
      zio.aws.workmail.model.UpdateMobileDeviceAccessRuleResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.UpdateMobileDeviceAccessRuleRequest,
      UpdateMobileDeviceAccessRuleResponse
    ]("updateMobileDeviceAccessRule", api.updateMobileDeviceAccessRule)(
      request.buildAwsValue()
    ).map(zio.aws.workmail.model.UpdateMobileDeviceAccessRuleResponse.wrap)
      .provideEnvironment(r)
    def associateDelegateToResource(
        request: AssociateDelegateToResourceRequest
    ): IO[
      AwsError,
      zio.aws.workmail.model.AssociateDelegateToResourceResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.AssociateDelegateToResourceRequest,
      AssociateDelegateToResourceResponse
    ]("associateDelegateToResource", api.associateDelegateToResource)(
      request.buildAwsValue()
    ).map(zio.aws.workmail.model.AssociateDelegateToResourceResponse.wrap)
      .provideEnvironment(r)
    def deleteRetentionPolicy(request: DeleteRetentionPolicyRequest): IO[
      AwsError,
      zio.aws.workmail.model.DeleteRetentionPolicyResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.DeleteRetentionPolicyRequest,
      DeleteRetentionPolicyResponse
    ]("deleteRetentionPolicy", api.deleteRetentionPolicy)(
      request.buildAwsValue()
    ).map(zio.aws.workmail.model.DeleteRetentionPolicyResponse.wrap)
      .provideEnvironment(r)
    def deregisterMailDomain(request: DeregisterMailDomainRequest): IO[
      AwsError,
      zio.aws.workmail.model.DeregisterMailDomainResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.DeregisterMailDomainRequest,
      DeregisterMailDomainResponse
    ]("deregisterMailDomain", api.deregisterMailDomain)(request.buildAwsValue())
      .map(zio.aws.workmail.model.DeregisterMailDomainResponse.wrap)
      .provideEnvironment(r)
    def listAvailabilityConfigurations(
        request: ListAvailabilityConfigurationsRequest
    ): ZStream[
      Any,
      AwsError,
      zio.aws.workmail.model.AvailabilityConfiguration.ReadOnly
    ] = asyncSimplePaginatedRequest[
      software.amazon.awssdk.services.workmail.model.ListAvailabilityConfigurationsRequest,
      ListAvailabilityConfigurationsResponse,
      AvailabilityConfiguration
    ](
      "listAvailabilityConfigurations",
      api.listAvailabilityConfigurations,
      (r, token) => r.toBuilder().nextToken(token).build(),
      r => scala.Option(r.nextToken()),
      r => zio.Chunk.fromIterable(r.availabilityConfigurations().asScala)
    )(request.buildAwsValue())
      .map(item => zio.aws.workmail.model.AvailabilityConfiguration.wrap(item))
      .provideEnvironment(r)
    def listAvailabilityConfigurationsPaginated(
        request: ListAvailabilityConfigurationsRequest
    ): IO[AwsError, ReadOnly] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.ListAvailabilityConfigurationsRequest,
      ListAvailabilityConfigurationsResponse
    ]("listAvailabilityConfigurations", api.listAvailabilityConfigurations)(
      request.buildAwsValue()
    ).map(zio.aws.workmail.model.ListAvailabilityConfigurationsResponse.wrap)
      .provideEnvironment(r)
    def startMailboxExportJob(request: StartMailboxExportJobRequest): IO[
      AwsError,
      zio.aws.workmail.model.StartMailboxExportJobResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.StartMailboxExportJobRequest,
      StartMailboxExportJobResponse
    ]("startMailboxExportJob", api.startMailboxExportJob)(
      request.buildAwsValue()
    ).map(zio.aws.workmail.model.StartMailboxExportJobResponse.wrap)
      .provideEnvironment(r)
    def listResourceDelegates(
        request: ListResourceDelegatesRequest
    ): ZStream[Any, AwsError, zio.aws.workmail.model.Delegate.ReadOnly] =
      asyncSimplePaginatedRequest[
        software.amazon.awssdk.services.workmail.model.ListResourceDelegatesRequest,
        ListResourceDelegatesResponse,
        Delegate
      ](
        "listResourceDelegates",
        api.listResourceDelegates,
        (r, token) => r.toBuilder().nextToken(token).build(),
        r => scala.Option(r.nextToken()),
        r => zio.Chunk.fromIterable(r.delegates().asScala)
      )(request.buildAwsValue())
        .map(item => zio.aws.workmail.model.Delegate.wrap(item))
        .provideEnvironment(r)
    def listResourceDelegatesPaginated(
        request: ListResourceDelegatesRequest
    ): IO[
      AwsError,
      zio.aws.workmail.model.ListResourceDelegatesResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.ListResourceDelegatesRequest,
      ListResourceDelegatesResponse
    ]("listResourceDelegates", api.listResourceDelegates)(
      request.buildAwsValue()
    ).map(zio.aws.workmail.model.ListResourceDelegatesResponse.wrap)
      .provideEnvironment(r)
    def listMailboxExportJobs(request: ListMailboxExportJobsRequest): ZStream[
      Any,
      AwsError,
      zio.aws.workmail.model.MailboxExportJob.ReadOnly
    ] = asyncSimplePaginatedRequest[
      software.amazon.awssdk.services.workmail.model.ListMailboxExportJobsRequest,
      ListMailboxExportJobsResponse,
      MailboxExportJob
    ](
      "listMailboxExportJobs",
      api.listMailboxExportJobs,
      (r, token) => r.toBuilder().nextToken(token).build(),
      r => scala.Option(r.nextToken()),
      r => zio.Chunk.fromIterable(r.jobs().asScala)
    )(request.buildAwsValue())
      .map(item => zio.aws.workmail.model.MailboxExportJob.wrap(item))
      .provideEnvironment(r)
    def listMailboxExportJobsPaginated(
        request: ListMailboxExportJobsRequest
    ): IO[
      AwsError,
      zio.aws.workmail.model.ListMailboxExportJobsResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.ListMailboxExportJobsRequest,
      ListMailboxExportJobsResponse
    ]("listMailboxExportJobs", api.listMailboxExportJobs)(
      request.buildAwsValue()
    ).map(zio.aws.workmail.model.ListMailboxExportJobsResponse.wrap)
      .provideEnvironment(r)
    def deleteGroup(
        request: DeleteGroupRequest
    ): IO[AwsError, zio.aws.workmail.model.DeleteGroupResponse.ReadOnly] =
      asyncRequestResponse[
        software.amazon.awssdk.services.workmail.model.DeleteGroupRequest,
        DeleteGroupResponse
      ]("deleteGroup", api.deleteGroup)(request.buildAwsValue())
        .map(zio.aws.workmail.model.DeleteGroupResponse.wrap)
        .provideEnvironment(r)
    def associateMemberToGroup(request: AssociateMemberToGroupRequest): IO[
      AwsError,
      zio.aws.workmail.model.AssociateMemberToGroupResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.AssociateMemberToGroupRequest,
      AssociateMemberToGroupResponse
    ]("associateMemberToGroup", api.associateMemberToGroup)(
      request.buildAwsValue()
    ).map(zio.aws.workmail.model.AssociateMemberToGroupResponse.wrap)
      .provideEnvironment(r)
    def describeResource(
        request: DescribeResourceRequest
    ): IO[AwsError, zio.aws.workmail.model.DescribeResourceResponse.ReadOnly] =
      asyncRequestResponse[
        software.amazon.awssdk.services.workmail.model.DescribeResourceRequest,
        DescribeResourceResponse
      ]("describeResource", api.describeResource)(request.buildAwsValue())
        .map(zio.aws.workmail.model.DescribeResourceResponse.wrap)
        .provideEnvironment(r)
    def putAccessControlRule(request: PutAccessControlRuleRequest): IO[
      AwsError,
      zio.aws.workmail.model.PutAccessControlRuleResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.PutAccessControlRuleRequest,
      PutAccessControlRuleResponse
    ]("putAccessControlRule", api.putAccessControlRule)(request.buildAwsValue())
      .map(zio.aws.workmail.model.PutAccessControlRuleResponse.wrap)
      .provideEnvironment(r)
    def getMailboxDetails(
        request: GetMailboxDetailsRequest
    ): IO[AwsError, zio.aws.workmail.model.GetMailboxDetailsResponse.ReadOnly] =
      asyncRequestResponse[
        software.amazon.awssdk.services.workmail.model.GetMailboxDetailsRequest,
        GetMailboxDetailsResponse
      ]("getMailboxDetails", api.getMailboxDetails)(request.buildAwsValue())
        .map(zio.aws.workmail.model.GetMailboxDetailsResponse.wrap)
        .provideEnvironment(r)
    def listOrganizations(request: ListOrganizationsRequest): ZStream[
      Any,
      AwsError,
      zio.aws.workmail.model.OrganizationSummary.ReadOnly
    ] = asyncSimplePaginatedRequest[
      software.amazon.awssdk.services.workmail.model.ListOrganizationsRequest,
      ListOrganizationsResponse,
      OrganizationSummary
    ](
      "listOrganizations",
      api.listOrganizations,
      (r, token) => r.toBuilder().nextToken(token).build(),
      r => scala.Option(r.nextToken()),
      r => zio.Chunk.fromIterable(r.organizationSummaries().asScala)
    )(request.buildAwsValue())
      .map(item => zio.aws.workmail.model.OrganizationSummary.wrap(item))
      .provideEnvironment(r)
    def listOrganizationsPaginated(
        request: ListOrganizationsRequest
    ): IO[AwsError, zio.aws.workmail.model.ListOrganizationsResponse.ReadOnly] =
      asyncRequestResponse[
        software.amazon.awssdk.services.workmail.model.ListOrganizationsRequest,
        ListOrganizationsResponse
      ]("listOrganizations", api.listOrganizations)(request.buildAwsValue())
        .map(zio.aws.workmail.model.ListOrganizationsResponse.wrap)
        .provideEnvironment(r)
    def deregisterFromWorkMail(request: DeregisterFromWorkMailRequest): IO[
      AwsError,
      zio.aws.workmail.model.DeregisterFromWorkMailResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.DeregisterFromWorkMailRequest,
      DeregisterFromWorkMailResponse
    ]("deregisterFromWorkMail", api.deregisterFromWorkMail)(
      request.buildAwsValue()
    ).map(zio.aws.workmail.model.DeregisterFromWorkMailResponse.wrap)
      .provideEnvironment(r)
    def updateAvailabilityConfiguration(
        request: UpdateAvailabilityConfigurationRequest
    ): IO[
      AwsError,
      zio.aws.workmail.model.UpdateAvailabilityConfigurationResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.UpdateAvailabilityConfigurationRequest,
      UpdateAvailabilityConfigurationResponse
    ]("updateAvailabilityConfiguration", api.updateAvailabilityConfiguration)(
      request.buildAwsValue()
    ).map(zio.aws.workmail.model.UpdateAvailabilityConfigurationResponse.wrap)
      .provideEnvironment(r)
    def listMailboxPermissions(
        request: ListMailboxPermissionsRequest
    ): ZStream[Any, AwsError, zio.aws.workmail.model.Permission.ReadOnly] =
      asyncSimplePaginatedRequest[
        software.amazon.awssdk.services.workmail.model.ListMailboxPermissionsRequest,
        ListMailboxPermissionsResponse,
        Permission
      ](
        "listMailboxPermissions",
        api.listMailboxPermissions,
        (r, token) => r.toBuilder().nextToken(token).build(),
        r => scala.Option(r.nextToken()),
        r => zio.Chunk.fromIterable(r.permissions().asScala)
      )(request.buildAwsValue())
        .map(item => zio.aws.workmail.model.Permission.wrap(item))
        .provideEnvironment(r)
    def listMailboxPermissionsPaginated(
        request: ListMailboxPermissionsRequest
    ): IO[
      AwsError,
      zio.aws.workmail.model.ListMailboxPermissionsResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.ListMailboxPermissionsRequest,
      ListMailboxPermissionsResponse
    ]("listMailboxPermissions", api.listMailboxPermissions)(
      request.buildAwsValue()
    ).map(zio.aws.workmail.model.ListMailboxPermissionsResponse.wrap)
      .provideEnvironment(r)
    def listGroups(
        request: ListGroupsRequest
    ): ZStream[Any, AwsError, zio.aws.workmail.model.Group.ReadOnly] =
      asyncSimplePaginatedRequest[
        software.amazon.awssdk.services.workmail.model.ListGroupsRequest,
        ListGroupsResponse,
        Group
      ](
        "listGroups",
        api.listGroups,
        (r, token) => r.toBuilder().nextToken(token).build(),
        r => scala.Option(r.nextToken()),
        r => zio.Chunk.fromIterable(r.groups().asScala)
      )(request.buildAwsValue())
        .map(item => zio.aws.workmail.model.Group.wrap(item))
        .provideEnvironment(r)
    def listGroupsPaginated(
        request: ListGroupsRequest
    ): IO[AwsError, zio.aws.workmail.model.ListGroupsResponse.ReadOnly] =
      asyncRequestResponse[
        software.amazon.awssdk.services.workmail.model.ListGroupsRequest,
        ListGroupsResponse
      ]("listGroups", api.listGroups)(request.buildAwsValue())
        .map(zio.aws.workmail.model.ListGroupsResponse.wrap)
        .provideEnvironment(r)
    def getMobileDeviceAccessEffect(
        request: GetMobileDeviceAccessEffectRequest
    ): IO[
      AwsError,
      zio.aws.workmail.model.GetMobileDeviceAccessEffectResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.GetMobileDeviceAccessEffectRequest,
      GetMobileDeviceAccessEffectResponse
    ]("getMobileDeviceAccessEffect", api.getMobileDeviceAccessEffect)(
      request.buildAwsValue()
    ).map(zio.aws.workmail.model.GetMobileDeviceAccessEffectResponse.wrap)
      .provideEnvironment(r)
    def describeMailboxExportJob(request: DescribeMailboxExportJobRequest): IO[
      AwsError,
      zio.aws.workmail.model.DescribeMailboxExportJobResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.DescribeMailboxExportJobRequest,
      DescribeMailboxExportJobResponse
    ]("describeMailboxExportJob", api.describeMailboxExportJob)(
      request.buildAwsValue()
    ).map(zio.aws.workmail.model.DescribeMailboxExportJobResponse.wrap)
      .provideEnvironment(r)
    def createUser(
        request: CreateUserRequest
    ): IO[AwsError, zio.aws.workmail.model.CreateUserResponse.ReadOnly] =
      asyncRequestResponse[
        software.amazon.awssdk.services.workmail.model.CreateUserRequest,
        CreateUserResponse
      ]("createUser", api.createUser)(request.buildAwsValue())
        .map(zio.aws.workmail.model.CreateUserResponse.wrap)
        .provideEnvironment(r)
    def deleteOrganization(request: DeleteOrganizationRequest): IO[
      AwsError,
      zio.aws.workmail.model.DeleteOrganizationResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.DeleteOrganizationRequest,
      DeleteOrganizationResponse
    ]("deleteOrganization", api.deleteOrganization)(request.buildAwsValue())
      .map(zio.aws.workmail.model.DeleteOrganizationResponse.wrap)
      .provideEnvironment(r)
    def describeEmailMonitoringConfiguration(
        request: DescribeEmailMonitoringConfigurationRequest
    ): IO[
      AwsError,
      zio.aws.workmail.model.DescribeEmailMonitoringConfigurationResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.DescribeEmailMonitoringConfigurationRequest,
      DescribeEmailMonitoringConfigurationResponse
    ](
      "describeEmailMonitoringConfiguration",
      api.describeEmailMonitoringConfiguration
    )(request.buildAwsValue())
      .map(
        zio.aws.workmail.model.DescribeEmailMonitoringConfigurationResponse.wrap
      )
      .provideEnvironment(r)
    def listGroupsForEntity(request: ListGroupsForEntityRequest): ZStream[
      Any,
      AwsError,
      zio.aws.workmail.model.GroupIdentifier.ReadOnly
    ] = asyncSimplePaginatedRequest[
      software.amazon.awssdk.services.workmail.model.ListGroupsForEntityRequest,
      ListGroupsForEntityResponse,
      GroupIdentifier
    ](
      "listGroupsForEntity",
      api.listGroupsForEntity,
      (r, token) => r.toBuilder().nextToken(token).build(),
      r => scala.Option(r.nextToken()),
      r => zio.Chunk.fromIterable(r.groups().asScala)
    )(request.buildAwsValue())
      .map(item => zio.aws.workmail.model.GroupIdentifier.wrap(item))
      .provideEnvironment(r)
    def listGroupsForEntityPaginated(request: ListGroupsForEntityRequest): IO[
      AwsError,
      zio.aws.workmail.model.ListGroupsForEntityResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.ListGroupsForEntityRequest,
      ListGroupsForEntityResponse
    ]("listGroupsForEntity", api.listGroupsForEntity)(request.buildAwsValue())
      .map(zio.aws.workmail.model.ListGroupsForEntityResponse.wrap)
      .provideEnvironment(r)
    def describeInboundDmarcSettings(
        request: DescribeInboundDmarcSettingsRequest
    ): IO[
      AwsError,
      zio.aws.workmail.model.DescribeInboundDmarcSettingsResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.DescribeInboundDmarcSettingsRequest,
      DescribeInboundDmarcSettingsResponse
    ]("describeInboundDmarcSettings", api.describeInboundDmarcSettings)(
      request.buildAwsValue()
    ).map(zio.aws.workmail.model.DescribeInboundDmarcSettingsResponse.wrap)
      .provideEnvironment(r)
    def assumeImpersonationRole(request: AssumeImpersonationRoleRequest): IO[
      AwsError,
      zio.aws.workmail.model.AssumeImpersonationRoleResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.AssumeImpersonationRoleRequest,
      AssumeImpersonationRoleResponse
    ]("assumeImpersonationRole", api.assumeImpersonationRole)(
      request.buildAwsValue()
    ).map(zio.aws.workmail.model.AssumeImpersonationRoleResponse.wrap)
      .provideEnvironment(r)
    def listAliases(
        request: ListAliasesRequest
    ): ZStream[Any, AwsError, EmailAddress] = asyncSimplePaginatedRequest[
      software.amazon.awssdk.services.workmail.model.ListAliasesRequest,
      ListAliasesResponse,
      java.lang.String
    ](
      "listAliases",
      api.listAliases,
      (r, token) => r.toBuilder().nextToken(token).build(),
      r => scala.Option(r.nextToken()),
      r => zio.Chunk.fromIterable(r.aliases().asScala)
    )(request.buildAwsValue())
      .map(item => zio.aws.workmail.model.primitives.EmailAddress(item))
      .provideEnvironment(r)
    def listAliasesPaginated(
        request: ListAliasesRequest
    ): IO[AwsError, zio.aws.workmail.model.ListAliasesResponse.ReadOnly] =
      asyncRequestResponse[
        software.amazon.awssdk.services.workmail.model.ListAliasesRequest,
        ListAliasesResponse
      ]("listAliases", api.listAliases)(request.buildAwsValue())
        .map(zio.aws.workmail.model.ListAliasesResponse.wrap)
        .provideEnvironment(r)
    def listMobileDeviceAccessRules(
        request: ListMobileDeviceAccessRulesRequest
    ): IO[
      AwsError,
      zio.aws.workmail.model.ListMobileDeviceAccessRulesResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.ListMobileDeviceAccessRulesRequest,
      ListMobileDeviceAccessRulesResponse
    ]("listMobileDeviceAccessRules", api.listMobileDeviceAccessRules)(
      request.buildAwsValue()
    ).map(zio.aws.workmail.model.ListMobileDeviceAccessRulesResponse.wrap)
      .provideEnvironment(r)
    def testAvailabilityConfiguration(
        request: TestAvailabilityConfigurationRequest
    ): IO[
      AwsError,
      zio.aws.workmail.model.TestAvailabilityConfigurationResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.TestAvailabilityConfigurationRequest,
      TestAvailabilityConfigurationResponse
    ]("testAvailabilityConfiguration", api.testAvailabilityConfiguration)(
      request.buildAwsValue()
    ).map(zio.aws.workmail.model.TestAvailabilityConfigurationResponse.wrap)
      .provideEnvironment(r)
    def putMailboxPermissions(request: PutMailboxPermissionsRequest): IO[
      AwsError,
      zio.aws.workmail.model.PutMailboxPermissionsResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.PutMailboxPermissionsRequest,
      PutMailboxPermissionsResponse
    ]("putMailboxPermissions", api.putMailboxPermissions)(
      request.buildAwsValue()
    ).map(zio.aws.workmail.model.PutMailboxPermissionsResponse.wrap)
      .provideEnvironment(r)
    def deleteAccessControlRule(request: DeleteAccessControlRuleRequest): IO[
      AwsError,
      zio.aws.workmail.model.DeleteAccessControlRuleResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.DeleteAccessControlRuleRequest,
      DeleteAccessControlRuleResponse
    ]("deleteAccessControlRule", api.deleteAccessControlRule)(
      request.buildAwsValue()
    ).map(zio.aws.workmail.model.DeleteAccessControlRuleResponse.wrap)
      .provideEnvironment(r)
    def createImpersonationRole(request: CreateImpersonationRoleRequest): IO[
      AwsError,
      zio.aws.workmail.model.CreateImpersonationRoleResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.CreateImpersonationRoleRequest,
      CreateImpersonationRoleResponse
    ]("createImpersonationRole", api.createImpersonationRole)(
      request.buildAwsValue()
    ).map(zio.aws.workmail.model.CreateImpersonationRoleResponse.wrap)
      .provideEnvironment(r)
    def putEmailMonitoringConfiguration(
        request: PutEmailMonitoringConfigurationRequest
    ): IO[
      AwsError,
      zio.aws.workmail.model.PutEmailMonitoringConfigurationResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.PutEmailMonitoringConfigurationRequest,
      PutEmailMonitoringConfigurationResponse
    ]("putEmailMonitoringConfiguration", api.putEmailMonitoringConfiguration)(
      request.buildAwsValue()
    ).map(zio.aws.workmail.model.PutEmailMonitoringConfigurationResponse.wrap)
      .provideEnvironment(r)
    def getAccessControlEffect(request: GetAccessControlEffectRequest): IO[
      AwsError,
      zio.aws.workmail.model.GetAccessControlEffectResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.GetAccessControlEffectRequest,
      GetAccessControlEffectResponse
    ]("getAccessControlEffect", api.getAccessControlEffect)(
      request.buildAwsValue()
    ).map(zio.aws.workmail.model.GetAccessControlEffectResponse.wrap)
      .provideEnvironment(r)
    def getMailDomain(
        request: GetMailDomainRequest
    ): IO[AwsError, zio.aws.workmail.model.GetMailDomainResponse.ReadOnly] =
      asyncRequestResponse[
        software.amazon.awssdk.services.workmail.model.GetMailDomainRequest,
        GetMailDomainResponse
      ]("getMailDomain", api.getMailDomain)(request.buildAwsValue())
        .map(zio.aws.workmail.model.GetMailDomainResponse.wrap)
        .provideEnvironment(r)
    def untagResource(
        request: UntagResourceRequest
    ): IO[AwsError, zio.aws.workmail.model.UntagResourceResponse.ReadOnly] =
      asyncRequestResponse[
        software.amazon.awssdk.services.workmail.model.UntagResourceRequest,
        UntagResourceResponse
      ]("untagResource", api.untagResource)(request.buildAwsValue())
        .map(zio.aws.workmail.model.UntagResourceResponse.wrap)
        .provideEnvironment(r)
    def createAlias(
        request: CreateAliasRequest
    ): IO[AwsError, zio.aws.workmail.model.CreateAliasResponse.ReadOnly] =
      asyncRequestResponse[
        software.amazon.awssdk.services.workmail.model.CreateAliasRequest,
        CreateAliasResponse
      ]("createAlias", api.createAlias)(request.buildAwsValue())
        .map(zio.aws.workmail.model.CreateAliasResponse.wrap)
        .provideEnvironment(r)
    def listResources(
        request: ListResourcesRequest
    ): ZStream[Any, AwsError, zio.aws.workmail.model.Resource.ReadOnly] =
      asyncSimplePaginatedRequest[
        software.amazon.awssdk.services.workmail.model.ListResourcesRequest,
        ListResourcesResponse,
        Resource
      ](
        "listResources",
        api.listResources,
        (r, token) => r.toBuilder().nextToken(token).build(),
        r => scala.Option(r.nextToken()),
        r => zio.Chunk.fromIterable(r.resources().asScala)
      )(request.buildAwsValue())
        .map(item => zio.aws.workmail.model.Resource.wrap(item))
        .provideEnvironment(r)
    def listResourcesPaginated(
        request: ListResourcesRequest
    ): IO[AwsError, zio.aws.workmail.model.ListResourcesResponse.ReadOnly] =
      asyncRequestResponse[
        software.amazon.awssdk.services.workmail.model.ListResourcesRequest,
        ListResourcesResponse
      ]("listResources", api.listResources)(request.buildAwsValue())
        .map(zio.aws.workmail.model.ListResourcesResponse.wrap)
        .provideEnvironment(r)
    def listGroupMembers(
        request: ListGroupMembersRequest
    ): ZStream[Any, AwsError, zio.aws.workmail.model.Member.ReadOnly] =
      asyncSimplePaginatedRequest[
        software.amazon.awssdk.services.workmail.model.ListGroupMembersRequest,
        ListGroupMembersResponse,
        Member
      ](
        "listGroupMembers",
        api.listGroupMembers,
        (r, token) => r.toBuilder().nextToken(token).build(),
        r => scala.Option(r.nextToken()),
        r => zio.Chunk.fromIterable(r.members().asScala)
      )(request.buildAwsValue())
        .map(item => zio.aws.workmail.model.Member.wrap(item))
        .provideEnvironment(r)
    def listGroupMembersPaginated(
        request: ListGroupMembersRequest
    ): IO[AwsError, zio.aws.workmail.model.ListGroupMembersResponse.ReadOnly] =
      asyncRequestResponse[
        software.amazon.awssdk.services.workmail.model.ListGroupMembersRequest,
        ListGroupMembersResponse
      ]("listGroupMembers", api.listGroupMembers)(request.buildAwsValue())
        .map(zio.aws.workmail.model.ListGroupMembersResponse.wrap)
        .provideEnvironment(r)
    def getDefaultRetentionPolicy(
        request: GetDefaultRetentionPolicyRequest
    ): IO[
      AwsError,
      zio.aws.workmail.model.GetDefaultRetentionPolicyResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.GetDefaultRetentionPolicyRequest,
      GetDefaultRetentionPolicyResponse
    ]("getDefaultRetentionPolicy", api.getDefaultRetentionPolicy)(
      request.buildAwsValue()
    ).map(zio.aws.workmail.model.GetDefaultRetentionPolicyResponse.wrap)
      .provideEnvironment(r)
    def createAvailabilityConfiguration(
        request: CreateAvailabilityConfigurationRequest
    ): IO[
      AwsError,
      zio.aws.workmail.model.CreateAvailabilityConfigurationResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.CreateAvailabilityConfigurationRequest,
      CreateAvailabilityConfigurationResponse
    ]("createAvailabilityConfiguration", api.createAvailabilityConfiguration)(
      request.buildAwsValue()
    ).map(zio.aws.workmail.model.CreateAvailabilityConfigurationResponse.wrap)
      .provideEnvironment(r)
    def registerMailDomain(request: RegisterMailDomainRequest): IO[
      AwsError,
      zio.aws.workmail.model.RegisterMailDomainResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.RegisterMailDomainRequest,
      RegisterMailDomainResponse
    ]("registerMailDomain", api.registerMailDomain)(request.buildAwsValue())
      .map(zio.aws.workmail.model.RegisterMailDomainResponse.wrap)
      .provideEnvironment(r)
    def listMobileDeviceAccessOverrides(
        request: ListMobileDeviceAccessOverridesRequest
    ): ZStream[
      Any,
      AwsError,
      zio.aws.workmail.model.MobileDeviceAccessOverride.ReadOnly
    ] = asyncSimplePaginatedRequest[
      software.amazon.awssdk.services.workmail.model.ListMobileDeviceAccessOverridesRequest,
      ListMobileDeviceAccessOverridesResponse,
      MobileDeviceAccessOverride
    ](
      "listMobileDeviceAccessOverrides",
      api.listMobileDeviceAccessOverrides,
      (r, token) => r.toBuilder().nextToken(token).build(),
      r => scala.Option(r.nextToken()),
      r => zio.Chunk.fromIterable(r.overrides().asScala)
    )(request.buildAwsValue())
      .map(item => zio.aws.workmail.model.MobileDeviceAccessOverride.wrap(item))
      .provideEnvironment(r)
    def listMobileDeviceAccessOverridesPaginated(
        request: ListMobileDeviceAccessOverridesRequest
    ): IO[
      AwsError,
      zio.aws.workmail.model.ListMobileDeviceAccessOverridesResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.ListMobileDeviceAccessOverridesRequest,
      ListMobileDeviceAccessOverridesResponse
    ]("listMobileDeviceAccessOverrides", api.listMobileDeviceAccessOverrides)(
      request.buildAwsValue()
    ).map(zio.aws.workmail.model.ListMobileDeviceAccessOverridesResponse.wrap)
      .provideEnvironment(r)
    def putInboundDmarcSettings(request: PutInboundDmarcSettingsRequest): IO[
      AwsError,
      zio.aws.workmail.model.PutInboundDmarcSettingsResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.PutInboundDmarcSettingsRequest,
      PutInboundDmarcSettingsResponse
    ]("putInboundDmarcSettings", api.putInboundDmarcSettings)(
      request.buildAwsValue()
    ).map(zio.aws.workmail.model.PutInboundDmarcSettingsResponse.wrap)
      .provideEnvironment(r)
    def describeGroup(
        request: DescribeGroupRequest
    ): IO[AwsError, zio.aws.workmail.model.DescribeGroupResponse.ReadOnly] =
      asyncRequestResponse[
        software.amazon.awssdk.services.workmail.model.DescribeGroupRequest,
        DescribeGroupResponse
      ]("describeGroup", api.describeGroup)(request.buildAwsValue())
        .map(zio.aws.workmail.model.DescribeGroupResponse.wrap)
        .provideEnvironment(r)
    def createGroup(
        request: CreateGroupRequest
    ): IO[AwsError, zio.aws.workmail.model.CreateGroupResponse.ReadOnly] =
      asyncRequestResponse[
        software.amazon.awssdk.services.workmail.model.CreateGroupRequest,
        CreateGroupResponse
      ]("createGroup", api.createGroup)(request.buildAwsValue())
        .map(zio.aws.workmail.model.CreateGroupResponse.wrap)
        .provideEnvironment(r)
    def disassociateDelegateFromResource(
        request: DisassociateDelegateFromResourceRequest
    ): IO[
      AwsError,
      zio.aws.workmail.model.DisassociateDelegateFromResourceResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.DisassociateDelegateFromResourceRequest,
      DisassociateDelegateFromResourceResponse
    ]("disassociateDelegateFromResource", api.disassociateDelegateFromResource)(
      request.buildAwsValue()
    ).map(zio.aws.workmail.model.DisassociateDelegateFromResourceResponse.wrap)
      .provideEnvironment(r)
    def describeUser(
        request: DescribeUserRequest
    ): IO[AwsError, zio.aws.workmail.model.DescribeUserResponse.ReadOnly] =
      asyncRequestResponse[
        software.amazon.awssdk.services.workmail.model.DescribeUserRequest,
        DescribeUserResponse
      ]("describeUser", api.describeUser)(request.buildAwsValue())
        .map(zio.aws.workmail.model.DescribeUserResponse.wrap)
        .provideEnvironment(r)
    def listTagsForResource(request: ListTagsForResourceRequest): IO[
      AwsError,
      zio.aws.workmail.model.ListTagsForResourceResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.ListTagsForResourceRequest,
      ListTagsForResourceResponse
    ]("listTagsForResource", api.listTagsForResource)(request.buildAwsValue())
      .map(zio.aws.workmail.model.ListTagsForResourceResponse.wrap)
      .provideEnvironment(r)
    def putRetentionPolicy(request: PutRetentionPolicyRequest): IO[
      AwsError,
      zio.aws.workmail.model.PutRetentionPolicyResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.PutRetentionPolicyRequest,
      PutRetentionPolicyResponse
    ]("putRetentionPolicy", api.putRetentionPolicy)(request.buildAwsValue())
      .map(zio.aws.workmail.model.PutRetentionPolicyResponse.wrap)
      .provideEnvironment(r)
    def updateGroup(
        request: UpdateGroupRequest
    ): IO[AwsError, zio.aws.workmail.model.UpdateGroupResponse.ReadOnly] =
      asyncRequestResponse[
        software.amazon.awssdk.services.workmail.model.UpdateGroupRequest,
        UpdateGroupResponse
      ]("updateGroup", api.updateGroup)(request.buildAwsValue())
        .map(zio.aws.workmail.model.UpdateGroupResponse.wrap)
        .provideEnvironment(r)
    def registerToWorkMail(request: RegisterToWorkMailRequest): IO[
      AwsError,
      zio.aws.workmail.model.RegisterToWorkMailResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.RegisterToWorkMailRequest,
      RegisterToWorkMailResponse
    ]("registerToWorkMail", api.registerToWorkMail)(request.buildAwsValue())
      .map(zio.aws.workmail.model.RegisterToWorkMailResponse.wrap)
      .provideEnvironment(r)
    def deleteMobileDeviceAccessRule(
        request: DeleteMobileDeviceAccessRuleRequest
    ): IO[
      AwsError,
      zio.aws.workmail.model.DeleteMobileDeviceAccessRuleResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.DeleteMobileDeviceAccessRuleRequest,
      DeleteMobileDeviceAccessRuleResponse
    ]("deleteMobileDeviceAccessRule", api.deleteMobileDeviceAccessRule)(
      request.buildAwsValue()
    ).map(zio.aws.workmail.model.DeleteMobileDeviceAccessRuleResponse.wrap)
      .provideEnvironment(r)
    def tagResource(
        request: TagResourceRequest
    ): IO[AwsError, zio.aws.workmail.model.TagResourceResponse.ReadOnly] =
      asyncRequestResponse[
        software.amazon.awssdk.services.workmail.model.TagResourceRequest,
        TagResourceResponse
      ]("tagResource", api.tagResource)(request.buildAwsValue())
        .map(zio.aws.workmail.model.TagResourceResponse.wrap)
        .provideEnvironment(r)
    def updatePrimaryEmailAddress(
        request: UpdatePrimaryEmailAddressRequest
    ): IO[
      AwsError,
      zio.aws.workmail.model.UpdatePrimaryEmailAddressResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.UpdatePrimaryEmailAddressRequest,
      UpdatePrimaryEmailAddressResponse
    ]("updatePrimaryEmailAddress", api.updatePrimaryEmailAddress)(
      request.buildAwsValue()
    ).map(zio.aws.workmail.model.UpdatePrimaryEmailAddressResponse.wrap)
      .provideEnvironment(r)
    def resetPassword(
        request: ResetPasswordRequest
    ): IO[AwsError, zio.aws.workmail.model.ResetPasswordResponse.ReadOnly] =
      asyncRequestResponse[
        software.amazon.awssdk.services.workmail.model.ResetPasswordRequest,
        ResetPasswordResponse
      ]("resetPassword", api.resetPassword)(request.buildAwsValue())
        .map(zio.aws.workmail.model.ResetPasswordResponse.wrap)
        .provideEnvironment(r)
    def deleteAlias(
        request: DeleteAliasRequest
    ): IO[AwsError, zio.aws.workmail.model.DeleteAliasResponse.ReadOnly] =
      asyncRequestResponse[
        software.amazon.awssdk.services.workmail.model.DeleteAliasRequest,
        DeleteAliasResponse
      ]("deleteAlias", api.deleteAlias)(request.buildAwsValue())
        .map(zio.aws.workmail.model.DeleteAliasResponse.wrap)
        .provideEnvironment(r)
    def getImpersonationRole(request: GetImpersonationRoleRequest): IO[
      AwsError,
      zio.aws.workmail.model.GetImpersonationRoleResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.GetImpersonationRoleRequest,
      GetImpersonationRoleResponse
    ]("getImpersonationRole", api.getImpersonationRole)(request.buildAwsValue())
      .map(zio.aws.workmail.model.GetImpersonationRoleResponse.wrap)
      .provideEnvironment(r)
    def deleteUser(
        request: DeleteUserRequest
    ): IO[AwsError, zio.aws.workmail.model.DeleteUserResponse.ReadOnly] =
      asyncRequestResponse[
        software.amazon.awssdk.services.workmail.model.DeleteUserRequest,
        DeleteUserResponse
      ]("deleteUser", api.deleteUser)(request.buildAwsValue())
        .map(zio.aws.workmail.model.DeleteUserResponse.wrap)
        .provideEnvironment(r)
    def deleteAvailabilityConfiguration(
        request: DeleteAvailabilityConfigurationRequest
    ): IO[
      AwsError,
      zio.aws.workmail.model.DeleteAvailabilityConfigurationResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.DeleteAvailabilityConfigurationRequest,
      DeleteAvailabilityConfigurationResponse
    ]("deleteAvailabilityConfiguration", api.deleteAvailabilityConfiguration)(
      request.buildAwsValue()
    ).map(zio.aws.workmail.model.DeleteAvailabilityConfigurationResponse.wrap)
      .provideEnvironment(r)
    def createMobileDeviceAccessRule(
        request: CreateMobileDeviceAccessRuleRequest
    ): IO[
      AwsError,
      zio.aws.workmail.model.CreateMobileDeviceAccessRuleResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.CreateMobileDeviceAccessRuleRequest,
      CreateMobileDeviceAccessRuleResponse
    ]("createMobileDeviceAccessRule", api.createMobileDeviceAccessRule)(
      request.buildAwsValue()
    ).map(zio.aws.workmail.model.CreateMobileDeviceAccessRuleResponse.wrap)
      .provideEnvironment(r)
    def updateMailboxQuota(request: UpdateMailboxQuotaRequest): IO[
      AwsError,
      zio.aws.workmail.model.UpdateMailboxQuotaResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.UpdateMailboxQuotaRequest,
      UpdateMailboxQuotaResponse
    ]("updateMailboxQuota", api.updateMailboxQuota)(request.buildAwsValue())
      .map(zio.aws.workmail.model.UpdateMailboxQuotaResponse.wrap)
      .provideEnvironment(r)
    def deleteEmailMonitoringConfiguration(
        request: DeleteEmailMonitoringConfigurationRequest
    ): IO[
      AwsError,
      zio.aws.workmail.model.DeleteEmailMonitoringConfigurationResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.DeleteEmailMonitoringConfigurationRequest,
      DeleteEmailMonitoringConfigurationResponse
    ](
      "deleteEmailMonitoringConfiguration",
      api.deleteEmailMonitoringConfiguration
    )(request.buildAwsValue())
      .map(
        zio.aws.workmail.model.DeleteEmailMonitoringConfigurationResponse.wrap
      )
      .provideEnvironment(r)
    def putMobileDeviceAccessOverride(
        request: PutMobileDeviceAccessOverrideRequest
    ): IO[
      AwsError,
      zio.aws.workmail.model.PutMobileDeviceAccessOverrideResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.PutMobileDeviceAccessOverrideRequest,
      PutMobileDeviceAccessOverrideResponse
    ]("putMobileDeviceAccessOverride", api.putMobileDeviceAccessOverride)(
      request.buildAwsValue()
    ).map(zio.aws.workmail.model.PutMobileDeviceAccessOverrideResponse.wrap)
      .provideEnvironment(r)
    def deleteMobileDeviceAccessOverride(
        request: DeleteMobileDeviceAccessOverrideRequest
    ): IO[
      AwsError,
      zio.aws.workmail.model.DeleteMobileDeviceAccessOverrideResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.DeleteMobileDeviceAccessOverrideRequest,
      DeleteMobileDeviceAccessOverrideResponse
    ]("deleteMobileDeviceAccessOverride", api.deleteMobileDeviceAccessOverride)(
      request.buildAwsValue()
    ).map(zio.aws.workmail.model.DeleteMobileDeviceAccessOverrideResponse.wrap)
      .provideEnvironment(r)
    def describeEntity(
        request: DescribeEntityRequest
    ): IO[AwsError, zio.aws.workmail.model.DescribeEntityResponse.ReadOnly] =
      asyncRequestResponse[
        software.amazon.awssdk.services.workmail.model.DescribeEntityRequest,
        DescribeEntityResponse
      ]("describeEntity", api.describeEntity)(request.buildAwsValue())
        .map(zio.aws.workmail.model.DescribeEntityResponse.wrap)
        .provideEnvironment(r)
    def getImpersonationRoleEffect(
        request: GetImpersonationRoleEffectRequest
    ): IO[
      AwsError,
      zio.aws.workmail.model.GetImpersonationRoleEffectResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.GetImpersonationRoleEffectRequest,
      GetImpersonationRoleEffectResponse
    ]("getImpersonationRoleEffect", api.getImpersonationRoleEffect)(
      request.buildAwsValue()
    ).map(zio.aws.workmail.model.GetImpersonationRoleEffectResponse.wrap)
      .provideEnvironment(r)
    def updateDefaultMailDomain(request: UpdateDefaultMailDomainRequest): IO[
      AwsError,
      zio.aws.workmail.model.UpdateDefaultMailDomainResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.UpdateDefaultMailDomainRequest,
      UpdateDefaultMailDomainResponse
    ]("updateDefaultMailDomain", api.updateDefaultMailDomain)(
      request.buildAwsValue()
    ).map(zio.aws.workmail.model.UpdateDefaultMailDomainResponse.wrap)
      .provideEnvironment(r)
    def getMobileDeviceAccessOverride(
        request: GetMobileDeviceAccessOverrideRequest
    ): IO[
      AwsError,
      zio.aws.workmail.model.GetMobileDeviceAccessOverrideResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.GetMobileDeviceAccessOverrideRequest,
      GetMobileDeviceAccessOverrideResponse
    ]("getMobileDeviceAccessOverride", api.getMobileDeviceAccessOverride)(
      request.buildAwsValue()
    ).map(zio.aws.workmail.model.GetMobileDeviceAccessOverrideResponse.wrap)
      .provideEnvironment(r)
    def createOrganization(request: CreateOrganizationRequest): IO[
      AwsError,
      zio.aws.workmail.model.CreateOrganizationResponse.ReadOnly
    ] = asyncRequestResponse[
      software.amazon.awssdk.services.workmail.model.CreateOrganizationRequest,
      CreateOrganizationResponse
    ]("createOrganization", api.createOrganization)(request.buildAwsValue())
      .map(zio.aws.workmail.model.CreateOrganizationResponse.wrap)
      .provideEnvironment(r)
    def deleteResource(
        request: DeleteResourceRequest
    ): IO[AwsError, zio.aws.workmail.model.DeleteResourceResponse.ReadOnly] =
      asyncRequestResponse[
        software.amazon.awssdk.services.workmail.model.DeleteResourceRequest,
        DeleteResourceResponse
      ]("deleteResource", api.deleteResource)(request.buildAwsValue())
        .map(zio.aws.workmail.model.DeleteResourceResponse.wrap)
        .provideEnvironment(r)
  }
  def deleteImpersonationRole(request: DeleteImpersonationRoleRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.DeleteImpersonationRoleResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.deleteImpersonationRole(request))
  def deleteMailboxPermissions(request: DeleteMailboxPermissionsRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.DeleteMailboxPermissionsResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.deleteMailboxPermissions(request))
  def disassociateMemberFromGroup(
      request: DisassociateMemberFromGroupRequest
  ): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.DisassociateMemberFromGroupResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.disassociateMemberFromGroup(request))
  def listAccessControlRules(request: ListAccessControlRulesRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.ListAccessControlRulesResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.listAccessControlRules(request))
  def updateImpersonationRole(request: UpdateImpersonationRoleRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.UpdateImpersonationRoleResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.updateImpersonationRole(request))
  def cancelMailboxExportJob(request: CancelMailboxExportJobRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.CancelMailboxExportJobResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.cancelMailboxExportJob(request))
  def createResource(request: CreateResourceRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.CreateResourceResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.createResource(request))
  def listUsers(request: ListUsersRequest): ZStream[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.User.ReadOnly
  ] = ZStream.serviceWithStream(_.listUsers(request))
  def listUsersPaginated(request: ListUsersRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.ListUsersResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.listUsersPaginated(request))
  def updateUser(request: UpdateUserRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.UpdateUserResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.updateUser(request))
  def describeOrganization(request: DescribeOrganizationRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.DescribeOrganizationResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.describeOrganization(request))
  def updateResource(request: UpdateResourceRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.UpdateResourceResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.updateResource(request))
  def listImpersonationRoles(request: ListImpersonationRolesRequest): ZStream[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.ImpersonationRole.ReadOnly
  ] = ZStream.serviceWithStream(_.listImpersonationRoles(request))
  def listImpersonationRolesPaginated(
      request: ListImpersonationRolesRequest
  ): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.ListImpersonationRolesResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.listImpersonationRolesPaginated(request))
  def listMailDomains(request: ListMailDomainsRequest): ZStream[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.MailDomainSummary.ReadOnly
  ] = ZStream.serviceWithStream(_.listMailDomains(request))
  def listMailDomainsPaginated(request: ListMailDomainsRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.ListMailDomainsResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.listMailDomainsPaginated(request))
  def updateMobileDeviceAccessRule(
      request: UpdateMobileDeviceAccessRuleRequest
  ): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.UpdateMobileDeviceAccessRuleResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.updateMobileDeviceAccessRule(request))
  def associateDelegateToResource(
      request: AssociateDelegateToResourceRequest
  ): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.AssociateDelegateToResourceResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.associateDelegateToResource(request))
  def deleteRetentionPolicy(request: DeleteRetentionPolicyRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.DeleteRetentionPolicyResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.deleteRetentionPolicy(request))
  def deregisterMailDomain(request: DeregisterMailDomainRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.DeregisterMailDomainResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.deregisterMailDomain(request))
  def listAvailabilityConfigurations(
      request: ListAvailabilityConfigurationsRequest
  ): ZStream[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.AvailabilityConfiguration.ReadOnly
  ] = ZStream.serviceWithStream(_.listAvailabilityConfigurations(request))
  def listAvailabilityConfigurationsPaginated(
      request: ListAvailabilityConfigurationsRequest
  ): ZIO[zio.aws.workmail.WorkMail, AwsError, ReadOnly] =
    ZIO.serviceWithZIO(_.listAvailabilityConfigurationsPaginated(request))
  def startMailboxExportJob(request: StartMailboxExportJobRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.StartMailboxExportJobResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.startMailboxExportJob(request))
  def listResourceDelegates(request: ListResourceDelegatesRequest): ZStream[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.Delegate.ReadOnly
  ] = ZStream.serviceWithStream(_.listResourceDelegates(request))
  def listResourceDelegatesPaginated(
      request: ListResourceDelegatesRequest
  ): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.ListResourceDelegatesResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.listResourceDelegatesPaginated(request))
  def listMailboxExportJobs(request: ListMailboxExportJobsRequest): ZStream[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.MailboxExportJob.ReadOnly
  ] = ZStream.serviceWithStream(_.listMailboxExportJobs(request))
  def listMailboxExportJobsPaginated(
      request: ListMailboxExportJobsRequest
  ): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.ListMailboxExportJobsResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.listMailboxExportJobsPaginated(request))
  def deleteGroup(request: DeleteGroupRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.DeleteGroupResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.deleteGroup(request))
  def associateMemberToGroup(request: AssociateMemberToGroupRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.AssociateMemberToGroupResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.associateMemberToGroup(request))
  def describeResource(request: DescribeResourceRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.DescribeResourceResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.describeResource(request))
  def putAccessControlRule(request: PutAccessControlRuleRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.PutAccessControlRuleResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.putAccessControlRule(request))
  def getMailboxDetails(request: GetMailboxDetailsRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.GetMailboxDetailsResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.getMailboxDetails(request))
  def listOrganizations(request: ListOrganizationsRequest): ZStream[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.OrganizationSummary.ReadOnly
  ] = ZStream.serviceWithStream(_.listOrganizations(request))
  def listOrganizationsPaginated(request: ListOrganizationsRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.ListOrganizationsResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.listOrganizationsPaginated(request))
  def deregisterFromWorkMail(request: DeregisterFromWorkMailRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.DeregisterFromWorkMailResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.deregisterFromWorkMail(request))
  def updateAvailabilityConfiguration(
      request: UpdateAvailabilityConfigurationRequest
  ): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.UpdateAvailabilityConfigurationResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.updateAvailabilityConfiguration(request))
  def listMailboxPermissions(request: ListMailboxPermissionsRequest): ZStream[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.Permission.ReadOnly
  ] = ZStream.serviceWithStream(_.listMailboxPermissions(request))
  def listMailboxPermissionsPaginated(
      request: ListMailboxPermissionsRequest
  ): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.ListMailboxPermissionsResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.listMailboxPermissionsPaginated(request))
  def listGroups(request: ListGroupsRequest): ZStream[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.Group.ReadOnly
  ] = ZStream.serviceWithStream(_.listGroups(request))
  def listGroupsPaginated(request: ListGroupsRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.ListGroupsResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.listGroupsPaginated(request))
  def getMobileDeviceAccessEffect(
      request: GetMobileDeviceAccessEffectRequest
  ): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.GetMobileDeviceAccessEffectResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.getMobileDeviceAccessEffect(request))
  def describeMailboxExportJob(request: DescribeMailboxExportJobRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.DescribeMailboxExportJobResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.describeMailboxExportJob(request))
  def createUser(request: CreateUserRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.CreateUserResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.createUser(request))
  def deleteOrganization(request: DeleteOrganizationRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.DeleteOrganizationResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.deleteOrganization(request))
  def describeEmailMonitoringConfiguration(
      request: DescribeEmailMonitoringConfigurationRequest
  ): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.DescribeEmailMonitoringConfigurationResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.describeEmailMonitoringConfiguration(request))
  def listGroupsForEntity(request: ListGroupsForEntityRequest): ZStream[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.GroupIdentifier.ReadOnly
  ] = ZStream.serviceWithStream(_.listGroupsForEntity(request))
  def listGroupsForEntityPaginated(request: ListGroupsForEntityRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.ListGroupsForEntityResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.listGroupsForEntityPaginated(request))
  def describeInboundDmarcSettings(
      request: DescribeInboundDmarcSettingsRequest
  ): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.DescribeInboundDmarcSettingsResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.describeInboundDmarcSettings(request))
  def assumeImpersonationRole(request: AssumeImpersonationRoleRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.AssumeImpersonationRoleResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.assumeImpersonationRole(request))
  def listAliases(
      request: ListAliasesRequest
  ): ZStream[zio.aws.workmail.WorkMail, AwsError, EmailAddress] =
    ZStream.serviceWithStream(_.listAliases(request))
  def listAliasesPaginated(request: ListAliasesRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.ListAliasesResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.listAliasesPaginated(request))
  def listMobileDeviceAccessRules(
      request: ListMobileDeviceAccessRulesRequest
  ): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.ListMobileDeviceAccessRulesResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.listMobileDeviceAccessRules(request))
  def testAvailabilityConfiguration(
      request: TestAvailabilityConfigurationRequest
  ): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.TestAvailabilityConfigurationResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.testAvailabilityConfiguration(request))
  def putMailboxPermissions(request: PutMailboxPermissionsRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.PutMailboxPermissionsResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.putMailboxPermissions(request))
  def deleteAccessControlRule(request: DeleteAccessControlRuleRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.DeleteAccessControlRuleResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.deleteAccessControlRule(request))
  def createImpersonationRole(request: CreateImpersonationRoleRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.CreateImpersonationRoleResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.createImpersonationRole(request))
  def putEmailMonitoringConfiguration(
      request: PutEmailMonitoringConfigurationRequest
  ): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.PutEmailMonitoringConfigurationResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.putEmailMonitoringConfiguration(request))
  def getAccessControlEffect(request: GetAccessControlEffectRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.GetAccessControlEffectResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.getAccessControlEffect(request))
  def getMailDomain(request: GetMailDomainRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.GetMailDomainResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.getMailDomain(request))
  def untagResource(request: UntagResourceRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.UntagResourceResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.untagResource(request))
  def createAlias(request: CreateAliasRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.CreateAliasResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.createAlias(request))
  def listResources(request: ListResourcesRequest): ZStream[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.Resource.ReadOnly
  ] = ZStream.serviceWithStream(_.listResources(request))
  def listResourcesPaginated(request: ListResourcesRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.ListResourcesResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.listResourcesPaginated(request))
  def listGroupMembers(request: ListGroupMembersRequest): ZStream[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.Member.ReadOnly
  ] = ZStream.serviceWithStream(_.listGroupMembers(request))
  def listGroupMembersPaginated(request: ListGroupMembersRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.ListGroupMembersResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.listGroupMembersPaginated(request))
  def getDefaultRetentionPolicy(request: GetDefaultRetentionPolicyRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.GetDefaultRetentionPolicyResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.getDefaultRetentionPolicy(request))
  def createAvailabilityConfiguration(
      request: CreateAvailabilityConfigurationRequest
  ): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.CreateAvailabilityConfigurationResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.createAvailabilityConfiguration(request))
  def registerMailDomain(request: RegisterMailDomainRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.RegisterMailDomainResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.registerMailDomain(request))
  def listMobileDeviceAccessOverrides(
      request: ListMobileDeviceAccessOverridesRequest
  ): ZStream[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.MobileDeviceAccessOverride.ReadOnly
  ] = ZStream.serviceWithStream(_.listMobileDeviceAccessOverrides(request))
  def listMobileDeviceAccessOverridesPaginated(
      request: ListMobileDeviceAccessOverridesRequest
  ): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.ListMobileDeviceAccessOverridesResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.listMobileDeviceAccessOverridesPaginated(request))
  def putInboundDmarcSettings(request: PutInboundDmarcSettingsRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.PutInboundDmarcSettingsResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.putInboundDmarcSettings(request))
  def describeGroup(request: DescribeGroupRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.DescribeGroupResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.describeGroup(request))
  def createGroup(request: CreateGroupRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.CreateGroupResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.createGroup(request))
  def disassociateDelegateFromResource(
      request: DisassociateDelegateFromResourceRequest
  ): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.DisassociateDelegateFromResourceResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.disassociateDelegateFromResource(request))
  def describeUser(request: DescribeUserRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.DescribeUserResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.describeUser(request))
  def listTagsForResource(request: ListTagsForResourceRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.ListTagsForResourceResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.listTagsForResource(request))
  def putRetentionPolicy(request: PutRetentionPolicyRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.PutRetentionPolicyResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.putRetentionPolicy(request))
  def updateGroup(request: UpdateGroupRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.UpdateGroupResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.updateGroup(request))
  def registerToWorkMail(request: RegisterToWorkMailRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.RegisterToWorkMailResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.registerToWorkMail(request))
  def deleteMobileDeviceAccessRule(
      request: DeleteMobileDeviceAccessRuleRequest
  ): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.DeleteMobileDeviceAccessRuleResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.deleteMobileDeviceAccessRule(request))
  def tagResource(request: TagResourceRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.TagResourceResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.tagResource(request))
  def updatePrimaryEmailAddress(request: UpdatePrimaryEmailAddressRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.UpdatePrimaryEmailAddressResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.updatePrimaryEmailAddress(request))
  def resetPassword(request: ResetPasswordRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.ResetPasswordResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.resetPassword(request))
  def deleteAlias(request: DeleteAliasRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.DeleteAliasResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.deleteAlias(request))
  def getImpersonationRole(request: GetImpersonationRoleRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.GetImpersonationRoleResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.getImpersonationRole(request))
  def deleteUser(request: DeleteUserRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.DeleteUserResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.deleteUser(request))
  def deleteAvailabilityConfiguration(
      request: DeleteAvailabilityConfigurationRequest
  ): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.DeleteAvailabilityConfigurationResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.deleteAvailabilityConfiguration(request))
  def createMobileDeviceAccessRule(
      request: CreateMobileDeviceAccessRuleRequest
  ): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.CreateMobileDeviceAccessRuleResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.createMobileDeviceAccessRule(request))
  def updateMailboxQuota(request: UpdateMailboxQuotaRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.UpdateMailboxQuotaResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.updateMailboxQuota(request))
  def deleteEmailMonitoringConfiguration(
      request: DeleteEmailMonitoringConfigurationRequest
  ): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.DeleteEmailMonitoringConfigurationResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.deleteEmailMonitoringConfiguration(request))
  def putMobileDeviceAccessOverride(
      request: PutMobileDeviceAccessOverrideRequest
  ): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.PutMobileDeviceAccessOverrideResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.putMobileDeviceAccessOverride(request))
  def deleteMobileDeviceAccessOverride(
      request: DeleteMobileDeviceAccessOverrideRequest
  ): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.DeleteMobileDeviceAccessOverrideResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.deleteMobileDeviceAccessOverride(request))
  def describeEntity(request: DescribeEntityRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.DescribeEntityResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.describeEntity(request))
  def getImpersonationRoleEffect(
      request: GetImpersonationRoleEffectRequest
  ): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.GetImpersonationRoleEffectResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.getImpersonationRoleEffect(request))
  def updateDefaultMailDomain(request: UpdateDefaultMailDomainRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.UpdateDefaultMailDomainResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.updateDefaultMailDomain(request))
  def getMobileDeviceAccessOverride(
      request: GetMobileDeviceAccessOverrideRequest
  ): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.GetMobileDeviceAccessOverrideResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.getMobileDeviceAccessOverride(request))
  def createOrganization(request: CreateOrganizationRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.CreateOrganizationResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.createOrganization(request))
  def deleteResource(request: DeleteResourceRequest): ZIO[
    zio.aws.workmail.WorkMail,
    AwsError,
    zio.aws.workmail.model.DeleteResourceResponse.ReadOnly
  ] = ZIO.serviceWithZIO(_.deleteResource(request))
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy