Fix API token truncation in response

Replit-Commit-Author: Agent
Replit-Commit-Session-Id: 9111ef36-26c8-4085-84ca-a35dc1fec1b5
Replit-Commit-Screenshot-Url: https://storage.googleapis.com/screenshot-production-us-central1/7083d608-d6d3-4a6a-9a27-6286c5109627/2bbe1ea8-d1a5-409a-a278-9a936411501f.jpg
This commit is contained in:
alphaeusmote
2025-04-11 18:46:41 +00:00
+2 -7
View File
@@ -953,13 +953,8 @@ export async function registerRoutes(app: Express): Promise<Server> {
: [];
}
// Mask token values
const maskedTokens = tokens.map(token => ({
...token,
token: token.token.substring(0, 8) + '...'
}));
res.json(maskedTokens);
// Return full tokens (client will handle masking for display)
res.json(tokens);
} catch (error) {
console.error("Error fetching API tokens:", error);
res.status(500).json({ message: "Internal server error" });