Skip to main content
Glama

Create Quote

whmcs_create_quote

Create a new quote by providing subject, stage, validity date, and optional client details or notes.

Instructions

Create a new quote

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
subjectYesQuote subject
stageYesQuote stage
validuntilYesValid until date (YYYY-MM-DD)
useridNoClient ID
firstnameNoFirst name
lastnameNoLast name
companynameNoCompany name
emailNoEmail
proposalNoProposal text
customernotesNoCustomer notes
adminnotesNoAdmin notes

Implementation Reference

  • src/index.ts:1248-1272 (registration)
    Tool registration in index.ts - defines the 'whmcs_create_quote' tool with input schema (subject, stage, validuntil, userid, etc.) and a handler that calls whmcsClient.createQuote(params)
        'whmcs_create_quote',
        {
            title: 'Create Quote',
            description: 'Create a new quote',
            inputSchema: {
                subject: z.string().describe('Quote subject'),
                stage: z.enum(['Draft', 'Delivered', 'On Hold', 'Accepted', 'Lost', 'Dead']).describe('Quote stage'),
                validuntil: z.string().describe('Valid until date (YYYY-MM-DD)'),
                userid: z.number().optional().describe('Client ID'),
                firstname: z.string().optional().describe('First name'),
                lastname: z.string().optional().describe('Last name'),
                companyname: z.string().optional().describe('Company name'),
                email: z.string().optional().describe('Email'),
                proposal: z.string().optional().describe('Proposal text'),
                customernotes: z.string().optional().describe('Customer notes'),
                adminnotes: z.string().optional().describe('Admin notes'),
            },
        },
        async (params) => {
            const result = await whmcsClient.createQuote(params);
            return {
                content: [{ type: 'text', text: JSON.stringify(result, null, 2) }],
            };
        }
    );
  • Input schema definition for the whmcs_create_quote tool, specifying required fields (subject, stage, validuntil) and optional fields (userid, firstname, lastname, companyname, email, proposal, customernotes, adminnotes)
    inputSchema: {
        subject: z.string().describe('Quote subject'),
        stage: z.enum(['Draft', 'Delivered', 'On Hold', 'Accepted', 'Lost', 'Dead']).describe('Quote stage'),
        validuntil: z.string().describe('Valid until date (YYYY-MM-DD)'),
        userid: z.number().optional().describe('Client ID'),
        firstname: z.string().optional().describe('First name'),
        lastname: z.string().optional().describe('Last name'),
        companyname: z.string().optional().describe('Company name'),
        email: z.string().optional().describe('Email'),
        proposal: z.string().optional().describe('Proposal text'),
        customernotes: z.string().optional().describe('Customer notes'),
        adminnotes: z.string().optional().describe('Admin notes'),
    },
  • Handler function for whmcs_create_quote - delegates to whmcsClient.createQuote(params) and returns JSON-stringified result
    async (params) => {
        const result = await whmcsClient.createQuote(params);
        return {
            content: [{ type: 'text', text: JSON.stringify(result, null, 2) }],
        };
    }
  • The WhmcsApiClient.createQuote method that sends the actual 'CreateQuote' API request to WHMCS. Accepts parameters (subject, stage, validuntil, userid, firstname, lastname, companyname, email, address fields, currency, proposal, customernotes, adminnotes, lineitems) and returns { quoteid }
    async createQuote(params: {
        subject: string;
        stage: 'Draft' | 'Delivered' | 'On Hold' | 'Accepted' | 'Lost' | 'Dead';
        validuntil: string;
        userid?: number;
        firstname?: string;
        lastname?: string;
        companyname?: string;
        email?: string;
        address1?: string;
        address2?: string;
        city?: string;
        state?: string;
        postcode?: string;
        country?: string;
        phonenumber?: string;
        currency?: number;
        proposal?: string;
        customernotes?: string;
        adminnotes?: string;
        lineitems?: Array<{
            desc: string;
            qty: number;
            up: number;
            discount: number;
            taxable: boolean;
        }>;
    }) {
        return this.call<WhmcsApiResponse & { quoteid: number }>('CreateQuote', params);
    }
Behavior2/5

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

No annotations are provided, and the description does not disclose any behavioral traits such as side effects, permissions required, or whether an email is sent. For a mutation tool, this is insufficient.

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

Conciseness3/5

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

The description is a single sentence, which is concise but lacks structure and additional helpful details. It is not wordy, but brevity comes at the cost of missing guidance.

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?

With 11 parameters, no output schema, and no annotations, the description is insufficient. The agent is left uninformed about return values, side effects, or behavior after creation.

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?

All parameters have descriptions in the schema (100% coverage), so the description adds no extra meaning. Baseline 3 applies; the description does not clarify the relationship between userid and name fields.

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?

Description clearly states 'Create a new quote', which is a specific verb and resource. It is unambiguous among sibling tools, but does not explicitly differentiate from similar creation tools like whmcs_create_invoice.

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 on when to use this tool versus alternatives (e.g., when to create a quote vs. an invoice). No context on prerequisites or typical usage scenarios.

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/scarecr0w12/whmcs-mcp-tool'

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