Deals
Track sales opportunities through your pipeline stages. Manage deal notes, tasks, emails, and risk scoring. Import and export deal data.
Authorization: Bearer <token> header. Some endpoints require Admin role.Core Endpoints
Retrieve a paginated list of deals. Includes risk scoring for open deals.
Query Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| page | integer | Optional | Page number for pagination. Default: 1 |
| per_page | integer | Optional | Number of results per page (max 100). Default: 25. Max: 100 |
| search | string | Optional | Search term to filter results |
| stage_id | integer | Optional | Filter by pipeline stage |
| assigned_to | integer | Optional | |
| won | string | Optional | Filter won/lost deals. Values: 0, 1 |
| stage_ids | string | Optional | Comma-separated list of stage IDs to filter by |
| date_from | string | Optional | Filter by date range start (YYYY-MM-DD) |
| date_to | string | Optional | Filter by date range end (YYYY-MM-DD) |
| date_field | string | Optional | Date field to filter on (default: expected_close_date). Values: expected_close_date, closed_at, created_at |
| scope | string | Optional | Filter by user scope (me, team, company). Values: me, team, company |
| sort_by | string | Optional | Sort field (default: title). Values: title, contact_name, company_name, stage_name, value, expected_close_date, closed_at, assigned_to_name, created_at |
| sort_dir | string | Optional | Sort direction (default: ASC). Values: ASC, DESC |
Response
Paginated deal list
{
"data": [
{
"id": 10,
"name": "Acme Enterprise License",
"value": 50000,
"stage_id": 3,
"stage_name": "Proposal",
"contact_id": 1,
"contact_name": "Jane Smith",
"company_id": 1,
"company_name": "Acme Corp",
"probability": 60,
"expected_close_date": "2026-03-15",
"is_won": false,
"is_lost": false,
"loss_reason": "...",
"assigned_to": 1,
"assigned_name": "...",
"notes": "...",
"tags": "...",
"partner_id": 1,
"reseller_id": 1,
"reseller_name": "Channel Partners Inc",
"reseller_contact_name": "Bob Wilson",
"risk": {
"risk_level": "medium",
"risk_score": 45,
"risk_factors": [
{
"label": "...",
"detail": "...",
"weight": "..."
}
]
},
"created_at": "2026-01-15T09:30:00.000000Z",
"updated_at": "2026-01-15T09:30:00.000000Z"
}
],
"current_page": 1,
"last_page": 1,
"per_page": 1,
"total": 1
}Code Examples
curl -X GET "https://crm.revorbit.com/api/deals" \ -H "Authorization: Bearer YOUR_JWT_TOKEN"
const response = await fetch(
"https://crm.revorbit.com/api/deals",
{
method: "GET",
headers: {
"Authorization": "Bearer YOUR_JWT_TOKEN",
}
}
);
const data = await response.json();Request Body
| Name | Type | Required | Description |
|---|---|---|---|
| name | string | Required | Deal name/title |
| value | number | Optional | Monetary value |
| stage_id | integer | Required | Pipeline stage ID |
| contact_id | integer | Optional | Ship To contact ID |
| bill_to_contact_id | integer | Optional | Bill To contact ID |
| company_id | integer | Optional | Associated company (Ship To) ID |
| partner_id | integer | Optional | Bill To company ID. Nullable |
| reseller_id | integer | Optional | Reseller company ID. Nullable |
| reseller_contact_id | integer | Optional | Reseller contact ID. Nullable |
| probability | integer | Optional | Win probability percentage (0-100) |
| expected_close_date | date | Optional | Expected close date (YYYY-MM-DD) |
| assigned_to | integer | Optional | |
| notes | string | Optional | |
| tags | string | Optional |
Code Examples
curl -X POST "https://crm.revorbit.com/api/deals" \
-H "Authorization: Bearer YOUR_JWT_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"name": "...",
"value": 1,
"stage_id": 1,
"contact_id": 1,
"bill_to_contact_id": 1,
"company_id": 1,
"partner_id": 1,
"reseller_id": 1,
"reseller_contact_id": 1,
"probability": 1,
"expected_close_date": "2026-01-15",
"assigned_to": 1,
"notes": "...",
"tags": "..."
}'const response = await fetch(
"https://crm.revorbit.com/api/deals",
{
method: "POST",
headers: {
"Authorization": "Bearer YOUR_JWT_TOKEN",
"Content-Type": "application/json"
},
body: JSON.stringify(
{
"name": "...",
"value": 1,
"stage_id": 1,
"contact_id": 1,
"bill_to_contact_id": 1,
"company_id": 1,
"partner_id": 1,
"reseller_id": 1,
"reseller_contact_id": 1,
"probability": 1,
"expected_close_date": "2026-01-15",
"assigned_to": 1,
"notes": "...",
"tags": "..."
}
)
}
);
const data = await response.json();Retrieve deals grouped by pipeline stage for Kanban view. Includes risk scoring. Supports optional date range, scope, and assignee filtering.
Query Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| date_from | string | Optional | Filter start date |
| date_to | string | Optional | Filter end date |
| date_field | string | Optional | Date field to filter on. Values: expected_close_date, closed_at, created_at. Default: expected_close_date |
| scope | string | Optional | Scope filter. Values: me, team, company |
| assigned_to | integer | Optional | Filter by assigned user ID |
Code Examples
curl -X GET "https://crm.revorbit.com/api/deals/pipeline" \ -H "Authorization: Bearer YOUR_JWT_TOKEN"
const response = await fetch(
"https://crm.revorbit.com/api/deals/pipeline",
{
method: "GET",
headers: {
"Authorization": "Bearer YOUR_JWT_TOKEN",
}
}
);
const data = await response.json();Retrieve all pipeline stages with display order.
Response
Stage list
{
"success": true,
"data": [
{
"id": 3,
"name": "Proposal",
"display_order": 3,
"probability": 50,
"is_won": false,
"is_lost": false,
"color": "#3b82f6"
}
]
}Code Examples
curl -X GET "https://crm.revorbit.com/api/deals/stages" \ -H "Authorization: Bearer YOUR_JWT_TOKEN"
const response = await fetch(
"https://crm.revorbit.com/api/deals/stages",
{
method: "GET",
headers: {
"Authorization": "Bearer YOUR_JWT_TOKEN",
}
}
);
const data = await response.json();Aggregate pipeline statistics (total value, count, win rate, etc.).
Code Examples
curl -X GET "https://crm.revorbit.com/api/deals/stats" \ -H "Authorization: Bearer YOUR_JWT_TOKEN"
const response = await fetch(
"https://crm.revorbit.com/api/deals/stats",
{
method: "GET",
headers: {
"Authorization": "Bearer YOUR_JWT_TOKEN",
}
}
);
const data = await response.json();Retrieve a single deal with full details including risk score.
Path Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| id | integer | Required | Resource ID |
Response
Deal details
{
"success": true,
"data": {
"id": 10,
"name": "Acme Enterprise License",
"value": 50000,
"stage_id": 3,
"stage_name": "Proposal",
"contact_id": 1,
"contact_name": "Jane Smith",
"company_id": 1,
"company_name": "Acme Corp",
"probability": 60,
"expected_close_date": "2026-03-15",
"is_won": false,
"is_lost": false,
"loss_reason": "...",
"assigned_to": 1,
"assigned_name": "...",
"notes": "...",
"tags": "...",
"partner_id": 1,
"reseller_id": 1,
"reseller_name": "Channel Partners Inc",
"reseller_contact_name": "Bob Wilson",
"risk": {
"risk_level": "medium",
"risk_score": 45,
"risk_factors": [
{
"label": "No activity",
"detail": "25 days",
"weight": 25
}
]
},
"created_at": "2026-01-15T09:30:00.000000Z",
"updated_at": "2026-01-15T09:30:00.000000Z"
}
}Code Examples
curl -X GET "https://crm.revorbit.com/api/deals/{id}" \
-H "Authorization: Bearer YOUR_JWT_TOKEN"const response = await fetch(
"https://crm.revorbit.com/api/deals/{id}",
{
method: "GET",
headers: {
"Authorization": "Bearer YOUR_JWT_TOKEN",
}
}
);
const data = await response.json();Path Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| id | integer | Required | Resource ID |
Request Body
| Name | Type | Required | Description |
|---|---|---|---|
| name | string | Required | Deal name/title |
| value | number | Optional | Monetary value |
| stage_id | integer | Required | Pipeline stage ID |
| contact_id | integer | Optional | Ship To contact ID |
| bill_to_contact_id | integer | Optional | Bill To contact ID |
| company_id | integer | Optional | Associated company (Ship To) ID |
| partner_id | integer | Optional | Bill To company ID. Nullable |
| reseller_id | integer | Optional | Reseller company ID. Nullable |
| reseller_contact_id | integer | Optional | Reseller contact ID. Nullable |
| probability | integer | Optional | Win probability percentage (0-100) |
| expected_close_date | date | Optional | Expected close date (YYYY-MM-DD) |
| assigned_to | integer | Optional | |
| notes | string | Optional | |
| tags | string | Optional |
Code Examples
curl -X PUT "https://crm.revorbit.com/api/deals/{id}" \
-H "Authorization: Bearer YOUR_JWT_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"name": "...",
"value": 1,
"stage_id": 1,
"contact_id": 1,
"bill_to_contact_id": 1,
"company_id": 1,
"partner_id": 1,
"reseller_id": 1,
"reseller_contact_id": 1,
"probability": 1,
"expected_close_date": "2026-01-15",
"assigned_to": 1,
"notes": "...",
"tags": "..."
}'const response = await fetch(
"https://crm.revorbit.com/api/deals/{id}",
{
method: "PUT",
headers: {
"Authorization": "Bearer YOUR_JWT_TOKEN",
"Content-Type": "application/json"
},
body: JSON.stringify(
{
"name": "...",
"value": 1,
"stage_id": 1,
"contact_id": 1,
"bill_to_contact_id": 1,
"company_id": 1,
"partner_id": 1,
"reseller_id": 1,
"reseller_contact_id": 1,
"probability": 1,
"expected_close_date": "2026-01-15",
"assigned_to": 1,
"notes": "...",
"tags": "..."
}
)
}
);
const data = await response.json();Path Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| id | integer | Required | Resource ID |
Code Examples
curl -X DELETE "https://crm.revorbit.com/api/deals/{id}" \
-H "Authorization: Bearer YOUR_JWT_TOKEN"const response = await fetch(
"https://crm.revorbit.com/api/deals/{id}",
{
method: "DELETE",
headers: {
"Authorization": "Bearer YOUR_JWT_TOKEN",
}
}
);
const data = await response.json();Move a deal to a different pipeline stage.
Path Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| id | integer | Required | Resource ID |
Request Body
| Name | Type | Required | Description |
|---|---|---|---|
| stage_id | integer | Required |
Code Examples
curl -X PUT "https://crm.revorbit.com/api/deals/{id}/stage" \
-H "Authorization: Bearer YOUR_JWT_TOKEN" \
-H "Content-Type: application/json" \
-d '{"stage_id":1}'const response = await fetch(
"https://crm.revorbit.com/api/deals/{id}/stage",
{
method: "PUT",
headers: {
"Authorization": "Bearer YOUR_JWT_TOKEN",
"Content-Type": "application/json"
},
body: JSON.stringify(
{
"stage_id": 1
}
)
}
);
const data = await response.json();Set which quote is the primary quote for this deal.
Path Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| id | integer | Required | Resource ID |
Request Body
| Name | Type | Required | Description |
|---|---|---|---|
| quote_id | integer | Required |
Code Examples
curl -X PUT "https://crm.revorbit.com/api/deals/{id}/primary-quote" \
-H "Authorization: Bearer YOUR_JWT_TOKEN" \
-H "Content-Type: application/json" \
-d '{"quote_id":1}'const response = await fetch(
"https://crm.revorbit.com/api/deals/{id}/primary-quote",
{
method: "PUT",
headers: {
"Authorization": "Bearer YOUR_JWT_TOKEN",
"Content-Type": "application/json"
},
body: JSON.stringify(
{
"quote_id": 1
}
)
}
);
const data = await response.json();Path Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| id | integer | Required | Resource ID |
Request Body
| Name | Type | Required | Description |
|---|---|---|---|
| content | string | Required |
Code Examples
curl -X POST "https://crm.revorbit.com/api/deals/{id}/notes" \
-H "Authorization: Bearer YOUR_JWT_TOKEN" \
-H "Content-Type: application/json" \
-d '{"content":"..."}'const response = await fetch(
"https://crm.revorbit.com/api/deals/{id}/notes",
{
method: "POST",
headers: {
"Authorization": "Bearer YOUR_JWT_TOKEN",
"Content-Type": "application/json"
},
body: JSON.stringify(
{
"content": "..."
}
)
}
);
const data = await response.json();Path Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| id | integer | Required | Resource ID |
| noteId | integer | Required |
Code Examples
curl -X DELETE "https://crm.revorbit.com/api/deals/{id}/notes/{noteId}" \
-H "Authorization: Bearer YOUR_JWT_TOKEN"const response = await fetch(
"https://crm.revorbit.com/api/deals/{id}/notes/{noteId}",
{
method: "DELETE",
headers: {
"Authorization": "Bearer YOUR_JWT_TOKEN",
}
}
);
const data = await response.json();Path Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| id | integer | Required | Resource ID |
Code Examples
curl -X GET "https://crm.revorbit.com/api/deals/{id}/tasks" \
-H "Authorization: Bearer YOUR_JWT_TOKEN"const response = await fetch(
"https://crm.revorbit.com/api/deals/{id}/tasks",
{
method: "GET",
headers: {
"Authorization": "Bearer YOUR_JWT_TOKEN",
}
}
);
const data = await response.json();Path Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| id | integer | Required | Resource ID |
Request Body
| Name | Type | Required | Description |
|---|---|---|---|
| title | string | Required | |
| description | string | Optional | |
| due_date | date | Optional | |
| due_time | string | Optional | |
| priority | string | Optional | Values: low, medium, high |
| assigned_to | integer | Optional | |
| contact_id | integer | Optional | |
| company_id | integer | Optional | |
| deal_id | integer | Optional |
Code Examples
curl -X POST "https://crm.revorbit.com/api/deals/{id}/tasks" \
-H "Authorization: Bearer YOUR_JWT_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"title": "...",
"description": "...",
"due_date": "2026-01-15",
"due_time": "...",
"priority": "low",
"assigned_to": 1,
"contact_id": 1,
"company_id": 1,
"deal_id": 1
}'const response = await fetch(
"https://crm.revorbit.com/api/deals/{id}/tasks",
{
method: "POST",
headers: {
"Authorization": "Bearer YOUR_JWT_TOKEN",
"Content-Type": "application/json"
},
body: JSON.stringify(
{
"title": "...",
"description": "...",
"due_date": "2026-01-15",
"due_time": "...",
"priority": "low",
"assigned_to": 1,
"contact_id": 1,
"company_id": 1,
"deal_id": 1
}
)
}
);
const data = await response.json();Path Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| id | integer | Required | Resource ID |
| taskId | integer | Required |
Request Body
| Name | Type | Required | Description |
|---|---|---|---|
| title | string | Required | |
| description | string | Optional | |
| due_date | date | Optional | |
| due_time | string | Optional | |
| priority | string | Optional | Values: low, medium, high |
| assigned_to | integer | Optional | |
| contact_id | integer | Optional | |
| company_id | integer | Optional | |
| deal_id | integer | Optional |
Code Examples
curl -X PUT "https://crm.revorbit.com/api/deals/{id}/tasks/{taskId}" \
-H "Authorization: Bearer YOUR_JWT_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"title": "...",
"description": "...",
"due_date": "2026-01-15",
"due_time": "...",
"priority": "low",
"assigned_to": 1,
"contact_id": 1,
"company_id": 1,
"deal_id": 1
}'const response = await fetch(
"https://crm.revorbit.com/api/deals/{id}/tasks/{taskId}",
{
method: "PUT",
headers: {
"Authorization": "Bearer YOUR_JWT_TOKEN",
"Content-Type": "application/json"
},
body: JSON.stringify(
{
"title": "...",
"description": "...",
"due_date": "2026-01-15",
"due_time": "...",
"priority": "low",
"assigned_to": 1,
"contact_id": 1,
"company_id": 1,
"deal_id": 1
}
)
}
);
const data = await response.json();Path Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| id | integer | Required | Resource ID |
| taskId | integer | Required |
Code Examples
curl -X DELETE "https://crm.revorbit.com/api/deals/{id}/tasks/{taskId}" \
-H "Authorization: Bearer YOUR_JWT_TOKEN"const response = await fetch(
"https://crm.revorbit.com/api/deals/{id}/tasks/{taskId}",
{
method: "DELETE",
headers: {
"Authorization": "Bearer YOUR_JWT_TOKEN",
}
}
);
const data = await response.json();Combined timeline of all emails linked to a deal.
Path Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| id | integer | Required | Resource ID |
Code Examples
curl -X GET "https://crm.revorbit.com/api/deals/{id}/timeline" \
-H "Authorization: Bearer YOUR_JWT_TOKEN"const response = await fetch(
"https://crm.revorbit.com/api/deals/{id}/timeline",
{
method: "GET",
headers: {
"Authorization": "Bearer YOUR_JWT_TOKEN",
}
}
);
const data = await response.json();Path Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| id | integer | Required | Resource ID |
Code Examples
curl -X GET "https://crm.revorbit.com/api/deals/{id}/linked-emails" \
-H "Authorization: Bearer YOUR_JWT_TOKEN"const response = await fetch(
"https://crm.revorbit.com/api/deals/{id}/linked-emails",
{
method: "GET",
headers: {
"Authorization": "Bearer YOUR_JWT_TOKEN",
}
}
);
const data = await response.json();Code Examples
curl -X GET "https://crm.revorbit.com/api/deals/export" \ -H "Authorization: Bearer YOUR_JWT_TOKEN"
const response = await fetch(
"https://crm.revorbit.com/api/deals/export",
{
method: "GET",
headers: {
"Authorization": "Bearer YOUR_JWT_TOKEN",
}
}
);
const data = await response.json();Code Examples
curl -X GET "https://crm.revorbit.com/api/deals/template" \ -H "Authorization: Bearer YOUR_JWT_TOKEN"
const response = await fetch(
"https://crm.revorbit.com/api/deals/template",
{
method: "GET",
headers: {
"Authorization": "Bearer YOUR_JWT_TOKEN",
}
}
);
const data = await response.json();Request Body
| Name | Type | Required | Description |
|---|---|---|---|
| file | file | Optional |
Code Examples
curl -X POST "https://crm.revorbit.com/api/deals/import" \ -H "Authorization: Bearer YOUR_JWT_TOKEN" \ -F "file=@/path/to/file"
const response = await fetch(
"https://crm.revorbit.com/api/deals/import",
{
method: "POST",
headers: {
"Authorization": "Bearer YOUR_JWT_TOKEN",
}
}
);
const data = await response.json();Pipeline Stages
Create a new pipeline stage.
Request Body
| Name | Type | Required | Description |
|---|---|---|---|
| name | string | Required | |
| probability | integer | Optional | |
| color | string | Optional | |
| is_won | boolean | Optional | |
| is_lost | boolean | Optional |
Code Examples
curl -X POST "https://crm.revorbit.com/api/pipeline-stages" \
-H "Authorization: Bearer YOUR_JWT_TOKEN" \
-H "Content-Type: application/json" \
-d '{"name":"...","probability":1,"color":"...","is_won":true,"is_lost":true}'const response = await fetch(
"https://crm.revorbit.com/api/pipeline-stages",
{
method: "POST",
headers: {
"Authorization": "Bearer YOUR_JWT_TOKEN",
"Content-Type": "application/json"
},
body: JSON.stringify(
{
"name": "...",
"probability": 1,
"color": "...",
"is_won": true,
"is_lost": true
}
)
}
);
const data = await response.json();Batch-update display order of all pipeline stages.
Request Body
| Name | Type | Required | Description |
|---|---|---|---|
| order | array[integer] | Required | Array of stage IDs in desired display order |
Code Examples
curl -X PUT "https://crm.revorbit.com/api/pipeline-stages/reorder" \
-H "Authorization: Bearer YOUR_JWT_TOKEN" \
-H "Content-Type: application/json" \
-d '{"order":[1]}'const response = await fetch(
"https://crm.revorbit.com/api/pipeline-stages/reorder",
{
method: "PUT",
headers: {
"Authorization": "Bearer YOUR_JWT_TOKEN",
"Content-Type": "application/json"
},
body: JSON.stringify(
{
"order": [
1
]
}
)
}
);
const data = await response.json();Path Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| id | integer | Required | Resource ID |
Request Body
| Name | Type | Required | Description |
|---|---|---|---|
| name | string | Optional | |
| color | string | Optional | |
| is_won | boolean | Optional | |
| is_lost | boolean | Optional |
Code Examples
curl -X PUT "https://crm.revorbit.com/api/pipeline-stages/{id}" \
-H "Authorization: Bearer YOUR_JWT_TOKEN" \
-H "Content-Type: application/json" \
-d '{"name":"...","color":"...","is_won":true,"is_lost":true}'const response = await fetch(
"https://crm.revorbit.com/api/pipeline-stages/{id}",
{
method: "PUT",
headers: {
"Authorization": "Bearer YOUR_JWT_TOKEN",
"Content-Type": "application/json"
},
body: JSON.stringify(
{
"name": "...",
"color": "...",
"is_won": true,
"is_lost": true
}
)
}
);
const data = await response.json();Path Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| id | integer | Required | Resource ID |
Code Examples
curl -X DELETE "https://crm.revorbit.com/api/pipeline-stages/{id}" \
-H "Authorization: Bearer YOUR_JWT_TOKEN"const response = await fetch(
"https://crm.revorbit.com/api/pipeline-stages/{id}",
{
method: "DELETE",
headers: {
"Authorization": "Bearer YOUR_JWT_TOKEN",
}
}
);
const data = await response.json();