Skip to content
Discussion options

You must be logged in to vote

Hi @B3K4682,

You can create a Dio Interceptor to automatically add it to your http headers.

metro make:interceptor AddBearerToken

Then, add it to the api services you need it in

@override
  get interceptors => {
        // ...
        AddBearerToken: AddBearerToken(),
      };

Replies: 2 comments 1 reply

Comment options

You must be logged in to vote
0 replies
Answer selected by B3K4682
Comment options

You must be logged in to vote
1 reply
@agordn52
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants