Skip to main content
Glama
carlosazaustre

Activity Reporting MCP Server

submit_public_speaking

Submit a public speaking activity draft to the Activity Reporting MCP Server, including details like title, description, date, event format, attendees, and relevant URLs for accurate reporting and tracking.

Instructions

Submit a public speaking activity draft

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
activityDateYesDate of your talk (YYYY-MM-DD format)
activityUrlYesEvent link or relevant URL
additionalInfoNoAdditional information (optional)
countryNoCountry (required if eventFormat is In-Person or Hybrid)
descriptionYesWhat was it about?
eventFormatYesSelect event format
inPersonAttendeesNoIn-person attendees (required if eventFormat is Hybrid or In-Person)
metricsYes
privateNoDo you want to make this activity private? (optional)
tagsNoTags (optional)
titleYesWhat was the title of your talk?

Implementation Reference

  • The core handler function that executes the tool logic by sending a POST request to the Advocu API endpoint '/activity-drafts/public-speaking' with the provided draft data. Handles authentication, errors, and formats responses for MCP.
    private async submitActivityDraft(
      endpoint: string,
      data:
        | ContentCreationDraft
        | PublicSpeakingDraft
        | WorkshopDraft
        | MentoringDraft
        | ProductFeedbackDraft
        | GooglerInteractionDraft
        | StoryDraft,
    ): Promise<{
      content: Array<{
        type: string;
        text: string;
      }>;
    }> {
      const url = `${this.baseUrl}/activity-drafts/${endpoint}`;
    
      try {
        const response = await fetch(url, {
          method: "POST",
          headers: {
            "Content-Type": "application/json",
            Authorization: `Bearer ${this.accessToken}`,
          },
          body: JSON.stringify(data),
        });
    
        if (!response.ok) {
          const errorText = await response.text();
          let errorMessage = `GDE API error (${response.status})`;
    
          if (response.status === 401) {
            errorMessage = "❌ GDE authentication failed. Your ADVOCU_ACCESS_TOKEN may be expired or invalid.\n\nPlease check your Advocu access token configuration.";
          } else if (response.status === 400) {
            errorMessage = `❌ GDE API rejected the request:\n\n${errorText}\n\nPlease check:\n- All required fields are present\n- Field values match expected formats\n- Tags are valid\n- Date format is correct (YYYY-MM-DD)`;
          } else if (response.status === 429) {
            errorMessage = "⏱️ GDE API rate limit exceeded (30 requests/minute). Please wait and try again.";
          } else {
            errorMessage = `❌ GDE API error (${response.status}):\n\n${errorText}`;
          }
    
          // Return error as content instead of throwing
          return {
            content: [
              {
                type: "text",
                text: errorMessage,
              },
            ],
          };
        }
    
        const result = (await response.json()) as Record<string, unknown>;
    
        return {
          content: [
            {
              type: "text",
              text: `✅ GDE Activity draft submitted successfully!\n\nEndpoint: ${endpoint}\nStatus: ${response.status}\nResponse: ${JSON.stringify(result, null, 2)}`,
            },
          ],
        };
      } catch (error) {
        if (error instanceof McpError) {
          throw error;
        }
        const errorMsg = this.getErrorMessage(error);
        throw new McpError(
          ErrorCode.InternalError,
          `❌ Failed to submit GDE activity:\n\n${errorMsg}\n\nEndpoint: ${endpoint}`
        );
      }
    }
  • src/server.ts:143-215 (registration)
    Registers the 'submit_public_speaking' tool in the MCP server's listTools handler, including its name, description, and complete input schema.
    {
      name: "submit_public_speaking",
      description: "Submit a public speaking activity draft",
      inputSchema: {
        type: "object",
        properties: {
          title: {
            type: "string",
            description: "What was the title of your talk?",
            minLength: 3,
            maxLength: 200,
          },
          description: {
            type: "string",
            description: "What was it about?",
            maxLength: 2000,
          },
          activityDate: {
            type: "string",
            pattern: "^\\d{4}-\\d{2}-\\d{2}$",
            description: "Date of your talk (YYYY-MM-DD format)",
          },
          tags: {
            type: "array",
            items: { type: "string" },
            description: "Tags (optional)",
            minItems: 0,
          },
          metrics: {
            type: "object",
            properties: {
              attendees: {
                type: "integer",
                minimum: 1,
                description: "How many people attended your session in total?",
              },
            },
            required: ["attendees"],
          },
          eventFormat: {
            type: "string",
            enum: Object.values(EventFormat),
            description: "Select event format",
          },
          country: {
            type: "string",
            enum: Object.values(Country),
            description: "Country (required if eventFormat is In-Person or Hybrid)",
          },
          inPersonAttendees: {
            type: "integer",
            minimum: 0,
            description: "In-person attendees (required if eventFormat is Hybrid or In-Person)",
          },
          activityUrl: {
            type: "string",
            maxLength: 500,
            pattern: "^https?://.*",
            description: "Event link or relevant URL",
          },
          additionalInfo: {
            type: "string",
            maxLength: 2000,
            description: "Additional information (optional)",
          },
          private: {
            type: "boolean",
            description: "Do you want to make this activity private? (optional)",
          },
        },
        required: ["title", "description", "activityDate", "metrics", "eventFormat", "activityUrl"],
      },
    },
  • Specific dispatch case in the CallToolRequestSchema handler that maps the tool call to the shared submitActivityDraft function with the appropriate endpoint and type casting.
    case "submit_public_speaking":
      return await this.submitActivityDraft("public-speaking", args as unknown as PublicSpeakingDraft);
  • Detailed input schema for the submit_public_speaking tool, defining validation rules for all parameters including required fields, types, enums, patterns, and constraints.
    inputSchema: {
      type: "object",
      properties: {
        title: {
          type: "string",
          description: "What was the title of your talk?",
          minLength: 3,
          maxLength: 200,
        },
        description: {
          type: "string",
          description: "What was it about?",
          maxLength: 2000,
        },
        activityDate: {
          type: "string",
          pattern: "^\\d{4}-\\d{2}-\\d{2}$",
          description: "Date of your talk (YYYY-MM-DD format)",
        },
        tags: {
          type: "array",
          items: { type: "string" },
          description: "Tags (optional)",
          minItems: 0,
        },
        metrics: {
          type: "object",
          properties: {
            attendees: {
              type: "integer",
              minimum: 1,
              description: "How many people attended your session in total?",
            },
          },
          required: ["attendees"],
        },
        eventFormat: {
          type: "string",
          enum: Object.values(EventFormat),
          description: "Select event format",
        },
        country: {
          type: "string",
          enum: Object.values(Country),
          description: "Country (required if eventFormat is In-Person or Hybrid)",
        },
        inPersonAttendees: {
          type: "integer",
          minimum: 0,
          description: "In-person attendees (required if eventFormat is Hybrid or In-Person)",
        },
        activityUrl: {
          type: "string",
          maxLength: 500,
          pattern: "^https?://.*",
          description: "Event link or relevant URL",
        },
        additionalInfo: {
          type: "string",
          maxLength: 2000,
          description: "Additional information (optional)",
        },
        private: {
          type: "boolean",
          description: "Do you want to make this activity private? (optional)",
        },
      },
      required: ["title", "description", "activityDate", "metrics", "eventFormat", "activityUrl"],
    },
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations provided, the description carries full burden but offers minimal behavioral disclosure. It implies a write operation ('Submit') but doesn't clarify permissions, whether this creates or updates records, error handling, or what happens upon submission. For a mutation tool with 11 parameters, this leaves significant gaps in understanding its behavior.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, efficient sentence that directly states the tool's purpose without unnecessary words. It's appropriately sized and front-loaded, with every word contributing to understanding the core function.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a complex mutation tool with 11 parameters, no annotations, and no output schema, the description is inadequate. It doesn't address behavioral aspects like permissions, side effects, or response format, leaving the agent with insufficient context to use the tool effectively despite the detailed input schema.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is high at 91%, so the schema already documents most parameters thoroughly. The description adds no additional parameter semantics beyond implying 'draft' submission, which doesn't clarify parameter usage beyond what the schema provides. Baseline 3 is appropriate given the schema does heavy lifting.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the action ('Submit') and resource ('public speaking activity draft'), providing a specific verb+resource combination. It distinguishes this as a submission tool for public speaking activities, though it doesn't explicitly differentiate from sibling tools like 'submit_workshop' or 'submit_story' beyond the activity type.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No guidance is provided on when to use this tool versus alternatives. The description doesn't mention prerequisites, appropriate contexts, or exclusions, nor does it reference sibling tools like 'submit_workshop' or 'submit_story' to help the agent choose correctly among submission options.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Related Tools

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/carlosazaustre/advocu-mcp-server'

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