Skip to main content
Glama
Kong

Kong Konnect MCP Server

Official
by Kong

list_control_plane_group_memberships

List all control planes that are members of a specific control plane group in Kong Konnect. Use this tool to view group membership details, including status and configuration information.

Instructions

List all control planes that are members of a specific control plane group.

INPUT:

  • groupId: String - ID of the control plane group (control plane that acts as the group)

  • pageSize: Number - Number of members to return per page (1-1000, default: 10)

  • pageAfter: String (optional) - Cursor for pagination after a specific item

OUTPUT:

  • metadata: Object - Contains groupId, pageSize, pageAfter, nextPageAfter, totalCount

  • members: Array - List of member control planes with details for each including:

    • controlPlaneId: String - Unique identifier for the control plane

    • name: String - Display name of the control plane

    • description: String - Description of the control plane

    • type: String - Type of the control plane

    • clusterType: String - Underlying cluster type

    • membershipStatus: Object - Group membership status including:

      • status: String - Current status (OK, CONFLICT, etc.)

      • message: String - Status message

      • conflicts: Array - List of configuration conflicts if any

    • metadata: Object - Creation and update timestamps

  • relatedTools: Array - List of related tools for group management

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
groupIdYesControl plane group ID (the ID of the control plane that acts as the group)
pageSizeNoNumber of members to return per page
pageAfterNoCursor for pagination after a specific item

Implementation Reference

  • Core handler function that executes the tool logic: calls the Kong API to list group memberships, transforms the raw API response into a standardized format with metadata, member details, status info, and related tool suggestions.
    export async function listControlPlaneGroupMemberships( api: KongApi, groupId: string, pageSize = 10, pageAfter?: string ) { try { const result = await api.listControlPlaneGroupMemberships(groupId, pageSize, pageAfter); // Transform the response to have consistent field names return { metadata: { groupId: groupId, pageSize: pageSize, pageAfter: pageAfter || null, nextPageAfter: result.meta?.next_page?.after || null, totalCount: result.meta?.total_count || 0 }, members: result.data.map((member: any) => ({ controlPlaneId: member.id, name: member.name, description: member.description, type: member.type, clusterType: member.cluster_type, membershipStatus: { status: member.cp_group_member_status?.status, message: member.cp_group_member_status?.message, conflicts: member.cp_group_member_status?.conflicts || [] }, metadata: { createdAt: member.created_at, updatedAt: member.updated_at } })), relatedTools: [ "Use get-control-plane-group-status to check for configuration conflicts", "Use check-control-plane-group-membership to verify if a specific control plane is a member", "Use get-control-plane to get more details about a specific member" ] }; } catch (error) { throw error; } }
  • src/tools.ts:82-86 (registration)
    Tool registration metadata: defines the method name, display name, description prompt, input parameters schema, and category used by the MCP server to register this tool.
    method: "list_control_plane_group_memberships", name: "List Control Plane Group Memberships", description: prompts.listControlPlaneGroupMembershipsPrompt(), parameters: parameters.listControlPlaneGroupMembershipsParameters(), category: "control_planes"
  • Zod schema defining input parameters for the tool: groupId (required), pageSize (with defaults and constraints), pageAfter (optional pagination cursor).
    export const listControlPlaneGroupMembershipsParameters = () => z.object({ groupId: z.string() .describe("Control plane group ID (the ID of the control plane that acts as the group)"), pageSize: z.number().int() .min(1).max(1000) .default(10) .describe("Number of members to return per page"), pageAfter: z.string() .optional() .describe("Cursor for pagination after a specific item"), });
  • MCP server tool dispatcher case: receives validated args from MCP framework and delegates to the core operations handler.
    case "list_control_plane_group_memberships": result = await controlPlanes.listControlPlaneGroupMemberships( this.api, args.groupId, args.pageSize, args.pageAfter );
  • API client helper: constructs the HTTP endpoint and makes authenticated request to Kong Konnect API for group memberships data.
    async listControlPlaneGroupMemberships(groupId: string, pageSize = 10, pageAfter?: string): Promise<any> { let endpoint = `/control-planes/${groupId}/group-memberships?page[size]=${pageSize}`; if (pageAfter) { endpoint += `&page[after]=${pageAfter}`; } return this.kongRequest<any>(endpoint); }

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/Kong/mcp-konnect'

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