Skip to main content
Glama
PaddleHQ

Paddle MCP Server

Official
by PaddleHQ

create_client_side_token

Generate client-side tokens to authenticate Paddle.js integrations for specific applications or environments, enabling secure payment processing.

Instructions

This tool will create a new client-side token in Paddle.

Client-side tokens are needed to authenticate with Paddle.js. A token is provided when initializing Paddle.js.

When creating a client-side token, provide a descriptive name to help identify its purpose. Usually created for each application or environment that needs to authenticate with Paddle.js.

If successful, the response includes a copy of the new client-side token entity. The returned token field is the client-side token that needs to be provided when initializing Paddle.js. Can be exposed client-side safely. If it starts with:

  • test_: The token is a test token for a sandbox environment and shouldn't be used in production.

  • live_: The token is a live token for a production environment. It can be used to test too but Paddle.js checkouts require real cards.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
nameYesName of this client-side token.
descriptionNoShort description for this client-side token.

Implementation Reference

  • The handler function that implements the core logic of the 'create_client_side_token' tool by calling paddle.clientTokens.create(params) and handling errors.
    export const createClientSideToken = async (paddle: Paddle, params: z.infer<typeof Parameters.createClientSideTokenParameters>) => {
      try {
        const clientSideToken = await paddle.clientTokens.create(params);
        return clientSideToken;
      } catch (error) {
        return error;
      }
    };
  • Tool schema definition including the method name, human-readable name, description prompt, Zod parameters schema reference, and required actions for permissions.
    {
      method: "create_client_side_token",
      name: "Create a client-side token",
      description: prompts.createClientSideTokenPrompt,
      parameters: params.createClientSideTokenParameters,
      actions: {
        clientSideTokens: {
          write: true,
          create: true,
        },
      },
    },
  • src/api.ts:90-90 (registration)
    Registers the createClientSideToken handler function to the tool method constant in the toolMap used by PaddleAPI to dispatch tool calls.
    [TOOL_METHODS.CREATE_CLIENT_SIDE_TOKEN]: funcs.createClientSideToken,
  • Constant defining the string identifier for the 'create_client_side_token' tool method.
    CREATE_CLIENT_SIDE_TOKEN: "create_client_side_token",
Behavior4/5

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

Annotations indicate this is a non-destructive write operation (readOnlyHint: false, destructiveHint: false). The description adds valuable behavioral context beyond annotations: it explains the response format (includes the new token entity), safety considerations (can be exposed client-side safely), and environment-specific behaviors (test_ vs. live_ token prefixes and their implications).

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

Conciseness4/5

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

The description is well-structured and front-loaded with the core purpose, followed by usage context and behavioral details. Most sentences add value, though the explanation of token prefixes could be slightly more concise. Overall, it efficiently conveys necessary information without unnecessary verbosity.

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

Completeness4/5

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

For a creation tool with no output schema, the description does a good job covering key aspects: purpose, usage, parameters (via schema), behavioral traits, and response details. It could be more complete by explicitly mentioning error conditions or prerequisites, but it adequately addresses the tool's complexity given the available annotations and schema coverage.

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 input schema has 100% description coverage, so the schema already documents both parameters (name and description). The description adds some semantic context by advising to 'provide a descriptive name to help identify its purpose', but does not provide additional details beyond what the schema descriptions offer.

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

Purpose5/5

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

The description clearly states the specific action ('create a new client-side token in Paddle'), identifies the resource ('client-side token'), and distinguishes it from siblings by explaining its unique purpose for authenticating with Paddle.js. This goes beyond just restating the tool name.

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

Usage Guidelines4/5

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

The description provides clear context for when to use this tool ('needed to authenticate with Paddle.js', 'usually created for each application or environment'), but does not explicitly mention when not to use it or name specific alternatives among the sibling tools (e.g., get_client_side_token or list_client_side_tokens).

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/PaddleHQ/paddle-mcp-server'

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