Skip to main content
Glama

list_certificates

Retrieve SSL/TLS certificates for a specific website to monitor security status, search by keyword, filter valid certificates, and manage pagination.

Instructions

Lists certificates of a website.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
siteIdYesThe website ID. Reference Value Source: list_sites. Example: 1234567890123
keywordNoThe search keyword.
validOnlyNoWhether to return only valid certificates.
pageNumberNoThe page number of the returned data.
pageSizeNoThe number of records per page.

Implementation Reference

  • The handler function that implements the core logic of the 'list_certificates' tool. It calls the service API with the provided parameters and returns the result as a standardized tool response.
    export const list_certificates = async (request: CallToolRequest) => {
      const res = await api.listCertificates(
        request.params.arguments as ListCertificatesRequest,
      );
    
      return {
        content: [{ type: 'text', text: JSON.stringify(res) }],
        success: true,
      };
    };
  • The tool registration object defining the schema, name, description, and input validation for 'list_certificates'.
    export const LIST_CERTIFICATES_TOOL: Tool = {
      name: 'list_certificates',
      description: 'Lists certificates of a website.',
      inputSchema: {
        type: 'object',
        properties: {
          siteId: {
            type: 'number',
            description:
              'The website ID. Reference Value Source: list_sites. Example: 1234567890123',
          },
          keyword: {
            type: 'string',
            description: 'The search keyword.',
          },
          validOnly: {
            type: 'boolean',
            description: 'Whether to return only valid certificates.',
          },
          pageNumber: {
            type: 'number',
            description: 'The page number of the returned data.',
          },
          pageSize: {
            type: 'number',
            description: 'The number of records per page.',
          },
        },
        required: ['siteId'],
        annotations: {},
      },
    };
  • Registration list for certificate tools, including LIST_CERTIFICATES_TOOL.
    export const CERTIFICATE_LIST = [
      SET_CERTIFICATE_TOOL,
      APPLY_CERTIFICATE_TOOL,
      GET_CERTIFICATE_TOOL,
      DELETE_CERTIFICATE_TOOL,
      LIST_CERTIFICATES_TOOL,
      GET_CERTIFICATE_QUOTA_TOOL,
    ];
  • Central registration of tool handlers, including 'list_certificates' mapped to its handler function.
    export const esaHandlers: ToolHandlers = {
      site_active_list,
      site_match,
      site_route_list,
      site_record_list,
      routine_create,
      routine_code_commit,
      routine_delete,
      routine_list,
      routine_get,
      routine_code_deploy,
      routine_route_list,
      deployment_delete,
      route_create,
      route_delete,
      route_update,
      route_get,
      er_record_create,
      er_record_delete,
      er_record_list,
      html_deploy,
      create_site,
      update_site_pause,
      get_site_pause,
      create_site_mx_record,
      create_site_ns_record,
      create_site_txt_record,
      create_site_cname_record,
      create_site_a_or_aaaa_record,
      update_record,
      list_records,
      get_record,
      delete_record,
      update_ipv6,
      get_ipv6,
      update_managed_transform,
      get_managed_transform,
      set_certificate,
      apply_certificate,
      get_certificate,
      delete_certificate,
      list_certificates,
      get_certificate_quota,
      list_sites,
    };
  • Helper method in the API service client that performs the actual listCertificates API call to the ESA service.
    listCertificates(params: ListCertificatesRequest) {
      const request = new ListCertificatesRequest(params);
      return this.callApi(
        this.client.listCertificates.bind(this.client) as ApiMethod<
          ListCertificatesRequest,
          ListCertificatesResponse
        >,
        request,
      );
    }
Behavior2/5

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

No annotations are provided, so the description carries full burden for behavioral disclosure. It states it's a list operation, implying read-only behavior, but doesn't cover critical aspects like pagination handling (implied by pageNumber/pageSize parameters), rate limits, authentication requirements, or what constitutes a 'valid' certificate. This leaves significant gaps for agent understanding.

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, clear sentence that efficiently communicates the core functionality without unnecessary words. It's front-loaded with the main action and resource, making it easy to parse quickly.

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?

Given no annotations, no output schema, and 5 parameters (including pagination and filtering), the description is insufficient. It doesn't explain return format, pagination behavior, or how filtering works (e.g., what 'valid' means), leaving the agent with incomplete context for proper tool invocation.

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%, providing full parameter documentation. The description adds no additional parameter semantics beyond implying the tool lists certificates for websites. This meets the baseline score of 3 since the schema adequately covers parameter meanings without needing description compensation.

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 ('Lists') and resource ('certificates of a website'), making the purpose immediately understandable. However, it doesn't differentiate from sibling tools like 'get_certificate' (singular retrieval) or 'apply_certificate' (application action), which would require more specificity for a perfect 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?

No guidance is provided on when to use this tool versus alternatives. The description doesn't mention prerequisites (e.g., needing a site ID from 'list_sites'), exclusions, or comparisons to similar tools like 'get_certificate' for single certificate retrieval or 'list_sites' for broader site listing.

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/aliyun/mcp-server-esa'

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