shoc-frontend-new/src/domain/notifications/api/notifications-api.ts

11 lines
312 B
TypeScript
Raw Normal View History

import { apiGet } from "@/api/api";
import {
notificationFeedSchema,
type NotificationFeed,
} from "@/domain/notifications/types/notification-feed";
export const notificationsApi = {
feed: async (): Promise<NotificationFeed> =>
notificationFeedSchema.parse(await apiGet<unknown>("notifications")),
};