feat: add ntfy integration (#2900)
Co-authored-by: Meier Lukas <meierschlumpf@gmail.com>
This commit is contained in:
14
packages/cron-jobs/src/jobs/integrations/notifications.ts
Normal file
14
packages/cron-jobs/src/jobs/integrations/notifications.ts
Normal file
@@ -0,0 +1,14 @@
|
||||
import { EVERY_5_MINUTES } from "@homarr/cron-jobs-core/expressions";
|
||||
import { createRequestIntegrationJobHandler } from "@homarr/request-handler/lib/cached-request-integration-job-handler";
|
||||
import { notificationsRequestHandler } from "@homarr/request-handler/notifications";
|
||||
|
||||
import { createCronJob } from "../../lib";
|
||||
|
||||
export const refreshNotificationsJob = createCronJob("refreshNotifications", EVERY_5_MINUTES).withCallback(
|
||||
createRequestIntegrationJobHandler(notificationsRequestHandler.handler, {
|
||||
widgetKinds: ["notifications"],
|
||||
getInput: {
|
||||
notifications: (options) => options,
|
||||
},
|
||||
}),
|
||||
);
|
||||
Reference in New Issue
Block a user