AgentSkillsCN

hubspot-update-deal

更新HubSpot CRM中的现有交易。当用户说“更新交易”、“编辑交易”、“更改交易阶段”、“移动交易”或“结束交易”时加载。需要交易ID。

SKILL.md
--- frontmatter
name: hubspot-update-deal
description: "Update an existing deal in HubSpot CRM. Load when user says 'update deal', 'edit deal', 'change deal stage', 'move deal', 'close deal'. Requires deal ID."

Update HubSpot Deal

Specialized skill for updating deals in HubSpot CRM.

Pre-Flight Check

Before running, execute config check:

bash
python 00-system/skills/hubspot/hubspot-master/scripts/check_hubspot_config.py --json

If ai_action is not proceed_with_operation, follow hubspot-connect setup guide.


Usage

Required Parameters

  • --id - Deal ID (required)

Optional Parameters (at least one required)

  • --name - New deal name
  • --amount - New deal value
  • --stage - New deal stage
  • --closedate - New close date (YYYY-MM-DD)

Examples

Update stage (move deal):

bash
python 00-system/skills/hubspot/hubspot-master/scripts/update_deal.py \
  --id 5840795376 \
  --stage "closedwon" \
  --json

Update amount:

bash
python 00-system/skills/hubspot/hubspot-master/scripts/update_deal.py \
  --id 5840795376 \
  --amount 75000 \
  --json

Close deal as won:

bash
python 00-system/skills/hubspot/hubspot-master/scripts/update_deal.py \
  --id 5840795376 \
  --stage "closedwon" \
  --closedate "2025-12-13" \
  --json

Common Deal Stages

Stage IDName
appointmentscheduledAppointment Scheduled
qualifiedtobuyQualified to Buy
presentationscheduledPresentation Scheduled
decisionmakerboughtinDecision Maker Bought In
contractsentContract Sent
closedwonClosed Won
closedlostClosed Lost

Finding Deal ID

If user says "close the Acme deal", first search:

bash
python 00-system/skills/hubspot/hubspot-master/scripts/search_deals.py --name "Acme" --json

Then use the returned ID for the update.


Output Format

json
{
  "id": "5840795376",
  "properties": {
    "dealname": "Acme Corp - Enterprise",
    "amount": "75000",
    "dealstage": "closedwon",
    "hs_lastmodifieddate": "2025-12-13T10:30:00Z"
  }
}

Display Format

code
✅ Deal updated!
  ID: 5840795376
  Name: Acme Corp - Enterprise
  Updated fields:
    - stage: Closed Won
    - amount: $75,000

Error Handling

ErrorSolution
401Invalid token - re-run setup
403Missing crm.objects.deals.write scope
404Deal not found - check ID
400Invalid stage ID
429Rate limited - wait and retry

Related Skills

  • hubspot-search-deals - Find deal ID
  • hubspot-list-deals - List all deals
  • hubspot-create-deal - Create new deal