Skip to main content
Glama
PaddleHQ

Paddle MCP Server

Official
by PaddleHQ

get_discount_group

Read-only

Retrieve a discount group from Paddle Billing by its unique ID to access discount details and apply them to transactions.

Instructions

This tool will retrieve a discount group from Paddle by its ID.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
discountGroupIdYesPaddle ID of the discount group.

Implementation Reference

  • The core handler function implementing the get_discount_group tool logic. It takes a Paddle instance and validated params, extracts discountGroupId, fetches the discount group via Paddle SDK, and returns it or the error.
    export const getDiscountGroup = async (paddle: Paddle, params: z.infer<typeof Parameters.getDiscountGroupParameters>) => {
      try {
        const { discountGroupId } = params;
        const discountGroup = await paddle.discountGroups.get(discountGroupId);
        return discountGroup;
      } catch (error) {
        return error;
      }
    };
  • src/tools.ts:191-202 (registration)
    Primary registration of the 'get_discount_group' tool, including method name, human-readable name, description prompt, parameters schema reference, and required permissions/actions.
    {
      method: "get_discount_group",
      name: "Get a discount group",
      description: prompts.getDiscountGroupPrompt,
      parameters: params.getDiscountGroupParameters,
      actions: {
        discountGroups: {
          read: true,
          get: true,
        },
      },
    },
  • src/api.ts:72-72 (registration)
    Maps the GET_DISCOUNT_GROUP constant to the getDiscountGroup handler function in the tool execution map used by PaddleAPI.
    [TOOL_METHODS.GET_DISCOUNT_GROUP]: funcs.getDiscountGroup,
  • src/constants.ts:64-64 (registration)
    Constant definition for the tool method string used in registrations and mappings.
    GET_DISCOUNT_GROUP: "get_discount_group",
Behavior3/5

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

The annotations provide readOnlyHint=true, indicating a safe read operation. The description adds minimal context by specifying retrieval by ID, but does not disclose additional behavioral traits such as error handling, rate limits, or authentication needs. With annotations covering safety, a 3 is appropriate as the description adds some value but lacks rich behavioral details.

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 with no wasted words. It is appropriately sized and front-loaded, clearly stating the tool's purpose without unnecessary elaboration.

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

Completeness3/5

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

Given the tool's low complexity (single parameter, read-only), annotations covering safety, and no output schema, the description is minimally adequate. However, it lacks details on return values or error cases, which would be helpful for completeness. A 3 reflects a basic but incomplete description for this context.

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, with the parameter 'discountGroupId' fully documented. The description implies retrieval by ID but does not add meaning beyond what the schema provides, such as ID format or examples. Baseline 3 is correct when the schema handles parameter documentation effectively.

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 tool's purpose: 'retrieve a discount group from Paddle by its ID.' It specifies the verb ('retrieve'), resource ('discount group'), and source ('Paddle'), but does not explicitly differentiate it from sibling tools like 'list_discount_groups' or 'get_discount', which would require a 5.

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. It does not mention sibling tools like 'list_discount_groups' for listing multiple groups or 'get_discount' for individual discounts, nor does it specify prerequisites or exclusions for usage.

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