feat: implement Settings, Security, and Backups routes with API integration

This commit is contained in:
Wikid82
2025-11-20 11:38:24 -05:00
parent 113745aa03
commit e62eeebfba
4 changed files with 80 additions and 3 deletions
+19
View File
@@ -0,0 +1,19 @@
import client from './client'
export interface UserProfile {
id: number
email: string
name: string
role: string
api_key: string
}
export const getProfile = async (): Promise<UserProfile> => {
const response = await client.get('/user/profile')
return response.data
}
export const regenerateApiKey = async (): Promise<{ api_key: string }> => {
const response = await client.post('/user/api-key')
return response.data
}