Skip to content

Create Deal

Module · Stable

Create a deal on a company; snapshots FX rate against the main currency at creation time.

Creates a deal linked to a company, or returns the existing one if a deal with the same name already exists for that company (created=false on the output — a deal name is only unique per company, not globally). A deal has two amounts in one currency: value_amount is the one-time amount and value_monthly the recurring amount per month; either may be left out, and neither may be negative. value_currency is ISO 4217; the platform snapshots the FX rate to the workspace’s main currency at creation time. Supply stage_name to use a human-readable pipeline stage label instead of stage_id. Supply source to record the lead channel (e.g. ‘Leadgen form — routario.com’) — resolved by name against the deal-source vocabulary you manage in Settings, registering an unknown label automatically. source_ref (e.g. ‘memory_item::deal:’) adds a faster idempotency lookup on top and survives a rename that would otherwise defeat the name-based match. Returns url, the deal’s page, so a caller can cite the deal it created or found.

Use after Create Company or Find Company has produced a company_id and you want to open a new sales deal at a known value and stage. The deal_id output feeds directly into Move Deal Stage, Add Note, or Create Task to build out the full opportunity record.

If the deal already exists and you only need to change its fields, use Update Deal instead. To advance an existing deal through the pipeline, use Move Deal Stage — calling Create Deal again with the same name for the same company is safe (it upserts) but will not move an existing deal to a different stage or update its other fields.

Configured per use: name, company_id, owner_actor_id, stage_id, stage_name, primary_contact_id, value_amount, value_monthly, value_currency, expected_close_date, source, source_ref.

  • deal_id
  • stage_id
  • value_amount_main
  • created
  • url

Auto-generated from the skill registry (load_skills()). Do not edit by hand.