MCP server
MCP workflows, step by step
The exact order of tool calls for the jobs people ask for most. Each step that is marked confirm means: call once, show the preview to the person, and call again with confirm: true only after they say yes.
Staff working in a customer's workspace: pass workspace on every call below.
Create a campaign with Montana's setup tools
This is the way to make every new campaign. It is the same flow Montana runs in the app chat. Admins only.
setup_context. Read what the workspace has: mailboxes, phone numbers, LinkedIn accounts, reps, credits, the plan and its default monthly budget (a third of the plan's credits), prices per lead and per piece of contact data, what the business sells, and the other campaigns.- Ask the person what you do not know yet, in this order, a few questions at a time: the goal (only if unclear), then the kind of company, its size, where, and the buyer's title; then how new leads should arrive (companies that fit, every day; only companies showing a trigger such as a job post; or both) and the channels. Give each question three or four options backed by what
setup_contextshowed, with one recommended. Never guess a place; offer only places the person named or the business serves. Work out contact data, budget and pace yourself from the channels and the plan. build_campaignwith the wholespec:goal,lead_shape,audience,industries,places(or["anywhere"]),size,titles,why_now,channels,arrival,triggers,monthly_budget,start_count,daily_new, and the person's choices word for word inanswers. It creates a draft campaign, saves the plan, starts a free sample of about 10 real leads in the background, and drafts a suggested cadence (nothing sends). It refuses a campaign with no place, with no audience, and a twin of an existing campaign with the same industries and places unlessseparate: true.campaign_statuson the next turn, before quoting any number. It shows whether the sample isrunning,done,emptyorfailed, and the leads found. Never launch on an empty or failed sample.- Adjust on the same campaign:
build_campaignwithcampaignand only the changed fields ofspec(changing who it targets takes a fresh sample),more_leadsfor 10 more sample leads (free up to 3 runs a day),remove_leadsto drop wrong ones (later samples learn from it). estimate_costbefore launch: the cost per lead, the starting list, the month, and how long the budget lasts.launch_campaign, confirm. Only when the person asks to launch. The preview gives the sample count, the cost and anything missing. Withconfirm: truethe campaign goes live, ready sample leads are added, the starting list is built and charged, and daily finding starts within the monthly budget. New leads wait in the review queue for the first 7 days. It refuses with fewer than 3 sample leads unless the person said to launch anyway (force: true).- The cadence is next: see add a batch to a cadence and start it. The campaign finds leads; nothing is sent until the cadence is approved, has a mailbox, and a batch is added.
The older step by step builder (draft_campaign, update_icp, set_sources, fetch_sample, mark_sample, set_scoring, set_reps, set_cadence, launch_campaign) still works. Use it only to fine tune checks, scoring or reps, or for a campaign that was made with it.
Import leads and load each lead's own drafts
Use this when the person brings their own leads and their own email for each one.
get_cadenceandcadence_settingsfor the campaign. Noteapprove_each_emailandmontana_writes, and which step numbers are email steps.set_cadence_settingswithsettings: { "montana_writes": false }. Do this before anything else, so Montana's background writer does not write drafts for these leads first.import_leads, confirm. Up to 200 leads a call, each with name, phone, email, website and anything you know. Repeat for more. Numbers already in the workspace are reused; do not call and bad numbers are skipped.write_cadenceoredit_stepif the step's general copy needs words, thenapprove_step_copyfor each email step. A step whose copy is still draft sends nothing, not even approved lead drafts.set_lead_draftsfor one step, up to 200{ lead, subject, body }a call.leadcan be the person's email, a contact id, the lead's id, name or phone. If the person has already said these are approved, sendapprove: trueandconfirm: truein the same call. Withoutapprovethe drafts wait for approval.- Check:
list_lead_draftswithstatus: "pending_approval"should be empty for that step, andget_cadenceshows the draft counts. - The leads are in the campaign but not yet in the cadence. Go on with add a batch to a cadence and start it.
If drafts were saved without approval, approve_lead_drafts, confirm, approves them: all of a campaign's, one step's, or chosen draft_ids. Check the ids: if none of them is valid, every waiting draft in scope is approved. To fix one draft, edit_lead_draft with approve: true saves and approves in one call.
Add a batch to a cadence and start it
list_mailboxes. See which mailboxes are connected, which are paused, their daily limits, what each sent in the last 24 hours, and which other cadences already use them.set_cadence_mailboxesto choose the mailboxes this cadence sends from, and each one's cap per day for this cadence (15 unless set). Do this first. A cadence with an email step cannot start without a connected, unpaused mailbox chosen, and there is no fallback to anyone else's mailbox.- If a chosen mailbox is paused:
resume_mailbox_sending, confirm. The preview names every running cadence that would start sending from it. set_mailbox_limitsandset_send_windowif the person wants a different daily limit, gap or sending hours.preview_cadencewith up to 3 sample leads: every step, its day and words, and sample emails with the mailbox and time each would go.test_send, confirm, sends one real step to the person's own address. It never goes to the lead.list_lead_liststo see the batches (lead lists by week).add_lists_to_cadence, confirm, withlists, aweek(a date in that week) orall_ready: true. Waiting leads in those lists start at step 1. Orset_cadence_auto_addwithon: trueso every new lead joins at once.go_live_check. It lists what still blocks sending: steps not approved, no leads, no mailbox, paused mailboxes, drafts waiting for approval.- Start, one of:
set_cadence_runningwithon: true, confirm. Starts it and keeps the approval setting as it is: with approve each email on, only approved emails go.approve_cadence, confirm. Approves every step's copy and every waiting draft, turns approve each email off so Montana's later emails send as written, and starts it. It checks the steps, the mailbox, empty steps and unfilled placeholders before changing anything.set_pilot_modeon, confirm. Goes further: new leads skip review too. If the start is refused, its earlier changes stay, so checkgo_live_checkfirst.
- Confirm it moved:
campaign_statusorabout_campaignshould say "Live, cadence sending", andupcoming_sendsshows the next emails with times.
Why are emails not sending?
Work down this list. Stop when you find the cause.
about_campaignorcampaign_status: is the state "Live, cadence sending"? A draft or paused campaign, or a cadence that is not started, sends nothing.set_campaign_pausedwithpaused: falseresumes a campaign;set_cadence_runningstarts a cadence.go_live_check: steps not approved, no mailbox, mailboxes paused, drafts waiting for approval, no leads in the cadence.cadence_results: per step,emails_waiting_to_sendandwaiting_because. Read the reasons:daily_limit: the mailboxes hit their limit. Remember the mailbox's own daily limit is shared by every cadence and manual email using it; the cadence cap is per cadence. Add mailboxes or raise limits withset_cadence_mailboxesandset_mailbox_limits.mailbox gap: normal pacing between emails from one mailbox.outside_hours: outside the send window, on the lead's clock.draft waiting for approvalorapproval: approve drafts (approve_lead_drafts) or switch approval off (set_cadence_writingwithapprove_each_email: false).step copy not approved:approve_step_copy.waiting for Montana to write: Montana is writing the lead's email; it will go within a few hours, orwrite_lead_emailswrites it now.earlier step not sent yet: the follow up guard. The earlier email has not reached this person yet; fix why that one is waiting.step delay not passed: the step's wait has not passed since the earlier email was sent.draft fails the approval check: the lead's email has a blank field, a greeting with a title and no name, or no address.list_lead_draftsshows itsproblems; fix the words withedit_lead_draft, or the lead, or the mailbox's sender name.
upcoming_sendsfor one lead: the next step, the exact email, the mailbox, the time it can go, why it waits, andproblemswith the email itself.queue_statusfor the call side: how many leads are queued and due.campaign_emailsfor what was really sent, replies, bounces and failures.
"Completed" in cadence numbers means handed to the sender, not sent. Never report a completed count as emails sent.
Remove leads
Pick the tool by how far the lead should go:
| Goal | Tool |
|---|---|
| Stop the cadence for some leads, keep calling them | remove_from_cadence (acts at once, no preview; they stay in the dial queue as calls only) |
| Take leads out of a campaign's cadence and dial queue | remove_from_cadence with exit_campaign: true |
| Take leads out of one campaign, and teach its finding to avoid ones like them | remove_leads, confirm (undo puts them back) |
| Turn down leads waiting in the review queue | decide_review with decision: "dismiss" and a reason |
| Remove leads from the whole workspace, nothing deleted | archive_leads, confirm (restore_leads brings them back) |
| Never call a number again | add_to_dnc |
| Never email an address again (and stop its cadences, like an opt out) | block_email (unblock_email takes it off) |
| Stop everything in a campaign | set_cadence_running off, or set_campaign_paused |
Send leads as a real list of ids, names, phones or emails. Ids are safest when names repeat.
Deals and stages
get_campaignlists the campaign's deal stages and the deals in each.edit_deal_stagesto add (action: "add", withbeforeorafter), rename, move or remove a working stage. Removing a stage with deals in it needsmove_deals_to. Won and Lost can be renamed but not removed. Admins only.create_dealwithlead,campaign,stage(key or name) andvaluein dollars (orvalue_cents). A lead has one open deal: setting a stage moves it.list_deals(filter by campaign, stage, owner, orstale_daysfor deals that have not moved) andmove_dealwithdeal_idand the newstage.
Keep an outside sender off clients
A script that sends email outside Sales Montana (your own sender, an agency's tool) must never write to a signed client or to anyone who asked not to be contacted. do_not_email_list gives it the full list, a page at a time.
- In Sales Montana, Settings, Email and apps, AI assistants, make a personal token at the Read only level, signed in as an admin or rep of the workspace. The token reaches only that workspace and can only read.
- The script calls the tool with JSON-RPC over POST,
limitup to 500, and followsnext_offsetuntil it is gone:
curl -s https://app.salesmontana.com/mcp \
-H "Authorization: Bearer smpat_your_token" \
-H "Content-Type: application/json" \
-d '{"jsonrpc":"2.0","id":1,"method":"tools/call","params":{"name":"do_not_email_list","arguments":{"limit":500,"offset":0}}}'
- The reply's
result.content[0].textis JSON:total,rowsandnext_offsetwhile more remain. Each row hascompany,domain,emails,phonesandreasons(each withsince). Refuse any address in a row'semails, and treat a row'sdomainas taken. - By default a client is a lead with a deal in a won stage, Pending Onboarding or Contracted, or with its own stage Won. Pass
stages(for example["Won", "Contracted"]) to use your own stage names. Leads marked do not contact, phones on the do not call list and every address on the do not email list are always in it. - Read it fresh before each send run; it is read only and cheap.
Calls only leads
To put a lead in a campaign's dial queue without the campaign's cadence ever emailing it, enrol it with calls_only: true (enrol_lead, add_leads_to_campaign, create_lead, import_leads or decide_review). It stays out of the cadence for good, even if set_cadence_auto_add is turned on later, and add_lists_to_cadence skips it. get_lead shows calls_only: true on its queue, and cadence_people with status: "not_in_cadence" lists it as "Calls only".
The review queue
list_review_queuefor a campaign: leads waiting inreview(or another status), best score first, with the signal and decision makers for each.- Show them to the person.
decide_reviewwith a list of{ company, decision, reason }, where decision isaddordismiss. Adding puts the lead in the campaign with the next rep. Dismissing marks it Lost with the reason, which later finding learns from. set_lead_findingwithauto_adddecides whether future leads skip review.
Signals
list_signal_topicsfor a campaign: the job post and LinkedIn post searches it watches each morning.edit_signal_topicwithopset toadd(withkind: "job_postings"androle,location,days, orkind: "linkedin_posts"andsearches),update,on,offorremove. Up to 12 per campaign.set_lead_findingfor how many new leads a day and the monthly budget.credits_overviewfor what finding is spending.
Reporting
| Question | Tool |
|---|---|
| How is a campaign doing? | campaign_report with a period |
| How did the team do? | team_report (admins) |
| How is the cadence doing, step by step? | cadence_results, then cadence_people for who replied, bounced or is stuck |
| What did we send, what came back? | campaign_emails, email_opens |
| Call quality | qa_report, list_calls, get_call |
| Calls we missed | missed_calls |
| Credits | credits_overview |
Mistakes we have seen, and how to avoid them
Approving and confirming in two separate steps, or sending confirm as text. An assistant sent confirm: "true" as text and kept getting the preview back. Send real booleans. When the person has already approved drafts you are loading, use set_lead_drafts with approve: true, confirm: true in one call.
Reading "completed" as "sent". "Completed 260, sent 61" was read as lost emails. They were queued behind the mailboxes' daily limits. Read emails_waiting_to_send and waiting_because.
Forgetting that cadences share mailbox limits. A mailbox's daily limit counts everything it sends. Two cadences on the same ten mailboxes split one limit, and the gap applies across both. Check list_mailboxes before promising a pace.
Montana's drafts racing loaded copy. Leads drafted by Montana before the person's own copy arrived. Set montana_writes: false before loading. Montana never overwrites a draft, but it can write one first, and with approve each email off a Montana draft can send before you replace it.
Expecting a follow up to go first. A later email never goes before the earlier one reached the person, and it goes in the same thread from the same mailbox. If step 1 is stuck, step 2 waits too. Fix step 1.
Starting a cadence with no mailbox. Emails used to go from a lead owner's own mailbox when none was chosen. That fallback is gone, and the start is now refused. Choose mailboxes first.
Adding leads and expecting the cadence to work them. Campaigns made since 1 December do not add new leads to the cadence on their own. Add the batch with add_lists_to_cadence, or turn on auto add. A campaign with 146 leads and none in the cadence sends nothing: go_live_check, upcoming_sends, cadence_results and set_cadence_running all say "146 leads are in this campaign but not in the cadence, so nothing sends". Before 2 December they counted those leads as scheduled.
Editing a step and expecting it to keep sending. Changing a step's words puts it back to draft, and nothing on it sends until approve_step_copy.
Running in the wrong workspace. A staff call without workspace runs in the staff member's own workspace. Name the workspace at the start and pass it every time.
Writing to the database directly. It skips permissions, the log, the undo, the confirmation and the record of who started what. Always use the tools.