Skip to main content
Glama

get_news_detail

Retrieve detailed information for a specific news article from the N Lobby school portal, including content and optional read status updates.

Instructions

Retrieve detailed information for a specific news article

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
newsIdYesThe ID of the news article to retrieve
markAsReadNoMark the news article as read (optional, default: false)

Implementation Reference

  • MCP tool handler for get_news_detail: extracts newsId and optional markAsRead, calls api.getNewsDetail, optionally marks as read, returns JSON response or error message.
    case "get_news_detail":
      try {
        const { newsId, markAsRead = false } = args as {
          newsId: string;
          markAsRead?: boolean;
        };
    
        const newsDetail = await this.api.getNewsDetail(newsId);
    
        if (markAsRead) {
          try {
            await this.api.markNewsAsRead(newsId);
          } catch (markError) {
            logger.error(
              `Failed to mark news ${newsId} as read:`,
              markError,
            );
          }
        }
    
        return {
          content: [
            {
              type: "text",
              text: JSON.stringify(newsDetail, null, 2),
            },
          ],
        };
      } catch (error) {
        return {
          content: [
            {
              type: "text",
              text: `Error: ${error instanceof Error ? error.message : "Unknown error"}\n\nTo authenticate:\n1. Login to N Lobby in your browser\n2. Open Developer Tools (F12)\n3. Go to Application/Storage tab\n4. Copy cookies and use the set_cookies tool\n5. Use health_check to verify connection`,
            },
          ],
        };
      }
  • Input schema for get_news_detail tool: requires newsId (string), optional markAsRead (boolean, default false).
    name: "get_news_detail",
    description:
      "Retrieve detailed information for a specific news article",
    inputSchema: {
      type: "object",
      properties: {
        newsId: {
          type: "string",
          description: "The ID of the news article to retrieve",
        },
        markAsRead: {
          type: "boolean",
          description:
            "Mark the news article as read (optional, default: false)",
          default: false,
        },
      },
      required: ["newsId"],
    },

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/minagishl/nlobby-mcp'

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