Authentication

Deal Flow uses Mautic®'s built-in authentication. All API calls must be made with credentials that have the appropriate Deal Flow permissions.

HTTP Basic Auth

Shell — cURL example
curl -u "your_username:your_password" \ https://your-mautic.com/deal-flow/1/view

OAuth2

Mautic supports OAuth2 for API access. Configure your client in Mautic → Settings → API Credentials, then pass the Bearer token in your requests.

Shell — OAuth2 Bearer token
curl -H "Authorization: Bearer YOUR_ACCESS_TOKEN" \ https://your-mautic.com/deal-flow/1/view
ℹ️

The API is available at your Mautic instance URL. There is no separate Deal Flow API server. All requests go through Mautic's routing layer.

Deals

GET /deal-flow/{page} List deals

Returns a paginated list of deals visible to the authenticated user.

ParameterTypeRequiredDescription
pageintegeroptionalPage number, default 1
GET /deal-flow/view/{objectId} Get a deal

Returns a single deal by ID, including its stage, pipeline, contacts, notes, and tasks.

ParameterTypeRequiredDescription
objectIdintegerrequiredDeal ID
POST /deal-flow/new Create a deal

Creates a new deal. Submit as a form POST with the deal fields.

FieldTypeRequiredDescription
deal[title]stringrequiredDeal title
deal[amount]decimaloptionalDeal value
deal[pipeline]integeroptionalPipeline ID
deal[stage]integeroptionalStage ID
deal[closeDate]dateoptionalExpected close date (YYYY-MM-DD)
deal[owner]integeroptionalMautic user ID
PUT /deal-flow/{objectId}/edit Update a deal

Updates an existing deal. Accepts the same fields as the create endpoint. Only include fields you want to change.

POST /deal-flow/{objectId}/stage Move to stage

Moves a deal to a different stage. Triggers a stage change audit event and syncs deal status.

FieldTypeRequiredDescription
stage_idintegerrequiredTarget stage ID
ℹ️

Moving a deal to a stage with type won or lost automatically updates the deal's status field.

POST /deal-flow/{objectId}/inline Inline field update

Updates a single deal field inline (used by the deal detail view's click-to-edit). Returns JSON with the updated value.

FieldTypeRequiredDescription
fieldstringrequiredField name (e.g. title, amount)
valuemixedrequiredNew value
POST /deal-flow/batch Batch operations

Performs a batch action (delete, change owner, change stage) on multiple deals at once.

FieldTypeRequiredDescription
ids[]integer[]requiredArray of deal IDs
actionstringrequireddelete, reassign, or move_stage

Stages

GET /deal-flow/settings/stages List stages

Returns all pipeline stages visible to the authenticated user.

Pipelines

GET /deal-flow/settings/pipelines List pipelines

Returns all pipelines. Each pipeline contains its stages in order.

Contacts (Buying Committee)

POST /deal-flow/{objectId}/contacts/add Add contact to deal

Associates a Mautic contact with a deal, optionally assigning a role in the buying committee.

FieldTypeRequiredDescription
contact_idintegerrequiredMautic contact ID
rolestringoptionalRole label (e.g. Champion, Economic Buyer)
is_primarybooleanoptionalWhether this is the primary contact
POST /deal-flow/{objectId}/contact/{contactId}/detach Remove contact

Removes a contact from a deal's buying committee.

Notes

POST /deal-flow/{objectId}/notes/add Add note

Adds a note to a deal. Note body supports HTML (sanitized on save).

FieldTypeRequiredDescription
note[body]string (HTML)requiredNote content

Tasks

POST /deal-flow/{objectId}/tasks/add Create task

Creates a task associated with a deal.

FieldTypeRequiredDescription
task[title]stringrequiredTask title
task[dueDate]dateoptionalDue date (YYYY-MM-DD)
task[assignee]integeroptionalMautic user ID to assign to
POST /deal-flow/{objectId}/tasks/{taskId}/complete Complete task

Marks a task as complete. Returns JSON {"success": true}.

Error Responses

Deal Flow follows Mautic's error response conventions. HTTP status codes indicate the result:

StatusMeaning
200Success
403Insufficient permissions
404Deal or resource not found
422Validation error — check response body for field errors
500Server error — check Mautic logs
ℹ️

The interactive API documentation is also available inside your Mautic installation at Deal Flow → Settings → API Docs.