kinde-oss / kinde-elixir-sdk

MIT License
11 stars 7 forks source link

How to use persisted tokens? #11

Open tcoopman opened 3 months ago

tcoopman commented 3 months ago

Prerequisites

How can we improve the docs or what is missing?

Can the documentation give some more details on how and what to save, and more importantly how to read those tokens in again and "restore" the KindeClientSDK with those tokens?

I know how to fetch all the data - and also know how I can save them in a cookie or session. But I have no idea what to do with those saved tokens? How can I use these tokens to initialize KindeClientSDK with those tokens, so I can use it?

Provide extra context, such as what you were trying to do and your requirements

I'm trying to persist the authentication state on a page refresh, or on closing the tab and opening it again

If the docs page already exists, please provide a link

https://docs.kinde.com/developer-tools/sdks/backend/elixir-sdk/#persisting-authentication-state-on-page-refresh-or-new-tab

onderay commented 2 months ago

Improvements to address this are being worked on here https://github.com/kinde-oss/kinde-elixir-sdk/pull/12