Skip to main content
Glama
ZLeventer

hubspot-mcp

hs_create_contact

Create a new contact in HubSpot CRM by providing an email address. Optionally add name, phone, company, job title, and lifecycle stage. Email is required.

Instructions

Create a new HubSpot contact. Email is required; all other fields are optional.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
emailYes
firstnameNo
lastnameNo
phoneNo
companyNo
jobtitleNo
lifecyclestageNo

Implementation Reference

  • src/index.ts:110-115 (registration)
    Registration of the 'hs_create_contact' tool with the MCP server, binding CreateContactSchema and the createContact handler.
    server.tool(
      "hs_create_contact",
      "Create a new HubSpot contact. Email is required; all other fields are optional.",
      CreateContactSchema.shape,
      async (args) => { try { return ok(await createContact(args)); } catch (e) { return err(e); } },
    );
  • CreateContactSchema: Zod schema defining the input properties for hs_create_contact (email required, firstname/lastname/phone/company/jobtitle/lifecyclestage optional).
    export const CreateContactSchema = z.object({
      email: z.string().email(),
      firstname: z.string().optional(),
      lastname: z.string().optional(),
      phone: z.string().optional(),
      company: z.string().optional(),
      jobtitle: z.string().optional(),
      lifecyclestage: z.string().optional(),
    });
  • createContact handler: constructs properties object from args and calls POST /crm/v3/objects/contacts to create a HubSpot contact.
    export async function createContact(args: z.infer<typeof CreateContactSchema>) {
      const { email, ...rest } = args;
      const properties: Record<string, string> = { email };
      for (const [k, v] of Object.entries(rest)) {
        if (v !== undefined) properties[k] = v;
      }
      return hubspot("/crm/v3/objects/contacts", "POST", { properties });
    }
  • Import statement bringing createContact and CreateContactSchema from src/tools/contacts.ts into the main server file.
    import {
      SearchContactsSchema, searchContacts,
      GetContactSchema, getContact,
      ContactByEmailSchema, contactByEmail,
      RecentContactsSchema, recentContacts,
      CreateContactSchema, createContact,
      UpdateContactSchema, updateContact,
    } from "./tools/contacts.js";
Behavior2/5

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

No behavioral details beyond creation. Does not mention idempotency, duplicate handling, permissions, or rate limits. With no annotations, the description should provide more context.

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?

Very short and to the point, but lacks necessary detail for a creation tool. Not an example of effective conciseness.

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?

No output schema, no description of return value, error handling, or duplicate policies. The description is insufficient for an agent to fully understand the tool's behavior.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Only states Email is required and others optional. Does not explain field meanings, formats, or valid values (e.g., phone, lifecyclestage). Schema coverage is 0%, so description should compensate but fails.

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?

Clearly states the tool creates a HubSpot contact and mentions required vs optional fields. However, does not differentiate from sibling tools like hs_update_contact.

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 such as hs_update_contact or hs_search_contacts.

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/ZLeventer/hubspot-mcp'

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