diff --git a/.version b/.version index 7433fb30..5c9dc9d0 100644 --- a/.version +++ b/.version @@ -1 +1 @@ -v2.6.0 \ No newline at end of file +v2.7.0 \ No newline at end of file diff --git a/CHANGELOG.md b/CHANGELOG.md index 45b8d18a..6a7c1288 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,11 @@ # Change Log +## [v2.7.0](https://github.com/auth0/auth0-react/tree/v2.7.0) (2025-10-15) +[Full Changelog](https://github.com/auth0/auth0-react/compare/v2.6.0...v2.7.0) + +**Added** +- Add support for connected accounts [\#912](https://github.com/auth0/auth0-react/pull/912) ([adamjmcgrath](https://github.com/adamjmcgrath)) + ## [v2.6.0](https://github.com/auth0/auth0-react/tree/v2.6.0) (2025-10-06) [Full Changelog](https://github.com/auth0/auth0-react/compare/v2.5.0...v2.6.0) diff --git a/docs/assets/hierarchy.js b/docs/assets/hierarchy.js index 5a7312df..569807a3 100644 --- a/docs/assets/hierarchy.js +++ b/docs/assets/hierarchy.js @@ -1 +1 @@ -window.hierarchyData = "eJyVlMtOwzAQRf9l1oYmsR252SFACImXCogFYmG508YitYPtrKr+O0oqkPvCYRUpOZMz1zPJGpy1wUP1znNBaD4lRcE/CDhcNKiCtsZDtYai4P3FyBVCBU+27do7u9Tmsd0iBD61mUNV8JJA5xqoQJuAbiEV+skBf16HVQMEVCO9hwqCn5/1Lzj7Leof1rqZOzRQvRc0+9gQKGgWdXGD4cV+onnToR4M45o5VTaipw0Bmk+jFm4vpaoxIdxC/41MqegjUyoi351VsnkO1skl7qrzQvyoBwP6yQF8soXtjd7Gy8j2oldou3DtnHV/iWIu4diJyCgbIop4qvcLOcOvTjucJ8X7bDogy8T+Hl9Ko7BpRuiO4COMlO0bx57rATzCVsZnedGFGk3QSvYbnvQdwUcYpzvT095rs5zhwqGvh+8sPcUTNWk3z8XO/8Cg0yrpi7n/rCvlJaEiIywThJUZYdOMcDasMGfxkF89XrW2fbBGYbKbAzgVe7P5Bo2A5S4=" \ No newline at end of file +window.hierarchyData = "eJyVlF1PgzAUhv/Lua4KtAXhzkxjTPzKnPHCeNF0h9HIWmzLldl/N7Bous1ZvCIpT3nO23PoJ1hjvIPqlWcloTQhGc3fCFisW5ReGe2g+oSM5sNDizVCBY+m67tbs1L6odsiBN6VXkKV8ZxAb1uoQGmPthYS3dkBf9r4dQsEZCucgwq8W54MHzj52TS8bFS7tKihes1Y+rYhkLE0qOIa/cK8o35RvhkN04o5tm1CTRsClCZBCTczIRuMCLfQfyNTVg6RKSsD362Ron3yxooV7qrT7PxbPRrQnR3AR0vYLgy2vAhsC7VG0/sra439SxRyEcdORMb4GLEMu3pXizl+9MriMireZ+MBWVruz/FMaIltO0H3Cz7ByPi+ceq5HsATbEV4lhe9b1B7JcUw4VHfL3jcyJOd7innlF7NsbbomvE/i3fxyJ4J7qzcuQ80WiWjvpD7z7jSvCC0TAlLS8KKlPAkJZxzkif5MMach41+dnjZme7eaInRig7gePQ8CS/kmdEaZXyiQi7m2Gy+AOlFBus=" \ No newline at end of file diff --git a/docs/assets/navigation.js b/docs/assets/navigation.js index f25d8eec..cbaa13f3 100644 --- a/docs/assets/navigation.js +++ b/docs/assets/navigation.js @@ -1 +1 @@ -window.navigationData = "eJylll1v0zAUhv+LrzvYChvQO1Q+VKljVbuJC8SFcU4Sa64d7JOxgvjvKAlpk/gjkXvZntfP4zj2cb79IQjPSBbkfYk5SOSMIlfyo9ZKkxkpKOZkQZigxoB56Qi9yHEvyIw8cpmQxdX87axJkwVBk1xwcwHPCFpSQf7OjrbPIEFz5tF0q3H8lbyFvdKHJWU52IJeOc6wVoyKHSpNM/BYrEic6TalW/hZcg2JZ72GiUgPN4bLbAupBpPfq0fwbQNfMs57V+0qj+lUs9gdwkYVZbGkkoEQ3kVyhOLmW4Pu+R5UiSFXNxJnCkvO5z8Y+FCo4ouSDDwSKxJtcsMjedW2uFwqWf1cSQSdUtY5gbz9q2lZVrIvnV/fDNEbrZ54AvquqBqd8ZMHwTGw0vx33Ts3VNO9nzvIWdiJTRbrs7njAiSKQ+hhPNnzxF855vVRmGIehuPUq0Ev7ohWjh48GZvUc3Rzm1oceK0yVWJofXqJ0P5qgg9ajNNOobhZN71UyZRnIZkdO0O3VhmXo7ZuKk62hYRrYDjqcwVD76fa4G3PKNzIfmQK7PQ11n4BhKY8OirYv4pihxQ7hwsPRdWv/v8/GHv57s3V9bwzvj5+9IewAMeCkzDppdWI6nuregonvy3GOz4Bshx0s5+Hjl4x3tG9rU6KJ6p5tT7926xveTX33WEnTlpKVr/m/t3VB9287oBKA3XUxWhrgeG/2v3sGn8sTgDYGzZEtNOW4vs/Ayx8aw==" \ No newline at end of file +window.navigationData = "eJylll1v2jAUhv+Lr+nasrXbuKvYh5DoioCqF9MuPOdArAbbs52ubNp/n5IQEscfiZxLOK+fx0nso/P9L9LwqtEMrUEJzhRsjwLQBAmsUzRDwPKDumzX3qT6kKEJeqYsQbMPE0QyrBSaIa2SC6ou4FWDZDhD/yZn9l2uU2CaEqwpZ5+l5LJRlOtBXTpCput6Osw254wB0R5NuxrH/woMJCUefrsax1+wezhweZxjkoItMMpxhiUnONtoLvEePBYrEme63+E1/MqphMTzvrqJSA9VirL9GnYSVLrlz+A7Zr5knPehOLUeU1Oz2C3CiotczDEjkGXel+QIxe23BG3pAXjuuyBWJM4UloznPyr4JLj4xhkBj8SKRJvc8EhecSyu5pwVPxdMg9xh0rqBtP6raolW0pROb2676JXkLzQB+SCKRqr85E6wD8wl/VP25hWW+ODndnIWdmCT1eXd3NAMmM6OoYfxZMeJn6hOy6swxNwNx6kXnV7cEi0cPXgwNin36OZWtTjwku95rkPvx0iEzlcVfJRZP60Jxe266qWc7eg+JLNjI3RLvqes19ZOxcnWkFAJRJ+GnDtCeM6CXyi4Ytwmeh/aFQwdkuKW1Y1LuJFmZAisGTnrMSS05d5VwSYqxEZj3brh+iiKpnn6v7P26uP765tpe7AtegD+mVmAc8FJGDY0F4hi6CuewsmviyMcxhmrv/4aVJ5pSxnIjt4BJCeux3qu932RL6BJCrJqE12YUYzfc3sIaBQvWNLii5tDgml5O/WNBg1nlzNSHlxzJDBBt+9aoFxBGXUx6lpg+e/6hrrWn4sDAPYVDBHttKX48R+nXTWO" \ No newline at end of file diff --git a/docs/assets/search.js b/docs/assets/search.js index a27fcf73..37c2f273 100644 --- a/docs/assets/search.js +++ b/docs/assets/search.js @@ -1 +1 @@ -window.searchData = "eJy1ml1vnDgUhv+Lc0vT8THzedfN7kqVqm21rXYvRlFFwclYIcAaJm01yn9fGQY4xmcmJkPvIvB5/do859hj58B0/r1km+2BPagsYRsOq4Bl0aNkG/bx3b7a/aF1rlnA9jplGxanUVnK8m3/6npXPaYsaN+wDWPPQas259CpxXlWVnofVy/LXdltkXTAikjLrLLd9R3yGYRdj9LH+lXb6qJeviayjLUqKpVnfj0OIkb0DvNF17l5P7vJs0r+qN5nldR3USw7A6p9Ur4lG579dtYgYy2jSv4pq3gn9Tj9qyb2roulh0qPxOvL+tlwv3NVJm9U+UZlO6lVJZNX27mXmdRRJX8v8uKTzvO7kdba+KTIi+IYP8Es3cvqXRzLsvySP8jss0plVqU/R3urolqkMiJlLzK5wX9VtfuUF/viIoffVbUrjirTWDRf9a88G5tXxpf5oNkxdBoz75N6rm7SSD2W4w2ppJ6kuA2fwNQuypJU/i0TpWVc3URp+i2KH0Zaa0T0USTuRSYwqErTXGaViqMmy8c4U2U0iP4FBUSVH/IoUdn9aHNpF/cLbKX5vXp1WtbBE2djZ6jF7bWedB8/ja18/wovTdAEBsrXV6ly8iq1L0dvEY4h0yDs7I8+6fxJJVJ/rDdbp6vmoN2I3dFOpYmW2SjlKxR1ZtaH5k9ZaOZjpIMu6HIDeea9BJBe8mxc9fe0VT6o4jJjRmEqaxjND3X+n2HSanAWRizbDvaDKXVn1Kl23p2YEtwOtSDl7Rb+qWQW25mn4FXbmP4WA5PnR3Jc4JXB+L+90jI5M3cvBo0oHafz1q+XF5P45RGeW2wvnoVmzc07mYlN5tlv8i7X0g6+wG6efasFo6Hg5MbbDDyx7fP2qy2diW1qWe119iW/wGEjUeWTmIPZesnn/anSu6L4XEVVv+upfhamnB8f+yeiM1BC6OWhdHb6XgTYu5GbQcY/RVpF39LBBums8UVIb3A6zbt9FtczZ69rvqL7ss6nGaHXvvKV+t4WYUKrezdWzAXljLrbmOruNmAqS+QPtjmwJ6lLk/MbBtfies0Cdqdkmphj0sZJwOL88dF88YAlebyv/7w9NvtHmmNL07hp/XbGgu0sEOJ6Pl/e3gbbNrh+UT9oNfondSBnwZZTgdwJ5FYgsGALAayuw3BtBYITCFagYMFWUD0KJ1BYgSELtiEVGDqBoRU4Z8F2TgXOncC5Fbg4NcaFE7iwApcs2C6oHpdO4NIKXLFgu6QCV07gygpcs2C7ogLXTuDaBsDwsCYJcNnhA3hqekjuOMGPDRA3WHCaPZchbkPEDRocyGCXI26DxA0enGSQuyxxGyZuEOEkh9zlidtAcYMJJ1nkLlPchoobVDiJFXe54jZY3ODCSbS4yxa34eIGGU7ixV2+uA0YGGY4SRi4hIFNGBhmgCQMXMJgUKLqGsXJIkVUKZswMMwASRi4hIFNGBhmgCQMXMLAJgwMM0ASBi5hYBMGdc0iCQOXMLAJA8MMkISBSxjYhIFhBkjCwCUMbMLAMAMkYeASBjZhYnbyOwuXMGETJmrCSDyFS5iwCROGGUHiKVzCxGAhrFdCsgAKYi20CROGGUEuTsIlTNiECcOMoBdhlzBhEyYWp3t2CRM2YcIwI0i2hUuYsAkThhlBsi1cwoRNmDDMCJJt4RImbMJCw4wg2Q5dwkKbsNAwI0i2Q5ew46N6r/gkdSWT982ecbtlUVGUzQ+RA/t63EoK0W5dD0zM2ebw/NxvHTeHZ7R7NO9MX8cjjV4Dlr0GrPw1umMBZCdEdpajpbpfflgTSYb+ikX3gwW5myN3IwbaanVHDL0kX6O5m3lJ9oey6BPMkAz3k8H/wIAM9ULeOsOvCEgEoIkTnoOzb+J7TTT1fpgeL9ORK2SqiVn4C9n/C4GQQER4qREX6b3aolfzg//U1XcviXLTj9iTd9W95qrXXPtqohucXgjBz/34cC+IEbooCbgfvKcudZEoTgjwEnXuY5EagpD7AYMuUJEO4o77VTX7kBOlBfoIwm/WhvemyBcqttwvT4kLT6SH0p77pWt7aYlEUFpxv7xqRKjZQgMEvwHmNQ3DaoRY9SP/1KkvqkVIU/ihSl1pocHikulH6+CsF5lDeST8tFqlk+QiOMAPjv50FDlDoxThcbXykytP1DWOqi73K7v0HR4aLMp48Mv4fSmdvZpAuSD8indz840Gh8o/95Mw6e1aQZMU+uVAp1M0l3poetC4wC/HW7E+mXR3VItcotGGfuXxtDAFMdIHj9m8DVihCpmqTLLN9vb5+X+5lFjk"; \ No newline at end of file +window.searchData = "eJy1mlFv2zYQx78L86qm5pG2Y7912QYUKNZiLbYHIyhUiYmFKKImyWkLI999oGRJR/HkUIn6Fli8P/+kfndkKB5Zob+XbLs7svski9mWw1XAsvBBsS37+O5Q7f8oCl2wgB2KlG1ZlIZlqcq3/aPLffWQsqB9wraMPQWt2pJDpxbprKyKQ1Q9L3dht0XSAcvDQmWV7a7vkC9Adj0qH+sXbatX9fI1VmVUJHmV6Myvx0HEhN5hueo6N88X1zqr1I/qfVap4jaMVGcgaX8p35INz747a5CRzjIVVe+iSB+y6t+k2v+t4qRQUTWts4uTUNgIfU+qfdEL0ZNAj3HMaKHCSv2pqmiviqne6tjbLnYGOzaCfjZcIKsyfpOUb5Jsr4qkUvGL7dypTBVhpX7Pdf6p0Pp2orU2Ps51np/iZ5ilO2XIUmX5Rd+r7HOSqqxKf072ZqhSZVkZkbIXmd2gwf+Tzg/5qxwa9vOTyjwWzVv9S2dTC4DxZV5odgqdx8z7uJ6r6zRMHsrphpK4nqSoDZ/B1D7M4lS1des6TNNvYXQ/0Voj0tasqBeZwWBSmuYqq5IobLJ8irOkDAfRv6CAJOUHHcZJdjfZXNrF/QJbqb5LXpyWdfDM2dgZeuEy2Xmad3VM9Z0+vMBLEzSDgfLlVaqcvUodyslbhFPIPAg7G7lPhX5MYlV8rHeF41Vz0G7CNm6fpHGhsknKFyjqzKwPzY/vJM18THTQBb3egM68lwDSi86mVX9PW+V9kr/OmFGYyxpG80Od/2eYtBqchRHLtoP9YErdGXWqnXcnpgS3Q81JebuFfyqZxXbhKXjRNqbfxcDk+ZGcFvjEYPzfISlUfGbung2a9B/gWN769fJsEj8/wnOL7atnoVlzdSczs0md/aZudaHs4FfY1dm3WjAcCs5uvM3AkW2ft9/C0pnZZqGqQ5F90a9w2EhUehZzsNis+bI//nqX55+rsOp3PdXP3JTz08+Tj2JUfDqMOSd40TUOu8Yj60Frb3R6y1xnpfpqejnb5bDlS/sbvE66q2deGNHL8L1cn5/O4eOz70mAvZ+7HtTMx7BIwm/pYIt5VnIl6S1ip3l7yKKaPXtn4Ct6KOuKtCD02ke+Ut/bZYzQ6p5NFXNT7Yy625jq7iZgSRarH2x7ZI+qKE3V3DK4FJcbFrDbRKWxORFvnAQs0g8PquYi1tGh/vPm1OwfZU6oTeOm9dsFC3aLQMhLKdc3N8GuDa4f1D+0Gv0vdSBnwY5TgdwJ5FYgsGAHAWwuhdhYgeAEghUoWLATVI/CCRRWoGTBTlKB0gmUVuCSBbslFbh0ApdW4IoFuxUVuHICV1bgemxy1k7g2gq8YsFuTfV45QReWYEbFuyuqMCNE7ixATA8bEgCXHb4AJ6aHpI7TvBjA8QNFpxmz2WI2xBxgwYHMtjliNsgcYMHJxnkLkvchokbRDjJIXd54jZQ3GDCSRa5yxS3oeIGFU7yyF2uuA0WN7hwEi3ussVtuLhBhpN4cZcvbgMGhhlOEgYuYWATBoYZIAkDlzAYlKi6RpGEAVGlbMLAMAN0hXMJA5swMMwASRi4hIFNGBhmgCQMXMLAJgwMM0ASBi5hYBMGdd0iCQOXMLAJA8MMkISBSxjYhIFhBkjCwCUMbMKEYQZIwoRLmLAJE3z0PQuXMGETJgwzgsRTuISJwUJYr4QknoJYC23ChGFGkAVQuIQJmzBhmBGCHLNLmLAJE4YZQeIpXMKETZgwzIgl2bNLmLAJE4YZQeIpXMKETZjYjI/ZJUzYhMnFqG3pEiZtwqRhRpCJIV3CpE2YrAkjE0O6hEmbMFkTRiaGdAmTg+1Wvd8i2ZbEjssmTBpmJMm2dAk7/VTvjx9VUan4fbNP3u1YmOdl8+/rkX09bZ9Ft10/MrFi2+PTU79d3h6f0I7ZPDN9nQ7Ceo3+usmRwcZfoztMQnbWvZTkk6W68wKsiUYo/RXz7p805A4NVMJ0re5gCs3dAs2d34D7o3wkw5GMn7Nztzh64WWvu5wii04r0PwhNbFuBOTCV7a/TdQromF7Tp7LHACaO9HECU81+7ZJr7nqJf2S6nRhBLlCppqYtb+QfTEJvQA0/15qxGWRXg3l6pWnGn29o5dECeZXSEbvY/SaG8SIH2z2ZQpEG0pW7keIew0CyWF6/ZJ27OoCEkXgcL+X7Nw6QGqIGO5XPdE1AaSDijD3KyT2UT5iGL0E4Tdrw9sByBeqSNwvU4nP+kgPJT73S9j20zwSQYnF/TKrEaHWFzRA8BugrmkY1iM0635JNPZtA71JxL/wQ5X6cIsGi2gFP1oHXzSQOZRHwk+rVRojFxAc4AfH4CAe2UNawo+R/qQdyeAVYXla+/wqbzlWJFEN555S5FdvNHGoeoBf9TiUytmnCrQSSD/emrsiaHBIAvzywJQKx4pE6ST96Op08uYzOJoeVC/Aj4VWrE/MojuaRy5Rgkq/eR8XphICzabwmM2bgOVJrtIkU2y7u3l6+h8wPJ5h"; \ No newline at end of file diff --git a/docs/classes/AuthenticationError.html b/docs/classes/AuthenticationError.html index e1910df7..1aeffaa9 100644 --- a/docs/classes/AuthenticationError.html +++ b/docs/classes/AuthenticationError.html @@ -1,6 +1,6 @@ AuthenticationError | @auth0/auth0-react
@auth0/auth0-react
    Preparing search index...

    Class AuthenticationError

    Thrown when handling the redirect callback fails, will be one of Auth0's Authentication API's Standard Error Responses: https://auth0.com/docs/api/authentication?javascript#standard-error-responses

    -

    Hierarchy (View Summary)

    Index

    Constructors

    Hierarchy (View Summary)

    Index

    Constructors

    Properties

    appState error error_description diff --git a/docs/classes/ConnectError.html b/docs/classes/ConnectError.html new file mode 100644 index 00000000..7deb7023 --- /dev/null +++ b/docs/classes/ConnectError.html @@ -0,0 +1,19 @@ +ConnectError | @auth0/auth0-react
    @auth0/auth0-react
      Preparing search index...

      Class ConnectError

      Thrown when handling the redirect callback for the connect flow fails, will be one of Auth0's +Authentication API's Standard Error Responses: https://auth0.com/docs/api/authentication?javascript#standard-error-responses

      +

      Hierarchy (View Summary)

      Index

      Constructors

      • Parameters

        • error: string
        • error_description: string
        • connection: string
        • state: string
        • OptionalappState: any

        Returns ConnectError

      Properties

      appState: any
      connection: string
      error: string
      error_description: string
      message: string
      name: string
      stack?: string
      state: string
      prepareStackTrace?: (err: Error, stackTraces: CallSite[]) => any

      Optional override for formatting stack traces

      +
      stackTraceLimit: number

      Methods

      • Create .stack property on a target object

        +

        Parameters

        • targetObject: object
        • OptionalconstructorOpt: Function

        Returns void

      • Parameters

        • __namedParameters: { error: string; error_description: string }

        Returns GenericError

      diff --git a/docs/classes/GenericError.html b/docs/classes/GenericError.html index 54de0e3e..fa105c1e 100644 --- a/docs/classes/GenericError.html +++ b/docs/classes/GenericError.html @@ -1,5 +1,5 @@ GenericError | @auth0/auth0-react
      @auth0/auth0-react
        Preparing search index...

        Class GenericError

        Thrown when network requests to the Auth server fail.

        -

        Hierarchy (View Summary)

        Index

        Constructors

        Hierarchy (View Summary)

        Index

        Constructors

        Properties

        error error_description message diff --git a/docs/classes/MfaRequiredError.html b/docs/classes/MfaRequiredError.html index 1bd135ee..28959d2e 100644 --- a/docs/classes/MfaRequiredError.html +++ b/docs/classes/MfaRequiredError.html @@ -1,5 +1,5 @@ MfaRequiredError | @auth0/auth0-react
        @auth0/auth0-react
          Preparing search index...

          Class MfaRequiredError

          Error thrown when the token exchange results in a mfa_required error

          -

          Hierarchy (View Summary)

          Index

          Constructors

          Hierarchy (View Summary)

          Index

          Constructors

          • Parameters

            • error: string
            • error_description: string
            • mfa_token: string

            Returns MfaRequiredError

          Properties

          error: string
          error_description: string
          message: string
          mfa_token: string
          name: string
          stack?: string
          prepareStackTrace?: (err: Error, stackTraces: CallSite[]) => any

          Optional override for formatting stack traces

          +

          Constructors

          • Parameters

            • error: string
            • error_description: string
            • mfa_token: string

            Returns MfaRequiredError

          Properties

          error: string
          error_description: string
          message: string
          mfa_token: string
          name: string
          stack?: string
          prepareStackTrace?: (err: Error, stackTraces: CallSite[]) => any

          Optional override for formatting stack traces

          stackTraceLimit: number

          Methods

          • Create .stack property on a target object

            Parameters

            • targetObject: object
            • OptionalconstructorOpt: Function

            Returns void

          • Parameters

            • __namedParameters: { error: string; error_description: string }

            Returns GenericError

          diff --git a/docs/classes/MissingRefreshTokenError.html b/docs/classes/MissingRefreshTokenError.html index 2ac73f73..0eecc340 100644 --- a/docs/classes/MissingRefreshTokenError.html +++ b/docs/classes/MissingRefreshTokenError.html @@ -1,5 +1,5 @@ MissingRefreshTokenError | @auth0/auth0-react
          @auth0/auth0-react
            Preparing search index...

            Class MissingRefreshTokenError

            Error thrown when there is no refresh token to use

            -

            Hierarchy (View Summary)

            Index

            Constructors

            Hierarchy (View Summary)

            Index

            Constructors

            Properties

            audience: string
            error: string
            error_description: string
            message: string
            name: string
            scope: string
            stack?: string
            prepareStackTrace?: (err: Error, stackTraces: CallSite[]) => any

            Optional override for formatting stack traces

            +

            Constructors

            Properties

            audience: string
            error: string
            error_description: string
            message: string
            name: string
            scope: string
            stack?: string
            prepareStackTrace?: (err: Error, stackTraces: CallSite[]) => any

            Optional override for formatting stack traces

            stackTraceLimit: number

            Methods

            • Create .stack property on a target object

              Parameters

              • targetObject: object
              • OptionalconstructorOpt: Function

              Returns void

            • Parameters

              • __namedParameters: { error: string; error_description: string }

              Returns GenericError

            diff --git a/docs/classes/OAuthError.html b/docs/classes/OAuthError.html index 5ec6db88..add5176c 100644 --- a/docs/classes/OAuthError.html +++ b/docs/classes/OAuthError.html @@ -1,7 +1,7 @@ OAuthError | @auth0/auth0-react
            @auth0/auth0-react
              Preparing search index...

              Class OAuthError

              An OAuth2 error will come from the authorization server and will have at least an error property which will be the error code. And possibly an error_description property

              See: https://openid.net/specs/openid-connect-core-1_0.html#rfc.section.3.1.2.6

              -

              Hierarchy

              • Error
                • OAuthError
              Index

              Constructors

              Hierarchy

              • Error
                • OAuthError
              Index

              Constructors

              • Parameters

                • error: string
                • Optionalerror_description: string

                Returns OAuthError

              Properties

              error: string
              error_description?: string
              message: string
              name: string
              stack?: string
              prepareStackTrace?: (err: Error, stackTraces: CallSite[]) => any

              Optional override for formatting stack traces

              +

              Constructors

              • Parameters

                • error: string
                • Optionalerror_description: string

                Returns OAuthError

              Properties

              error: string
              error_description?: string
              message: string
              name: string
              stack?: string
              prepareStackTrace?: (err: Error, stackTraces: CallSite[]) => any

              Optional override for formatting stack traces

              stackTraceLimit: number

              Methods

              • Create .stack property on a target object

                Parameters

                • targetObject: object
                • OptionalconstructorOpt: Function

                Returns void

              diff --git a/docs/classes/PopupCancelledError.html b/docs/classes/PopupCancelledError.html index cedae710..5b96190e 100644 --- a/docs/classes/PopupCancelledError.html +++ b/docs/classes/PopupCancelledError.html @@ -1,5 +1,5 @@ PopupCancelledError | @auth0/auth0-react
              @auth0/auth0-react
                Preparing search index...

                Class PopupCancelledError

                Thrown when network requests to the Auth server fail.

                -

                Hierarchy (View Summary)

                Index

                Constructors

                Hierarchy (View Summary)

                Index

                Constructors

                Properties

                error: string
                error_description: string
                message: string
                name: string
                popup: Window
                stack?: string
                prepareStackTrace?: (err: Error, stackTraces: CallSite[]) => any

                Optional override for formatting stack traces

                +

                Constructors

                Properties

                error: string
                error_description: string
                message: string
                name: string
                popup: Window
                stack?: string
                prepareStackTrace?: (err: Error, stackTraces: CallSite[]) => any

                Optional override for formatting stack traces

                stackTraceLimit: number

                Methods

                • Create .stack property on a target object

                  Parameters

                  • targetObject: object
                  • OptionalconstructorOpt: Function

                  Returns void

                • Parameters

                  • __namedParameters: { error: string; error_description: string }

                  Returns GenericError

                diff --git a/docs/classes/PopupTimeoutError.html b/docs/classes/PopupTimeoutError.html index 7a7b072c..83e875cb 100644 --- a/docs/classes/PopupTimeoutError.html +++ b/docs/classes/PopupTimeoutError.html @@ -1,5 +1,5 @@ PopupTimeoutError | @auth0/auth0-react
                @auth0/auth0-react
                  Preparing search index...

                  Class PopupTimeoutError

                  Error thrown when the login popup times out (if the user does not complete auth)

                  -

                  Hierarchy (View Summary)

                  Index

                  Constructors

                  Hierarchy (View Summary)

                  Index

                  Constructors

                  Properties

                  error: string
                  error_description: string
                  message: string
                  name: string
                  popup: Window
                  stack?: string
                  prepareStackTrace?: (err: Error, stackTraces: CallSite[]) => any

                  Optional override for formatting stack traces

                  +

                  Constructors

                  Properties

                  error: string
                  error_description: string
                  message: string
                  name: string
                  popup: Window
                  stack?: string
                  prepareStackTrace?: (err: Error, stackTraces: CallSite[]) => any

                  Optional override for formatting stack traces

                  stackTraceLimit: number

                  Methods

                  • Create .stack property on a target object

                    Parameters

                    • targetObject: object
                    • OptionalconstructorOpt: Function

                    Returns void

                  • Parameters

                    • __namedParameters: { error: string; error_description: string }

                    Returns GenericError

                  diff --git a/docs/classes/TimeoutError.html b/docs/classes/TimeoutError.html index 3ff9df6b..c7a32361 100644 --- a/docs/classes/TimeoutError.html +++ b/docs/classes/TimeoutError.html @@ -1,6 +1,6 @@ TimeoutError | @auth0/auth0-react
                  @auth0/auth0-react
                    Preparing search index...

                    Class TimeoutError

                    Thrown when silent auth times out (usually due to a configuration issue) or when network requests to the Auth server timeout.

                    -

                    Hierarchy (View Summary)

                    Index

                    Constructors

                    Hierarchy (View Summary)

                    Index

                    Constructors

                    Properties

                    error: string
                    error_description: string
                    message: string
                    name: string
                    stack?: string
                    prepareStackTrace?: (err: Error, stackTraces: CallSite[]) => any

                    Optional override for formatting stack traces

                    +

                    Constructors

                    Properties

                    error: string
                    error_description: string
                    message: string
                    name: string
                    stack?: string
                    prepareStackTrace?: (err: Error, stackTraces: CallSite[]) => any

                    Optional override for formatting stack traces

                    stackTraceLimit: number

                    Methods

                    • Create .stack property on a target object

                      Parameters

                      • targetObject: object
                      • OptionalconstructorOpt: Function

                      Returns void

                    • Parameters

                      • __namedParameters: { error: string; error_description: string }

                      Returns GenericError

                    diff --git a/docs/classes/UseDpopNonceError.html b/docs/classes/UseDpopNonceError.html index 4f3183f2..4574c35d 100644 --- a/docs/classes/UseDpopNonceError.html +++ b/docs/classes/UseDpopNonceError.html @@ -1,5 +1,5 @@ UseDpopNonceError | @auth0/auth0-react
                    @auth0/auth0-react
                      Preparing search index...

                      Class UseDpopNonceError

                      Error thrown when the wrong DPoP nonce is used and a potential subsequent retry wasn't able to fix it.

                      -

                      Hierarchy (View Summary)

                      Index

                      Constructors

                      Hierarchy (View Summary)

                      Index

                      Constructors

                      Properties

                      error: string
                      error_description: string
                      message: string
                      name: string
                      newDpopNonce: undefined | string
                      stack?: string
                      prepareStackTrace?: (err: Error, stackTraces: CallSite[]) => any

                      Optional override for formatting stack traces

                      +

                      Constructors

                      Properties

                      error: string
                      error_description: string
                      message: string
                      name: string
                      newDpopNonce: undefined | string
                      stack?: string
                      prepareStackTrace?: (err: Error, stackTraces: CallSite[]) => any

                      Optional override for formatting stack traces

                      stackTraceLimit: number

                      Methods

                      • Create .stack property on a target object

                        Parameters

                        • targetObject: object
                        • OptionalconstructorOpt: Function

                        Returns void

                      • Parameters

                        • __namedParameters: { error: string; error_description: string }

                        Returns GenericError

                      diff --git a/docs/classes/User.html b/docs/classes/User.html index d988f522..928d0f65 100644 --- a/docs/classes/User.html +++ b/docs/classes/User.html @@ -1,4 +1,4 @@ -User | @auth0/auth0-react
                      @auth0/auth0-react
                        Preparing search index...

                        Class User

                        Indexable

                        • [key: string]: any
                        Index

                        Constructors

                        constructor +User | @auth0/auth0-react
                        @auth0/auth0-react
                          Preparing search index...

                          Class User

                          Indexable

                          • [key: string]: any
                          Index

                          Constructors

                          Properties

                          Constructors

                          Properties

                          address?: string
                          birthdate?: string
                          email?: string
                          email_verified?: boolean
                          family_name?: string
                          gender?: string
                          given_name?: string
                          locale?: string
                          middle_name?: string
                          name?: string
                          nickname?: string
                          phone_number?: string
                          phone_number_verified?: boolean
                          picture?: string
                          preferred_username?: string
                          profile?: string
                          sub?: string
                          updated_at?: string
                          website?: string
                          zoneinfo?: string
                          +

                          Constructors

                          Properties

                          address?: string
                          birthdate?: string
                          email?: string
                          email_verified?: boolean
                          family_name?: string
                          gender?: string
                          given_name?: string
                          locale?: string
                          middle_name?: string
                          name?: string
                          nickname?: string
                          phone_number?: string
                          phone_number_verified?: boolean
                          picture?: string
                          preferred_username?: string
                          profile?: string
                          sub?: string
                          updated_at?: string
                          website?: string
                          zoneinfo?: string
                          diff --git a/docs/enums/ResponseType.html b/docs/enums/ResponseType.html new file mode 100644 index 00000000..8504aca8 --- /dev/null +++ b/docs/enums/ResponseType.html @@ -0,0 +1,8 @@ +ResponseType | @auth0/auth0-react
                          @auth0/auth0-react
                            Preparing search index...

                            Enumeration ResponseType

                            The types of responses expected from the authorization server.

                            +
                              +
                            • code: used for the standard login flow.
                            • +
                            • connect_code: used for the connect account flow.
                            • +
                            +
                            Index

                            Enumeration Members

                            Enumeration Members

                            Code: "code"
                            ConnectCode: "connect_code"
                            diff --git a/docs/functions/Auth0Provider.html b/docs/functions/Auth0Provider.html index 38bea866..572412b9 100644 --- a/docs/functions/Auth0Provider.html +++ b/docs/functions/Auth0Provider.html @@ -2,4 +2,4 @@

                            Provides the Auth0Context to its child components.

                            -

                            Type Parameters

                            Parameters

                            Returns Element

                            +

                            Type Parameters

                            Parameters

                            Returns Element

                            diff --git a/docs/functions/useAuth0.html b/docs/functions/useAuth0.html index 3f485e64..d0d49687 100644 --- a/docs/functions/useAuth0.html +++ b/docs/functions/useAuth0.html @@ -3,4 +3,4 @@

                            Use the useAuth0 hook in your components to access the auth state and methods.

                            TUser is an optional type param to provide a type to the user field.

                            -

                            Type Parameters

                            Parameters

                            Returns Auth0ContextInterface<TUser>

                            +

                            Type Parameters

                            Parameters

                            Returns Auth0ContextInterface<TUser>

                            diff --git a/docs/functions/withAuth0.html b/docs/functions/withAuth0.html index 7af2d52e..71c9484f 100644 --- a/docs/functions/withAuth0.html +++ b/docs/functions/withAuth0.html @@ -4,4 +4,4 @@

                            Wrap your class components in this Higher Order Component to give them access to the Auth0Context.

                            Providing a context as the second argument allows you to configure the Auth0Provider the Auth0Context should come from f you have multiple within your application.

                            -

                            Type Parameters

                            Parameters

                            Returns ComponentType<Omit<P, "auth0">>

                            +

                            Type Parameters

                            Parameters

                            Returns ComponentType<Omit<P, "auth0">>

                            diff --git a/docs/functions/withAuthenticationRequired.html b/docs/functions/withAuthenticationRequired.html index 49bb86f8..d2227e12 100644 --- a/docs/functions/withAuthenticationRequired.html +++ b/docs/functions/withAuthenticationRequired.html @@ -3,4 +3,4 @@

                            When you wrap your components in this Higher Order Component and an anonymous user visits your component they will be redirected to the login page; after login they will be returned to the page they were redirected from.

                            -

                            Type Parameters

                            Parameters

                            Returns FC<P>

                            +

                            Type Parameters

                            Parameters

                            Returns FC<P>

                            diff --git a/docs/hierarchy.html b/docs/hierarchy.html index b622c523..e73cddff 100644 --- a/docs/hierarchy.html +++ b/docs/hierarchy.html @@ -1 +1 @@ -@auth0/auth0-react
                            @auth0/auth0-react
                              Preparing search index...

                              @auth0/auth0-react

                              Hierarchy Summary

                              +@auth0/auth0-react
                              @auth0/auth0-react
                                Preparing search index...

                                @auth0/auth0-react

                                Hierarchy Summary

                                diff --git a/docs/interfaces/Auth0ContextInterface.html b/docs/interfaces/Auth0ContextInterface.html index 5a6a8754..809869b5 100644 --- a/docs/interfaces/Auth0ContextInterface.html +++ b/docs/interfaces/Auth0ContextInterface.html @@ -1,5 +1,6 @@ Auth0ContextInterface | @auth0/auth0-react
                                @auth0/auth0-react
                                  Preparing search index...

                                  Interface Auth0ContextInterface<TUser>

                                  Contains the authenticated state and authentication methods provided by the useAuth0 hook.

                                  -
                                  interface Auth0ContextInterface<TUser extends User = User> {
                                      createFetcher: <TOutput extends CustomFetchMinimalOutput = Response>(
                                          config?: FetcherConfig<TOutput>,
                                      ) => Fetcher<TOutput>;
                                      error: undefined | Error;
                                      generateDpopProof: (
                                          params: {
                                              accessToken: string;
                                              method: string;
                                              nonce?: string;
                                              url: string;
                                          },
                                      ) => Promise<string>;
                                      getAccessTokenSilently: {
                                          (
                                              options: GetTokenSilentlyOptions & { detailedResponse: true },
                                          ): Promise<GetTokenSilentlyVerboseResponse>;
                                          (options?: GetTokenSilentlyOptions): Promise<string>;
                                          (
                                              options: GetTokenSilentlyOptions,
                                          ): Promise<string | GetTokenSilentlyVerboseResponse>;
                                      };
                                      getAccessTokenWithPopup: (
                                          options?: GetTokenWithPopupOptions,
                                          config?: PopupConfigOptions,
                                      ) => Promise<undefined | string>;
                                      getDpopNonce: (id?: string) => Promise<undefined | string>;
                                      getIdTokenClaims: () => Promise<undefined | IdToken>;
                                      handleRedirectCallback: (url?: string) => Promise<RedirectLoginResult<any>>;
                                      isAuthenticated: boolean;
                                      isLoading: boolean;
                                      loginWithPopup: (
                                          options?: PopupLoginOptions,
                                          config?: PopupConfigOptions,
                                      ) => Promise<void>;
                                      loginWithRedirect: (
                                          options?: RedirectLoginOptions<AppState>,
                                      ) => Promise<void>;
                                      logout: (options?: LogoutOptions) => Promise<void>;
                                      setDpopNonce: (nonce: string, id?: string) => Promise<void>;
                                      user: undefined | TUser;
                                  }

                                  Type Parameters

                                  Hierarchy

                                  • AuthState<TUser>
                                    • Auth0ContextInterface
                                  Index

                                  Properties

                                  interface Auth0ContextInterface<TUser extends User = User> {
                                      connectAccountWithRedirect: (
                                          options: RedirectConnectAccountOptions,
                                      ) => Promise<void>;
                                      createFetcher: <TOutput extends CustomFetchMinimalOutput = Response>(
                                          config?: FetcherConfig<TOutput>,
                                      ) => Fetcher<TOutput>;
                                      error: undefined | Error;
                                      generateDpopProof: (
                                          params: {
                                              accessToken: string;
                                              method: string;
                                              nonce?: string;
                                              url: string;
                                          },
                                      ) => Promise<string>;
                                      getAccessTokenSilently: {
                                          (
                                              options: GetTokenSilentlyOptions & { detailedResponse: true },
                                          ): Promise<GetTokenSilentlyVerboseResponse>;
                                          (options?: GetTokenSilentlyOptions): Promise<string>;
                                          (
                                              options: GetTokenSilentlyOptions,
                                          ): Promise<string | GetTokenSilentlyVerboseResponse>;
                                      };
                                      getAccessTokenWithPopup: (
                                          options?: GetTokenWithPopupOptions,
                                          config?: PopupConfigOptions,
                                      ) => Promise<undefined | string>;
                                      getDpopNonce: (id?: string) => Promise<undefined | string>;
                                      getIdTokenClaims: () => Promise<undefined | IdToken>;
                                      handleRedirectCallback: (
                                          url?: string,
                                      ) => Promise<ConnectAccountRedirectResult | RedirectLoginResult<any>>;
                                      isAuthenticated: boolean;
                                      isLoading: boolean;
                                      loginWithPopup: (
                                          options?: PopupLoginOptions,
                                          config?: PopupConfigOptions,
                                      ) => Promise<void>;
                                      loginWithRedirect: (
                                          options?: RedirectLoginOptions<AppState>,
                                      ) => Promise<void>;
                                      logout: (options?: LogoutOptions) => Promise<void>;
                                      setDpopNonce: (nonce: string, id?: string) => Promise<void>;
                                      user: undefined | TUser;
                                  }

                                  Type Parameters

                                  Hierarchy

                                  • AuthState<TUser>
                                    • Auth0ContextInterface
                                  Index

                                  Properties

                                  createFetcher: <TOutput extends CustomFetchMinimalOutput = Response>(
                                      config?: FetcherConfig<TOutput>,
                                  ) => Fetcher<TOutput>

                                  Returns a new Fetcher class that will contain a fetchWithAuth() method. +

                                  Properties

                                  connectAccountWithRedirect: (
                                      options: RedirectConnectAccountOptions,
                                  ) => Promise<void>
                                  await connectAccountWithRedirect({
                                  connection: 'google-oauth2',
                                  authorizationParams: {
                                  access_type: 'offline',
                                  scope: 'openid profile email https://www.googleapis.com/auth/drive.readonly',
                                  }
                                  }); +
                                  + +

                                  Redirects to the /connect URL using the parameters +provided as arguments. This then redirects to the connection's login page +where the user can authenticate and authorize the account to be connected.

                                  +

                                  If connecting the account is successful onRedirectCallback will be called +with the details of the connected account.

                                  +
                                  createFetcher: <TOutput extends CustomFetchMinimalOutput = Response>(
                                      config?: FetcherConfig<TOutput>,
                                  ) => Fetcher<TOutput>

                                  Returns a new Fetcher class that will contain a fetchWithAuth() method. This is a drop-in replacement for the Fetch API's fetch() method, but will handle certain authentication logic for you, like building the proper auth headers or managing DPoP nonces and retries automatically.

                                  @@ -24,13 +33,13 @@ handle certain authentication logic for you, like building the proper auth headers or managing DPoP nonces and retries automatically.

                                  Check the EXAMPLES.md file for a deeper look into this method.

                                  -

                                  Type Parameters

                                  • TOutput extends CustomFetchMinimalOutput = Response

                                  Parameters

                                  Returns Fetcher<TOutput>

                                  error: undefined | Error
                                  generateDpopProof: (
                                      params: {
                                          accessToken: string;
                                          method: string;
                                          nonce?: string;
                                          url: string;
                                      },
                                  ) => Promise<string>

                                  Returns a string to be used to demonstrate possession of the private +

                                  Type Parameters

                                  • TOutput extends CustomFetchMinimalOutput = Response

                                  Parameters

                                  Returns Fetcher<TOutput>

                                  error: undefined | Error
                                  generateDpopProof: (
                                      params: {
                                          accessToken: string;
                                          method: string;
                                          nonce?: string;
                                          url: string;
                                      },
                                  ) => Promise<string>

                                  Returns a string to be used to demonstrate possession of the private key used to cryptographically bind access tokens with DPoP.

                                  It requires enabling the Auth0ClientOptions.useDpop option.

                                  Type Declaration

                                  getAccessTokenSilently: {
                                      (
                                          options: GetTokenSilentlyOptions & { detailedResponse: true },
                                      ): Promise<GetTokenSilentlyVerboseResponse>;
                                      (options?: GetTokenSilentlyOptions): Promise<string>;
                                      (
                                          options: GetTokenSilentlyOptions,
                                      ): Promise<string | GetTokenSilentlyVerboseResponse>;
                                  }
                                  const token = await getAccessTokenSilently(options);
                                  +

                                  Parameters

                                  Returns Promise<string>

                                  getAccessTokenSilently: {
                                      (
                                          options: GetTokenSilentlyOptions & { detailedResponse: true },
                                      ): Promise<GetTokenSilentlyVerboseResponse>;
                                      (options?: GetTokenSilentlyOptions): Promise<string>;
                                      (
                                          options: GetTokenSilentlyOptions,
                                      ): Promise<string | GetTokenSilentlyVerboseResponse>;
                                  }
                                  const token = await getAccessTokenSilently(options);
                                   

                                  If there's a valid token stored, return it. Otherwise, opens an @@ -49,7 +58,7 @@ back to using an iframe to make the token exchange.

                                  Note that in all cases, falling back to an iframe requires access to the auth0 cookie.

                                  -
                                  getAccessTokenWithPopup: (
                                      options?: GetTokenWithPopupOptions,
                                      config?: PopupConfigOptions,
                                  ) => Promise<undefined | string>
                                  const token = await getTokenWithPopup(options, config);
                                  +
                                  getAccessTokenWithPopup: (
                                      options?: GetTokenWithPopupOptions,
                                      config?: PopupConfigOptions,
                                  ) => Promise<undefined | string>
                                  const token = await getTokenWithPopup(options, config);
                                   

                                  Get an access token interactively.

                                  @@ -57,7 +66,7 @@ provided as arguments. Random and secure state and nonce parameters will be auto-generated. If the response is successful, results will be valid according to their expiration times.

                                  -
                                  getDpopNonce: (id?: string) => Promise<undefined | string>

                                  Returns the current DPoP nonce used for making requests to Auth0.

                                  +
                                  getDpopNonce: (id?: string) => Promise<undefined | string>

                                  Returns the current DPoP nonce used for making requests to Auth0.

                                  It can return undefined because when starting fresh it will not be populated until after the first response from the server.

                                  It requires enabling the Auth0ClientOptions.useDpop option.

                                  @@ -72,16 +81,16 @@

                                  The identifier of a nonce: if absent, it will get the nonce used for requests to Auth0. Otherwise, it will be used to select a specific non-Auth0 nonce.

                                  -
                                  getIdTokenClaims: () => Promise<undefined | IdToken>
                                  const claims = await getIdTokenClaims();
                                  +
                                  getIdTokenClaims: () => Promise<undefined | IdToken>
                                  const claims = await getIdTokenClaims();
                                   

                                  Returns all claims from the id_token if available.

                                  -
                                  handleRedirectCallback: (url?: string) => Promise<RedirectLoginResult<any>>

                                  After the browser redirects back to the callback page, +

                                  handleRedirectCallback: (
                                      url?: string,
                                  ) => Promise<ConnectAccountRedirectResult | RedirectLoginResult<any>>

                                  After the browser redirects back to the callback page, call handleRedirectCallback to handle success and error responses from Auth0. If the response is successful, results will be valid according to their expiration times.

                                  -

                                  Type Declaration

                                  isAuthenticated: boolean
                                  isLoading: boolean
                                  loginWithPopup: (
                                      options?: PopupLoginOptions,
                                      config?: PopupConfigOptions,
                                  ) => Promise<void>
                                  await loginWithPopup(options, config);
                                  +

                                  Type Declaration

                                  isAuthenticated: boolean
                                  isLoading: boolean
                                  loginWithPopup: (
                                      options?: PopupLoginOptions,
                                      config?: PopupConfigOptions,
                                  ) => Promise<void>
                                  await loginWithPopup(options, config);
                                   

                                  Opens a popup with the /authorize URL using the parameters @@ -91,20 +100,20 @@

                                  IMPORTANT: This method has to be called from an event handler that was started by the user like a button click, for example, otherwise the popup will be blocked in most browsers.

                                  -
                                  loginWithRedirect: (options?: RedirectLoginOptions<AppState>) => Promise<void>
                                  await loginWithRedirect(options);
                                  +
                                  loginWithRedirect: (options?: RedirectLoginOptions<AppState>) => Promise<void>
                                  await loginWithRedirect(options);
                                   

                                  Performs a redirect to /authorize using the parameters provided as arguments. Random and secure state and nonce parameters will be auto-generated.

                                  -
                                  logout: (options?: LogoutOptions) => Promise<void>
                                  auth0.logout({ logoutParams: { returnTo: window.location.origin } });
                                  +
                                  logout: (options?: LogoutOptions) => Promise<void>
                                  auth0.logout({ logoutParams: { returnTo: window.location.origin } });
                                   

                                  Clears the application session and performs a redirect to /v2/logout, using the parameters provided as arguments, to clear the Auth0 session. If the logoutParams.federated option is specified, it also clears the Identity Provider session. Read more about how Logout works at Auth0.

                                  -
                                  setDpopNonce: (nonce: string, id?: string) => Promise<void>

                                  Sets the current DPoP nonce used for making requests to Auth0.

                                  +
                                  setDpopNonce: (nonce: string, id?: string) => Promise<void>

                                  Sets the current DPoP nonce used for making requests to Auth0.

                                  It requires enabling the Auth0ClientOptions.useDpop option.

                                  Type Declaration

                                  user: undefined | TUser
                                  +
                                  user: undefined | TUser
                                  diff --git a/docs/interfaces/Auth0ProviderOptions.html b/docs/interfaces/Auth0ProviderOptions.html index 8351ab7b..6d8e64fc 100644 --- a/docs/interfaces/Auth0ProviderOptions.html +++ b/docs/interfaces/Auth0ProviderOptions.html @@ -1,5 +1,5 @@ Auth0ProviderOptions | @auth0/auth0-react
                                  @auth0/auth0-react
                                    Preparing search index...

                                    Interface Auth0ProviderOptions<TUser>

                                    The main configuration to instantiate the Auth0Provider.

                                    -
                                    interface Auth0ProviderOptions<TUser extends User = User> {
                                        auth0Client?: {
                                            env?: { [key: string]: string };
                                            name: string;
                                            version: string;
                                        };
                                        authorizationParams?: AuthorizationParams;
                                        authorizeTimeoutInSeconds?: number;
                                        cache?: ICache;
                                        cacheLocation?: CacheLocation;
                                        children?: ReactNode;
                                        clientId: string;
                                        context?: Context<Auth0ContextInterface<TUser>>;
                                        cookieDomain?: string;
                                        domain: string;
                                        httpTimeoutInSeconds?: number;
                                        issuer?: string;
                                        leeway?: number;
                                        legacySameSiteCookie?: boolean;
                                        nowProvider?: () => number | Promise<number>;
                                        onRedirectCallback?: (appState?: AppState, user?: TUser) => void;
                                        sessionCheckExpiryDays?: number;
                                        skipRedirectCallback?: boolean;
                                        useCookiesForTransactions?: boolean;
                                        useDpop?: boolean;
                                        useFormData?: boolean;
                                        useRefreshTokens?: boolean;
                                        useRefreshTokensFallback?: boolean;
                                        workerUrl?: string;
                                    }

                                    Type Parameters

                                    Hierarchy

                                    • Auth0ClientOptions
                                      • Auth0ProviderOptions
                                    Index

                                    Properties

                                    interface Auth0ProviderOptions<TUser extends User = User> {
                                        auth0Client?: {
                                            env?: { [key: string]: string };
                                            name: string;
                                            version: string;
                                        };
                                        authorizationParams?: AuthorizationParams;
                                        authorizeTimeoutInSeconds?: number;
                                        cache?: ICache;
                                        cacheLocation?: CacheLocation;
                                        children?: ReactNode;
                                        clientId: string;
                                        context?: Context<Auth0ContextInterface<TUser>>;
                                        cookieDomain?: string;
                                        domain: string;
                                        httpTimeoutInSeconds?: number;
                                        issuer?: string;
                                        leeway?: number;
                                        legacySameSiteCookie?: boolean;
                                        nowProvider?: () => number | Promise<number>;
                                        onRedirectCallback?: (appState?: AppState, user?: TUser) => void;
                                        sessionCheckExpiryDays?: number;
                                        skipRedirectCallback?: boolean;
                                        useCookiesForTransactions?: boolean;
                                        useDpop?: boolean;
                                        useFormData?: boolean;
                                        useMrrt?: boolean;
                                        useRefreshTokens?: boolean;
                                        useRefreshTokensFallback?: boolean;
                                        workerUrl?: string;
                                    }

                                    Type Parameters

                                    Hierarchy

                                    • Auth0ClientOptions
                                      • Auth0ProviderOptions
                                    Index

                                    Properties

                                    auth0Client?: { env?: { [key: string]: string }; name: string; version: string }

                                    Internal property to send information about the client to the authorization server.

                                    -
                                    authorizationParams?: AuthorizationParams

                                    URL parameters that will be sent back to the Authorization Server. This can be known parameters +

                                    authorizationParams?: AuthorizationParams

                                    URL parameters that will be sent back to the Authorization Server. This can be known parameters defined by Auth0 or custom parameters that you define.

                                    -
                                    authorizeTimeoutInSeconds?: number

                                    A maximum number of seconds to wait before declaring background calls to /authorize as failed for timeout +

                                    authorizeTimeoutInSeconds?: number

                                    A maximum number of seconds to wait before declaring background calls to /authorize as failed for timeout Defaults to 60s.

                                    -
                                    cache?: ICache

                                    Specify a custom cache implementation to use for token storage and retrieval. This setting takes precedence over cacheLocation if they are both specified.

                                    -
                                    cacheLocation?: CacheLocation

                                    The location to use when storing cache data. Valid values are memory or localstorage. +

                                    cache?: ICache

                                    Specify a custom cache implementation to use for token storage and retrieval. This setting takes precedence over cacheLocation if they are both specified.

                                    +
                                    cacheLocation?: CacheLocation

                                    The location to use when storing cache data. Valid values are memory or localstorage. The default setting is memory.

                                    Read more about changing storage options in the Auth0 docs

                                    -
                                    children?: ReactNode

                                    The child nodes your Provider has wrapped

                                    -
                                    clientId: string

                                    The Client ID found on your Application settings page

                                    -
                                    context?: Context<Auth0ContextInterface<TUser>>

                                    Context to be used when creating the Auth0Provider, defaults to the internally created context.

                                    +
                                    children?: ReactNode

                                    The child nodes your Provider has wrapped

                                    +
                                    clientId: string

                                    The Client ID found on your Application settings page

                                    +
                                    context?: Context<Auth0ContextInterface<TUser>>

                                    Context to be used when creating the Auth0Provider, defaults to the internally created context.

                                    This allows multiple Auth0Providers to be nested within the same application, the context value can then be passed to useAuth0, withAuth0, or withAuthenticationRequired to use that specific Auth0Provider to access auth state and methods specifically tied to the provider that the context belongs to.

                                    @@ -47,55 +48,56 @@ used to store data is different

                                    For a sample on using multiple Auth0Providers review the React Account Linking Sample

                                    -
                                    cookieDomain?: string

                                    The domain the cookie is accessible from. If not set, the cookie is scoped to +

                                    cookieDomain?: string

                                    The domain the cookie is accessible from. If not set, the cookie is scoped to the current domain, including the subdomain.

                                    Note: setting this incorrectly may cause silent authentication to stop working on page load.

                                    To keep a user logged in across multiple subdomains set this to your top-level domain and prefixed with a . (eg: .example.com).

                                    -
                                    domain: string

                                    Your Auth0 account domain such as 'example.auth0.com', +

                                    domain: string

                                    Your Auth0 account domain such as 'example.auth0.com', 'example.eu.auth0.com' or , 'example.mycompany.com' (when using custom domains)

                                    -
                                    httpTimeoutInSeconds?: number

                                    Specify the timeout for HTTP calls using fetch. The default is 10 seconds.

                                    -
                                    issuer?: string

                                    The issuer to be used for validation of JWTs, optionally defaults to the domain above

                                    -
                                    leeway?: number

                                    The value in seconds used to account for clock skew in JWT expirations. +

                                    httpTimeoutInSeconds?: number

                                    Specify the timeout for HTTP calls using fetch. The default is 10 seconds.

                                    +
                                    issuer?: string

                                    The issuer to be used for validation of JWTs, optionally defaults to the domain above

                                    +
                                    leeway?: number

                                    The value in seconds used to account for clock skew in JWT expirations. Typically, this value is no more than a minute or two at maximum. Defaults to 60s.

                                    -
                                    legacySameSiteCookie?: boolean

                                    Sets an additional cookie with no SameSite attribute to support legacy browsers +

                                    legacySameSiteCookie?: boolean

                                    Sets an additional cookie with no SameSite attribute to support legacy browsers that are not compatible with the latest SameSite changes. This will log a warning on modern browsers, you can disable the warning by setting this to false but be aware that some older useragents will not work, See https://www.chromium.org/updates/same-site/incompatible-clients Defaults to true

                                    -
                                    nowProvider?: () => number | Promise<number>

                                    Modify the value used as the current time during the token validation.

                                    +
                                    nowProvider?: () => number | Promise<number>

                                    Modify the value used as the current time during the token validation.

                                    Note: Using this improperly can potentially compromise the token validation.

                                    -
                                    onRedirectCallback?: (appState?: AppState, user?: TUser) => void

                                    By default this removes the code and state parameters from the url when you are redirected from the authorize page. +

                                    onRedirectCallback?: (appState?: AppState, user?: TUser) => void

                                    By default this removes the code and state parameters from the url when you are redirected from the authorize page. It uses window.history but you might want to overwrite this if you are using a custom router, like react-router-dom See the EXAMPLES.md for more info.

                                    -
                                    sessionCheckExpiryDays?: number

                                    Number of days until the cookie auth0.is.authenticated will expire +

                                    sessionCheckExpiryDays?: number

                                    Number of days until the cookie auth0.is.authenticated will expire Defaults to 1.

                                    -
                                    skipRedirectCallback?: boolean

                                    By default, if the page url has code/state params, the SDK will treat them as Auth0's and attempt to exchange the +

                                    skipRedirectCallback?: boolean

                                    By default, if the page url has code/state params, the SDK will treat them as Auth0's and attempt to exchange the code for a token. In some cases the code might be for something else (another OAuth SDK perhaps). In these instances you can instruct the client to ignore them eg

                                    <Auth0Provider
                                    clientId={clientId}
                                    domain={domain}
                                    skipRedirectCallback={window.location.pathname === '/stripe-oauth-callback'}
                                    >
                                    -
                                    useCookiesForTransactions?: boolean

                                    If true, the SDK will use a cookie when storing information about the auth transaction while +

                                    useCookiesForTransactions?: boolean

                                    If true, the SDK will use a cookie when storing information about the auth transaction while the user is going through the authentication flow on the authorization server.

                                    The default is false, in which case the SDK will use session storage.

                                    You might want to enable this if you rely on your users being able to authenticate using flows that may end up spanning across multiple tabs (e.g. magic links) or you cannot otherwise rely on session storage being available.

                                    -
                                    useDpop?: boolean

                                    If true, DPoP (OAuth 2.0 Demonstrating Proof of Possession, RFC9449) +

                                    useDpop?: boolean

                                    If true, DPoP (OAuth 2.0 Demonstrating Proof of Possession, RFC9449) will be used to cryptographically bind tokens to this specific browser so they can't be used from a different device in case of a leak.

                                    The default setting is false.

                                    -
                                    useFormData?: boolean

                                    If true, data to the token endpoint is transmitted as x-www-form-urlencoded data, if false it will be transmitted as JSON. The default setting is true.

                                    +
                                    useFormData?: boolean

                                    If true, data to the token endpoint is transmitted as x-www-form-urlencoded data, if false it will be transmitted as JSON. The default setting is true.

                                    Note: Setting this to false may affect you if you use Auth0 Rules and are sending custom, non-primitive data. If you disable this, please verify that your Auth0 Rules continue to work as intended.

                                    -
                                    useRefreshTokens?: boolean

                                    If true, refresh tokens are used to fetch new access tokens from the Auth0 server. If false, the legacy technique of using a hidden iframe and the authorization_code grant with prompt=none is used. +

                                    useMrrt?: boolean

                                    If true, the SDK will allow the refreshing of tokens using MRRT

                                    +
                                    useRefreshTokens?: boolean

                                    If true, refresh tokens are used to fetch new access tokens from the Auth0 server. If false, the legacy technique of using a hidden iframe and the authorization_code grant with prompt=none is used. The default setting is false.

                                    Note: Use of refresh tokens must be enabled by an administrator on your Auth0 client application.

                                    -
                                    useRefreshTokensFallback?: boolean

                                    If true, fallback to the technique of using a hidden iframe and the authorization_code grant with prompt=none when unable to use refresh tokens. If false, the iframe fallback is not used and +

                                    useRefreshTokensFallback?: boolean

                                    If true, fallback to the technique of using a hidden iframe and the authorization_code grant with prompt=none when unable to use refresh tokens. If false, the iframe fallback is not used and errors relating to a failed refresh_token grant should be handled appropriately. The default setting is false.

                                    Note: There might be situations where doing silent auth with a Web Message response from an iframe is not possible, like when you're serving your application from the file system or a custom protocol (like in a Desktop or Native app). @@ -104,9 +106,9 @@

                                    let token: string;
                                    try {
                                    token = await auth0.getTokenSilently();
                                    } catch (e) {
                                    if (e.error === 'missing_refresh_token' || e.error === 'invalid_grant') {
                                    auth0.loginWithRedirect();
                                    }
                                    }
                                    -
                                    workerUrl?: string

                                    If provided, the SDK will load the token worker from this URL instead of the integrated blob. An example of when this is useful is if you have strict +

                                    workerUrl?: string

                                    If provided, the SDK will load the token worker from this URL instead of the integrated blob. An example of when this is useful is if you have strict Content-Security-Policy (CSP) and wish to avoid needing to set worker-src: blob:. We recommend either serving the worker, which you can find in the module at <module_path>/dist/auth0-spa-js.worker.production.js, from the same host as your application or using the Auth0 CDN https://cdn.auth0.com/js/auth0-spa-js/<version>/auth0-spa-js.worker.production.js.

                                    Note: The worker is only used when useRefreshTokens: true, cacheLocation: 'memory', and the cache is not custom.

                                    -
                                    +
                                    diff --git a/docs/interfaces/AuthorizationParams.html b/docs/interfaces/AuthorizationParams.html index 28270848..4a049f09 100644 --- a/docs/interfaces/AuthorizationParams.html +++ b/docs/interfaces/AuthorizationParams.html @@ -1,6 +1,6 @@ AuthorizationParams | @auth0/auth0-react
                                    @auth0/auth0-react
                                      Preparing search index...

                                      Interface AuthorizationParams

                                      interface AuthorizationParams {
                                          acr_values?: string;
                                          audience?: string;
                                          connection?: string;
                                          display?: "page" | "popup" | "touch" | "wap";
                                          id_token_hint?: string;
                                          invitation?: string;
                                          login_hint?: string;
                                          max_age?: string | number;
                                          organization?: string;
                                          prompt?: "none" | "login" | "consent" | "select_account";
                                          redirect_uri?: string;
                                          scope?: string;
                                          screen_hint?: string;
                                          ui_locales?: string;
                                          [key: string]: any;
                                      }

                                      Indexable

                                      • [key: string]: any

                                        If you need to send custom parameters to the Authorization Server, make sure to use the original parameter name.

                                        -
                                      Index

                                      Properties

                                      Index

                                      Properties

                                      acr_values?: string
                                      audience?: string

                                      The default audience to be used for requesting API access.

                                      -
                                      connection?: string

                                      The name of the connection configured for your application. +

                                      Properties

                                      acr_values?: string
                                      audience?: string

                                      The default audience to be used for requesting API access.

                                      +
                                      connection?: string

                                      The name of the connection configured for your application. If null, it will redirect to the Auth0 Login Page and show the Login Widget.

                                      -
                                      display?: "page" | "popup" | "touch" | "wap"
                                        +
                                      display?: "page" | "popup" | "touch" | "wap"
                                      • 'page': displays the UI with a full page view
                                      • 'popup': displays the UI with a popup window
                                      • 'touch': displays the UI in a way that leverages a touch interface
                                      • 'wap': displays the UI with a "feature phone" type interface
                                      -
                                      id_token_hint?: string

                                      Previously issued ID Token.

                                      -
                                      invitation?: string

                                      The Id of an invitation to accept. This is available from the user invitation URL that is given when participating in a user invitation flow.

                                      -
                                      login_hint?: string

                                      The user's email address or other identifier. When your app knows +

                                      id_token_hint?: string

                                      Previously issued ID Token.

                                      +
                                      invitation?: string

                                      The Id of an invitation to accept. This is available from the user invitation URL that is given when participating in a user invitation flow.

                                      +
                                      login_hint?: string

                                      The user's email address or other identifier. When your app knows which user is trying to authenticate, you can provide this parameter to pre-fill the email box or select the right session for sign-in.

                                      This currently only affects the classic Lock experience.

                                      -
                                      max_age?: string | number

                                      Maximum allowable elapsed time (in seconds) since authentication. +

                                      max_age?: string | number

                                      Maximum allowable elapsed time (in seconds) since authentication. If the last time the user authenticated is greater than this value, the user must be reauthenticated.

                                      -
                                      organization?: string

                                      The organization to log in to.

                                      +
                                      organization?: string

                                      The organization to log in to.

                                      This will specify an organization parameter in your user's login request.

                                      • If you provide an Organization ID (a string with the prefix org_), it will be validated against the org_id claim of your user's ID Token. The validation is case-sensitive.
                                      • @@ -41,25 +41,25 @@ To use an Organization Name you must have "Allow Organization Names in Authentication API" switched on in your Auth0 settings dashboard. More information is available on the Auth0 documentation portal
                                      -
                                      prompt?: "none" | "login" | "consent" | "select_account"
                                        +
                                      prompt?: "none" | "login" | "consent" | "select_account"
                                      • 'none': do not prompt user for login or consent on reauthentication
                                      • 'login': prompt user for reauthentication
                                      • 'consent': prompt user for consent before processing request
                                      • 'select_account': prompt user to select an account
                                      -
                                      redirect_uri?: string

                                      The default URL where Auth0 will redirect your browser to with +

                                      redirect_uri?: string

                                      The default URL where Auth0 will redirect your browser to with the authentication result. It must be whitelisted in the "Allowed Callback URLs" field in your Auth0 Application's settings. If not provided here, it should be provided in the other methods that provide authentication.

                                      -
                                      scope?: string

                                      The default scope to be used on authentication requests.

                                      +
                                      scope?: string

                                      The default scope to be used on authentication requests.

                                      This defaults to profile email if not set. If you are setting extra scopes and require profile and email to be included then you must include them in the provided scope.

                                      Note: The openid scope is always applied regardless of this setting.

                                      -
                                      screen_hint?: string

                                      Provides a hint to Auth0 as to what flow should be displayed. +

                                      screen_hint?: string

                                      Provides a hint to Auth0 as to what flow should be displayed. The default behavior is to show a login page but you can override this by passing 'signup' to show the signup page instead.

                                      This only affects the New Universal Login Experience.

                                      -
                                      ui_locales?: string

                                      The space-separated list of language tags, ordered by preference. +

                                      ui_locales?: string

                                      The space-separated list of language tags, ordered by preference. For example: 'fr-CA fr en'.

                                      -
                                      +
                                      diff --git a/docs/interfaces/GetTokenSilentlyOptions.html b/docs/interfaces/GetTokenSilentlyOptions.html index f144b6b8..274d1153 100644 --- a/docs/interfaces/GetTokenSilentlyOptions.html +++ b/docs/interfaces/GetTokenSilentlyOptions.html @@ -1,4 +1,4 @@ -GetTokenSilentlyOptions | @auth0/auth0-react
                                      @auth0/auth0-react
                                        Preparing search index...

                                        Interface GetTokenSilentlyOptions

                                        interface GetTokenSilentlyOptions {
                                            authorizationParams?: {
                                                audience?: string;
                                                redirect_uri?: string;
                                                scope?: string;
                                                [key: string]: any;
                                            };
                                            cacheMode?: "on"
                                            | "off"
                                            | "cache-only";
                                            detailedResponse?: boolean;
                                            timeoutInSeconds?: number;
                                        }
                                        Index

                                        Properties

                                        authorizationParams? +GetTokenSilentlyOptions | @auth0/auth0-react
                                        @auth0/auth0-react
                                          Preparing search index...

                                          Interface GetTokenSilentlyOptions

                                          interface GetTokenSilentlyOptions {
                                              authorizationParams?: {
                                                  audience?: string;
                                                  redirect_uri?: string;
                                                  scope?: string;
                                                  [key: string]: any;
                                              };
                                              cacheMode?: "on"
                                              | "off"
                                              | "cache-only";
                                              detailedResponse?: boolean;
                                              timeoutInSeconds?: number;
                                          }
                                          Index

                                          Properties

                                          authorizationParams? cacheMode? detailedResponse? timeoutInSeconds? @@ -13,13 +13,13 @@ It must be whitelisted in the "Allowed Web Origins" in your Auth0 Application's settings.

                                        • Optionalscope?: string

                                          The scope that was used in the authentication request

                                          -
                                        • cacheMode?: "on" | "off" | "cache-only"

                                          When off, ignores the cache and always sends a +

                                          cacheMode?: "on" | "off" | "cache-only"

                                          When off, ignores the cache and always sends a request to Auth0. When cache-only, only reads from the cache and never sends a request to Auth0. Defaults to on, where it both reads from the cache and sends a request to Auth0 as needed.

                                          -
                                          detailedResponse?: boolean

                                          If true, the full response from the /oauth/token endpoint (or the cache, if the cache was used) is returned +

                                          detailedResponse?: boolean

                                          If true, the full response from the /oauth/token endpoint (or the cache, if the cache was used) is returned (minus refresh_token if one was issued). Otherwise, just the access token is returned.

                                          The default is false.

                                          -
                                          timeoutInSeconds?: number

                                          A maximum number of seconds to wait before declaring the background /authorize call as failed for timeout +

                                          timeoutInSeconds?: number

                                          A maximum number of seconds to wait before declaring the background /authorize call as failed for timeout Defaults to 60s.

                                          -
                                          +
                                          diff --git a/docs/interfaces/GetTokenWithPopupOptions.html b/docs/interfaces/GetTokenWithPopupOptions.html index d9e67880..61b92c0f 100644 --- a/docs/interfaces/GetTokenWithPopupOptions.html +++ b/docs/interfaces/GetTokenWithPopupOptions.html @@ -1,8 +1,8 @@ -GetTokenWithPopupOptions | @auth0/auth0-react
                                          @auth0/auth0-react
                                            Preparing search index...

                                            Interface GetTokenWithPopupOptions

                                            interface GetTokenWithPopupOptions {
                                                authorizationParams?: AuthorizationParams;
                                                cacheMode?: "on" | "off" | "cache-only";
                                            }

                                            Hierarchy (View Summary)

                                            Index

                                            Properties

                                            authorizationParams? +GetTokenWithPopupOptions | @auth0/auth0-react
                                            @auth0/auth0-react
                                              Preparing search index...

                                              Interface GetTokenWithPopupOptions

                                              interface GetTokenWithPopupOptions {
                                                  authorizationParams?: AuthorizationParams;
                                                  cacheMode?: "on" | "off" | "cache-only";
                                              }

                                              Hierarchy (View Summary)

                                              Index

                                              Properties

                                              authorizationParams?: AuthorizationParams

                                              URL parameters that will be sent back to the Authorization Server. This can be known parameters defined by Auth0 or custom parameters that you define.

                                              -
                                              cacheMode?: "on" | "off" | "cache-only"

                                              When off, ignores the cache and always sends a request to Auth0. +

                                              cacheMode?: "on" | "off" | "cache-only"

                                              When off, ignores the cache and always sends a request to Auth0. When cache-only, only reads from the cache and never sends a request to Auth0. Defaults to on, where it both reads from the cache and sends a request to Auth0 as needed.

                                              -
                                              +
                                              diff --git a/docs/interfaces/IdToken.html b/docs/interfaces/IdToken.html index ff027416..aad5d7d4 100644 --- a/docs/interfaces/IdToken.html +++ b/docs/interfaces/IdToken.html @@ -1,4 +1,4 @@ -IdToken | @auth0/auth0-react
                                              @auth0/auth0-react
                                                Preparing search index...

                                                Interface IdToken

                                                interface IdToken {
                                                    __raw: string;
                                                    acr?: string;
                                                    address?: string;
                                                    amr?: string[];
                                                    at_hash?: string;
                                                    aud?: string;
                                                    auth_time?: string;
                                                    azp?: string;
                                                    birthdate?: string;
                                                    c_hash?: string;
                                                    cnf?: string;
                                                    email?: string;
                                                    email_verified?: boolean;
                                                    exp?: number;
                                                    family_name?: string;
                                                    gender?: string;
                                                    given_name?: string;
                                                    iat?: number;
                                                    iss?: string;
                                                    jti?: string;
                                                    locale?: string;
                                                    middle_name?: string;
                                                    name?: string;
                                                    nbf?: number;
                                                    nickname?: string;
                                                    nonce?: string;
                                                    org_id?: string;
                                                    org_name?: string;
                                                    phone_number?: string;
                                                    phone_number_verified?: boolean;
                                                    picture?: string;
                                                    preferred_username?: string;
                                                    profile?: string;
                                                    sid?: string;
                                                    sub_jwk?: string;
                                                    updated_at?: string;
                                                    website?: string;
                                                    zoneinfo?: string;
                                                    [key: string]: any;
                                                }

                                                Indexable

                                                • [key: string]: any
                                                Index

                                                Properties

                                                __raw +IdToken | @auth0/auth0-react
                                                @auth0/auth0-react
                                                  Preparing search index...

                                                  Interface IdToken

                                                  interface IdToken {
                                                      __raw: string;
                                                      acr?: string;
                                                      address?: string;
                                                      amr?: string[];
                                                      at_hash?: string;
                                                      aud?: string;
                                                      auth_time?: string;
                                                      azp?: string;
                                                      birthdate?: string;
                                                      c_hash?: string;
                                                      cnf?: string;
                                                      email?: string;
                                                      email_verified?: boolean;
                                                      exp?: number;
                                                      family_name?: string;
                                                      gender?: string;
                                                      given_name?: string;
                                                      iat?: number;
                                                      iss?: string;
                                                      jti?: string;
                                                      locale?: string;
                                                      middle_name?: string;
                                                      name?: string;
                                                      nbf?: number;
                                                      nickname?: string;
                                                      nonce?: string;
                                                      org_id?: string;
                                                      org_name?: string;
                                                      phone_number?: string;
                                                      phone_number_verified?: boolean;
                                                      picture?: string;
                                                      preferred_username?: string;
                                                      profile?: string;
                                                      sid?: string;
                                                      sub_jwk?: string;
                                                      updated_at?: string;
                                                      website?: string;
                                                      zoneinfo?: string;
                                                      [key: string]: any;
                                                  }

                                                  Indexable

                                                  • [key: string]: any
                                                  Index

                                                  Properties

                                                  Properties

                                                  __raw: string
                                                  acr?: string
                                                  address?: string
                                                  amr?: string[]
                                                  at_hash?: string
                                                  aud?: string
                                                  auth_time?: string
                                                  azp?: string
                                                  birthdate?: string
                                                  c_hash?: string
                                                  cnf?: string
                                                  email?: string
                                                  email_verified?: boolean
                                                  exp?: number
                                                  family_name?: string
                                                  gender?: string
                                                  given_name?: string
                                                  iat?: number
                                                  iss?: string
                                                  jti?: string
                                                  locale?: string
                                                  middle_name?: string
                                                  name?: string
                                                  nbf?: number
                                                  nickname?: string
                                                  nonce?: string
                                                  org_id?: string
                                                  org_name?: string
                                                  phone_number?: string
                                                  phone_number_verified?: boolean
                                                  picture?: string
                                                  preferred_username?: string
                                                  profile?: string
                                                  sid?: string
                                                  sub_jwk?: string
                                                  updated_at?: string
                                                  website?: string
                                                  zoneinfo?: string
                                                  +

                                                  Properties

                                                  __raw: string
                                                  acr?: string
                                                  address?: string
                                                  amr?: string[]
                                                  at_hash?: string
                                                  aud?: string
                                                  auth_time?: string
                                                  azp?: string
                                                  birthdate?: string
                                                  c_hash?: string
                                                  cnf?: string
                                                  email?: string
                                                  email_verified?: boolean
                                                  exp?: number
                                                  family_name?: string
                                                  gender?: string
                                                  given_name?: string
                                                  iat?: number
                                                  iss?: string
                                                  jti?: string
                                                  locale?: string
                                                  middle_name?: string
                                                  name?: string
                                                  nbf?: number
                                                  nickname?: string
                                                  nonce?: string
                                                  org_id?: string
                                                  org_name?: string
                                                  phone_number?: string
                                                  phone_number_verified?: boolean
                                                  picture?: string
                                                  preferred_username?: string
                                                  profile?: string
                                                  sid?: string
                                                  sub_jwk?: string
                                                  updated_at?: string
                                                  website?: string
                                                  zoneinfo?: string
                                                  diff --git a/docs/interfaces/LogoutOptions.html b/docs/interfaces/LogoutOptions.html index 4baced9c..44cbc0d9 100644 --- a/docs/interfaces/LogoutOptions.html +++ b/docs/interfaces/LogoutOptions.html @@ -1,11 +1,11 @@ -LogoutOptions | @auth0/auth0-react
                                                  @auth0/auth0-react
                                                    Preparing search index...

                                                    Interface LogoutOptions

                                                    interface LogoutOptions {
                                                        clientId?: null | string;
                                                        logoutParams?: {
                                                            federated?: boolean;
                                                            returnTo?: string;
                                                            [key: string]: any;
                                                        };
                                                        openUrl?: false
                                                        | ((url: string) => void | Promise<void>);
                                                    }

                                                    Hierarchy

                                                    • Omit<SPALogoutOptions, "onRedirect">
                                                      • LogoutOptions
                                                    Index

                                                    Properties

                                                    clientId? +LogoutOptions | @auth0/auth0-react
                                                    @auth0/auth0-react
                                                      Preparing search index...

                                                      Interface LogoutOptions

                                                      interface LogoutOptions {
                                                          clientId?: null | string;
                                                          logoutParams?: {
                                                              federated?: boolean;
                                                              returnTo?: string;
                                                              [key: string]: any;
                                                          };
                                                          openUrl?: false
                                                          | ((url: string) => void | Promise<void>);
                                                      }

                                                      Hierarchy

                                                      • Omit<SPALogoutOptions, "onRedirect">
                                                        • LogoutOptions
                                                      Index

                                                      Properties

                                                      clientId?: null | string

                                                      The clientId of your application.

                                                      If this property is not set, then the clientId that was used during initialization of the SDK is sent to the logout endpoint.

                                                      If this property is set to null, then no client ID value is sent to the logout endpoint.

                                                      Read more about how redirecting after logout works

                                                      -
                                                      logoutParams?: { federated?: boolean; returnTo?: string; [key: string]: any }

                                                      Parameters to pass to the logout endpoint. This can be known parameters defined by Auth0 or custom parameters +

                                                      logoutParams?: { federated?: boolean; returnTo?: string; [key: string]: any }

                                                      Parameters to pass to the logout endpoint. This can be known parameters defined by Auth0 or custom parameters you wish to provide.

                                                      Type Declaration

                                                      • [key: string]: any

                                                        If you need to send custom parameters to the logout endpoint, make sure to use the original parameter name.

                                                      • Optionalfederated?: boolean

                                                        When supported by the upstream identity provider, @@ -20,7 +20,7 @@ returnTo URL must be listed in the "Allowed Logout URLs" at the account level in the Auth0 dashboard.

                                                        Read more about how redirecting after logout works

                                                        -
                                                      openUrl?: false | ((url: string) => void | Promise<void>)

                                                      Used to control the redirect and not rely on the SDK to do the actual redirect.

                                                      +
                                                      openUrl?: false | ((url: string) => void | Promise<void>)

                                                      Used to control the redirect and not rely on the SDK to do the actual redirect.

                                                      Set to false to disable the redirect, or provide a function to handle the actual redirect yourself.

                                                      await auth0.logout({
                                                      openUrl(url) {
                                                      window.location.replace(url);
                                                      }
                                                      });
                                                      @@ -28,4 +28,4 @@
                                                      import { Browser } from '@capacitor/browser';

                                                      await auth0.logout({
                                                      async openUrl(url) {
                                                      await Browser.open({ url });
                                                      }
                                                      });
                                                      -
                                                      +
                                                      diff --git a/docs/interfaces/LogoutUrlOptions.html b/docs/interfaces/LogoutUrlOptions.html index 39026df6..cbae6d21 100644 --- a/docs/interfaces/LogoutUrlOptions.html +++ b/docs/interfaces/LogoutUrlOptions.html @@ -1,10 +1,10 @@ -LogoutUrlOptions | @auth0/auth0-react
                                                      @auth0/auth0-react
                                                        Preparing search index...

                                                        Interface LogoutUrlOptions

                                                        interface LogoutUrlOptions {
                                                            clientId?: null | string;
                                                            logoutParams?: {
                                                                federated?: boolean;
                                                                returnTo?: string;
                                                                [key: string]: any;
                                                            };
                                                        }
                                                        Index

                                                        Properties

                                                        clientId? +LogoutUrlOptions | @auth0/auth0-react
                                                        @auth0/auth0-react
                                                          Preparing search index...

                                                          Interface LogoutUrlOptions

                                                          interface LogoutUrlOptions {
                                                              clientId?: null | string;
                                                              logoutParams?: {
                                                                  federated?: boolean;
                                                                  returnTo?: string;
                                                                  [key: string]: any;
                                                              };
                                                          }
                                                          Index

                                                          Properties

                                                          clientId?: null | string

                                                          The clientId of your application.

                                                          If this property is not set, then the clientId that was used during initialization of the SDK is sent to the logout endpoint.

                                                          If this property is set to null, then no client ID value is sent to the logout endpoint.

                                                          Read more about how redirecting after logout works

                                                          -
                                                          logoutParams?: { federated?: boolean; returnTo?: string; [key: string]: any }

                                                          Parameters to pass to the logout endpoint. This can be known parameters defined by Auth0 or custom parameters +

                                                          logoutParams?: { federated?: boolean; returnTo?: string; [key: string]: any }

                                                          Parameters to pass to the logout endpoint. This can be known parameters defined by Auth0 or custom parameters you wish to provide.

                                                          Type Declaration

                                                          • [key: string]: any

                                                            If you need to send custom parameters to the logout endpoint, make sure to use the original parameter name.

                                                          • Optionalfederated?: boolean

                                                            When supported by the upstream identity provider, @@ -19,4 +19,4 @@ returnTo URL must be listed in the "Allowed Logout URLs" at the account level in the Auth0 dashboard.

                                                            Read more about how redirecting after logout works

                                                            -
                                                          +
                                                          diff --git a/docs/interfaces/PopupConfigOptions.html b/docs/interfaces/PopupConfigOptions.html index 8ef191bb..41ad642e 100644 --- a/docs/interfaces/PopupConfigOptions.html +++ b/docs/interfaces/PopupConfigOptions.html @@ -1,8 +1,8 @@ -PopupConfigOptions | @auth0/auth0-react
                                                          @auth0/auth0-react
                                                            Preparing search index...

                                                            Interface PopupConfigOptions

                                                            interface PopupConfigOptions {
                                                                popup?: any;
                                                                timeoutInSeconds?: number;
                                                            }
                                                            Index

                                                            Properties

                                                            popup? +PopupConfigOptions | @auth0/auth0-react
                                                            @auth0/auth0-react
                                                              Preparing search index...

                                                              Interface PopupConfigOptions

                                                              interface PopupConfigOptions {
                                                                  popup?: any;
                                                                  timeoutInSeconds?: number;
                                                              }
                                                              Index

                                                              Properties

                                                              popup?: any

                                                              Accepts an already-created popup window to use. If not specified, the SDK will create its own. This may be useful for platforms like iOS that have security restrictions around when popups can be invoked (e.g. from a user click event)

                                                              -
                                                              timeoutInSeconds?: number

                                                              The number of seconds to wait for a popup response before +

                                                              timeoutInSeconds?: number

                                                              The number of seconds to wait for a popup response before throwing a timeout error. Defaults to 60s

                                                              -
                                                              +
                                                              diff --git a/docs/interfaces/PopupLoginOptions.html b/docs/interfaces/PopupLoginOptions.html index 56730be5..afc82362 100644 --- a/docs/interfaces/PopupLoginOptions.html +++ b/docs/interfaces/PopupLoginOptions.html @@ -1,4 +1,4 @@ -PopupLoginOptions | @auth0/auth0-react
                                                              @auth0/auth0-react
                                                                Preparing search index...

                                                                Interface PopupLoginOptions

                                                                interface PopupLoginOptions {
                                                                    authorizationParams?: AuthorizationParams;
                                                                }

                                                                Hierarchy (View Summary)

                                                                Index

                                                                Properties

                                                                authorizationParams? +PopupLoginOptions | @auth0/auth0-react
                                                                @auth0/auth0-react
                                                                  Preparing search index...

                                                                  Interface PopupLoginOptions

                                                                  interface PopupLoginOptions {
                                                                      authorizationParams?: AuthorizationParams;
                                                                  }

                                                                  Hierarchy (View Summary)

                                                                  Index

                                                                  Properties

                                                                  authorizationParams?: AuthorizationParams

                                                                  URL parameters that will be sent back to the Authorization Server. This can be known parameters defined by Auth0 or custom parameters that you define.

                                                                  -
                                                                  +
                                                                  diff --git a/docs/interfaces/RedirectConnectAccountOptions.html b/docs/interfaces/RedirectConnectAccountOptions.html new file mode 100644 index 00000000..c137b699 --- /dev/null +++ b/docs/interfaces/RedirectConnectAccountOptions.html @@ -0,0 +1,23 @@ +RedirectConnectAccountOptions | @auth0/auth0-react
                                                                  @auth0/auth0-react
                                                                    Preparing search index...

                                                                    Interface RedirectConnectAccountOptions<TAppState>

                                                                    interface RedirectConnectAccountOptions<TAppState = any> {
                                                                        appState?: TAppState;
                                                                        authorization_params?: AuthorizationParams;
                                                                        connection: string;
                                                                        openUrl?: (url: string) => Promise<void>;
                                                                        redirectUri?: string;
                                                                    }

                                                                    Type Parameters

                                                                    • TAppState = any
                                                                    Index

                                                                    Properties

                                                                    appState?: TAppState

                                                                    Optional application state to persist through the transaction.

                                                                    +
                                                                    await auth0.connectAccountWithRedirect({
                                                                    connection: 'google-oauth2',
                                                                    appState: { returnTo: '/settings' }
                                                                    }); +
                                                                    + +
                                                                    authorization_params?: AuthorizationParams

                                                                    Additional authorization parameters for the request.

                                                                    +
                                                                    await auth0.connectAccountWithRedirect({
                                                                    connection: 'google-oauth2',
                                                                    authorization_params: {
                                                                    scope: 'https://www.googleapis.com/auth/calendar'
                                                                    access_type: 'offline'
                                                                    }
                                                                    }); +
                                                                    + +
                                                                    await auth0.connectAccountWithRedirect({
                                                                    connection: 'github',
                                                                    authorization_params: {
                                                                    scope: 'repo user',
                                                                    audience: 'https://api.github.com'
                                                                    }
                                                                    }); +
                                                                    + +
                                                                    connection: string

                                                                    The name of the connection to link (e.g. 'google-oauth2').

                                                                    +
                                                                    openUrl?: (url: string) => Promise<void>

                                                                    Optional function to handle the redirect URL.

                                                                    +
                                                                    await auth0.connectAccountWithRedirect({
                                                                    connection: 'google-oauth2',
                                                                    openUrl: async (url) => { myBrowserApi.open(url); }
                                                                    }); +
                                                                    + +
                                                                    redirectUri?: string

                                                                    The URI to redirect back to after connecting the account.

                                                                    +
                                                                    diff --git a/docs/interfaces/RedirectLoginOptions.html b/docs/interfaces/RedirectLoginOptions.html index a7410a91..6d6d3d60 100644 --- a/docs/interfaces/RedirectLoginOptions.html +++ b/docs/interfaces/RedirectLoginOptions.html @@ -1,16 +1,16 @@ -RedirectLoginOptions | @auth0/auth0-react
                                                                    @auth0/auth0-react
                                                                      Preparing search index...

                                                                      Interface RedirectLoginOptions<TAppState>

                                                                      interface RedirectLoginOptions<TAppState = AppState> {
                                                                          appState?: TAppState;
                                                                          authorizationParams?: AuthorizationParams;
                                                                          fragment?: string;
                                                                          openUrl?: (url: string) => void | Promise<void>;
                                                                      }

                                                                      Type Parameters

                                                                      Hierarchy

                                                                      • Omit<SPARedirectLoginOptions<TAppState>, "onRedirect">
                                                                        • RedirectLoginOptions
                                                                      Index

                                                                      Properties

                                                                      appState? +RedirectLoginOptions | @auth0/auth0-react
                                                                      @auth0/auth0-react
                                                                        Preparing search index...

                                                                        Interface RedirectLoginOptions<TAppState>

                                                                        interface RedirectLoginOptions<TAppState = AppState> {
                                                                            appState?: TAppState;
                                                                            authorizationParams?: AuthorizationParams;
                                                                            fragment?: string;
                                                                            openUrl?: (url: string) => void | Promise<void>;
                                                                        }

                                                                        Type Parameters

                                                                        Hierarchy

                                                                        • Omit<SPARedirectLoginOptions<TAppState>, "onRedirect">
                                                                          • RedirectLoginOptions
                                                                        Index

                                                                        Properties

                                                                        appState?: TAppState

                                                                        Used to store state before doing the redirect

                                                                        -
                                                                        authorizationParams?: AuthorizationParams

                                                                        URL parameters that will be sent back to the Authorization Server. This can be known parameters +

                                                                        authorizationParams?: AuthorizationParams

                                                                        URL parameters that will be sent back to the Authorization Server. This can be known parameters defined by Auth0 or custom parameters that you define.

                                                                        -
                                                                        fragment?: string

                                                                        Used to add to the URL fragment before redirecting

                                                                        -
                                                                        openUrl?: (url: string) => void | Promise<void>

                                                                        Used to control the redirect and not rely on the SDK to do the actual redirect.

                                                                        +
                                                                        fragment?: string

                                                                        Used to add to the URL fragment before redirecting

                                                                        +
                                                                        openUrl?: (url: string) => void | Promise<void>

                                                                        Used to control the redirect and not rely on the SDK to do the actual redirect.

                                                                        const client = new Auth0Client({
                                                                        openUrl(url) {
                                                                        window.location.replace(url);
                                                                        }
                                                                        });
                                                                        import { Browser } from '@capacitor/browser';

                                                                        const client = new Auth0Client({
                                                                        async openUrl(url) {
                                                                        await Browser.open({ url });
                                                                        }
                                                                        });
                                                                        -
                                                                        +
                                                                        diff --git a/docs/interfaces/WithAuth0Props.html b/docs/interfaces/WithAuth0Props.html index 4ce06979..9b151084 100644 --- a/docs/interfaces/WithAuth0Props.html +++ b/docs/interfaces/WithAuth0Props.html @@ -1,3 +1,3 @@ WithAuth0Props | @auth0/auth0-react
                                                                        @auth0/auth0-react
                                                                          Preparing search index...

                                                                          Interface WithAuth0Props

                                                                          Components wrapped in withAuth0 will have an additional auth0 prop

                                                                          -
                                                                          interface WithAuth0Props {
                                                                              auth0: Auth0ContextInterface;
                                                                          }
                                                                          Index

                                                                          Properties

                                                                          Properties

                                                                          +
                                                                          interface WithAuth0Props {
                                                                              auth0: Auth0ContextInterface;
                                                                          }
                                                                          Index

                                                                          Properties

                                                                          Properties

                                                                          diff --git a/docs/interfaces/WithAuthenticationRequiredOptions.html b/docs/interfaces/WithAuthenticationRequiredOptions.html index 8c8371c1..fdda885b 100644 --- a/docs/interfaces/WithAuthenticationRequiredOptions.html +++ b/docs/interfaces/WithAuthenticationRequiredOptions.html @@ -1,5 +1,5 @@ WithAuthenticationRequiredOptions | @auth0/auth0-react
                                                                          @auth0/auth0-react
                                                                            Preparing search index...

                                                                            Interface WithAuthenticationRequiredOptions

                                                                            Options for the withAuthenticationRequired Higher Order Component

                                                                            -
                                                                            interface WithAuthenticationRequiredOptions {
                                                                                context?: Context<Auth0ContextInterface<User>>;
                                                                                loginOptions?: RedirectLoginOptions<AppState>;
                                                                                onBeforeAuthentication?: () => Promise<void>;
                                                                                onRedirecting?: () => Element;
                                                                                returnTo?: string | (() => string);
                                                                            }
                                                                            Index

                                                                            Properties

                                                                            interface WithAuthenticationRequiredOptions {
                                                                                context?: Context<Auth0ContextInterface<User>>;
                                                                                loginOptions?: RedirectLoginOptions<AppState>;
                                                                                onBeforeAuthentication?: () => Promise<void>;
                                                                                onRedirecting?: () => Element;
                                                                                returnTo?: string | (() => string);
                                                                            }
                                                                            Index

                                                                            Properties

                                                                            context?: Context<Auth0ContextInterface<User>>

                                                                            The context to be used when calling useAuth0, this should only be provided if you are using multiple Auth0Providers within your application and you wish to tie a specific component to a Auth0Provider other than the Auth0Provider associated with the default Auth0Context.

                                                                            -
                                                                            withAuthenticationRequired(Profile, {
                                                                            loginOptions: {
                                                                            appState: {
                                                                            customProp: 'foo'
                                                                            }
                                                                            }
                                                                            }) +
                                                                            withAuthenticationRequired(Profile, {
                                                                            loginOptions: {
                                                                            appState: {
                                                                            customProp: 'foo'
                                                                            }
                                                                            }
                                                                            })

                                                                            Pass additional login options, like extra appState to the login page. This will be merged with the returnTo option used by the onRedirectCallback handler.

                                                                            -
                                                                            onBeforeAuthentication?: () => Promise<void>
                                                                            withAuthenticationRequired(Profile, {
                                                                            onBeforeAuthentication: () => { analyticsLibrary.track('login_triggered'); }
                                                                            }) +
                                                                            onBeforeAuthentication?: () => Promise<void>
                                                                            withAuthenticationRequired(Profile, {
                                                                            onBeforeAuthentication: () => { analyticsLibrary.track('login_triggered'); }
                                                                            })

                                                                            Allows executing logic before the user is redirected to the login page.

                                                                            -
                                                                            onRedirecting?: () => Element
                                                                            withAuthenticationRequired(Profile, {
                                                                            onRedirecting: () => <div>Redirecting you to the login...</div>
                                                                            }) +
                                                                            onRedirecting?: () => Element
                                                                            withAuthenticationRequired(Profile, {
                                                                            onRedirecting: () => <div>Redirecting you to the login...</div>
                                                                            })

                                                                            Render a message to show that the user is being redirected to the login.

                                                                            -
                                                                            returnTo?: string | (() => string)
                                                                            withAuthenticationRequired(Profile, {
                                                                            returnTo: '/profile'
                                                                            }) +
                                                                            returnTo?: string | (() => string)
                                                                            withAuthenticationRequired(Profile, {
                                                                            returnTo: '/profile'
                                                                            })

                                                                            or

                                                                            @@ -28,4 +28,4 @@

                                                                            Add a path for the onRedirectCallback handler to return the user to after login.

                                                                            -
                                                                            +
                                                                            diff --git a/docs/modules.html b/docs/modules.html index 892db9f4..a691e17b 100644 --- a/docs/modules.html +++ b/docs/modules.html @@ -1 +1 @@ -@auth0/auth0-react
                                                                            @auth0/auth0-react
                                                                              Preparing search index...
                                                                              +@auth0/auth0-react
                                                                              @auth0/auth0-react
                                                                                Preparing search index...
                                                                                diff --git a/docs/types/AppState.html b/docs/types/AppState.html index 02d22179..98d01f42 100644 --- a/docs/types/AppState.html +++ b/docs/types/AppState.html @@ -1,3 +1,6 @@ -AppState | @auth0/auth0-react
                                                                                @auth0/auth0-react
                                                                                  Preparing search index...

                                                                                  Type Alias AppState

                                                                                  The state of the application before the user was redirected to the login page.

                                                                                  -
                                                                                  type AppState = {
                                                                                      returnTo?: string;
                                                                                      [key: string]: any;
                                                                                  }

                                                                                  Indexable

                                                                                  • [key: string]: any
                                                                                  Index

                                                                                  Properties

                                                                                  Properties

                                                                                  returnTo?: string
                                                                                  +AppState | @auth0/auth0-react
                                                                                  @auth0/auth0-react
                                                                                    Preparing search index...

                                                                                    Type Alias AppState

                                                                                    The state of the application before the user was redirected to the login page +and any account that the user may have connected to.

                                                                                    +
                                                                                    type AppState = {
                                                                                        connectedAccount?: ConnectedAccount;
                                                                                        response_type?: ResponseType;
                                                                                        returnTo?: string;
                                                                                        [key: string]: any;
                                                                                    }

                                                                                    Indexable

                                                                                    • [key: string]: any
                                                                                    Index

                                                                                    Properties

                                                                                    connectedAccount?: ConnectedAccount
                                                                                    response_type?: ResponseType
                                                                                    returnTo?: string
                                                                                    diff --git a/docs/types/CacheLocation.html b/docs/types/CacheLocation.html index 831a198d..36fdde33 100644 --- a/docs/types/CacheLocation.html +++ b/docs/types/CacheLocation.html @@ -1,2 +1,2 @@ CacheLocation | @auth0/auth0-react
                                                                                    @auth0/auth0-react
                                                                                      Preparing search index...

                                                                                      Type Alias CacheLocation

                                                                                      CacheLocation: "memory" | "localstorage"

                                                                                      The possible locations where tokens can be stored

                                                                                      -
                                                                                      +
                                                                                      diff --git a/docs/types/ConnectAccountRedirectResult.html b/docs/types/ConnectAccountRedirectResult.html new file mode 100644 index 00000000..99856dd1 --- /dev/null +++ b/docs/types/ConnectAccountRedirectResult.html @@ -0,0 +1,10 @@ +ConnectAccountRedirectResult | @auth0/auth0-react
                                                                                      @auth0/auth0-react
                                                                                        Preparing search index...

                                                                                        Type Alias ConnectAccountRedirectResult<TAppState>

                                                                                        ConnectAccountRedirectResult: CompleteResponse & {
                                                                                            appState?: TAppState;
                                                                                            response_type: ConnectCode;
                                                                                        }

                                                                                        The result returned after a successful account connection redirect.

                                                                                        +

                                                                                        Combines the redirect login result (including any persisted app state) +with the complete response from the My Account API.

                                                                                        +

                                                                                        Type Parameters

                                                                                        • TAppState = any

                                                                                          The type of application state persisted through the transaction.

                                                                                          +

                                                                                        Type Declaration

                                                                                        • OptionalappState?: TAppState

                                                                                          State stored when the redirect request was made

                                                                                          +
                                                                                        • response_type: ConnectCode

                                                                                          The type of response, for connect account it will be connect_code

                                                                                          +
                                                                                        const result = await auth0.connectAccountWithRedirect(options);
                                                                                        console.log(result.appState); // Access persisted app state
                                                                                        console.log(result.connection); // The connection of the account you connected to.
                                                                                        console.log(result.response_type === 'connect_code'); // The response type will be 'connect_code' +
                                                                                        + +
                                                                                        diff --git a/docs/types/ConnectedAccount.html b/docs/types/ConnectedAccount.html new file mode 100644 index 00000000..7d84fd4e --- /dev/null +++ b/docs/types/ConnectedAccount.html @@ -0,0 +1,2 @@ +ConnectedAccount | @auth0/auth0-react
                                                                                        @auth0/auth0-react
                                                                                          Preparing search index...

                                                                                          Type Alias ConnectedAccount

                                                                                          ConnectedAccount: Omit<
                                                                                              ConnectAccountRedirectResult,
                                                                                              "appState"
                                                                                              | "response_type",
                                                                                          >

                                                                                          The account that has been connected during the connect flow.

                                                                                          +
                                                                                          diff --git a/docs/types/FetcherConfig.html b/docs/types/FetcherConfig.html index 62625832..400e907a 100644 --- a/docs/types/FetcherConfig.html +++ b/docs/types/FetcherConfig.html @@ -1,5 +1,5 @@ -FetcherConfig | @auth0/auth0-react
                                                                                          @auth0/auth0-react
                                                                                            Preparing search index...

                                                                                            Type Alias FetcherConfig<TOutput>

                                                                                            type FetcherConfig<TOutput extends CustomFetchMinimalOutput> = {
                                                                                                baseUrl?: string;
                                                                                                dpopNonceId?: string;
                                                                                                fetch?: CustomFetchImpl<TOutput>;
                                                                                                getAccessToken?: AccessTokenFactory;
                                                                                            }

                                                                                            Type Parameters

                                                                                            • TOutput extends CustomFetchMinimalOutput
                                                                                            Index

                                                                                            Properties

                                                                                            baseUrl? +FetcherConfig | @auth0/auth0-react
                                                                                            @auth0/auth0-react
                                                                                              Preparing search index...

                                                                                              Type Alias FetcherConfig<TOutput>

                                                                                              type FetcherConfig<TOutput extends CustomFetchMinimalOutput> = {
                                                                                                  baseUrl?: string;
                                                                                                  dpopNonceId?: string;
                                                                                                  fetch?: CustomFetchImpl<TOutput>;
                                                                                                  getAccessToken?: AccessTokenFactory;
                                                                                              }

                                                                                              Type Parameters

                                                                                              • TOutput extends CustomFetchMinimalOutput
                                                                                              Index

                                                                                              Properties

                                                                                              baseUrl?: string
                                                                                              dpopNonceId?: string
                                                                                              fetch?: CustomFetchImpl<TOutput>
                                                                                              getAccessToken?: AccessTokenFactory
                                                                                              +

                                                                                              Properties

                                                                                              baseUrl?: string
                                                                                              dpopNonceId?: string
                                                                                              fetch?: CustomFetchImpl<TOutput>
                                                                                              getAccessToken?: AccessTokenFactory
                                                                                              diff --git a/docs/variables/Auth0Context.html b/docs/variables/Auth0Context.html index 6d089a50..4ec8437f 100644 --- a/docs/variables/Auth0Context.html +++ b/docs/variables/Auth0Context.html @@ -1,2 +1,2 @@ Auth0Context | @auth0/auth0-react
                                                                                              @auth0/auth0-react
                                                                                                Preparing search index...

                                                                                                Variable Auth0ContextConst

                                                                                                Auth0Context: Context<Auth0ContextInterface<User>> = ...

                                                                                                The Auth0 Context

                                                                                                -
                                                                                                +
                                                                                                diff --git a/package-lock.json b/package-lock.json index cff235fb..55fed64f 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "@auth0/auth0-react", - "version": "2.6.0", + "version": "2.7.0", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "@auth0/auth0-react", - "version": "2.6.0", + "version": "2.7.0", "license": "MIT", "dependencies": { "@auth0/auth0-spa-js": "^2.6.0" diff --git a/package.json b/package.json index c36bf276..d32b0544 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "author": "Auth0", "name": "@auth0/auth0-react", - "version": "2.6.0", + "version": "2.7.0", "description": "Auth0 SDK for React Single Page Applications (SPA)", "keywords": [ "auth0",