check authentication for all servers on initialization and update permission roles

This commit is contained in:
jeffvli
2025-12-07 17:53:26 -08:00
parent 4ddada1fe3
commit c82762a3fc
10 changed files with 283 additions and 44 deletions
+10 -2
View File
@@ -7,9 +7,13 @@ const baseResponse = z.object({
}),
});
const authenticate = z.object({
const userParameters = z.object({
id: z.string(),
});
const user = z.object({
user: z.object({
adminRoles: z.boolean(),
adminRole: z.boolean(),
commentRole: z.boolean(),
coverArtRole: z.boolean(),
downloadRole: z.boolean(),
@@ -26,6 +30,8 @@ const authenticate = z.object({
}),
});
const authenticate = user;
const authenticateParameters = z.object({
c: z.string(),
f: z.string(),
@@ -641,6 +647,7 @@ export const ssType = {
structuredLyrics: structuredLyricsParameters,
topSongsList: topSongsListParameters,
updatePlaylist: updatePlaylistParameters,
user: userParameters,
},
_response: {
album,
@@ -683,5 +690,6 @@ export const ssType = {
song,
structuredLyrics,
topSongsList,
user,
},
};