diff --git a/stytch/src/main/kotlin/com/stytch/java/b2b/StytchB2BClient.kt b/stytch/src/main/kotlin/com/stytch/java/b2b/StytchB2BClient.kt index d0f6e010..95341d00 100644 --- a/stytch/src/main/kotlin/com/stytch/java/b2b/StytchB2BClient.kt +++ b/stytch/src/main/kotlin/com/stytch/java/b2b/StytchB2BClient.kt @@ -55,11 +55,7 @@ import kotlinx.coroutines.SupervisorJob public class StytchB2BClient @JvmOverloads - constructor( - projectId: String, - secret: String, - clientConfig: OptionalClientConfig = OptionalClientConfig(), - ) { + constructor(projectId: String, secret: String, clientConfig: OptionalClientConfig = OptionalClientConfig()) { private val coroutineScope = CoroutineScope(SupervisorJob()) private val baseUrl = getBaseUrl(projectId, clientConfig) private val httpClient: HttpClient = diff --git a/stytch/src/main/kotlin/com/stytch/java/b2b/api/discoveryintermediatesessions/DiscoveryIntermediateSessions.kt b/stytch/src/main/kotlin/com/stytch/java/b2b/api/discoveryintermediatesessions/DiscoveryIntermediateSessions.kt index 71ba32a0..a8d0fb32 100644 --- a/stytch/src/main/kotlin/com/stytch/java/b2b/api/discoveryintermediatesessions/DiscoveryIntermediateSessions.kt +++ b/stytch/src/main/kotlin/com/stytch/java/b2b/api/discoveryintermediatesessions/DiscoveryIntermediateSessions.kt @@ -145,8 +145,7 @@ internal class IntermediateSessionsImpl( } override fun exchangeCompletable(data: ExchangeRequest): CompletableFuture> = - coroutineScope - .async { - exchange(data) - }.asCompletableFuture() + coroutineScope.async { + exchange(data) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/b2b/api/discoveryorganizations/DiscoveryOrganizations.kt b/stytch/src/main/kotlin/com/stytch/java/b2b/api/discoveryorganizations/DiscoveryOrganizations.kt index f9bf29f3..c6babf48 100644 --- a/stytch/src/main/kotlin/com/stytch/java/b2b/api/discoveryorganizations/DiscoveryOrganizations.kt +++ b/stytch/src/main/kotlin/com/stytch/java/b2b/api/discoveryorganizations/DiscoveryOrganizations.kt @@ -219,10 +219,9 @@ internal class OrganizationsImpl( } override fun createCompletable(data: CreateRequest): CompletableFuture> = - coroutineScope - .async { - create(data) - }.asCompletableFuture() + coroutineScope.async { + create(data) + }.asCompletableFuture() override suspend fun list(data: ListRequest): StytchResult = withContext(Dispatchers.IO) { @@ -242,8 +241,7 @@ internal class OrganizationsImpl( } override fun listCompletable(data: ListRequest): CompletableFuture> = - coroutineScope - .async { - list(data) - }.asCompletableFuture() + coroutineScope.async { + list(data) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/b2b/api/idpoauth/IDPOAuth.kt b/stytch/src/main/kotlin/com/stytch/java/b2b/api/idpoauth/IDPOAuth.kt index bc774532..52fc8904 100644 --- a/stytch/src/main/kotlin/com/stytch/java/b2b/api/idpoauth/IDPOAuth.kt +++ b/stytch/src/main/kotlin/com/stytch/java/b2b/api/idpoauth/IDPOAuth.kt @@ -213,10 +213,9 @@ internal class OAuthImpl( } override fun authorizeStartCompletable(data: AuthorizeStartRequest): CompletableFuture> = - coroutineScope - .async { - authorizeStart(data) - }.asCompletableFuture() + coroutineScope.async { + authorizeStart(data) + }.asCompletableFuture() override suspend fun authorize(data: AuthorizeRequest): StytchResult = withContext(Dispatchers.IO) { @@ -236,8 +235,7 @@ internal class OAuthImpl( } override fun authorizeCompletable(data: AuthorizeRequest): CompletableFuture> = - coroutineScope - .async { - authorize(data) - }.asCompletableFuture() + coroutineScope.async { + authorize(data) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/b2b/api/impersonation/Impersonation.kt b/stytch/src/main/kotlin/com/stytch/java/b2b/api/impersonation/Impersonation.kt index 2b26b137..31bbcde6 100644 --- a/stytch/src/main/kotlin/com/stytch/java/b2b/api/impersonation/Impersonation.kt +++ b/stytch/src/main/kotlin/com/stytch/java/b2b/api/impersonation/Impersonation.kt @@ -82,8 +82,7 @@ internal class ImpersonationImpl( } override fun authenticateCompletable(data: AuthenticateRequest): CompletableFuture> = - coroutineScope - .async { - authenticate(data) - }.asCompletableFuture() + coroutineScope.async { + authenticate(data) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/b2b/api/magiclinks/MagicLinks.kt b/stytch/src/main/kotlin/com/stytch/java/b2b/api/magiclinks/MagicLinks.kt index 103a6a3c..42252c39 100644 --- a/stytch/src/main/kotlin/com/stytch/java/b2b/api/magiclinks/MagicLinks.kt +++ b/stytch/src/main/kotlin/com/stytch/java/b2b/api/magiclinks/MagicLinks.kt @@ -129,8 +129,7 @@ internal class MagicLinksImpl( } override fun authenticateCompletable(data: AuthenticateRequest): CompletableFuture> = - coroutineScope - .async { - authenticate(data) - }.asCompletableFuture() + coroutineScope.async { + authenticate(data) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/b2b/api/magiclinksdiscovery/MagicLinksDiscovery.kt b/stytch/src/main/kotlin/com/stytch/java/b2b/api/magiclinksdiscovery/MagicLinksDiscovery.kt index 58b55eda..98a65eb2 100644 --- a/stytch/src/main/kotlin/com/stytch/java/b2b/api/magiclinksdiscovery/MagicLinksDiscovery.kt +++ b/stytch/src/main/kotlin/com/stytch/java/b2b/api/magiclinksdiscovery/MagicLinksDiscovery.kt @@ -67,8 +67,7 @@ internal class DiscoveryImpl( } override fun authenticateCompletable(data: AuthenticateRequest): CompletableFuture> = - coroutineScope - .async { - authenticate(data) - }.asCompletableFuture() + coroutineScope.async { + authenticate(data) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/b2b/api/magiclinksemail/MagicLinksEmail.kt b/stytch/src/main/kotlin/com/stytch/java/b2b/api/magiclinksemail/MagicLinksEmail.kt index fe9bd68c..8b86b01c 100644 --- a/stytch/src/main/kotlin/com/stytch/java/b2b/api/magiclinksemail/MagicLinksEmail.kt +++ b/stytch/src/main/kotlin/com/stytch/java/b2b/api/magiclinksemail/MagicLinksEmail.kt @@ -137,10 +137,9 @@ internal class EmailImpl( } override fun loginOrSignupCompletable(data: LoginOrSignupRequest): CompletableFuture> = - coroutineScope - .async { - loginOrSignup(data) - }.asCompletableFuture() + coroutineScope.async { + loginOrSignup(data) + }.asCompletableFuture() override suspend fun invite( data: InviteRequest, @@ -170,8 +169,7 @@ internal class EmailImpl( data: InviteRequest, methodOptions: InviteRequestOptions?, ): CompletableFuture> = - coroutineScope - .async { - invite(data, methodOptions) - }.asCompletableFuture() + coroutineScope.async { + invite(data, methodOptions) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/b2b/api/magiclinksemaildiscovery/MagicLinksEmailDiscovery.kt b/stytch/src/main/kotlin/com/stytch/java/b2b/api/magiclinksemaildiscovery/MagicLinksEmailDiscovery.kt index 91a7351d..318226ab 100644 --- a/stytch/src/main/kotlin/com/stytch/java/b2b/api/magiclinksemaildiscovery/MagicLinksEmailDiscovery.kt +++ b/stytch/src/main/kotlin/com/stytch/java/b2b/api/magiclinksemaildiscovery/MagicLinksEmailDiscovery.kt @@ -64,8 +64,7 @@ internal class DiscoveryImpl( } override fun sendCompletable(data: SendRequest): CompletableFuture> = - coroutineScope - .async { - send(data) - }.asCompletableFuture() + coroutineScope.async { + send(data) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/b2b/api/oauth/OAuth.kt b/stytch/src/main/kotlin/com/stytch/java/b2b/api/oauth/OAuth.kt index 94a31615..beccc3f4 100644 --- a/stytch/src/main/kotlin/com/stytch/java/b2b/api/oauth/OAuth.kt +++ b/stytch/src/main/kotlin/com/stytch/java/b2b/api/oauth/OAuth.kt @@ -148,8 +148,7 @@ internal class OAuthImpl( } override fun authenticateCompletable(data: AuthenticateRequest): CompletableFuture> = - coroutineScope - .async { - authenticate(data) - }.asCompletableFuture() + coroutineScope.async { + authenticate(data) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/b2b/api/oauthdiscovery/OAuthDiscovery.kt b/stytch/src/main/kotlin/com/stytch/java/b2b/api/oauthdiscovery/OAuthDiscovery.kt index 6cda22a6..6beaf325 100644 --- a/stytch/src/main/kotlin/com/stytch/java/b2b/api/oauthdiscovery/OAuthDiscovery.kt +++ b/stytch/src/main/kotlin/com/stytch/java/b2b/api/oauthdiscovery/OAuthDiscovery.kt @@ -67,8 +67,7 @@ internal class DiscoveryImpl( } override fun authenticateCompletable(data: AuthenticateRequest): CompletableFuture> = - coroutineScope - .async { - authenticate(data) - }.asCompletableFuture() + coroutineScope.async { + authenticate(data) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/b2b/api/organizations/Organizations.kt b/stytch/src/main/kotlin/com/stytch/java/b2b/api/organizations/Organizations.kt index 3fa7856c..183edaea 100644 --- a/stytch/src/main/kotlin/com/stytch/java/b2b/api/organizations/Organizations.kt +++ b/stytch/src/main/kotlin/com/stytch/java/b2b/api/organizations/Organizations.kt @@ -317,10 +317,9 @@ internal class OrganizationsImpl( } override fun createCompletable(data: CreateRequest): CompletableFuture> = - coroutineScope - .async { - create(data) - }.asCompletableFuture() + coroutineScope.async { + create(data) + }.asCompletableFuture() override suspend fun get(data: GetRequest): StytchResult = withContext(Dispatchers.IO) { @@ -343,10 +342,9 @@ internal class OrganizationsImpl( } override fun getCompletable(data: GetRequest): CompletableFuture> = - coroutineScope - .async { - get(data) - }.asCompletableFuture() + coroutineScope.async { + get(data) + }.asCompletableFuture() override suspend fun update( data: UpdateRequest, @@ -376,10 +374,9 @@ internal class OrganizationsImpl( data: UpdateRequest, methodOptions: UpdateRequestOptions?, ): CompletableFuture> = - coroutineScope - .async { - update(data, methodOptions) - }.asCompletableFuture() + coroutineScope.async { + update(data, methodOptions) + }.asCompletableFuture() override suspend fun delete( data: DeleteRequest, @@ -408,10 +405,9 @@ internal class OrganizationsImpl( data: DeleteRequest, methodOptions: DeleteRequestOptions?, ): CompletableFuture> = - coroutineScope - .async { - delete(data, methodOptions) - }.asCompletableFuture() + coroutineScope.async { + delete(data, methodOptions) + }.asCompletableFuture() override suspend fun search(data: SearchRequest): StytchResult = withContext(Dispatchers.IO) { @@ -431,10 +427,9 @@ internal class OrganizationsImpl( } override fun searchCompletable(data: SearchRequest): CompletableFuture> = - coroutineScope - .async { - search(data) - }.asCompletableFuture() + coroutineScope.async { + search(data) + }.asCompletableFuture() override suspend fun metrics(data: MetricsRequest): StytchResult = withContext(Dispatchers.IO) { @@ -457,10 +452,9 @@ internal class OrganizationsImpl( } override fun metricsCompletable(data: MetricsRequest): CompletableFuture> = - coroutineScope - .async { - metrics(data) - }.asCompletableFuture() + coroutineScope.async { + metrics(data) + }.asCompletableFuture() override suspend fun connectedApps( data: ConnectedAppsRequest, @@ -493,10 +487,9 @@ internal class OrganizationsImpl( data: ConnectedAppsRequest, methodOptions: ConnectedAppsRequestOptions?, ): CompletableFuture> = - coroutineScope - .async { - connectedApps(data, methodOptions) - }.asCompletableFuture() + coroutineScope.async { + connectedApps(data, methodOptions) + }.asCompletableFuture() override suspend fun getConnectedApp( data: GetConnectedAppRequest, @@ -529,10 +522,9 @@ internal class OrganizationsImpl( data: GetConnectedAppRequest, methodOptions: GetConnectedAppRequestOptions?, ): CompletableFuture> = - coroutineScope - .async { - getConnectedApp(data, methodOptions) - }.asCompletableFuture() + coroutineScope.async { + getConnectedApp(data, methodOptions) + }.asCompletableFuture() override suspend fun deleteExternalId( data: DeleteExternalIdRequest, @@ -561,8 +553,7 @@ internal class OrganizationsImpl( data: DeleteExternalIdRequest, methodOptions: DeleteExternalIdRequestOptions?, ): CompletableFuture> = - coroutineScope - .async { - deleteExternalId(data, methodOptions) - }.asCompletableFuture() + coroutineScope.async { + deleteExternalId(data, methodOptions) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/b2b/api/organizationsmembers/OrganizationsMembers.kt b/stytch/src/main/kotlin/com/stytch/java/b2b/api/organizationsmembers/OrganizationsMembers.kt index b6c2f57c..738363c6 100644 --- a/stytch/src/main/kotlin/com/stytch/java/b2b/api/organizationsmembers/OrganizationsMembers.kt +++ b/stytch/src/main/kotlin/com/stytch/java/b2b/api/organizationsmembers/OrganizationsMembers.kt @@ -666,10 +666,9 @@ internal class MembersImpl( data: UpdateRequest, methodOptions: UpdateRequestOptions?, ): CompletableFuture> = - coroutineScope - .async { - update(data, methodOptions) - }.asCompletableFuture() + coroutineScope.async { + update(data, methodOptions) + }.asCompletableFuture() override suspend fun delete( data: DeleteRequest, @@ -698,10 +697,9 @@ internal class MembersImpl( data: DeleteRequest, methodOptions: DeleteRequestOptions?, ): CompletableFuture> = - coroutineScope - .async { - delete(data, methodOptions) - }.asCompletableFuture() + coroutineScope.async { + delete(data, methodOptions) + }.asCompletableFuture() override suspend fun reactivate( data: ReactivateRequest, @@ -731,10 +729,9 @@ internal class MembersImpl( data: ReactivateRequest, methodOptions: ReactivateRequestOptions?, ): CompletableFuture> = - coroutineScope - .async { - reactivate(data, methodOptions) - }.asCompletableFuture() + coroutineScope.async { + reactivate(data, methodOptions) + }.asCompletableFuture() override suspend fun deleteMFAPhoneNumber( data: DeleteMFAPhoneNumberRequest, @@ -763,10 +760,9 @@ internal class MembersImpl( data: DeleteMFAPhoneNumberRequest, methodOptions: DeleteMFAPhoneNumberRequestOptions?, ): CompletableFuture> = - coroutineScope - .async { - deleteMFAPhoneNumber(data, methodOptions) - }.asCompletableFuture() + coroutineScope.async { + deleteMFAPhoneNumber(data, methodOptions) + }.asCompletableFuture() override suspend fun deleteTOTP( data: DeleteTOTPRequest, @@ -795,10 +791,9 @@ internal class MembersImpl( data: DeleteTOTPRequest, methodOptions: DeleteTOTPRequestOptions?, ): CompletableFuture> = - coroutineScope - .async { - deleteTOTP(data, methodOptions) - }.asCompletableFuture() + coroutineScope.async { + deleteTOTP(data, methodOptions) + }.asCompletableFuture() override suspend fun search( data: SearchRequest, @@ -828,10 +823,9 @@ internal class MembersImpl( data: SearchRequest, methodOptions: SearchRequestOptions?, ): CompletableFuture> = - coroutineScope - .async { - search(data, methodOptions) - }.asCompletableFuture() + coroutineScope.async { + search(data, methodOptions) + }.asCompletableFuture() override suspend fun deletePassword( data: DeletePasswordRequest, @@ -860,10 +854,9 @@ internal class MembersImpl( data: DeletePasswordRequest, methodOptions: DeletePasswordRequestOptions?, ): CompletableFuture> = - coroutineScope - .async { - deletePassword(data, methodOptions) - }.asCompletableFuture() + coroutineScope.async { + deletePassword(data, methodOptions) + }.asCompletableFuture() override suspend fun dangerouslyGet(data: DangerouslyGetRequest): StytchResult = withContext(Dispatchers.IO) { @@ -886,10 +879,9 @@ internal class MembersImpl( } override fun dangerouslyGetCompletable(data: DangerouslyGetRequest): CompletableFuture> = - coroutineScope - .async { - dangerouslyGet(data) - }.asCompletableFuture() + coroutineScope.async { + dangerouslyGet(data) + }.asCompletableFuture() override suspend fun oidcProviders(data: OIDCProviderInformationRequest): StytchResult = withContext(Dispatchers.IO) { @@ -912,10 +904,9 @@ internal class MembersImpl( } override fun oidcProvidersCompletable(data: OIDCProviderInformationRequest): CompletableFuture> = - coroutineScope - .async { - oidcProviders(data) - }.asCompletableFuture() + coroutineScope.async { + oidcProviders(data) + }.asCompletableFuture() override suspend fun unlinkRetiredEmail( data: UnlinkRetiredEmailRequest, @@ -945,10 +936,9 @@ internal class MembersImpl( data: UnlinkRetiredEmailRequest, methodOptions: UnlinkRetiredEmailRequestOptions?, ): CompletableFuture> = - coroutineScope - .async { - unlinkRetiredEmail(data, methodOptions) - }.asCompletableFuture() + coroutineScope.async { + unlinkRetiredEmail(data, methodOptions) + }.asCompletableFuture() override suspend fun startEmailUpdate( data: StartEmailUpdateRequest, @@ -978,10 +968,9 @@ internal class MembersImpl( data: StartEmailUpdateRequest, methodOptions: StartEmailUpdateRequestOptions?, ): CompletableFuture> = - coroutineScope - .async { - startEmailUpdate(data, methodOptions) - }.asCompletableFuture() + coroutineScope.async { + startEmailUpdate(data, methodOptions) + }.asCompletableFuture() override suspend fun getConnectedApps( data: GetConnectedAppsRequest, @@ -1014,10 +1003,9 @@ internal class MembersImpl( data: GetConnectedAppsRequest, methodOptions: GetConnectedAppsRequestOptions?, ): CompletableFuture> = - coroutineScope - .async { - getConnectedApps(data, methodOptions) - }.asCompletableFuture() + coroutineScope.async { + getConnectedApps(data, methodOptions) + }.asCompletableFuture() override suspend fun deleteExternalId( data: DeleteExternalIdRequest, @@ -1046,10 +1034,9 @@ internal class MembersImpl( data: DeleteExternalIdRequest, methodOptions: DeleteExternalIdRequestOptions?, ): CompletableFuture> = - coroutineScope - .async { - deleteExternalId(data, methodOptions) - }.asCompletableFuture() + coroutineScope.async { + deleteExternalId(data, methodOptions) + }.asCompletableFuture() override suspend fun create( data: CreateRequest, @@ -1079,10 +1066,9 @@ internal class MembersImpl( data: CreateRequest, methodOptions: CreateRequestOptions?, ): CompletableFuture> = - coroutineScope - .async { - create(data, methodOptions) - }.asCompletableFuture() + coroutineScope.async { + create(data, methodOptions) + }.asCompletableFuture() override suspend fun get(data: GetRequest): StytchResult = withContext(Dispatchers.IO) { @@ -1105,8 +1091,7 @@ internal class MembersImpl( } override fun getCompletable(data: GetRequest): CompletableFuture> = - coroutineScope - .async { - get(data) - }.asCompletableFuture() + coroutineScope.async { + get(data) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/b2b/api/organizationsmembersconnectedapps/OrganizationsMembersConnectedApps.kt b/stytch/src/main/kotlin/com/stytch/java/b2b/api/organizationsmembersconnectedapps/OrganizationsMembersConnectedApps.kt index c3916a9c..01a742e3 100644 --- a/stytch/src/main/kotlin/com/stytch/java/b2b/api/organizationsmembersconnectedapps/OrganizationsMembersConnectedApps.kt +++ b/stytch/src/main/kotlin/com/stytch/java/b2b/api/organizationsmembersconnectedapps/OrganizationsMembersConnectedApps.kt @@ -92,8 +92,7 @@ internal class ConnectedAppsImpl( data: RevokeRequest, methodOptions: RevokeRequestOptions?, ): CompletableFuture> = - coroutineScope - .async { - revoke(data, methodOptions) - }.asCompletableFuture() + coroutineScope.async { + revoke(data, methodOptions) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/b2b/api/organizationsmembersoauthproviders/OrganizationsMembersOAuthProviders.kt b/stytch/src/main/kotlin/com/stytch/java/b2b/api/organizationsmembersoauthproviders/OrganizationsMembersOAuthProviders.kt index 32dca88c..b51a4137 100644 --- a/stytch/src/main/kotlin/com/stytch/java/b2b/api/organizationsmembersoauthproviders/OrganizationsMembersOAuthProviders.kt +++ b/stytch/src/main/kotlin/com/stytch/java/b2b/api/organizationsmembersoauthproviders/OrganizationsMembersOAuthProviders.kt @@ -203,10 +203,9 @@ internal class OAuthProvidersImpl( } override fun googleCompletable(data: ProviderInformationRequest): CompletableFuture> = - coroutineScope - .async { - google(data) - }.asCompletableFuture() + coroutineScope.async { + google(data) + }.asCompletableFuture() override suspend fun microsoft(data: ProviderInformationRequest): StytchResult = withContext(Dispatchers.IO) { @@ -233,10 +232,9 @@ internal class OAuthProvidersImpl( } override fun microsoftCompletable(data: ProviderInformationRequest): CompletableFuture> = - coroutineScope - .async { - microsoft(data) - }.asCompletableFuture() + coroutineScope.async { + microsoft(data) + }.asCompletableFuture() override suspend fun slack(data: SlackRequest): StytchResult = withContext(Dispatchers.IO) { @@ -259,10 +257,9 @@ internal class OAuthProvidersImpl( } override fun slackCompletable(data: SlackRequest): CompletableFuture> = - coroutineScope - .async { - slack(data) - }.asCompletableFuture() + coroutineScope.async { + slack(data) + }.asCompletableFuture() override suspend fun hubspot(data: ProviderInformationRequest): StytchResult = withContext(Dispatchers.IO) { @@ -285,10 +282,9 @@ internal class OAuthProvidersImpl( } override fun hubspotCompletable(data: ProviderInformationRequest): CompletableFuture> = - coroutineScope - .async { - hubspot(data) - }.asCompletableFuture() + coroutineScope.async { + hubspot(data) + }.asCompletableFuture() override suspend fun github(data: ProviderInformationRequest): StytchResult = withContext(Dispatchers.IO) { @@ -311,8 +307,7 @@ internal class OAuthProvidersImpl( } override fun githubCompletable(data: ProviderInformationRequest): CompletableFuture> = - coroutineScope - .async { - github(data) - }.asCompletableFuture() + coroutineScope.async { + github(data) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/b2b/api/otpemail/OTPEmail.kt b/stytch/src/main/kotlin/com/stytch/java/b2b/api/otpemail/OTPEmail.kt index c0303a06..d348f30c 100644 --- a/stytch/src/main/kotlin/com/stytch/java/b2b/api/otpemail/OTPEmail.kt +++ b/stytch/src/main/kotlin/com/stytch/java/b2b/api/otpemail/OTPEmail.kt @@ -165,10 +165,9 @@ internal class EmailImpl( } override fun loginOrSignupCompletable(data: LoginOrSignupRequest): CompletableFuture> = - coroutineScope - .async { - loginOrSignup(data) - }.asCompletableFuture() + coroutineScope.async { + loginOrSignup(data) + }.asCompletableFuture() override suspend fun authenticate(data: AuthenticateRequest): StytchResult = withContext(Dispatchers.IO) { @@ -188,8 +187,7 @@ internal class EmailImpl( } override fun authenticateCompletable(data: AuthenticateRequest): CompletableFuture> = - coroutineScope - .async { - authenticate(data) - }.asCompletableFuture() + coroutineScope.async { + authenticate(data) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/b2b/api/otpemaildiscovery/OTPEmailDiscovery.kt b/stytch/src/main/kotlin/com/stytch/java/b2b/api/otpemaildiscovery/OTPEmailDiscovery.kt index 31a4deea..f6ce2d8c 100644 --- a/stytch/src/main/kotlin/com/stytch/java/b2b/api/otpemaildiscovery/OTPEmailDiscovery.kt +++ b/stytch/src/main/kotlin/com/stytch/java/b2b/api/otpemaildiscovery/OTPEmailDiscovery.kt @@ -90,10 +90,9 @@ internal class DiscoveryImpl( } override fun sendCompletable(data: SendRequest): CompletableFuture> = - coroutineScope - .async { - send(data) - }.asCompletableFuture() + coroutineScope.async { + send(data) + }.asCompletableFuture() override suspend fun authenticate(data: AuthenticateRequest): StytchResult = withContext(Dispatchers.IO) { @@ -113,8 +112,7 @@ internal class DiscoveryImpl( } override fun authenticateCompletable(data: AuthenticateRequest): CompletableFuture> = - coroutineScope - .async { - authenticate(data) - }.asCompletableFuture() + coroutineScope.async { + authenticate(data) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/b2b/api/otpsms/OTPSms.kt b/stytch/src/main/kotlin/com/stytch/java/b2b/api/otpsms/OTPSms.kt index 3a24ad1e..4c0184b0 100644 --- a/stytch/src/main/kotlin/com/stytch/java/b2b/api/otpsms/OTPSms.kt +++ b/stytch/src/main/kotlin/com/stytch/java/b2b/api/otpsms/OTPSms.kt @@ -273,10 +273,9 @@ internal class SmsImpl( } override fun sendCompletable(data: SendRequest): CompletableFuture> = - coroutineScope - .async { - send(data) - }.asCompletableFuture() + coroutineScope.async { + send(data) + }.asCompletableFuture() override suspend fun authenticate(data: AuthenticateRequest): StytchResult = withContext(Dispatchers.IO) { @@ -296,8 +295,7 @@ internal class SmsImpl( } override fun authenticateCompletable(data: AuthenticateRequest): CompletableFuture> = - coroutineScope - .async { - authenticate(data) - }.asCompletableFuture() + coroutineScope.async { + authenticate(data) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/b2b/api/passwords/Passwords.kt b/stytch/src/main/kotlin/com/stytch/java/b2b/api/passwords/Passwords.kt index 5a136c1a..ad20792d 100644 --- a/stytch/src/main/kotlin/com/stytch/java/b2b/api/passwords/Passwords.kt +++ b/stytch/src/main/kotlin/com/stytch/java/b2b/api/passwords/Passwords.kt @@ -278,10 +278,9 @@ internal class PasswordsImpl( } override fun strengthCheckCompletable(data: StrengthCheckRequest): CompletableFuture> = - coroutineScope - .async { - strengthCheck(data) - }.asCompletableFuture() + coroutineScope.async { + strengthCheck(data) + }.asCompletableFuture() override suspend fun migrate(data: MigrateRequest): StytchResult = withContext(Dispatchers.IO) { @@ -301,10 +300,9 @@ internal class PasswordsImpl( } override fun migrateCompletable(data: MigrateRequest): CompletableFuture> = - coroutineScope - .async { - migrate(data) - }.asCompletableFuture() + coroutineScope.async { + migrate(data) + }.asCompletableFuture() override suspend fun authenticate(data: AuthenticateRequest): StytchResult = withContext(Dispatchers.IO) { @@ -324,8 +322,7 @@ internal class PasswordsImpl( } override fun authenticateCompletable(data: AuthenticateRequest): CompletableFuture> = - coroutineScope - .async { - authenticate(data) - }.asCompletableFuture() + coroutineScope.async { + authenticate(data) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/b2b/api/passwordsdiscovery/PasswordsDiscovery.kt b/stytch/src/main/kotlin/com/stytch/java/b2b/api/passwordsdiscovery/PasswordsDiscovery.kt index e0bdc0f5..84efbfa0 100644 --- a/stytch/src/main/kotlin/com/stytch/java/b2b/api/passwordsdiscovery/PasswordsDiscovery.kt +++ b/stytch/src/main/kotlin/com/stytch/java/b2b/api/passwordsdiscovery/PasswordsDiscovery.kt @@ -100,8 +100,7 @@ internal class DiscoveryImpl( } override fun authenticateCompletable(data: AuthenticateRequest): CompletableFuture> = - coroutineScope - .async { - authenticate(data) - }.asCompletableFuture() + coroutineScope.async { + authenticate(data) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/b2b/api/passwordsdiscoveryemail/PasswordsDiscoveryEmail.kt b/stytch/src/main/kotlin/com/stytch/java/b2b/api/passwordsdiscoveryemail/PasswordsDiscoveryEmail.kt index a05757cf..8f9ad3b4 100644 --- a/stytch/src/main/kotlin/com/stytch/java/b2b/api/passwordsdiscoveryemail/PasswordsDiscoveryEmail.kt +++ b/stytch/src/main/kotlin/com/stytch/java/b2b/api/passwordsdiscoveryemail/PasswordsDiscoveryEmail.kt @@ -138,10 +138,9 @@ internal class EmailImpl( } override fun resetStartCompletable(data: ResetStartRequest): CompletableFuture> = - coroutineScope - .async { - resetStart(data) - }.asCompletableFuture() + coroutineScope.async { + resetStart(data) + }.asCompletableFuture() override suspend fun reset(data: ResetRequest): StytchResult = withContext(Dispatchers.IO) { @@ -161,8 +160,7 @@ internal class EmailImpl( } override fun resetCompletable(data: ResetRequest): CompletableFuture> = - coroutineScope - .async { - reset(data) - }.asCompletableFuture() + coroutineScope.async { + reset(data) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/b2b/api/passwordsemail/PasswordsEmail.kt b/stytch/src/main/kotlin/com/stytch/java/b2b/api/passwordsemail/PasswordsEmail.kt index 43e38500..e9544780 100644 --- a/stytch/src/main/kotlin/com/stytch/java/b2b/api/passwordsemail/PasswordsEmail.kt +++ b/stytch/src/main/kotlin/com/stytch/java/b2b/api/passwordsemail/PasswordsEmail.kt @@ -199,10 +199,9 @@ internal class EmailImpl( } override fun resetStartCompletable(data: ResetStartRequest): CompletableFuture> = - coroutineScope - .async { - resetStart(data) - }.asCompletableFuture() + coroutineScope.async { + resetStart(data) + }.asCompletableFuture() override suspend fun reset(data: ResetRequest): StytchResult = withContext(Dispatchers.IO) { @@ -222,10 +221,9 @@ internal class EmailImpl( } override fun resetCompletable(data: ResetRequest): CompletableFuture> = - coroutineScope - .async { - reset(data) - }.asCompletableFuture() + coroutineScope.async { + reset(data) + }.asCompletableFuture() override suspend fun requireReset( data: RequireResetRequest, @@ -255,8 +253,7 @@ internal class EmailImpl( data: RequireResetRequest, methodOptions: RequireResetRequestOptions?, ): CompletableFuture> = - coroutineScope - .async { - requireReset(data, methodOptions) - }.asCompletableFuture() + coroutineScope.async { + requireReset(data, methodOptions) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/b2b/api/passwordsexistingpassword/PasswordsExistingPassword.kt b/stytch/src/main/kotlin/com/stytch/java/b2b/api/passwordsexistingpassword/PasswordsExistingPassword.kt index bcc816b2..aa40e404 100644 --- a/stytch/src/main/kotlin/com/stytch/java/b2b/api/passwordsexistingpassword/PasswordsExistingPassword.kt +++ b/stytch/src/main/kotlin/com/stytch/java/b2b/api/passwordsexistingpassword/PasswordsExistingPassword.kt @@ -124,8 +124,7 @@ internal class ExistingPasswordImpl( } override fun resetCompletable(data: ResetRequest): CompletableFuture> = - coroutineScope - .async { - reset(data) - }.asCompletableFuture() + coroutineScope.async { + reset(data) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/b2b/api/passwordssession/PasswordsSession.kt b/stytch/src/main/kotlin/com/stytch/java/b2b/api/passwordssession/PasswordsSession.kt index 57c98bf9..2e4f7933 100644 --- a/stytch/src/main/kotlin/com/stytch/java/b2b/api/passwordssession/PasswordsSession.kt +++ b/stytch/src/main/kotlin/com/stytch/java/b2b/api/passwordssession/PasswordsSession.kt @@ -79,8 +79,7 @@ internal class SessionsImpl( } override fun resetCompletable(data: ResetRequest): CompletableFuture> = - coroutineScope - .async { - reset(data) - }.asCompletableFuture() + coroutineScope.async { + reset(data) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/b2b/api/rbac/RBAC.kt b/stytch/src/main/kotlin/com/stytch/java/b2b/api/rbac/RBAC.kt index 53dd7bdb..562a7faa 100644 --- a/stytch/src/main/kotlin/com/stytch/java/b2b/api/rbac/RBAC.kt +++ b/stytch/src/main/kotlin/com/stytch/java/b2b/api/rbac/RBAC.kt @@ -114,8 +114,7 @@ internal class RBACImpl( } override fun policyCompletable(data: PolicyRequest): CompletableFuture> = - coroutineScope - .async { - policy(data) - }.asCompletableFuture() + coroutineScope.async { + policy(data) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/b2b/api/rbacorganizations/RBACOrganizations.kt b/stytch/src/main/kotlin/com/stytch/java/b2b/api/rbacorganizations/RBACOrganizations.kt index d8cb5e7b..053a5370 100644 --- a/stytch/src/main/kotlin/com/stytch/java/b2b/api/rbacorganizations/RBACOrganizations.kt +++ b/stytch/src/main/kotlin/com/stytch/java/b2b/api/rbacorganizations/RBACOrganizations.kt @@ -26,6 +26,10 @@ import java.util.concurrent.CompletableFuture public interface Organizations { /** + * + * The organization RBAC policy feature is currently in private beta and must be enabled for your Workspace. Please + * contact Stytch support at support@stytch.com to request access. + * * Get the active RBAC Policy for a specific Organization within your Stytch Project. An Organization RBAC Policy contains * the roles that have been defined specifically for that organization, allowing for organization-specific permissioning * models. @@ -46,6 +50,10 @@ public interface Organizations { public suspend fun getOrgPolicy(data: GetOrgPolicyRequest): StytchResult /** + * + * The organization RBAC policy feature is currently in private beta and must be enabled for your Workspace. Please + * contact Stytch support at support@stytch.com to request access. + * * Get the active RBAC Policy for a specific Organization within your Stytch Project. An Organization RBAC Policy contains * the roles that have been defined specifically for that organization, allowing for organization-specific permissioning * models. @@ -69,6 +77,10 @@ public interface Organizations { ) /** + * + * The organization RBAC policy feature is currently in private beta and must be enabled for your Workspace. Please + * contact Stytch support at support@stytch.com to request access. + * * Get the active RBAC Policy for a specific Organization within your Stytch Project. An Organization RBAC Policy contains * the roles that have been defined specifically for that organization, allowing for organization-specific permissioning * models. @@ -89,6 +101,10 @@ public interface Organizations { public fun getOrgPolicyCompletable(data: GetOrgPolicyRequest): CompletableFuture> /** + * + * The organization RBAC policy feature is currently in private beta and must be enabled for your Workspace. Please + * contact Stytch support at support@stytch.com to request access. + * * Set the RBAC Policy for a specific Organization within your Stytch Project. An Organization RBAC Policy allows you to * define roles that are specific to that organization, providing fine-grained control over permissions at the * organization level. @@ -117,6 +133,10 @@ public interface Organizations { public suspend fun setOrgPolicy(data: SetOrgPolicyRequest): StytchResult /** + * + * The organization RBAC policy feature is currently in private beta and must be enabled for your Workspace. Please + * contact Stytch support at support@stytch.com to request access. + * * Set the RBAC Policy for a specific Organization within your Stytch Project. An Organization RBAC Policy allows you to * define roles that are specific to that organization, providing fine-grained control over permissions at the * organization level. @@ -148,6 +168,10 @@ public interface Organizations { ) /** + * + * The organization RBAC policy feature is currently in private beta and must be enabled for your Workspace. Please + * contact Stytch support at support@stytch.com to request access. + * * Set the RBAC Policy for a specific Organization within your Stytch Project. An Organization RBAC Policy allows you to * define roles that are specific to that organization, providing fine-grained control over permissions at the * organization level. @@ -203,10 +227,9 @@ internal class OrganizationsImpl( } override fun getOrgPolicyCompletable(data: GetOrgPolicyRequest): CompletableFuture> = - coroutineScope - .async { - getOrgPolicy(data) - }.asCompletableFuture() + coroutineScope.async { + getOrgPolicy(data) + }.asCompletableFuture() override suspend fun setOrgPolicy(data: SetOrgPolicyRequest): StytchResult = withContext(Dispatchers.IO) { @@ -226,8 +249,7 @@ internal class OrganizationsImpl( } override fun setOrgPolicyCompletable(data: SetOrgPolicyRequest): CompletableFuture> = - coroutineScope - .async { - setOrgPolicy(data) - }.asCompletableFuture() + coroutineScope.async { + setOrgPolicy(data) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/b2b/api/recoverycodes/RecoveryCodes.kt b/stytch/src/main/kotlin/com/stytch/java/b2b/api/recoverycodes/RecoveryCodes.kt index 56e78f71..6c43f749 100644 --- a/stytch/src/main/kotlin/com/stytch/java/b2b/api/recoverycodes/RecoveryCodes.kt +++ b/stytch/src/main/kotlin/com/stytch/java/b2b/api/recoverycodes/RecoveryCodes.kt @@ -112,10 +112,9 @@ internal class RecoveryCodesImpl( } override fun recoverCompletable(data: RecoverRequest): CompletableFuture> = - coroutineScope - .async { - recover(data) - }.asCompletableFuture() + coroutineScope.async { + recover(data) + }.asCompletableFuture() override suspend fun get(data: GetRequest): StytchResult = withContext(Dispatchers.IO) { @@ -138,10 +137,9 @@ internal class RecoveryCodesImpl( } override fun getCompletable(data: GetRequest): CompletableFuture> = - coroutineScope - .async { - get(data) - }.asCompletableFuture() + coroutineScope.async { + get(data) + }.asCompletableFuture() override suspend fun rotate(data: RotateRequest): StytchResult = withContext(Dispatchers.IO) { @@ -161,8 +159,7 @@ internal class RecoveryCodesImpl( } override fun rotateCompletable(data: RotateRequest): CompletableFuture> = - coroutineScope - .async { - rotate(data) - }.asCompletableFuture() + coroutineScope.async { + rotate(data) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/b2b/api/scimconnection/SCIMConnection.kt b/stytch/src/main/kotlin/com/stytch/java/b2b/api/scimconnection/SCIMConnection.kt index c5435d86..3497320b 100644 --- a/stytch/src/main/kotlin/com/stytch/java/b2b/api/scimconnection/SCIMConnection.kt +++ b/stytch/src/main/kotlin/com/stytch/java/b2b/api/scimconnection/SCIMConnection.kt @@ -286,10 +286,9 @@ internal class ConnectionImpl( data: UpdateRequest, methodOptions: UpdateRequestOptions?, ): CompletableFuture> = - coroutineScope - .async { - update(data, methodOptions) - }.asCompletableFuture() + coroutineScope.async { + update(data, methodOptions) + }.asCompletableFuture() override suspend fun delete( data: DeleteRequest, @@ -318,10 +317,9 @@ internal class ConnectionImpl( data: DeleteRequest, methodOptions: DeleteRequestOptions?, ): CompletableFuture> = - coroutineScope - .async { - delete(data, methodOptions) - }.asCompletableFuture() + coroutineScope.async { + delete(data, methodOptions) + }.asCompletableFuture() override suspend fun rotateStart( data: RotateStartRequest, @@ -351,10 +349,9 @@ internal class ConnectionImpl( data: RotateStartRequest, methodOptions: RotateStartRequestOptions?, ): CompletableFuture> = - coroutineScope - .async { - rotateStart(data, methodOptions) - }.asCompletableFuture() + coroutineScope.async { + rotateStart(data, methodOptions) + }.asCompletableFuture() override suspend fun rotateComplete( data: RotateCompleteRequest, @@ -384,10 +381,9 @@ internal class ConnectionImpl( data: RotateCompleteRequest, methodOptions: RotateCompleteRequestOptions?, ): CompletableFuture> = - coroutineScope - .async { - rotateComplete(data, methodOptions) - }.asCompletableFuture() + coroutineScope.async { + rotateComplete(data, methodOptions) + }.asCompletableFuture() override suspend fun rotateCancel( data: RotateCancelRequest, @@ -417,10 +413,9 @@ internal class ConnectionImpl( data: RotateCancelRequest, methodOptions: RotateCancelRequestOptions?, ): CompletableFuture> = - coroutineScope - .async { - rotateCancel(data, methodOptions) - }.asCompletableFuture() + coroutineScope.async { + rotateCancel(data, methodOptions) + }.asCompletableFuture() override suspend fun getGroups( data: GetGroupsRequest, @@ -453,10 +448,9 @@ internal class ConnectionImpl( data: GetGroupsRequest, methodOptions: GetGroupsRequestOptions?, ): CompletableFuture> = - coroutineScope - .async { - getGroups(data, methodOptions) - }.asCompletableFuture() + coroutineScope.async { + getGroups(data, methodOptions) + }.asCompletableFuture() override suspend fun create( data: CreateRequest, @@ -486,10 +480,9 @@ internal class ConnectionImpl( data: CreateRequest, methodOptions: CreateRequestOptions?, ): CompletableFuture> = - coroutineScope - .async { - create(data, methodOptions) - }.asCompletableFuture() + coroutineScope.async { + create(data, methodOptions) + }.asCompletableFuture() override suspend fun get( data: GetRequest, @@ -522,8 +515,7 @@ internal class ConnectionImpl( data: GetRequest, methodOptions: GetRequestOptions?, ): CompletableFuture> = - coroutineScope - .async { - get(data, methodOptions) - }.asCompletableFuture() + coroutineScope.async { + get(data, methodOptions) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/b2b/api/sessions/Sessions.kt b/stytch/src/main/kotlin/com/stytch/java/b2b/api/sessions/Sessions.kt index 358d5bac..3663cb3a 100644 --- a/stytch/src/main/kotlin/com/stytch/java/b2b/api/sessions/Sessions.kt +++ b/stytch/src/main/kotlin/com/stytch/java/b2b/api/sessions/Sessions.kt @@ -270,9 +270,6 @@ public interface Sessions { * The Access Token must contain the `full_access` scope (only available to First Party clients) and must not be more than * 5 minutes old. Access Tokens may only be exchanged a single time. * - * The Member Session returned will be the same Member Session that was active in your application (the authorizing party) - * during the initial authorization flow. - * * Because the Member previously completed MFA and satisfied all Organization authentication requirements at the time of * the original Access Token issuance, this endpoint will never return an `intermediate_session_token` or require MFA. */ @@ -285,9 +282,6 @@ public interface Sessions { * The Access Token must contain the `full_access` scope (only available to First Party clients) and must not be more than * 5 minutes old. Access Tokens may only be exchanged a single time. * - * The Member Session returned will be the same Member Session that was active in your application (the authorizing party) - * during the initial authorization flow. - * * Because the Member previously completed MFA and satisfied all Organization authentication requirements at the time of * the original Access Token issuance, this endpoint will never return an `intermediate_session_token` or require MFA. */ @@ -303,9 +297,6 @@ public interface Sessions { * The Access Token must contain the `full_access` scope (only available to First Party clients) and must not be more than * 5 minutes old. Access Tokens may only be exchanged a single time. * - * The Member Session returned will be the same Member Session that was active in your application (the authorizing party) - * during the initial authorization flow. - * * Because the Member previously completed MFA and satisfied all Organization authentication requirements at the time of * the original Access Token issuance, this endpoint will never return an `intermediate_session_token` or require MFA. */ @@ -580,10 +571,9 @@ internal class SessionsImpl( } override fun getCompletable(data: GetRequest): CompletableFuture> = - coroutineScope - .async { - get(data) - }.asCompletableFuture() + coroutineScope.async { + get(data) + }.asCompletableFuture() override suspend fun authenticate(data: AuthenticateRequest): StytchResult = withContext(Dispatchers.IO) { @@ -603,10 +593,9 @@ internal class SessionsImpl( } override fun authenticateCompletable(data: AuthenticateRequest): CompletableFuture> = - coroutineScope - .async { - authenticate(data) - }.asCompletableFuture() + coroutineScope.async { + authenticate(data) + }.asCompletableFuture() override suspend fun revoke( data: RevokeRequest, @@ -636,10 +625,9 @@ internal class SessionsImpl( data: RevokeRequest, methodOptions: RevokeRequestOptions?, ): CompletableFuture> = - coroutineScope - .async { - revoke(data, methodOptions) - }.asCompletableFuture() + coroutineScope.async { + revoke(data, methodOptions) + }.asCompletableFuture() override suspend fun exchange(data: ExchangeRequest): StytchResult = withContext(Dispatchers.IO) { @@ -659,10 +647,9 @@ internal class SessionsImpl( } override fun exchangeCompletable(data: ExchangeRequest): CompletableFuture> = - coroutineScope - .async { - exchange(data) - }.asCompletableFuture() + coroutineScope.async { + exchange(data) + }.asCompletableFuture() override suspend fun exchangeAccessToken(data: ExchangeAccessTokenRequest): StytchResult = withContext(Dispatchers.IO) { @@ -684,10 +671,9 @@ internal class SessionsImpl( override fun exchangeAccessTokenCompletable( data: ExchangeAccessTokenRequest, ): CompletableFuture> = - coroutineScope - .async { - exchangeAccessToken(data) - }.asCompletableFuture() + coroutineScope.async { + exchangeAccessToken(data) + }.asCompletableFuture() override suspend fun attest(data: AttestRequest): StytchResult = withContext(Dispatchers.IO) { @@ -707,10 +693,9 @@ internal class SessionsImpl( } override fun attestCompletable(data: AttestRequest): CompletableFuture> = - coroutineScope - .async { - attest(data) - }.asCompletableFuture() + coroutineScope.async { + attest(data) + }.asCompletableFuture() override suspend fun migrate(data: MigrateRequest): StytchResult = withContext(Dispatchers.IO) { @@ -730,10 +715,9 @@ internal class SessionsImpl( } override fun migrateCompletable(data: MigrateRequest): CompletableFuture> = - coroutineScope - .async { - migrate(data) - }.asCompletableFuture() + coroutineScope.async { + migrate(data) + }.asCompletableFuture() override suspend fun getJWKS(data: GetJWKSRequest): StytchResult = withContext(Dispatchers.IO) { @@ -756,10 +740,9 @@ internal class SessionsImpl( } override fun getJWKSCompletable(data: GetJWKSRequest): CompletableFuture> = - coroutineScope - .async { - getJWKS(data) - }.asCompletableFuture() + coroutineScope.async { + getJWKS(data) + }.asCompletableFuture() // MANUAL(authenticateJWT_impl)(SERVICE_METHOD) override suspend fun authenticateJwt( diff --git a/stytch/src/main/kotlin/com/stytch/java/b2b/api/sso/SSO.kt b/stytch/src/main/kotlin/com/stytch/java/b2b/api/sso/SSO.kt index 95931576..4d1905d7 100644 --- a/stytch/src/main/kotlin/com/stytch/java/b2b/api/sso/SSO.kt +++ b/stytch/src/main/kotlin/com/stytch/java/b2b/api/sso/SSO.kt @@ -205,10 +205,9 @@ internal class SSOImpl( data: GetConnectionsRequest, methodOptions: GetConnectionsRequestOptions?, ): CompletableFuture> = - coroutineScope - .async { - getConnections(data, methodOptions) - }.asCompletableFuture() + coroutineScope.async { + getConnections(data, methodOptions) + }.asCompletableFuture() override suspend fun deleteConnection( data: DeleteConnectionRequest, @@ -237,10 +236,9 @@ internal class SSOImpl( data: DeleteConnectionRequest, methodOptions: DeleteConnectionRequestOptions?, ): CompletableFuture> = - coroutineScope - .async { - deleteConnection(data, methodOptions) - }.asCompletableFuture() + coroutineScope.async { + deleteConnection(data, methodOptions) + }.asCompletableFuture() override suspend fun authenticate(data: AuthenticateRequest): StytchResult = withContext(Dispatchers.IO) { @@ -260,8 +258,7 @@ internal class SSOImpl( } override fun authenticateCompletable(data: AuthenticateRequest): CompletableFuture> = - coroutineScope - .async { - authenticate(data) - }.asCompletableFuture() + coroutineScope.async { + authenticate(data) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/b2b/api/ssoexternal/SSOExternal.kt b/stytch/src/main/kotlin/com/stytch/java/b2b/api/ssoexternal/SSOExternal.kt index 28e59a75..c2fa1cd0 100644 --- a/stytch/src/main/kotlin/com/stytch/java/b2b/api/ssoexternal/SSOExternal.kt +++ b/stytch/src/main/kotlin/com/stytch/java/b2b/api/ssoexternal/SSOExternal.kt @@ -110,10 +110,9 @@ internal class ExternalImpl( data: CreateConnectionRequest, methodOptions: CreateConnectionRequestOptions?, ): CompletableFuture> = - coroutineScope - .async { - createConnection(data, methodOptions) - }.asCompletableFuture() + coroutineScope.async { + createConnection(data, methodOptions) + }.asCompletableFuture() override suspend fun updateConnection( data: UpdateConnectionRequest, @@ -143,8 +142,7 @@ internal class ExternalImpl( data: UpdateConnectionRequest, methodOptions: UpdateConnectionRequestOptions?, ): CompletableFuture> = - coroutineScope - .async { - updateConnection(data, methodOptions) - }.asCompletableFuture() + coroutineScope.async { + updateConnection(data, methodOptions) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/b2b/api/ssooidc/SSOOIDC.kt b/stytch/src/main/kotlin/com/stytch/java/b2b/api/ssooidc/SSOOIDC.kt index 06c146cb..f415ed74 100644 --- a/stytch/src/main/kotlin/com/stytch/java/b2b/api/ssooidc/SSOOIDC.kt +++ b/stytch/src/main/kotlin/com/stytch/java/b2b/api/ssooidc/SSOOIDC.kt @@ -179,10 +179,9 @@ internal class OIDCImpl( data: CreateConnectionRequest, methodOptions: CreateConnectionRequestOptions?, ): CompletableFuture> = - coroutineScope - .async { - createConnection(data, methodOptions) - }.asCompletableFuture() + coroutineScope.async { + createConnection(data, methodOptions) + }.asCompletableFuture() override suspend fun updateConnection( data: UpdateConnectionRequest, @@ -212,8 +211,7 @@ internal class OIDCImpl( data: UpdateConnectionRequest, methodOptions: UpdateConnectionRequestOptions?, ): CompletableFuture> = - coroutineScope - .async { - updateConnection(data, methodOptions) - }.asCompletableFuture() + coroutineScope.async { + updateConnection(data, methodOptions) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/b2b/api/ssosaml/SSOSAML.kt b/stytch/src/main/kotlin/com/stytch/java/b2b/api/ssosaml/SSOSAML.kt index c035217f..d43d91a0 100644 --- a/stytch/src/main/kotlin/com/stytch/java/b2b/api/ssosaml/SSOSAML.kt +++ b/stytch/src/main/kotlin/com/stytch/java/b2b/api/ssosaml/SSOSAML.kt @@ -239,10 +239,9 @@ internal class SAMLImpl( data: CreateConnectionRequest, methodOptions: CreateConnectionRequestOptions?, ): CompletableFuture> = - coroutineScope - .async { - createConnection(data, methodOptions) - }.asCompletableFuture() + coroutineScope.async { + createConnection(data, methodOptions) + }.asCompletableFuture() override suspend fun updateConnection( data: UpdateConnectionRequest, @@ -272,10 +271,9 @@ internal class SAMLImpl( data: UpdateConnectionRequest, methodOptions: UpdateConnectionRequestOptions?, ): CompletableFuture> = - coroutineScope - .async { - updateConnection(data, methodOptions) - }.asCompletableFuture() + coroutineScope.async { + updateConnection(data, methodOptions) + }.asCompletableFuture() override suspend fun updateByURL( data: UpdateByURLRequest, @@ -305,10 +303,9 @@ internal class SAMLImpl( data: UpdateByURLRequest, methodOptions: UpdateByURLRequestOptions?, ): CompletableFuture> = - coroutineScope - .async { - updateByURL(data, methodOptions) - }.asCompletableFuture() + coroutineScope.async { + updateByURL(data, methodOptions) + }.asCompletableFuture() override suspend fun deleteVerificationCertificate( data: DeleteVerificationCertificateRequest, @@ -340,10 +337,9 @@ internal class SAMLImpl( data: DeleteVerificationCertificateRequest, methodOptions: DeleteVerificationCertificateRequestOptions?, ): CompletableFuture> = - coroutineScope - .async { - deleteVerificationCertificate(data, methodOptions) - }.asCompletableFuture() + coroutineScope.async { + deleteVerificationCertificate(data, methodOptions) + }.asCompletableFuture() override suspend fun deleteEncryptionPrivateKey( data: DeleteEncryptionPrivateKeyRequest, @@ -375,8 +371,7 @@ internal class SAMLImpl( data: DeleteEncryptionPrivateKeyRequest, methodOptions: DeleteEncryptionPrivateKeyRequestOptions?, ): CompletableFuture> = - coroutineScope - .async { - deleteEncryptionPrivateKey(data, methodOptions) - }.asCompletableFuture() + coroutineScope.async { + deleteEncryptionPrivateKey(data, methodOptions) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/b2b/api/totps/TOTPs.kt b/stytch/src/main/kotlin/com/stytch/java/b2b/api/totps/TOTPs.kt index b9b07b76..e0094cf9 100644 --- a/stytch/src/main/kotlin/com/stytch/java/b2b/api/totps/TOTPs.kt +++ b/stytch/src/main/kotlin/com/stytch/java/b2b/api/totps/TOTPs.kt @@ -128,10 +128,9 @@ internal class TOTPsImpl( } override fun createCompletable(data: CreateRequest): CompletableFuture> = - coroutineScope - .async { - create(data) - }.asCompletableFuture() + coroutineScope.async { + create(data) + }.asCompletableFuture() override suspend fun authenticate(data: AuthenticateRequest): StytchResult = withContext(Dispatchers.IO) { @@ -151,10 +150,9 @@ internal class TOTPsImpl( } override fun authenticateCompletable(data: AuthenticateRequest): CompletableFuture> = - coroutineScope - .async { - authenticate(data) - }.asCompletableFuture() + coroutineScope.async { + authenticate(data) + }.asCompletableFuture() override suspend fun migrate(data: MigrateRequest): StytchResult = withContext(Dispatchers.IO) { @@ -174,8 +172,7 @@ internal class TOTPsImpl( } override fun migrateCompletable(data: MigrateRequest): CompletableFuture> = - coroutineScope - .async { - migrate(data) - }.asCompletableFuture() + coroutineScope.async { + migrate(data) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/common/Version.kt b/stytch/src/main/kotlin/com/stytch/java/common/Version.kt index d3e96dea..69a98302 100644 --- a/stytch/src/main/kotlin/com/stytch/java/common/Version.kt +++ b/stytch/src/main/kotlin/com/stytch/java/common/Version.kt @@ -1,3 +1,3 @@ package com.stytch.java.common -internal const val VERSION = "9.2.0" +internal const val VERSION = "9.2.1" diff --git a/stytch/src/main/kotlin/com/stytch/java/consumer/StytchClient.kt b/stytch/src/main/kotlin/com/stytch/java/consumer/StytchClient.kt index e7d9a048..2875a223 100644 --- a/stytch/src/main/kotlin/com/stytch/java/consumer/StytchClient.kt +++ b/stytch/src/main/kotlin/com/stytch/java/consumer/StytchClient.kt @@ -50,11 +50,7 @@ import kotlinx.coroutines.SupervisorJob public class StytchClient @JvmOverloads - constructor( - projectId: String, - secret: String, - clientConfig: OptionalClientConfig = OptionalClientConfig(), - ) { + constructor(projectId: String, secret: String, clientConfig: OptionalClientConfig = OptionalClientConfig()) { private val coroutineScope = CoroutineScope(SupervisorJob()) private val baseUrl = getBaseUrl(projectId, clientConfig) private val httpClient: HttpClient = diff --git a/stytch/src/main/kotlin/com/stytch/java/consumer/api/connectedappsclients/ConnectedAppsClients.kt b/stytch/src/main/kotlin/com/stytch/java/consumer/api/connectedappsclients/ConnectedAppsClients.kt index 05e20ba3..76e4d957 100644 --- a/stytch/src/main/kotlin/com/stytch/java/consumer/api/connectedappsclients/ConnectedAppsClients.kt +++ b/stytch/src/main/kotlin/com/stytch/java/consumer/api/connectedappsclients/ConnectedAppsClients.kt @@ -170,10 +170,9 @@ internal class ClientsImpl( } override fun getCompletable(data: GetRequest): CompletableFuture> = - coroutineScope - .async { - get(data) - }.asCompletableFuture() + coroutineScope.async { + get(data) + }.asCompletableFuture() override suspend fun update(data: UpdateRequest): StytchResult = withContext(Dispatchers.IO) { @@ -193,10 +192,9 @@ internal class ClientsImpl( } override fun updateCompletable(data: UpdateRequest): CompletableFuture> = - coroutineScope - .async { - update(data) - }.asCompletableFuture() + coroutineScope.async { + update(data) + }.asCompletableFuture() override suspend fun delete(data: DeleteRequest): StytchResult = withContext(Dispatchers.IO) { @@ -215,10 +213,9 @@ internal class ClientsImpl( } override fun deleteCompletable(data: DeleteRequest): CompletableFuture> = - coroutineScope - .async { - delete(data) - }.asCompletableFuture() + coroutineScope.async { + delete(data) + }.asCompletableFuture() override suspend fun search(data: SearchRequest): StytchResult = withContext(Dispatchers.IO) { @@ -238,10 +235,9 @@ internal class ClientsImpl( } override fun searchCompletable(data: SearchRequest): CompletableFuture> = - coroutineScope - .async { - search(data) - }.asCompletableFuture() + coroutineScope.async { + search(data) + }.asCompletableFuture() override suspend fun create(data: CreateRequest): StytchResult = withContext(Dispatchers.IO) { @@ -261,8 +257,7 @@ internal class ClientsImpl( } override fun createCompletable(data: CreateRequest): CompletableFuture> = - coroutineScope - .async { - create(data) - }.asCompletableFuture() + coroutineScope.async { + create(data) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/consumer/api/connectedappsclientssecrets/ConnectedAppsClientsSecrets.kt b/stytch/src/main/kotlin/com/stytch/java/consumer/api/connectedappsclientssecrets/ConnectedAppsClientsSecrets.kt index a8f4e3aa..a40400b1 100644 --- a/stytch/src/main/kotlin/com/stytch/java/consumer/api/connectedappsclientssecrets/ConnectedAppsClientsSecrets.kt +++ b/stytch/src/main/kotlin/com/stytch/java/consumer/api/connectedappsclientssecrets/ConnectedAppsClientsSecrets.kt @@ -137,10 +137,9 @@ internal class SecretsImpl( } override fun rotateStartCompletable(data: RotateStartRequest): CompletableFuture> = - coroutineScope - .async { - rotateStart(data) - }.asCompletableFuture() + coroutineScope.async { + rotateStart(data) + }.asCompletableFuture() override suspend fun rotateCancel(data: RotateCancelRequest): StytchResult = withContext(Dispatchers.IO) { @@ -160,10 +159,9 @@ internal class SecretsImpl( } override fun rotateCancelCompletable(data: RotateCancelRequest): CompletableFuture> = - coroutineScope - .async { - rotateCancel(data) - }.asCompletableFuture() + coroutineScope.async { + rotateCancel(data) + }.asCompletableFuture() override suspend fun rotate(data: RotateRequest): StytchResult = withContext(Dispatchers.IO) { @@ -183,8 +181,7 @@ internal class SecretsImpl( } override fun rotateCompletable(data: RotateRequest): CompletableFuture> = - coroutineScope - .async { - rotate(data) - }.asCompletableFuture() + coroutineScope.async { + rotate(data) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/consumer/api/cryptowallets/CryptoWallets.kt b/stytch/src/main/kotlin/com/stytch/java/consumer/api/cryptowallets/CryptoWallets.kt index 640043dc..cbe81ebf 100644 --- a/stytch/src/main/kotlin/com/stytch/java/consumer/api/cryptowallets/CryptoWallets.kt +++ b/stytch/src/main/kotlin/com/stytch/java/consumer/api/cryptowallets/CryptoWallets.kt @@ -108,10 +108,9 @@ internal class CryptoWalletsImpl( } override fun authenticateStartCompletable(data: AuthenticateStartRequest): CompletableFuture> = - coroutineScope - .async { - authenticateStart(data) - }.asCompletableFuture() + coroutineScope.async { + authenticateStart(data) + }.asCompletableFuture() override suspend fun authenticate(data: AuthenticateRequest): StytchResult = withContext(Dispatchers.IO) { @@ -131,8 +130,7 @@ internal class CryptoWalletsImpl( } override fun authenticateCompletable(data: AuthenticateRequest): CompletableFuture> = - coroutineScope - .async { - authenticate(data) - }.asCompletableFuture() + coroutineScope.async { + authenticate(data) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/consumer/api/debug/Debug.kt b/stytch/src/main/kotlin/com/stytch/java/consumer/api/debug/Debug.kt index 64db01b8..2a32ce55 100644 --- a/stytch/src/main/kotlin/com/stytch/java/consumer/api/debug/Debug.kt +++ b/stytch/src/main/kotlin/com/stytch/java/consumer/api/debug/Debug.kt @@ -60,8 +60,7 @@ internal class DebugImpl( } override fun whoamiCompletable(data: WhoamiRequest): CompletableFuture> = - coroutineScope - .async { - whoami(data) - }.asCompletableFuture() + coroutineScope.async { + whoami(data) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/consumer/api/fraudemail/FraudEmail.kt b/stytch/src/main/kotlin/com/stytch/java/consumer/api/fraudemail/FraudEmail.kt index 077408ef..c3f03415 100644 --- a/stytch/src/main/kotlin/com/stytch/java/consumer/api/fraudemail/FraudEmail.kt +++ b/stytch/src/main/kotlin/com/stytch/java/consumer/api/fraudemail/FraudEmail.kt @@ -82,8 +82,7 @@ internal class EmailImpl( } override fun riskCompletable(data: RiskRequest): CompletableFuture> = - coroutineScope - .async { - risk(data) - }.asCompletableFuture() + coroutineScope.async { + risk(data) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/consumer/api/fraudfingerprint/FraudFingerprint.kt b/stytch/src/main/kotlin/com/stytch/java/consumer/api/fraudfingerprint/FraudFingerprint.kt index 6cb89040..b4b9b024 100644 --- a/stytch/src/main/kotlin/com/stytch/java/consumer/api/fraudfingerprint/FraudFingerprint.kt +++ b/stytch/src/main/kotlin/com/stytch/java/consumer/api/fraudfingerprint/FraudFingerprint.kt @@ -115,8 +115,7 @@ internal class FingerprintImpl( } override fun lookupCompletable(data: LookupRequest): CompletableFuture> = - coroutineScope - .async { - lookup(data) - }.asCompletableFuture() + coroutineScope.async { + lookup(data) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/consumer/api/fraudrules/FraudRules.kt b/stytch/src/main/kotlin/com/stytch/java/consumer/api/fraudrules/FraudRules.kt index 936aeae9..b5486a3c 100644 --- a/stytch/src/main/kotlin/com/stytch/java/consumer/api/fraudrules/FraudRules.kt +++ b/stytch/src/main/kotlin/com/stytch/java/consumer/api/fraudrules/FraudRules.kt @@ -141,10 +141,9 @@ internal class RulesImpl( } override fun setCompletable(data: SetRequest): CompletableFuture> = - coroutineScope - .async { - set(data) - }.asCompletableFuture() + coroutineScope.async { + set(data) + }.asCompletableFuture() override suspend fun list(data: ListRequest): StytchResult = withContext(Dispatchers.IO) { @@ -164,8 +163,7 @@ internal class RulesImpl( } override fun listCompletable(data: ListRequest): CompletableFuture> = - coroutineScope - .async { - list(data) - }.asCompletableFuture() + coroutineScope.async { + list(data) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/consumer/api/fraudverdictreasons/FraudVerdictReasons.kt b/stytch/src/main/kotlin/com/stytch/java/consumer/api/fraudverdictreasons/FraudVerdictReasons.kt index e18a3a71..20dc495f 100644 --- a/stytch/src/main/kotlin/com/stytch/java/consumer/api/fraudverdictreasons/FraudVerdictReasons.kt +++ b/stytch/src/main/kotlin/com/stytch/java/consumer/api/fraudverdictreasons/FraudVerdictReasons.kt @@ -108,10 +108,9 @@ internal class VerdictReasonsImpl( } override fun overrideCompletable(data: OverrideRequest): CompletableFuture> = - coroutineScope - .async { - override(data) - }.asCompletableFuture() + coroutineScope.async { + override(data) + }.asCompletableFuture() override suspend fun list(data: ListRequest): StytchResult = withContext(Dispatchers.IO) { @@ -131,8 +130,7 @@ internal class VerdictReasonsImpl( } override fun listCompletable(data: ListRequest): CompletableFuture> = - coroutineScope - .async { - list(data) - }.asCompletableFuture() + coroutineScope.async { + list(data) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/consumer/api/idpoauth/IDPOAuth.kt b/stytch/src/main/kotlin/com/stytch/java/consumer/api/idpoauth/IDPOAuth.kt index c6aee897..b293ac71 100644 --- a/stytch/src/main/kotlin/com/stytch/java/consumer/api/idpoauth/IDPOAuth.kt +++ b/stytch/src/main/kotlin/com/stytch/java/consumer/api/idpoauth/IDPOAuth.kt @@ -213,10 +213,9 @@ internal class OAuthImpl( } override fun authorizeStartCompletable(data: AuthorizeStartRequest): CompletableFuture> = - coroutineScope - .async { - authorizeStart(data) - }.asCompletableFuture() + coroutineScope.async { + authorizeStart(data) + }.asCompletableFuture() override suspend fun authorize(data: AuthorizeRequest): StytchResult = withContext(Dispatchers.IO) { @@ -236,8 +235,7 @@ internal class OAuthImpl( } override fun authorizeCompletable(data: AuthorizeRequest): CompletableFuture> = - coroutineScope - .async { - authorize(data) - }.asCompletableFuture() + coroutineScope.async { + authorize(data) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/consumer/api/impersonation/Impersonation.kt b/stytch/src/main/kotlin/com/stytch/java/consumer/api/impersonation/Impersonation.kt index d10e1619..7ea42f58 100644 --- a/stytch/src/main/kotlin/com/stytch/java/consumer/api/impersonation/Impersonation.kt +++ b/stytch/src/main/kotlin/com/stytch/java/consumer/api/impersonation/Impersonation.kt @@ -82,8 +82,7 @@ internal class ImpersonationImpl( } override fun authenticateCompletable(data: AuthenticateRequest): CompletableFuture> = - coroutineScope - .async { - authenticate(data) - }.asCompletableFuture() + coroutineScope.async { + authenticate(data) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/consumer/api/m2mclients/M2MClients.kt b/stytch/src/main/kotlin/com/stytch/java/consumer/api/m2mclients/M2MClients.kt index 36ee778d..84fbdf5c 100644 --- a/stytch/src/main/kotlin/com/stytch/java/consumer/api/m2mclients/M2MClients.kt +++ b/stytch/src/main/kotlin/com/stytch/java/consumer/api/m2mclients/M2MClients.kt @@ -221,10 +221,9 @@ internal class ClientsImpl( } override fun getCompletable(data: GetRequest): CompletableFuture> = - coroutineScope - .async { - get(data) - }.asCompletableFuture() + coroutineScope.async { + get(data) + }.asCompletableFuture() override suspend fun search(data: SearchRequest): StytchResult = withContext(Dispatchers.IO) { @@ -244,10 +243,9 @@ internal class ClientsImpl( } override fun searchCompletable(data: SearchRequest): CompletableFuture> = - coroutineScope - .async { - search(data) - }.asCompletableFuture() + coroutineScope.async { + search(data) + }.asCompletableFuture() override suspend fun update(data: UpdateRequest): StytchResult = withContext(Dispatchers.IO) { @@ -267,10 +265,9 @@ internal class ClientsImpl( } override fun updateCompletable(data: UpdateRequest): CompletableFuture> = - coroutineScope - .async { - update(data) - }.asCompletableFuture() + coroutineScope.async { + update(data) + }.asCompletableFuture() override suspend fun delete(data: DeleteRequest): StytchResult = withContext(Dispatchers.IO) { @@ -289,10 +286,9 @@ internal class ClientsImpl( } override fun deleteCompletable(data: DeleteRequest): CompletableFuture> = - coroutineScope - .async { - delete(data) - }.asCompletableFuture() + coroutineScope.async { + delete(data) + }.asCompletableFuture() override suspend fun create(data: CreateRequest): StytchResult = withContext(Dispatchers.IO) { @@ -312,8 +308,7 @@ internal class ClientsImpl( } override fun createCompletable(data: CreateRequest): CompletableFuture> = - coroutineScope - .async { - create(data) - }.asCompletableFuture() + coroutineScope.async { + create(data) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/consumer/api/m2mclientssecrets/M2MClientsSecrets.kt b/stytch/src/main/kotlin/com/stytch/java/consumer/api/m2mclientssecrets/M2MClientsSecrets.kt index 1c866b93..a00de29f 100644 --- a/stytch/src/main/kotlin/com/stytch/java/consumer/api/m2mclientssecrets/M2MClientsSecrets.kt +++ b/stytch/src/main/kotlin/com/stytch/java/consumer/api/m2mclientssecrets/M2MClientsSecrets.kt @@ -152,10 +152,9 @@ internal class SecretsImpl( } override fun rotateStartCompletable(data: RotateStartRequest): CompletableFuture> = - coroutineScope - .async { - rotateStart(data) - }.asCompletableFuture() + coroutineScope.async { + rotateStart(data) + }.asCompletableFuture() override suspend fun rotateCancel(data: RotateCancelRequest): StytchResult = withContext(Dispatchers.IO) { @@ -175,10 +174,9 @@ internal class SecretsImpl( } override fun rotateCancelCompletable(data: RotateCancelRequest): CompletableFuture> = - coroutineScope - .async { - rotateCancel(data) - }.asCompletableFuture() + coroutineScope.async { + rotateCancel(data) + }.asCompletableFuture() override suspend fun rotate(data: RotateRequest): StytchResult = withContext(Dispatchers.IO) { @@ -198,8 +196,7 @@ internal class SecretsImpl( } override fun rotateCompletable(data: RotateRequest): CompletableFuture> = - coroutineScope - .async { - rotate(data) - }.asCompletableFuture() + coroutineScope.async { + rotate(data) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/consumer/api/magiclinks/MagicLinks.kt b/stytch/src/main/kotlin/com/stytch/java/consumer/api/magiclinks/MagicLinks.kt index f4fae76c..bb001d01 100644 --- a/stytch/src/main/kotlin/com/stytch/java/consumer/api/magiclinks/MagicLinks.kt +++ b/stytch/src/main/kotlin/com/stytch/java/consumer/api/magiclinks/MagicLinks.kt @@ -120,10 +120,9 @@ internal class MagicLinksImpl( } override fun authenticateCompletable(data: AuthenticateRequest): CompletableFuture> = - coroutineScope - .async { - authenticate(data) - }.asCompletableFuture() + coroutineScope.async { + authenticate(data) + }.asCompletableFuture() override suspend fun create(data: CreateRequest): StytchResult = withContext(Dispatchers.IO) { @@ -143,8 +142,7 @@ internal class MagicLinksImpl( } override fun createCompletable(data: CreateRequest): CompletableFuture> = - coroutineScope - .async { - create(data) - }.asCompletableFuture() + coroutineScope.async { + create(data) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/consumer/api/magiclinksemail/MagicLinksEmail.kt b/stytch/src/main/kotlin/com/stytch/java/consumer/api/magiclinksemail/MagicLinksEmail.kt index 851a588d..c72ebefd 100644 --- a/stytch/src/main/kotlin/com/stytch/java/consumer/api/magiclinksemail/MagicLinksEmail.kt +++ b/stytch/src/main/kotlin/com/stytch/java/consumer/api/magiclinksemail/MagicLinksEmail.kt @@ -214,10 +214,9 @@ internal class EmailImpl( } override fun sendCompletable(data: SendRequest): CompletableFuture> = - coroutineScope - .async { - send(data) - }.asCompletableFuture() + coroutineScope.async { + send(data) + }.asCompletableFuture() override suspend fun loginOrCreate(data: LoginOrCreateRequest): StytchResult = withContext(Dispatchers.IO) { @@ -237,10 +236,9 @@ internal class EmailImpl( } override fun loginOrCreateCompletable(data: LoginOrCreateRequest): CompletableFuture> = - coroutineScope - .async { - loginOrCreate(data) - }.asCompletableFuture() + coroutineScope.async { + loginOrCreate(data) + }.asCompletableFuture() override suspend fun invite(data: InviteRequest): StytchResult = withContext(Dispatchers.IO) { @@ -260,10 +258,9 @@ internal class EmailImpl( } override fun inviteCompletable(data: InviteRequest): CompletableFuture> = - coroutineScope - .async { - invite(data) - }.asCompletableFuture() + coroutineScope.async { + invite(data) + }.asCompletableFuture() override suspend fun revokeInvite(data: RevokeInviteRequest): StytchResult = withContext(Dispatchers.IO) { @@ -283,8 +280,7 @@ internal class EmailImpl( } override fun revokeInviteCompletable(data: RevokeInviteRequest): CompletableFuture> = - coroutineScope - .async { - revokeInvite(data) - }.asCompletableFuture() + coroutineScope.async { + revokeInvite(data) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/consumer/api/oauth/OAuth.kt b/stytch/src/main/kotlin/com/stytch/java/consumer/api/oauth/OAuth.kt index 5a4d0c9e..92bd6ab4 100644 --- a/stytch/src/main/kotlin/com/stytch/java/consumer/api/oauth/OAuth.kt +++ b/stytch/src/main/kotlin/com/stytch/java/consumer/api/oauth/OAuth.kt @@ -126,10 +126,9 @@ internal class OAuthImpl( } override fun attachCompletable(data: AttachRequest): CompletableFuture> = - coroutineScope - .async { - attach(data) - }.asCompletableFuture() + coroutineScope.async { + attach(data) + }.asCompletableFuture() override suspend fun authenticate(data: AuthenticateRequest): StytchResult = withContext(Dispatchers.IO) { @@ -149,8 +148,7 @@ internal class OAuthImpl( } override fun authenticateCompletable(data: AuthenticateRequest): CompletableFuture> = - coroutineScope - .async { - authenticate(data) - }.asCompletableFuture() + coroutineScope.async { + authenticate(data) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/consumer/api/otp/OTP.kt b/stytch/src/main/kotlin/com/stytch/java/consumer/api/otp/OTP.kt index 5143e70f..e57f564e 100644 --- a/stytch/src/main/kotlin/com/stytch/java/consumer/api/otp/OTP.kt +++ b/stytch/src/main/kotlin/com/stytch/java/consumer/api/otp/OTP.kt @@ -89,8 +89,7 @@ internal class OTPsImpl( } override fun authenticateCompletable(data: AuthenticateRequest): CompletableFuture> = - coroutineScope - .async { - authenticate(data) - }.asCompletableFuture() + coroutineScope.async { + authenticate(data) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/consumer/api/otpemail/OTPEmail.kt b/stytch/src/main/kotlin/com/stytch/java/consumer/api/otpemail/OTPEmail.kt index 822fbee0..a334c11c 100644 --- a/stytch/src/main/kotlin/com/stytch/java/consumer/api/otpemail/OTPEmail.kt +++ b/stytch/src/main/kotlin/com/stytch/java/consumer/api/otpemail/OTPEmail.kt @@ -138,10 +138,9 @@ internal class EmailImpl( } override fun sendCompletable(data: SendRequest): CompletableFuture> = - coroutineScope - .async { - send(data) - }.asCompletableFuture() + coroutineScope.async { + send(data) + }.asCompletableFuture() override suspend fun loginOrCreate(data: LoginOrCreateRequest): StytchResult = withContext(Dispatchers.IO) { @@ -161,8 +160,7 @@ internal class EmailImpl( } override fun loginOrCreateCompletable(data: LoginOrCreateRequest): CompletableFuture> = - coroutineScope - .async { - loginOrCreate(data) - }.asCompletableFuture() + coroutineScope.async { + loginOrCreate(data) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/consumer/api/otpsms/OTPSms.kt b/stytch/src/main/kotlin/com/stytch/java/consumer/api/otpsms/OTPSms.kt index 0260dfdf..586fd8a3 100644 --- a/stytch/src/main/kotlin/com/stytch/java/consumer/api/otpsms/OTPSms.kt +++ b/stytch/src/main/kotlin/com/stytch/java/consumer/api/otpsms/OTPSms.kt @@ -234,10 +234,9 @@ internal class SmsImpl( } override fun sendCompletable(data: SendRequest): CompletableFuture> = - coroutineScope - .async { - send(data) - }.asCompletableFuture() + coroutineScope.async { + send(data) + }.asCompletableFuture() override suspend fun loginOrCreate(data: LoginOrCreateRequest): StytchResult = withContext(Dispatchers.IO) { @@ -257,8 +256,7 @@ internal class SmsImpl( } override fun loginOrCreateCompletable(data: LoginOrCreateRequest): CompletableFuture> = - coroutineScope - .async { - loginOrCreate(data) - }.asCompletableFuture() + coroutineScope.async { + loginOrCreate(data) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/consumer/api/otpwhatsapp/OTPWhatsApp.kt b/stytch/src/main/kotlin/com/stytch/java/consumer/api/otpwhatsapp/OTPWhatsApp.kt index ff60c334..ecddd5c2 100644 --- a/stytch/src/main/kotlin/com/stytch/java/consumer/api/otpwhatsapp/OTPWhatsApp.kt +++ b/stytch/src/main/kotlin/com/stytch/java/consumer/api/otpwhatsapp/OTPWhatsApp.kt @@ -180,10 +180,9 @@ internal class WhatsAppImpl( } override fun sendCompletable(data: SendRequest): CompletableFuture> = - coroutineScope - .async { - send(data) - }.asCompletableFuture() + coroutineScope.async { + send(data) + }.asCompletableFuture() override suspend fun loginOrCreate(data: LoginOrCreateRequest): StytchResult = withContext(Dispatchers.IO) { @@ -203,8 +202,7 @@ internal class WhatsAppImpl( } override fun loginOrCreateCompletable(data: LoginOrCreateRequest): CompletableFuture> = - coroutineScope - .async { - loginOrCreate(data) - }.asCompletableFuture() + coroutineScope.async { + loginOrCreate(data) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/consumer/api/passwords/Passwords.kt b/stytch/src/main/kotlin/com/stytch/java/consumer/api/passwords/Passwords.kt index 207ca181..9d4220cb 100644 --- a/stytch/src/main/kotlin/com/stytch/java/consumer/api/passwords/Passwords.kt +++ b/stytch/src/main/kotlin/com/stytch/java/consumer/api/passwords/Passwords.kt @@ -293,10 +293,9 @@ internal class PasswordsImpl( } override fun createCompletable(data: CreateRequest): CompletableFuture> = - coroutineScope - .async { - create(data) - }.asCompletableFuture() + coroutineScope.async { + create(data) + }.asCompletableFuture() override suspend fun authenticate(data: AuthenticateRequest): StytchResult = withContext(Dispatchers.IO) { @@ -316,10 +315,9 @@ internal class PasswordsImpl( } override fun authenticateCompletable(data: AuthenticateRequest): CompletableFuture> = - coroutineScope - .async { - authenticate(data) - }.asCompletableFuture() + coroutineScope.async { + authenticate(data) + }.asCompletableFuture() override suspend fun strengthCheck(data: StrengthCheckRequest): StytchResult = withContext(Dispatchers.IO) { @@ -339,10 +337,9 @@ internal class PasswordsImpl( } override fun strengthCheckCompletable(data: StrengthCheckRequest): CompletableFuture> = - coroutineScope - .async { - strengthCheck(data) - }.asCompletableFuture() + coroutineScope.async { + strengthCheck(data) + }.asCompletableFuture() override suspend fun migrate(data: MigrateRequest): StytchResult = withContext(Dispatchers.IO) { @@ -362,8 +359,7 @@ internal class PasswordsImpl( } override fun migrateCompletable(data: MigrateRequest): CompletableFuture> = - coroutineScope - .async { - migrate(data) - }.asCompletableFuture() + coroutineScope.async { + migrate(data) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/consumer/api/passwordsemail/PasswordsEmail.kt b/stytch/src/main/kotlin/com/stytch/java/consumer/api/passwordsemail/PasswordsEmail.kt index 3c0f8fc1..5dca5fb1 100644 --- a/stytch/src/main/kotlin/com/stytch/java/consumer/api/passwordsemail/PasswordsEmail.kt +++ b/stytch/src/main/kotlin/com/stytch/java/consumer/api/passwordsemail/PasswordsEmail.kt @@ -111,10 +111,9 @@ internal class EmailImpl( } override fun resetStartCompletable(data: ResetStartRequest): CompletableFuture> = - coroutineScope - .async { - resetStart(data) - }.asCompletableFuture() + coroutineScope.async { + resetStart(data) + }.asCompletableFuture() override suspend fun reset(data: ResetRequest): StytchResult = withContext(Dispatchers.IO) { @@ -134,8 +133,7 @@ internal class EmailImpl( } override fun resetCompletable(data: ResetRequest): CompletableFuture> = - coroutineScope - .async { - reset(data) - }.asCompletableFuture() + coroutineScope.async { + reset(data) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/consumer/api/passwordsexistingpassword/PasswordsExistingPassword.kt b/stytch/src/main/kotlin/com/stytch/java/consumer/api/passwordsexistingpassword/PasswordsExistingPassword.kt index 252e2b81..d9b9d1af 100644 --- a/stytch/src/main/kotlin/com/stytch/java/consumer/api/passwordsexistingpassword/PasswordsExistingPassword.kt +++ b/stytch/src/main/kotlin/com/stytch/java/consumer/api/passwordsexistingpassword/PasswordsExistingPassword.kt @@ -70,8 +70,7 @@ internal class ExistingPasswordImpl( } override fun resetCompletable(data: ResetRequest): CompletableFuture> = - coroutineScope - .async { - reset(data) - }.asCompletableFuture() + coroutineScope.async { + reset(data) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/consumer/api/passwordssession/PasswordsSession.kt b/stytch/src/main/kotlin/com/stytch/java/consumer/api/passwordssession/PasswordsSession.kt index e11cf092..f9c16969 100644 --- a/stytch/src/main/kotlin/com/stytch/java/consumer/api/passwordssession/PasswordsSession.kt +++ b/stytch/src/main/kotlin/com/stytch/java/consumer/api/passwordssession/PasswordsSession.kt @@ -79,8 +79,7 @@ internal class SessionsImpl( } override fun resetCompletable(data: ResetRequest): CompletableFuture> = - coroutineScope - .async { - reset(data) - }.asCompletableFuture() + coroutineScope.async { + reset(data) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/consumer/api/project/Project.kt b/stytch/src/main/kotlin/com/stytch/java/consumer/api/project/Project.kt index 6df7fa3a..9a7d54d6 100644 --- a/stytch/src/main/kotlin/com/stytch/java/consumer/api/project/Project.kt +++ b/stytch/src/main/kotlin/com/stytch/java/consumer/api/project/Project.kt @@ -60,8 +60,7 @@ internal class ProjectImpl( } override fun metricsCompletable(data: MetricsRequest): CompletableFuture> = - coroutineScope - .async { - metrics(data) - }.asCompletableFuture() + coroutineScope.async { + metrics(data) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/consumer/api/rbac/RBAC.kt b/stytch/src/main/kotlin/com/stytch/java/consumer/api/rbac/RBAC.kt index 83800dde..d4a99f1a 100644 --- a/stytch/src/main/kotlin/com/stytch/java/consumer/api/rbac/RBAC.kt +++ b/stytch/src/main/kotlin/com/stytch/java/consumer/api/rbac/RBAC.kt @@ -111,8 +111,7 @@ internal class RBACImpl( } override fun policyCompletable(data: PolicyRequest): CompletableFuture> = - coroutineScope - .async { - policy(data) - }.asCompletableFuture() + coroutineScope.async { + policy(data) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/consumer/api/sessions/Sessions.kt b/stytch/src/main/kotlin/com/stytch/java/consumer/api/sessions/Sessions.kt index d36b611b..a3b9734d 100644 --- a/stytch/src/main/kotlin/com/stytch/java/consumer/api/sessions/Sessions.kt +++ b/stytch/src/main/kotlin/com/stytch/java/consumer/api/sessions/Sessions.kt @@ -167,9 +167,6 @@ public interface Sessions { * Use this endpoint to exchange a Connected Apps Access Token back into a Stytch Session for the underlying User. * This session can be used with the Stytch SDKs and APIs. * - * The Session returned will be the same Session that was active in your application (the authorizing party) during the - * initial authorization flow. - * * The Access Token must contain the `full_access` scope (only available to First Party clients) and must not be more than * 5 minutes old. Access Tokens may only be exchanged a single time. */ @@ -179,9 +176,6 @@ public interface Sessions { * Use this endpoint to exchange a Connected Apps Access Token back into a Stytch Session for the underlying User. * This session can be used with the Stytch SDKs and APIs. * - * The Session returned will be the same Session that was active in your application (the authorizing party) during the - * initial authorization flow. - * * The Access Token must contain the `full_access` scope (only available to First Party clients) and must not be more than * 5 minutes old. Access Tokens may only be exchanged a single time. */ @@ -194,9 +188,6 @@ public interface Sessions { * Use this endpoint to exchange a Connected Apps Access Token back into a Stytch Session for the underlying User. * This session can be used with the Stytch SDKs and APIs. * - * The Session returned will be the same Session that was active in your application (the authorizing party) during the - * initial authorization flow. - * * The Access Token must contain the `full_access` scope (only available to First Party clients) and must not be more than * 5 minutes old. Access Tokens may only be exchanged a single time. */ @@ -430,10 +421,9 @@ internal class SessionsImpl( } override fun getCompletable(data: GetRequest): CompletableFuture> = - coroutineScope - .async { - get(data) - }.asCompletableFuture() + coroutineScope.async { + get(data) + }.asCompletableFuture() override suspend fun authenticate(data: AuthenticateRequest): StytchResult = withContext(Dispatchers.IO) { @@ -453,10 +443,9 @@ internal class SessionsImpl( } override fun authenticateCompletable(data: AuthenticateRequest): CompletableFuture> = - coroutineScope - .async { - authenticate(data) - }.asCompletableFuture() + coroutineScope.async { + authenticate(data) + }.asCompletableFuture() override suspend fun revoke(data: RevokeRequest): StytchResult = withContext(Dispatchers.IO) { @@ -476,10 +465,9 @@ internal class SessionsImpl( } override fun revokeCompletable(data: RevokeRequest): CompletableFuture> = - coroutineScope - .async { - revoke(data) - }.asCompletableFuture() + coroutineScope.async { + revoke(data) + }.asCompletableFuture() override suspend fun migrate(data: MigrateRequest): StytchResult = withContext(Dispatchers.IO) { @@ -499,10 +487,9 @@ internal class SessionsImpl( } override fun migrateCompletable(data: MigrateRequest): CompletableFuture> = - coroutineScope - .async { - migrate(data) - }.asCompletableFuture() + coroutineScope.async { + migrate(data) + }.asCompletableFuture() override suspend fun exchangeAccessToken(data: ExchangeAccessTokenRequest): StytchResult = withContext(Dispatchers.IO) { @@ -524,10 +511,9 @@ internal class SessionsImpl( override fun exchangeAccessTokenCompletable( data: ExchangeAccessTokenRequest, ): CompletableFuture> = - coroutineScope - .async { - exchangeAccessToken(data) - }.asCompletableFuture() + coroutineScope.async { + exchangeAccessToken(data) + }.asCompletableFuture() override suspend fun getJWKS(data: GetJWKSRequest): StytchResult = withContext(Dispatchers.IO) { @@ -550,10 +536,9 @@ internal class SessionsImpl( } override fun getJWKSCompletable(data: GetJWKSRequest): CompletableFuture> = - coroutineScope - .async { - getJWKS(data) - }.asCompletableFuture() + coroutineScope.async { + getJWKS(data) + }.asCompletableFuture() override suspend fun attest(data: AttestRequest): StytchResult = withContext(Dispatchers.IO) { @@ -573,10 +558,9 @@ internal class SessionsImpl( } override fun attestCompletable(data: AttestRequest): CompletableFuture> = - coroutineScope - .async { - attest(data) - }.asCompletableFuture() + coroutineScope.async { + attest(data) + }.asCompletableFuture() // MANUAL(authenticateJWT_impl)(SERVICE_METHOD) override suspend fun authenticateJwt( diff --git a/stytch/src/main/kotlin/com/stytch/java/consumer/api/totps/TOTPs.kt b/stytch/src/main/kotlin/com/stytch/java/consumer/api/totps/TOTPs.kt index 79deec54..ec1db76f 100644 --- a/stytch/src/main/kotlin/com/stytch/java/consumer/api/totps/TOTPs.kt +++ b/stytch/src/main/kotlin/com/stytch/java/consumer/api/totps/TOTPs.kt @@ -127,10 +127,9 @@ internal class TOTPsImpl( } override fun createCompletable(data: CreateRequest): CompletableFuture> = - coroutineScope - .async { - create(data) - }.asCompletableFuture() + coroutineScope.async { + create(data) + }.asCompletableFuture() override suspend fun authenticate(data: AuthenticateRequest): StytchResult = withContext(Dispatchers.IO) { @@ -150,10 +149,9 @@ internal class TOTPsImpl( } override fun authenticateCompletable(data: AuthenticateRequest): CompletableFuture> = - coroutineScope - .async { - authenticate(data) - }.asCompletableFuture() + coroutineScope.async { + authenticate(data) + }.asCompletableFuture() override suspend fun recoveryCodes(data: RecoveryCodesRequest): StytchResult = withContext(Dispatchers.IO) { @@ -173,10 +171,9 @@ internal class TOTPsImpl( } override fun recoveryCodesCompletable(data: RecoveryCodesRequest): CompletableFuture> = - coroutineScope - .async { - recoveryCodes(data) - }.asCompletableFuture() + coroutineScope.async { + recoveryCodes(data) + }.asCompletableFuture() override suspend fun recover(data: RecoverRequest): StytchResult = withContext(Dispatchers.IO) { @@ -196,8 +193,7 @@ internal class TOTPsImpl( } override fun recoverCompletable(data: RecoverRequest): CompletableFuture> = - coroutineScope - .async { - recover(data) - }.asCompletableFuture() + coroutineScope.async { + recover(data) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/consumer/api/users/Users.kt b/stytch/src/main/kotlin/com/stytch/java/consumer/api/users/Users.kt index 4baaa038..1d8bf60c 100644 --- a/stytch/src/main/kotlin/com/stytch/java/consumer/api/users/Users.kt +++ b/stytch/src/main/kotlin/com/stytch/java/consumer/api/users/Users.kt @@ -497,10 +497,9 @@ internal class UsersImpl( } override fun createCompletable(data: CreateRequest): CompletableFuture> = - coroutineScope - .async { - create(data) - }.asCompletableFuture() + coroutineScope.async { + create(data) + }.asCompletableFuture() override suspend fun get(data: GetRequest): StytchResult = withContext(Dispatchers.IO) { @@ -523,10 +522,9 @@ internal class UsersImpl( } override fun getCompletable(data: GetRequest): CompletableFuture> = - coroutineScope - .async { - get(data) - }.asCompletableFuture() + coroutineScope.async { + get(data) + }.asCompletableFuture() override suspend fun search(data: SearchRequest): StytchResult = withContext(Dispatchers.IO) { @@ -546,10 +544,9 @@ internal class UsersImpl( } override fun searchCompletable(data: SearchRequest): CompletableFuture> = - coroutineScope - .async { - search(data) - }.asCompletableFuture() + coroutineScope.async { + search(data) + }.asCompletableFuture() override suspend fun update(data: UpdateRequest): StytchResult = withContext(Dispatchers.IO) { @@ -569,10 +566,9 @@ internal class UsersImpl( } override fun updateCompletable(data: UpdateRequest): CompletableFuture> = - coroutineScope - .async { - update(data) - }.asCompletableFuture() + coroutineScope.async { + update(data) + }.asCompletableFuture() override suspend fun exchangePrimaryFactor(data: ExchangePrimaryFactorRequest): StytchResult = withContext(Dispatchers.IO) { @@ -594,10 +590,9 @@ internal class UsersImpl( override fun exchangePrimaryFactorCompletable( data: ExchangePrimaryFactorRequest, ): CompletableFuture> = - coroutineScope - .async { - exchangePrimaryFactor(data) - }.asCompletableFuture() + coroutineScope.async { + exchangePrimaryFactor(data) + }.asCompletableFuture() override suspend fun delete(data: DeleteRequest): StytchResult = withContext(Dispatchers.IO) { @@ -616,10 +611,9 @@ internal class UsersImpl( } override fun deleteCompletable(data: DeleteRequest): CompletableFuture> = - coroutineScope - .async { - delete(data) - }.asCompletableFuture() + coroutineScope.async { + delete(data) + }.asCompletableFuture() override suspend fun deleteEmail(data: DeleteEmailRequest): StytchResult = withContext(Dispatchers.IO) { @@ -638,10 +632,9 @@ internal class UsersImpl( } override fun deleteEmailCompletable(data: DeleteEmailRequest): CompletableFuture> = - coroutineScope - .async { - deleteEmail(data) - }.asCompletableFuture() + coroutineScope.async { + deleteEmail(data) + }.asCompletableFuture() override suspend fun deletePhoneNumber(data: DeletePhoneNumberRequest): StytchResult = withContext(Dispatchers.IO) { @@ -660,10 +653,9 @@ internal class UsersImpl( } override fun deletePhoneNumberCompletable(data: DeletePhoneNumberRequest): CompletableFuture> = - coroutineScope - .async { - deletePhoneNumber(data) - }.asCompletableFuture() + coroutineScope.async { + deletePhoneNumber(data) + }.asCompletableFuture() override suspend fun deleteWebAuthnRegistration( data: DeleteWebAuthnRegistrationRequest, @@ -686,10 +678,9 @@ internal class UsersImpl( override fun deleteWebAuthnRegistrationCompletable( data: DeleteWebAuthnRegistrationRequest, ): CompletableFuture> = - coroutineScope - .async { - deleteWebAuthnRegistration(data) - }.asCompletableFuture() + coroutineScope.async { + deleteWebAuthnRegistration(data) + }.asCompletableFuture() override suspend fun deleteBiometricRegistration( data: DeleteBiometricRegistrationRequest, @@ -712,10 +703,9 @@ internal class UsersImpl( override fun deleteBiometricRegistrationCompletable( data: DeleteBiometricRegistrationRequest, ): CompletableFuture> = - coroutineScope - .async { - deleteBiometricRegistration(data) - }.asCompletableFuture() + coroutineScope.async { + deleteBiometricRegistration(data) + }.asCompletableFuture() override suspend fun deleteTOTP(data: DeleteTOTPRequest): StytchResult = withContext(Dispatchers.IO) { @@ -734,10 +724,9 @@ internal class UsersImpl( } override fun deleteTOTPCompletable(data: DeleteTOTPRequest): CompletableFuture> = - coroutineScope - .async { - deleteTOTP(data) - }.asCompletableFuture() + coroutineScope.async { + deleteTOTP(data) + }.asCompletableFuture() override suspend fun deleteCryptoWallet(data: DeleteCryptoWalletRequest): StytchResult = withContext(Dispatchers.IO) { @@ -758,10 +747,9 @@ internal class UsersImpl( override fun deleteCryptoWalletCompletable( data: DeleteCryptoWalletRequest, ): CompletableFuture> = - coroutineScope - .async { - deleteCryptoWallet(data) - }.asCompletableFuture() + coroutineScope.async { + deleteCryptoWallet(data) + }.asCompletableFuture() override suspend fun deletePassword(data: DeletePasswordRequest): StytchResult = withContext(Dispatchers.IO) { @@ -780,10 +768,9 @@ internal class UsersImpl( } override fun deletePasswordCompletable(data: DeletePasswordRequest): CompletableFuture> = - coroutineScope - .async { - deletePassword(data) - }.asCompletableFuture() + coroutineScope.async { + deletePassword(data) + }.asCompletableFuture() override suspend fun deleteOAuthRegistration(data: DeleteOAuthRegistrationRequest): StytchResult = withContext(Dispatchers.IO) { @@ -804,10 +791,9 @@ internal class UsersImpl( override fun deleteOAuthRegistrationCompletable( data: DeleteOAuthRegistrationRequest, ): CompletableFuture> = - coroutineScope - .async { - deleteOAuthRegistration(data) - }.asCompletableFuture() + coroutineScope.async { + deleteOAuthRegistration(data) + }.asCompletableFuture() override suspend fun deleteExternalId(data: DeleteExternalIdRequest): StytchResult = withContext(Dispatchers.IO) { @@ -826,10 +812,9 @@ internal class UsersImpl( } override fun deleteExternalIdCompletable(data: DeleteExternalIdRequest): CompletableFuture> = - coroutineScope - .async { - deleteExternalId(data) - }.asCompletableFuture() + coroutineScope.async { + deleteExternalId(data) + }.asCompletableFuture() override suspend fun connectedApps(data: ConnectedAppsRequest): StytchResult = withContext(Dispatchers.IO) { @@ -852,10 +837,9 @@ internal class UsersImpl( } override fun connectedAppsCompletable(data: ConnectedAppsRequest): CompletableFuture> = - coroutineScope - .async { - connectedApps(data) - }.asCompletableFuture() + coroutineScope.async { + connectedApps(data) + }.asCompletableFuture() override suspend fun revoke(data: RevokeRequest): StytchResult = withContext(Dispatchers.IO) { @@ -875,8 +859,7 @@ internal class UsersImpl( } override fun revokeCompletable(data: RevokeRequest): CompletableFuture> = - coroutineScope - .async { - revoke(data) - }.asCompletableFuture() + coroutineScope.async { + revoke(data) + }.asCompletableFuture() } diff --git a/stytch/src/main/kotlin/com/stytch/java/consumer/api/webauthn/WebAuthn.kt b/stytch/src/main/kotlin/com/stytch/java/consumer/api/webauthn/WebAuthn.kt index 380aab87..ff712fa9 100644 --- a/stytch/src/main/kotlin/com/stytch/java/consumer/api/webauthn/WebAuthn.kt +++ b/stytch/src/main/kotlin/com/stytch/java/consumer/api/webauthn/WebAuthn.kt @@ -283,10 +283,9 @@ internal class WebAuthnImpl( } override fun registerStartCompletable(data: RegisterStartRequest): CompletableFuture> = - coroutineScope - .async { - registerStart(data) - }.asCompletableFuture() + coroutineScope.async { + registerStart(data) + }.asCompletableFuture() override suspend fun register(data: RegisterRequest): StytchResult = withContext(Dispatchers.IO) { @@ -306,10 +305,9 @@ internal class WebAuthnImpl( } override fun registerCompletable(data: RegisterRequest): CompletableFuture> = - coroutineScope - .async { - register(data) - }.asCompletableFuture() + coroutineScope.async { + register(data) + }.asCompletableFuture() override suspend fun authenticateStart(data: AuthenticateStartRequest): StytchResult = withContext(Dispatchers.IO) { @@ -329,10 +327,9 @@ internal class WebAuthnImpl( } override fun authenticateStartCompletable(data: AuthenticateStartRequest): CompletableFuture> = - coroutineScope - .async { - authenticateStart(data) - }.asCompletableFuture() + coroutineScope.async { + authenticateStart(data) + }.asCompletableFuture() override suspend fun authenticate(data: AuthenticateRequest): StytchResult = withContext(Dispatchers.IO) { @@ -352,10 +349,9 @@ internal class WebAuthnImpl( } override fun authenticateCompletable(data: AuthenticateRequest): CompletableFuture> = - coroutineScope - .async { - authenticate(data) - }.asCompletableFuture() + coroutineScope.async { + authenticate(data) + }.asCompletableFuture() override suspend fun update(data: UpdateRequest): StytchResult = withContext(Dispatchers.IO) { @@ -375,10 +371,9 @@ internal class WebAuthnImpl( } override fun updateCompletable(data: UpdateRequest): CompletableFuture> = - coroutineScope - .async { - update(data) - }.asCompletableFuture() + coroutineScope.async { + update(data) + }.asCompletableFuture() override suspend fun listCredentials(data: ListCredentialsRequest): StytchResult = withContext(Dispatchers.IO) { @@ -401,8 +396,7 @@ internal class WebAuthnImpl( } override fun listCredentialsCompletable(data: ListCredentialsRequest): CompletableFuture> = - coroutineScope - .async { - listCredentials(data) - }.asCompletableFuture() + coroutineScope.async { + listCredentials(data) + }.asCompletableFuture() } diff --git a/version.gradle.kts b/version.gradle.kts index 3e1d71cb..5dd46d9f 100644 --- a/version.gradle.kts +++ b/version.gradle.kts @@ -1 +1 @@ -version = "9.2.0" +version = "9.2.1"