Skip to main content
POST
Finish or pause everyone at an account
Finishes or pauses the enrollments of everyone at one company — the “we just booked a meeting there, stop emailing the rest” case.

Dry run first

This can touch many people, so send dry_run: true first. It counts the enrollments that would change and changes nothing:
Check that account is the company you meant and matched is the size you expect, then send the same body without dry_run, with an Idempotency-Key and a reason. The response then has queued: true, and the enrollments change in the background a moment later.

Naming the account

Send one of these. If you send more than one, contact wins, then domain. Personal email domains such as gmail.com never identify a company. An account that cannot be identified returns 422.

What changes

Each changed enrollment gets an account_action event on its timeline, carrying your reason.

Limits

One call considers at most 2,000 contacts at the account and changes at most 500 enrollments. If matched is above 500, call again once the first batch has gone through; enrollments already finished or paused no longer match.

Authorizations

x-api-key
string
header
required

Team-scoped API key generated in the Salesfinity dashboard under Settings → Connections → API & Webhooks. A missing or invalid key returns HTTP 403.

Headers

Idempotency-Key
string

Makes this write safe to retry. Send a unique value, such as a UUID, and send the same value again when you retry the same request. A retry with the same key and the same request (method, path including the query string, and JSON body) returns the original successful response without acting twice. The same key with a different body or path returns 409, and so does a retry while the first request is still running; that one is safe to repeat after a moment. A request that fails frees its key, so a retry runs the write again: after a 5xx on a create, confirm with a GET before retrying. Keys are kept for 24 hours and are scoped to your team.

Body

application/json
user_id
string
required

The team member this call acts as. Must be an active member of the team the API key belongs to.

Example:

"507f1f77bcf86cd799439011"

action
enum<string>
required

finish ends every live enrollment at the account. pause pauses the active ones.

Available options:
finish,
pause
scope
enum<string>
required

sequence limits it to one sequence and needs the sequence's author, the team owner or a team admin as user_id. team covers every sequence the team runs and needs the team owner or a team admin.

Available options:
sequence,
team
contact
string

A contact on your team; the action targets that contact's company. Send this, domain or company_name. When more than one is sent, contact wins, then domain.

domain
string

A company domain, such as acme.com. A URL or www. prefix is stripped. Matches contacts whose email address is at this domain.

Maximum string length: 253
company_name
string

A company name. Matches contacts with the same company name once case, punctuation and suffixes such as Inc or LLC are ignored.

Maximum string length: 200
sequence
string

The sequence to act on. Required when scope is sequence, and ignored otherwise.

days
number

How long a pause lasts, in whole days; the enrollments resume themselves after it. Leave it out to pause until someone resumes them. Ignored for finish.

Required range: 1 <= x <= 365
reason
string

Why. Recorded on each changed enrollment's account_action timeline event.

Maximum string length: 500
dry_run
boolean
default:false

Count the enrollments that would change, and change nothing.

Response

How many enrollments matched, and whether the change was queued.

account
object
required

The account the action resolved to. kind is company (a company record id), domain (an email domain) or name (a normalized company name).

matched
integer
required

Enrollments the action applies to: every live enrollment for finish, every active one for pause.

queued
boolean
required

True when the change was queued. False for a dry run, or when nothing matched.