Skip to content

Releases: tkhq/swift-sdk

Release: v1.2.1

28 Nov 11:54
35a3f20
Compare
Choose a tag to compare

What's Changed

  • Fixed missing return in guard statement ( #9 )

Full Changelog: 1.2.0...1.2.1

Release: v1.2.0

27 Nov 23:41
fe5e60f
Compare
Choose a tag to compare

What's Changed

Challenge format ( #1 )

The backend expects the challenge in hex format, and SHA256Digest returns only the raw format.
Now the challenge is properly encoded/formated.

ProxyMiddleware ( #5 ) - ⚠️ Minor Breaking

The ProxyMiddleware header for the forwarded Turnkey API request has been renamed:

Old New
X-Forwarded-For X-Turnkey-Request-Url

Ensure your backend is updated to support the new header name if you are using the latest version.

New Contributors

Full Changelog: 1.1.0...1.2.0

Release: v1.1.0

13 Nov 00:22
bd8993b
Compare
Choose a tag to compare

Version: 1.1.0

What's Changed

Oauth

Support for OAuth endpoints has been added:

  • getOauthProviders()
  • createOauthProviders()
  • deleteOauthProviders()

Sessions

Support for Session endpoints has been added:

  • createReadOnlySession()
  • createReadWriteSession()

Non-breaking

  • emailAuth(): Added an optional invalidateExisting parameter to emailAuth for API key invalidation.
  • updateUser(): updateUser now supports updating the userPhoneNumber field.

⚠️ Breaking

  • createApiKeys():
  • createSubOrganization:
    • Now uses RootUserParamsV4, which introduces the following changes:
      • New required oauthProviders field: Must be provided as a list of OAuth provider parameters.
      • New optional userPhoneNumber field: Represents the user's phone number in E.164 format.
      • Updated apiKeys type: Now requires ApiKeyParamsV2 instead of ApiKeyParams.

Migration Guide: createSubOrganization()

let rootUsers: [Components.Schemas.RootUserParamsV4] = [
  .init(
    userName: "user1",
    userEmail: "[email protected]",
    apiKeys: [
      .init(
        apiKeyName: "turnkey-demo",
        publicKey: apiPublicKey!,
        curveType: .API_KEY_CURVE_P256 // New required field
      )
    ],
    authenticators: [],
    oauthProviders: [] // New required field
  )
]

let output = try await client.createSubOrganization(
  organizationId: organizationId!,
  subOrganizationName: subOrganizationName,
  rootUsers: rootUsers,
  rootQuorumThreshold: rootQuorumThreshold,
  wallet: wallet,
  disableEmailRecovery: disableEmailRecovery,
  disableEmailAuth: disableEmailAuth,
  disableSmsAuth: false, // New optional parameter
  disableOtpEmailAuth: false // New optional parameter
)

Full Changelog: 1.0.0...1.1.0

Turnkey's swift-sdk

08 May 18:05
15130e5
Compare
Choose a tag to compare

Initial release for Turnkey's swift-sdk 🎉