mirror of
https://github.com/glitch-soc/mastodon.git
synced 2025-01-21 23:22:56 -05:00
af0a1a8774
Port d558dfd77dc4f64d3a633efcfc0683ee603a1520 to glitch-soc Signed-off-by: Claire <claire.github-309c@sitedethib.com>
11 lines
441 B
TypeScript
11 lines
441 B
TypeScript
import { apiRequest } from 'flavours/glitch/api';
|
|
import type { NotificationPolicyJSON } from 'flavours/glitch/api_types/notification_policies';
|
|
|
|
export const apiGetNotificationPolicy = () =>
|
|
apiRequest<NotificationPolicyJSON>('GET', '/v1/notifications/policy');
|
|
|
|
export const apiUpdateNotificationsPolicy = (
|
|
policy: Partial<NotificationPolicyJSON>,
|
|
) =>
|
|
apiRequest<NotificationPolicyJSON>('PUT', '/v1/notifications/policy', policy);
|