Skip to main content
Glama
agentreadycrm

agentreadycrm

Official

Find Or Create Contact

find_or_create_contact
Idempotent

Find an existing CRM contact by external reference, email, or name in an organization, or create a record with the details you have. Use it when a person appears and you need to record or act on them.

Instructions

Find a contact, or create them when this workspace does not hold them yet.

Call it whenever a person comes up that you may record or act on, with everything you know about them in one call. It matches by external reference, then email, then name within the same organization, and a match fills only the values the contact lacks. Never create a name-only contact and call again to add more: to change a value the contact holds use update_contact, and to join two records of one person merge_contacts. For a list of more than a few people use import_contacts. Linking a person to a discovered lookalike organization promotes it to active.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "find_or_create_contact"
  }
}

Input Schema

NameRequiredDescriptionDefault
nameNoThe person's full name. Optional when email is given: a new contact is then named from the address (jane.doe@ becomes "Jane Doe"). Pass name or email.
emailNoTheir email address; the strongest match key after an external reference.
phoneNoTheir phone number.
titleNoTheir role at their organization, e.g. "VP Sales".
fieldsNoCustom field values by key, e.g. {"fit": "strong"}; list_fields lists the keys. A match keeps the values it holds and takes only the keys it lacks.
sourceNoWhere you learned of them (open text, e.g. "research", "manual", "import").
statusNoTheir stage: sourced, enriched, contacted, engaged, or a stage of your own (default "sourced").
fields_byNoWho is setting these fields: an agent, a run, or a person.
lead_sourceNoHow they came to you (open text, e.g. "referral", "inbound", "event").
email_statusNoWhether the address can receive mail. Omit when it has not been checked.
external_refsNoWhat other systems call this record, as opaque URIs (e.g. "crm://people/123", or the source's own record URL). One a record here already holds is the match, ahead of every other key; one held by another record is refused as a conflict, never moved.
organization_idNoThe organization they work at, by id.
organization_nameNoThe organization's name when you hold no id: it is found or created, and the contact is linked to it.

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.2.0

TDQS

A4.8/5.0
Behavior5/5

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

Beyond the annotations (idempotent, non-destructive, closed-world), the description discloses the match precedence chain (external ref, then email, then name scoped to the same organization), that a match back-fills only missing values, that a conflicting external_ref is refused rather than moved, and that linking to a lookalike organization promotes it to active. That is exactly the kind of state-change detail annotations cannot carry.

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?

Purpose is front-loaded, then usage, then alternatives, then edge behavior — a sensible progression with no filler. The second sentence is long and packs match order, partial-fill, anti-pattern, and three sibling references together, which costs a little readability.

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

Completeness5/5

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

For a 13-parameter upsert with annotations and an output schema already supplied, the description covers everything an agent needs: when to call, how matching resolves, what a match does to existing data, the conflict case, and which sibling to use instead. Nothing decision-relevant is left to inference.

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

Parameters4/5

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

With 100% schema coverage the baseline is 3, and the description adds real meaning on top: the ordering of match keys and the organization-scoped name matching, plus the 'only fills values the contact lacks' rule that governs how fields are written. It stops short of explaining the organization_name side effect of creating an organization beyond a single clause.

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 first sentence states a specific verb pair and resource plus the upsert semantics: 'Find a contact, or create them when this workspace does not hold them yet.' It is immediately distinguishable from update_contact, merge_contacts, and import_contacts, which are named for their different jobs.

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

Usage Guidelines5/5

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

It gives a positive trigger ('Call it whenever a person comes up that you may record or act on') and explicit routing to alternatives: update_contact for changing an existing value, merge_contacts for two records of one person, import_contacts for lists of more than a few people. Exclusions and substitutions are both stated.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.