Skip to main content
Glama

fc_get_space_analytics

Retrieve analytics and statistics for community spaces to track engagement metrics and performance data within specified date ranges.

Instructions

Get analytics and statistics for a space

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
space_idYesThe space ID to get analytics for
date_fromNoStart date (YYYY-MM-DD)
date_toNoEnd date (YYYY-MM-DD)

Implementation Reference

  • Handler function that fetches space analytics via WordPress API endpoint 'fc-manager/v1/analytics/space' using provided space_id and optional date range, returns JSON-formatted response or error.
    fc_get_space_analytics: async (args: any) => {
      try {
        const params: any = { space_id: args.space_id };
        
        if (args.date_from) params.date_from = args.date_from;
        if (args.date_to) params.date_to = args.date_to;
        
        const response = await makeWordPressRequest('GET', 'fc-manager/v1/analytics/space', params);
        return { toolResult: { content: [{ type: 'text', text: JSON.stringify(response, null, 2) }] } };
      } catch (error: any) {
        return { toolResult: { isError: true, content: [{ type: 'text', text: `Error: ${error.message}` }] } };
      }
    },
  • Zod input schema defining required space_id and optional date_from/date_to parameters for the tool.
    const getSpaceAnalyticsSchema = z.object({
      space_id: z.number().describe('The space ID to get analytics for'),
      date_from: z.string().optional().describe('Start date (YYYY-MM-DD)'),
      date_to: z.string().optional().describe('End date (YYYY-MM-DD)')
    });
  • Tool registration entry in the fluentCommunityTools array, specifying name, description, and input schema reference.
    {
      name: 'fc_get_space_analytics',
      description: 'Get analytics and statistics for a FluentCommunity space',
      inputSchema: { type: 'object', properties: getSpaceAnalyticsSchema.shape }
    },
Behavior2/5

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

With no annotations provided, the description carries full burden for behavioral disclosure. It states this is a 'get' operation which implies read-only behavior, but doesn't specify what analytics are returned, whether authentication is required, rate limits, or error conditions. The description is too vague about what 'analytics and statistics' actually means.

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 states exactly what the tool does without any unnecessary words. It's appropriately sized for a simple retrieval tool and gets straight to the point.

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 tool that presumably returns analytics data (which can be complex), the description is insufficient. With no annotations and no output schema, the description should provide more context about what kind of analytics are returned, the format of the response, or examples of the statistics provided. The current description leaves too much unspecified.

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?

The schema has 100% description coverage, so all parameters are documented in the structured schema. The description doesn't add any additional meaning about the parameters beyond what's already in the schema descriptions. This meets the baseline expectation when schema coverage is complete.

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 ('Get analytics and statistics') and resource ('for a space'), making the purpose immediately understandable. However, it doesn't differentiate this tool from potential sibling analytics tools (none exist in the provided list), so it doesn't reach the highest score.

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?

The description provides no guidance on when to use this tool versus alternatives. There's no mention of prerequisites, appropriate contexts, or comparison with other tools like 'fc_get_space' or 'fc_search_content' that might provide related information.

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

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/wplaunchify/fluent-community-mcp'

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