feat: add functionality to create and reveal secret access keys for users

Signed-off-by: Noste <83548733+Noooste@users.noreply.github.com>
This commit is contained in:
Noste
2025-12-20 12:24:53 +01:00
parent 983e6e5fa9
commit 4656d1bce9
13 changed files with 1033 additions and 138 deletions
+5
View File
@@ -222,6 +222,11 @@ export const accessApi = {
return response.data.data;
},
getSecretKey: async (accessKey: string): Promise<string> => {
const response = await api.get(`/v1/users/${accessKey}/secret`);
return response.data.data.secretKey;
},
// eslint-disable-next-line @typescript-eslint/no-explicit-any
createKey: async (name: string, permissions?: any[]): Promise<AccessKey> => {
const response = await api.post('/v1/users', { name, permissions });