Skip to main content
Glama

fc_list_posts

Retrieve and filter community posts by space, user, status, type, or search terms to manage content effectively.

Instructions

List all posts from FluentCommunity with optional filtering

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
space_idNoFilter posts by space ID
user_idNoFilter posts by user ID
statusNoFilter by status (published, draft, etc.)
typeNoFilter by post type (text, video, etc.)
limitNoNumber of posts to return (default: 20)
offsetNoOffset for pagination (default: 0)
searchNoSearch term to filter posts

Implementation Reference

  • Handler function for fc_list_posts tool that makes a GET request to the WordPress API endpoint 'fc-manager/v1/posts' with filtering parameters and returns the response.
    fc_list_posts: async (args: any) => {
      try {
        const params: any = {
          per_page: args.limit || 20,
          offset: args.offset || 0,
        };
        
        if (args.space_id) params.space_id = args.space_id;
        if (args.user_id) params.user_id = args.user_id;
        if (args.status) params.status = args.status;
        if (args.type) params.type = args.type;
        if (args.search) params.search = args.search;
        
        const response = await makeWordPressRequest('GET', 'fc-manager/v1/posts', 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 schema defining input parameters for the fc_list_posts tool, including optional filters like space_id, user_id, status, type, limit, offset, and search.
    const listPostsSchema = z.object({
      space_id: z.number().optional().describe('Filter posts by space ID'),
      user_id: z.number().optional().describe('Filter posts by user ID'),
      status: z.enum(['published', 'draft', 'pending', 'archived']).optional().describe('Filter by status'),
      type: z.string().optional().describe('Filter by post type (text, video, etc.)'),
      limit: z.number().optional().default(20).describe('Number of posts to return'),
      offset: z.number().optional().default(0).describe('Offset for pagination'),
      search: z.string().optional().describe('Search term to filter posts')
    });
  • Tool registration object in fluentCommunityTools array, defining the name, description, and inputSchema for fc_list_posts.
      name: 'fc_list_posts',
      description: 'List all posts from FluentCommunity with optional filtering',
      inputSchema: { type: 'object', properties: listPostsSchema.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 but only states it lists posts with filtering. It doesn't disclose behavioral traits like pagination behavior (implied by limit/offset but not explained), rate limits, authentication needs, whether it's read-only (implied but not stated), or what the output format looks like. This leaves significant gaps for a tool with 7 parameters.

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 front-loads the core purpose ('List all posts') and adds essential qualification ('with optional filtering'). There is no wasted verbiage or redundancy.

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 list/read tool with 7 parameters, no annotations, and no output schema, the description is insufficient. It doesn't explain the return format (e.g., list of post objects), pagination details, error conditions, or how filtering interacts. Given the complexity and lack of structured data, more context is needed for effective use.

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 100%, so the schema fully documents all 7 parameters with descriptions, defaults, and an enum. The description adds no additional parameter semantics beyond mentioning 'optional filtering', which is already covered by the schema. This meets the baseline for high schema coverage.

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 verb ('List') and resource ('posts from FluentCommunity') with scope ('all'), making the purpose evident. However, it doesn't explicitly differentiate from sibling tools like fc_search_content or fc_get_post, which could also retrieve posts in different ways.

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 mentions 'optional filtering' but provides no guidance on when to use this tool versus alternatives like fc_search_content (for search-based retrieval) or fc_get_post (for single post retrieval). No context about prerequisites, typical use cases, or exclusions is given.

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