You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
thank you verry much for the work you have done with this Project. You are such a bless :) 👍
In my Case I have a API with basic Authentication. As i refer, there is no common Way to set this up in the existing Class. So i done it this way before init()
String username = 'username';
String password = 'password';
String basicAuth =
'Basic ${base64.encode(utf8.encode('$username:$password'))}';
print(basicAuth);
restApiClient.addOrUpdateHeader(key: 'authorization', value: basicAuth);
//init must be called, preferably right after the instantiation
await restApiClient.init();
The function to modify the Header i found in your Library :) And it works :)
I don´t know if it is necessary to do the formatingstuff of the String, but i found it on the Internet and it works, so i don´t touche it :)
If you like you can use my code and implement the Basic Authentication in your Library. Perhabs there is an other better Way to do this (i am coding dart since two days 🙃)
The text was updated successfully, but these errors were encountered:
Hi salihagic :)
thank you verry much for the work you have done with this Project. You are such a bless :) 👍
In my Case I have a API with basic Authentication. As i refer, there is no common Way to set this up in the existing Class. So i done it this way before init()
The function to modify the Header i found in your Library :) And it works :)
I don´t know if it is necessary to do the formatingstuff of the String, but i found it on the Internet and it works, so i don´t touche it :)
If you like you can use my code and implement the Basic Authentication in your Library. Perhabs there is an other better Way to do this (i am coding dart since two days 🙃)
The text was updated successfully, but these errors were encountered: