Close is the CRM that sales teams pick when they want to sell, not administrate. But even in a lean CRM, reps still burn time toggling between their inbox, the dialer, and the pipeline view to log what just happened. OpenClaw eliminates that toggle. Connect Close to OpenClaw through a custom skill, and your AI agent handles lead lookups, activity logging, opportunity updates, and pipeline alerts directly from a Telegram or WhatsApp message.
This guide covers the full integration: generating your Close API key, writing the OpenClaw skill file, testing it against live CRM data, and setting up the automations that make the connection worth building. If OpenClaw is already running, you will be done in about 15 minutes. Close uses Basic Auth for its API, which makes this one of the simpler CRM integrations to wire up.
What This Integration Does
Once connected, your OpenClaw agent becomes a chat-based interface to your Close CRM. Instead of clicking through Close’s UI to find a lead, log a call, or check which opportunities are stalling, you message your agent and it handles the API calls.
What you can do out of the box:
- Search leads and contacts by name, email, company, or custom field values
- Check opportunity stages and pipeline health with a single message
- Create and update leads with nested contacts and custom fields
- Log activities like notes, calls, and emails directly from chat
- Get daily pipeline summaries through OpenClaw’s heartbeat scheduling
The agent calls Close’s REST API (v1) using Basic Auth with your API key. No middleware, no paid Zapier tier, no third-party connector. Data flows directly between your machine and Close’s servers.
Before You Start
Three things need to be in place:
-
OpenClaw installed and running on your machine or a VPS. If you have not set it up yet, follow our OpenClaw setup guide first. That guide covers installation, workspace files, memory, and Telegram configuration.
-
A Close CRM account with API access. All Close plans include API access, including the Startup tier. You need permission to create API keys (admin or user-level access depending on your org settings).
-
A text editor for writing the skill file. VS Code, Cursor, or anything that handles Markdown.
Step 1: Get Your Close API Key
Close uses HTTP Basic Authentication for its API. You pass your API key as the username and leave the password blank. This is simpler than HubSpot’s Private App flow or Salesforce’s OAuth dance.
Generate the Key
- Log into Close and click Settings in the left sidebar
- Navigate to Integrations and select API Keys
- Click + New API Key
- Name it something descriptive:
OpenClaw Integration - Click Generate and copy the key immediately
Close shows the full key only once during creation. If you lose it, you will need to delete the key and generate a new one. We recommend keeping a separate API key for every integration so you can revoke access without disrupting other tools.
Store the Key Safely
Do not paste the key directly into your skill file. Store it in a .env file outside your OpenClaw workspace:
# ~/.env or ~/openclaw/.env
CLOSE_API_KEY=api_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
OpenClaw reads environment variables at runtime. This keeps the secret out of any file your agent might log or share.
Step 2: Write the OpenClaw Close Skill
OpenClaw skills are Markdown files that teach your agent how to use an external tool. The skill lives in your workspace’s skills/ directory and contains API call templates your agent adapts at runtime.
Create the Skill Directory
mkdir -p ~/.openclaw/workspace/skills/close-crm
Write the SKILL.md File
Create ~/.openclaw/workspace/skills/close-crm/SKILL.md with this content:
---
name: close-crm
description: Read and write Close CRM data. Manage leads, contacts, opportunities, activities, and tasks via the Close REST API.
tools:
- shell
---
# Close CRM Skill
## Authentication
Use the environment variable `CLOSE_API_KEY` for all API requests.
All requests go to `https://api.close.com/api/v1` using HTTP Basic Auth
with the API key as the username and an empty password.
## Available Operations
### Search Leads
Search leads by name, email, or company:
curl -s -u "$CLOSE_API_KEY:" \
"https://api.close.com/api/v1/lead/?query=SEARCH_TERM&_limit=10&_fields=id,display_name,contacts,status_label" \
| jq '.data[] | {id: .id, name: .display_name, status: .status_label}'
### Get Lead Details
Fetch full details for a specific lead:
curl -s -u "$CLOSE_API_KEY:" \
"https://api.close.com/api/v1/lead/LEAD_ID" \
| jq '{name: .display_name, contacts: .contacts, opportunities: .opportunities, status: .status_label}'
### List Activities for a Lead
Fetch calls, emails, notes, and meetings for a lead:
curl -s -u "$CLOSE_API_KEY:" \
"https://api.close.com/api/v1/activity/?lead_id=LEAD_ID&_limit=20" \
| jq '.data[] | {type: ._type, date: .date_created, note: .note}'
### Create a New Lead
curl -s -u "$CLOSE_API_KEY:" \
-H "Content-Type: application/json" \
-X POST "https://api.close.com/api/v1/lead/" \
-d '{
"name": "COMPANY_NAME",
"contacts": [{
"name": "CONTACT_NAME",
"emails": [{"email": "EMAIL", "type": "office"}],
"phones": [{"phone": "PHONE", "type": "office"}]
}]
}' | jq '{id: .id, name: .display_name}'
### Log a Note on a Lead
curl -s -u "$CLOSE_API_KEY:" \
-H "Content-Type: application/json" \
-X POST "https://api.close.com/api/v1/activity/note/" \
-d '{
"lead_id": "LEAD_ID",
"note": "NOTE_CONTENT"
}' | jq '{id: .id, note: .note}'
### Update an Opportunity
curl -s -u "$CLOSE_API_KEY:" \
-H "Content-Type: application/json" \
-X PUT "https://api.close.com/api/v1/opportunity/OPPORTUNITY_ID" \
-d '{
"status_id": "NEW_STATUS_ID",
"value": VALUE_IN_CENTS,
"note": "STATUS_CHANGE_NOTE"
}' | jq '{id: .id, status: .status_label, value: .value}'
### List Opportunities
curl -s -u "$CLOSE_API_KEY:" \
"https://api.close.com/api/v1/opportunity/?_limit=50&_order_by=-date_updated&_fields=id,lead_name,status_label,value,confidence,date_won" \
| jq '.data[] | {lead: .lead_name, status: .status_label, value: .value, confidence: .confidence}'
## Rules
- Always confirm before creating or updating records. Show the user what will be created or changed and wait for approval.
- When searching leads, try company name first. Fall back to contact name or email if no company is provided.
- For opportunity updates, show the current status and proposed change before executing.
- Close uses "leads" as the top-level object. A lead represents a company and contains contacts. Do not confuse leads with individual people.
- Activities (notes, calls, emails) must reference a lead_id. Fetch the lead first if you only have a contact name.
- If you receive a 429 rate limit response, wait for the number of seconds in the rate_reset header and retry once.
- Never log the API key in responses or memory files.
How Close’s Data Model Works
This is worth understanding before you start querying, because Close structures data differently from HubSpot or Salesforce.
In Close, a lead is the top-level object. It represents a company or organization. Each lead contains one or more contacts (the individual people), plus opportunities (potential deals), tasks, and activities. When you fetch a lead, contacts, opportunities, and tasks come nested in the response. Activities do not. You fetch those separately via the /activity/ endpoint with a lead_id filter.
This means when your agent looks up “John at Acme Corp,” it first searches for the Acme Corp lead, then finds John in the lead’s contacts array. Getting this hierarchy right in your skill file saves your agent from making confused API calls.
Step 3: Test the Connection
Restart OpenClaw so it picks up the new skill:
openclaw gateway restart
Open your Telegram chat with your OpenClaw agent and run these tests:
Read test:
“How many leads do we have in Close?”
The agent should call the leads endpoint and return a count.
Search test:
“Find the lead for Acme Corp in Close”
The agent should return the lead name, status, and contacts.
Activity test:
“Show me the last 5 activities on the Acme Corp lead”
The agent should fetch activities filtered by the lead ID and return them formatted.
Write test (with confirmation):
“Log a note on Acme Corp: Called Sarah, discussed Q3 renewal, she wants a revised proposal by Friday”
The agent should show you the note content and lead it will attach to, then ask for confirmation before posting.
If any test fails, check these common issues:
| Symptom | Likely Cause | Fix |
|---|---|---|
| 401 Unauthorized | API key is wrong or deleted | Check Settings > API Keys in Close |
| Empty results on search | Query syntax mismatch | Try a different search term; Close search is full-text |
| Activities return empty | Wrong lead_id | Verify the lead_id by fetching the lead first |
| Timeout or 429 | Rate limit hit | Wait 10 seconds, retry |
| Agent does not use the skill | Skill directory not detected | Run openclaw gateway restart and check skill name matches |
What to Automate First
Close users tend to be outbound-focused sales teams. The automations that save the most time match that workflow: fast lead lookups between calls, activity logging after conversations, and pipeline monitoring to catch deals going cold.
Week 1: Pipeline Lookups
Use your agent as a faster way to check the CRM during your workday:
- “What stage is the Globex opportunity at?”
- “When was our last activity on the Initech lead?”
- “Show me all opportunities closing this month”
- “Who are the contacts at Widget Corp?”
This builds the habit of talking to your CRM through chat. More importantly, it lets you verify the agent’s responses against Close’s UI before you trust it with write operations.
Week 2: Activity Logging and Lead Updates
Once lookups feel reliable, start creating records:
- “Log a note on Initech: Demo went well, they want to loop in their CTO next week”
- “Create a new lead: DataFlow Inc, contact Sarah Chen, sarah@dataflow.io, 415-555-0123”
- “Update the Widget Corp opportunity to Negotiation stage”
Activity logging is where most teams see the fastest return. After a call, you type one message to your agent instead of navigating to Close, finding the lead, clicking Add Note, and typing the same information in a web form.
Week 3: Automated Pipeline Alerts
Use OpenClaw’s heartbeat to run periodic checks without being asked.
Add this to your heartbeat.md:
## Stale Opportunity Check
Check Close for opportunities that have been in the same stage for more than 10 days.
If any are found, send me a summary in Telegram with the lead name,
opportunity status, days in current stage, and the value.
Or set up a morning pipeline brief:
## Daily Pipeline Brief (runs at 8:00 AM)
Pull all opportunities with status_type "active" from Close.
Group by status. For each opportunity, check if there has been
any activity in the last 3 days. Flag opportunities with no
recent activity. Send the summary to Telegram.
This progression (read, then write, then automate) is the safest way to adopt CRM automation. Skipping straight to automated writes is how you end up with duplicate leads and misattributed activities.
Security Considerations
Your Close API key has full read/write access to your CRM data. Handle it like a database password.
Use a dedicated key. Create a separate API key named OpenClaw Integration so you can revoke it independently without breaking other integrations. Close lets you manage multiple keys under Settings > API Keys.
Store it in .env. Keep the key in a .env file outside your workspace directory. Never put it in agents.md, soul.md, or any workspace file the agent reads into context.
Require confirmation for writes. The skill’s Rules section tells the agent to confirm before creating or updating records. This is your guard against misunderstood instructions. If the agent ever skips confirmation, strengthen the rule language in SKILL.md.
Check the audit trail. Close does not have a dedicated audit log like HubSpot, but you can filter the activity feed by API-created records. Spot-check periodically to confirm the agent is making the calls you expect.
For a deeper look at OpenClaw security practices, see Step 9 in our OpenClaw setup guide.
Frequently Asked Questions
Do I need a paid Close plan to use the API?
All Close plans include API access. The Startup plan ($29/user/month as of early 2026) supports lead, contact, opportunity, and activity endpoints. Higher tiers add features like custom activities and workflows, but the core CRUD operations work on every plan.
How is this different from using Zapier or Make with Close?
Zapier and Make are trigger-based: “when X happens in Close, do Y.” OpenClaw is conversational and proactive. You can ask it questions, give it complex instructions (“find all stale opportunities and draft a follow-up plan”), and it maintains memory across interactions. Zapier handles simple automations well. OpenClaw handles the messy, judgment-dependent tasks that break rigid workflows.
What is Close’s API rate limit?
Close uses dynamic rate limiting rather than a fixed requests-per-second cap. For normal conversational use through OpenClaw, you will not hit the limit. If you do, the API returns a 429 status with a rate_reset value telling you how many seconds to wait. The skill file includes a rule to handle this automatically.
Can OpenClaw update opportunities without asking me first?
Yes, if you configure it that way. The default skill file requires confirmation for all write operations. If you want fully autonomous updates (for example, “mark any opportunity as lost if no activity in 30 days”), you can modify the Rules section. We recommend keeping confirmation on for at least the first two weeks while you build trust in the agent’s accuracy.
Does Close use contacts or leads as the main object?
Leads. This trips up people coming from HubSpot or Salesforce. In Close, a lead represents a company. Contacts (individual people) are nested inside leads. When you search for a person, your agent first finds the lead, then locates the contact within it. The skill file accounts for this hierarchy.
Can I use this with WhatsApp or Slack instead of Telegram?
Yes. The Close skill works regardless of which messaging channel you use with OpenClaw. Telegram, WhatsApp, Slack, Discord, and iMessage are all supported. The only difference is the channel configuration. For always-on availability, you can run OpenClaw on a VPS like Hostinger.
Key Takeaways
- Connect Close to OpenClaw by generating an API key and writing a custom SKILL.md file with Close API call templates
- Close uses Basic Auth (API key as username, empty password), making this one of the simpler CRM integrations
- Understand Close’s data model: leads are the top-level object containing contacts, opportunities, and tasks; activities are fetched separately
- Start with read-only lookups, add write operations after you trust the agent’s responses, then layer in automated alerts via heartbeat
- Store your API key in a
.envfile and require agent confirmation for all write operations until you are confident in accuracy
SFAI Labs