-
Notifications
You must be signed in to change notification settings - Fork 28
Expose auth cookies or request headers for external clients #116
Description
🔖 Enhancement description
A small public helper in the SDK to expose the current authenticated cookie/header state for use with external networking and media libraries like Coil or Glide when loading protected Appwrite Storage files.
I would not expect the SDK to handle all image loading or external networking use cases itself, so exposing auth state seems like the best option here.
🎤 Pitch
Apps may use external libraries for many things. One example is using Coil, Glide, or custom networking for loading protected files from Appwrite Storage.
Right now there is no clean public way to reuse the SDK - managed session for those requests. It requires writing a hacky helper that reads the SDK's saved shared preferences directly. The problem with that approach is that it depends on internal SDK details, such as the shared preferences key like myCookie, which can change over time.
A small public helper would solve this. A more advanced option could be exposing, or allowing apps to provide, a specific OkHttpClient instance.
👀 Have you spent some time to check if this issue has been raised before?
- I checked and didn't find similar issue
🏢 Have you read the Code of Conduct?
- I have read the Code of Conduct