Skip to main content
Glama
nulab

Backlog MCP Server

mark_notification_as_read

Mark notifications as read in Backlog to clear alerts and update your notification status.

Instructions

Mark a notification as read

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
idYesNotification ID to mark as read

Implementation Reference

  • The handler function that executes the tool logic: marks the notification as read using the Backlog client and returns a success message.
    handler: async ({ id }) => {
      await backlog.markAsReadNotification(id);
      return {
        success: true,
        message: `Notification ${id} marked as read`,
      };
    },
  • Input schema (notification id: number) and output schema (success: boolean, message: string).
    const markNotificationAsReadSchema = buildToolSchema((t) => ({
      id: z
        .number()
        .describe(
          t('TOOL_MARK_NOTIFICATION_AS_READ_ID', 'Notification ID to mark as read')
        ),
    }));
    
    export const MarkNotificationAsReadResultSchema = z.object({
      success: z.boolean(),
      message: z.string(),
    });
  • Factory function exporting the tool definition with name, description, schemas, and handler.
    export const markNotificationAsReadTool = (
      backlog: Backlog,
      { t }: TranslationHelper
    ): ToolDefinition<
      ReturnType<typeof markNotificationAsReadSchema>,
      (typeof MarkNotificationAsReadResultSchema)['shape']
    > => {
      return {
        name: 'mark_notification_as_read',
        description: t(
          'TOOL_MARK_NOTIFICATION_AS_READ_DESCRIPTION',
          'Mark a notification as read'
        ),
        schema: z.object(markNotificationAsReadSchema(t)),
        outputSchema: MarkNotificationAsReadResultSchema,
        handler: async ({ id }) => {
          await backlog.markAsReadNotification(id);
          return {
            success: true,
            message: `Notification ${id} marked as read`,
          };
        },
      };
    };
  • Registration of the tool within the 'notifications' toolset group in the main tools export.
    {
      name: 'notifications',
      description: 'Tools for managing user notifications.',
      enabled: false,
      tools: [
        getNotificationsTool(backlog, helper),
        getNotificationsCountTool(backlog, helper),
        resetUnreadNotificationCountTool(backlog, helper),
        markNotificationAsReadTool(backlog, helper),
      ],
    },

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/nulab/backlog-mcp-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server