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
Yos666666 edited this page Sep 14, 2021
·
6 revisions
/src/api/login/index.js
Functions
Authenticate a user
auth(username,password)
username - string : Email of user
password - string : Password of user
Example
import{auth}from'aquila-connector/api/login';importaxiosfrom'aquila-connector/lib/AxiosInstance';constres=awaitauth('email@user.com','user_password');axios.defaults.headers.common['Authorization']=res.data;// Set JWT
Resets a user's password (forgot password)
sendMailResetPassword(email,lang)
email - string : Email of user
lang - string? : current language ("fr" is the default value) - Optionnal