Skip to content

Releases: auth0/Auth0.swift

1.0.0-beta.3

21 Jun 01:28
6b18f5d
Compare
Choose a tag to compare
1.0.0-beta.3 Pre-release
Pre-release

Full Changelog

Added:

  • Show better error when PKCE is not enabled in client #30 (hzalaz)
  • Auth0 telemetry information #29 (hzalaz)
  • Multifactor support for /oauth/ro #28 (hzalaz)

Changed:

  • Added parameter labels in Authentication API methods #27 (hzalaz)
  • Reworked Error handling #26 (hzalaz)

Breaking changes:

Most of the Authentication API methods first parameters labels are required so for example this call:

Auth0
    .login("mail@mail.com", password: "secret", connection: "connection")

now needs to have the usernameOrEmail parameter label

Auth0
    .login(usernameOrEmail: "mail@mail.com", password: "secret", connection: "connection")

Now all Result object return ErrorType instead of a specific error, this means that OS errors like no network, or connection could not be established are not wrapped in any Auth0 error anymore.

Also the error types that Auth0.swift API clients can return are no longer an enum but a simple object:

  • Authentication API: AuthenticationError
  • Management API: ManagementError

Each of them has it's own values according at what each api returns when the request fails. Now to handle Auth0.swift errors in your callback, you can do the following:

Auth0
    .login(usernameOrEmail: "mail@mail.com", password: "secret", connection: "connection")
    .start { result in
        switch result {
        case .Success(let credentials):
            print(credentials)
        case .Failure(let cause as AuthenticationError):
            print("Auth0 error was \(cause)")
        case .Failure(let cause):
            print("Unknown error: \(cause)")
        }
    }

Also, AuthenticationError has some helper methods to check for common failures:

Auth0
    .login(usernameOrEmail: "mail@mail.com", password: "secret", connection: "connection")
    .start { result in
        switch result {
        case .Success(let credentials):
            print(credentials)
        case .Failure(let cause as AuthenticationError) where cause.isMultifactorRequired:
            print("Need to ask the user for his mfa code!")
        case .Failure(let cause):
            print("Login failed with error: \(cause)")
        }
    }

1.0.0-beta.2

11 Jun 19:21
d17fb18
Compare
Choose a tag to compare
1.0.0-beta.2 Pre-release
Pre-release

Full Changelog

Added:

  • Authenticate a user using web-based authentication with Auth0, e.g. social authentication. (iOS Only) #19,#20 & #24 (hzalaz)
  • Load Auth0 clientId & domain from a plist file #21 (hzalaz)
  • Request Logging support #23 (hzalaz)

Fixed:

  • Date parsing format in UserProfile #22 (srna)

1.0.0-beta.1

25 May 19:44
f1f722f
Compare
Choose a tag to compare
1.0.0-beta.1 Pre-release
Pre-release

Full Changelog

Added:

  • Auth0 Authentication API endpoints, now you can use Auth0.swift to write your own login box.

Changed:

  • Dropped support for iOS 8
  • Reworked Swift API and updated to Swift 2.2
  • Removed Alamofire as dependency, all networking is done with NSURLSession directly
  • Request callbacks, in Swift, have a single value of enum Result<Payload,ErrorType>
  • Improved code docs

0.3.0

11 Jun 19:23
59d4d60
Compare
Choose a tag to compare

Full Changelog

Closed issues:

  • Alamofire dependency #5

Merged pull requests:

  • Update dependencies and fix compile issues #7 (hzalaz)
  • Load domain from Auth0.plist if not in main infoDictionary #4 (bradfol)

0.2.0

17 Sep 01:15
Compare
Choose a tag to compare

Full Changelog

Merged pull requests:

0.1.2

03 Jul 15:19
Compare
Choose a tag to compare

Full Changelog

Merged pull requests:

  • Allow to call method users from Auth0 struct #1 (hzalaz)

0.1.1

02 Jul 20:40
Compare
Choose a tag to compare

0.1.0

02 Jul 20:40
Compare
Choose a tag to compare

* This Change Log was automatically generated by github_changelog_generator