testing routes
Some checks failed
Deploy to Web Server flyer-crawler.projectium.com / deploy (push) Failing after 2m23s

This commit is contained in:
2025-11-29 05:29:38 -08:00
parent 9e5c2047f7
commit bf0bf9ae21
22 changed files with 774 additions and 44 deletions

View File

@@ -809,6 +809,26 @@ export async function deleteUserAccount(password: string, tokenOverride?: string
}, tokenOverride);
}
// --- Notification API Functions ---
/**
* Fetches notifications for the authenticated user.
* @param limit The number of notifications to fetch.
* @param offset The number of notifications to skip for pagination.
* @returns A promise that resolves to the API response.
*/
export const getNotifications = async (limit: number = 20, offset: number = 0, tokenOverride?: string): Promise<Response> => {
return apiFetch(`/users/notifications?limit=${limit}&offset=${offset}`, {}, tokenOverride);
};
/**
* Marks all of the user's unread notifications as read.
* @returns A promise that resolves to the API response.
*/
export const markAllNotificationsAsRead = async (tokenOverride?: string): Promise<Response> => {
return apiFetch(`/users/notifications/mark-all-read`, { method: 'POST' }, tokenOverride);
};
// --- Budgeting and Spending Analysis API Functions ---
/**