Skip to content

localStorage authentication #471

Answered by wwilsman
alanltr asked this question in Support
Aug 3, 2021 · 1 comments · 2 replies
Discussion options

You must be logged in to vote

Hey @alanltr!

Which SDK are you using or how are you taking snapshots of your app? For most SDKs, you can set localStorage using your existing test framework API.

However, web storage objects like localStorage are not sent to the server with each request, and can only be accessed by client-side JavaScript APIs. If your app reads the token from the web storage data and uses it to authenticate requests, it is probably sending the token using a request header. Request headers can be sent per-snapshot with discovery.requestHeaders, or using the accompanying config file option.

Replies: 1 comment 2 replies

Comment options

You must be logged in to vote
2 replies
@alanltr
Comment options

@wwilsman
Comment options

Answer selected by Robdel12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Support
Labels
None yet
2 participants