mark_watching_as_read
Mark a Backlog watch notification as read to clear it from your notification list and update your project tracking status.
Instructions
Mark a watch as read
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| watchId | Yes | Watch ID to mark as read |
Implementation Reference
- src/tools/markWatchingAsRead.ts:34-40 (handler)The handler function that executes the tool logic: calls backlog.resetWatchingListItemAsRead(watchId) and returns a success response.handler: async ({ watchId }) => { await backlog.resetWatchingListItemAsRead(watchId); return { success: true, message: `Watch ${watchId} marked as read`, }; },
- src/tools/markWatchingAsRead.ts:6-12 (schema)Input schema defining the 'watchId' parameter as a number.const markWatchingAsReadSchema = buildToolSchema((t) => ({ watchId: z .number() .describe( t('TOOL_MARK_WATCHING_AS_READ_WATCH_ID', 'Watch ID to mark as read') ), }));
- Output schema defining the result with success boolean and message string.export const MarkWatchingAsReadResultSchema = z.object({ success: z.boolean(), message: z.string(), });
- src/tools/tools.ts:111-111 (registration)Registration of the markWatchingAsReadTool in the 'issue' toolset group.markWatchingAsReadTool(backlog, helper),
- src/tools/markWatchingAsRead.ts:19-42 (registration)The tool factory function that defines and exports the tool with name, description, schema, outputSchema, and handler.export const markWatchingAsReadTool = ( backlog: Backlog, { t }: TranslationHelper ): ToolDefinition< ReturnType<typeof markWatchingAsReadSchema>, (typeof MarkWatchingAsReadResultSchema)['shape'] > => { return { name: 'mark_watching_as_read', description: t( 'TOOL_MARK_WATCHING_AS_READ_DESCRIPTION', 'Mark a watch as read' ), schema: z.object(markWatchingAsReadSchema(t)), outputSchema: MarkWatchingAsReadResultSchema, handler: async ({ watchId }) => { await backlog.resetWatchingListItemAsRead(watchId); return { success: true, message: `Watch ${watchId} marked as read`, }; }, }; };