refactor: db-only credits and admin controls
Remove blockchain dependence from credit flow: - watch credits now DB-only - webhook earnings now DB-only - wallet balance now DB-only - admin bonus/adjustment routes operate on DB totals Add admin adjustment API for account control. Keep Solana service file unused for now; safe to delete later.
This commit is contained in:
@@ -87,6 +87,8 @@ export const adminApi = {
|
||||
updateUser: (id: string, data: any) => api.put(`/admin/users/${id}`, data),
|
||||
grantBonus: (userId: string, amount: number, reason?: string) =>
|
||||
api.post(`/admin/users/${userId}/bonus`, { amount, reason }),
|
||||
adjustUser: (userId: string, amount: number, reason?: string) =>
|
||||
api.post(`/wallet/admin/${userId}/adjust`, { amount, reason }),
|
||||
getAnalytics: () => api.get("/admin/analytics"),
|
||||
getAllTransactions: (page = 1, limit = 50) =>
|
||||
api.get(`/transactions/admin/all?page=${page}&limit=${limit}`),
|
||||
|
||||
Reference in New Issue
Block a user