mirror of
https://github.com/usebruno/bruno.git
synced 2026-07-07 14:08:38 +00:00
refactor: Auth
This commit is contained in:
13
renderer/api/auth.js
Normal file
13
renderer/api/auth.js
Normal file
@@ -0,0 +1,13 @@
|
||||
import { get, post, put } from './base';
|
||||
|
||||
const AuthApi = {
|
||||
whoami: () =>get('auth/v1/user/whoami'),
|
||||
signup: (params) =>post('auth/v1/user/signup', params),
|
||||
login: (params) =>post('auth/v1/user/login', params),
|
||||
signout: () => post('auth/v1/user/logout'),
|
||||
getProfile: () =>get('auth/v1/user/profile'),
|
||||
updateProfile: (params) =>put('auth/v1/user/profile', params),
|
||||
updateUsername: (params) =>put('auth/v1/user/username', params)
|
||||
};
|
||||
|
||||
export default AuthApi;
|
||||
Reference in New Issue
Block a user