Opportunity Stage
GET https://leads.qreq.com/api/opportunity-stages
curl --request GET \
--url 'https://leads.qreq.com/api/opportunity-stages' \
--header 'Authorization: Bearer {api_key}'
--url 'https://leads.qreq.com/api/opportunity-stages' \
--header 'Authorization: Bearer {api_key}'
{
"status": "success",
"message": "Opportunity stages retrieved successfully.",
"data": {
"current_page": 1,
"data": [
{
"id": 156,
"name": "Closed Lost",
"color": "#EF4444",
"probability": 0,
"description": null,
"status": "active",
"created_by": 33,
"created_at": "2025-11-01T13:31:42.000000Z",
"updated_at": "2025-11-01T13:31:42.000000Z"
},
{
"id": 155,
"name": "Closed Won",
"color": "#10B981",
"probability": 100,
"description": null,
"status": "active",
"created_by": 33,
"created_at": "2025-11-01T13:31:42.000000Z",
"updated_at": "2025-11-01T13:31:42.000000Z"
},
{
"id": 154,
"name": "Negotiation",
"color": "#8B5CF6",
"probability": 75,
"description": null,
"status": "active",
"created_by": 33,
"created_at": "2025-11-01T13:31:42.000000Z",
"updated_at": "2025-11-01T13:31:42.000000Z"
},
{
"id": 153,
"name": "Proposal",
"color": "#F59E0B",
"probability": 50,
"description": null,
"status": "active",
"created_by": 33,
"created_at": "2025-11-01T13:31:42.000000Z",
"updated_at": "2025-11-01T13:31:42.000000Z"
},
{
"id": 152,
"name": "Qualification",
"color": "#3B82F6",
"probability": 25,
"description": null,
"status": "active",
"created_by": 33,
"created_at": "2025-11-01T13:31:42.000000Z",
"updated_at": "2025-11-01T13:31:42.000000Z"
},
{
"id": 151,
"name": "Prospecting",
"color": "#6B7280",
"probability": 10,
"description": null,
"status": "active",
"created_by": 33,
"created_at": "2025-11-01T13:31:42.000000Z",
"updated_at": "2025-11-01T13:31:42.000000Z"
}
],
"first_page_url": "https://leads.qreq.com/api/opportunity-stages?page=1",
"from": 1,
"last_page": 1,
"last_page_url": "https://leads.qreq.com/api/opportunity-stages?page=1",
"links": [
{
"url": null,
"label": "« Previous",
"page": null,
"active": false
},
{
"url": "https://leads.qreq.com/api/opportunity-stages?page=1",
"label": "1",
"page": 1,
"active": true
},
{
"url": null,
"label": "Next »",
"page": null,
"active": false
}
],
"next_page_url": null,
"path": "https://leads.qreq.com/api/opportunity-stages",
"per_page": 10,
"prev_page_url": null,
"to": 6,
"total": 6
}
}
POST https://leads.qreq.com/api/opportunity-stages
| Parameters | Details | Description |
|---|---|---|
| name | Required String | Stage name |
| color | Required String | Color in HEX format (e.g., #FF5733) |
| probability | Required Integer | Probability percentage (0–100) |
| description | Optional String | Optional description |
| status | Optional String | Active or inactive. Defaults to active |
curl --request POST \
--url 'https://leads.qreq.com/api/opportunity-stages' \
--header 'Authorization: Bearer {api_key}' \
--header 'Content-Type: application/json' \
--data-raw '{ "name": "Negotiation", "color": "#28A745", "probability": 70, "description": "Discussion and deal stage", "status": "active" }'
--url 'https://leads.qreq.com/api/opportunity-stages' \
--header 'Authorization: Bearer {api_key}' \
--header 'Content-Type: application/json' \
--data-raw '{ "name": "Negotiation", "color": "#28A745", "probability": 70, "description": "Discussion and deal stage", "status": "active" }'
{
"status": "success",
"message": "Opportunity stage created successfully.",
"data": {
"name": "test stage",
"color": "#fff",
"probability": "80",
"description": "test stage description",
"status": "active",
"created_by": 33,
"updated_at": "2025-11-03T05:44:23.000000Z",
"created_at": "2025-11-03T05:44:23.000000Z",
"id": 241
}
}
PUT https://leads.qreq.com/api/opportunity-stages/{stage_id}
| Parameters | Details | Description |
|---|---|---|
| name | OptionalString | Stage name |
| color | OptionalString | Color in HEX format |
| probability | OptionalInteger | Probability percentage (0–100) |
| description | OptionalString | Optional description |
| status | OptionalString | Active or inactive |
curl --request PUT \
--url 'https://leads.qreq.com/api/opportunity-stages/{stage_id}' \
--header 'Authorization: Bearer {api_key}' \
--header 'Content-Type: application/json' \
--data-raw '{ "name": "Contract Sent", "color": "#007BFF", "probability": 85, "description": "Awaiting client confirmation", "status": "inactive" }'
--url 'https://leads.qreq.com/api/opportunity-stages/{stage_id}' \
--header 'Authorization: Bearer {api_key}' \
--header 'Content-Type: application/json' \
--data-raw '{ "name": "Contract Sent", "color": "#007BFF", "probability": 85, "description": "Awaiting client confirmation", "status": "inactive" }'
{
"status": "success",
"message": "Opportunity stage updated successfully.",
"data": {
"id": 241,
"name": "test stage 1",
"color": "#fff",
"probability": "80",
"description": "test stage description 1",
"status": "active",
"created_by": 33,
"created_at": "2025-11-03T05:44:23.000000Z",
"updated_at": "2025-11-03T05:46:51.000000Z"
}
}
DELETE https://leads.qreq.com/api/opportunity-stages/{stage_id}
curl --request DELETE \
--url 'https://leads.qreq.com/api/opportunity-stages/{stage_id}' \
--header 'Authorization: Bearer {api_key}'
--url 'https://leads.qreq.com/api/opportunity-stages/{stage_id}' \
--header 'Authorization: Bearer {api_key}'
{
"status": "success",
"message": "Opportunity stage deleted successfully."
}
PATCH https://leads.qreq.com/api/opportunity-stages/{stage_id}/toggle-status
curl --request PATCH \
--url 'https://leads.qreq.com/api/opportunity-stages/{stage_id}/toggle-status' \
--header 'Authorization: Bearer {api_key}'
--url 'https://leads.qreq.com/api/opportunity-stages/{stage_id}/toggle-status' \
--header 'Authorization: Bearer {api_key}'
{
"status": "success",
"message": "Opportunity stage status updated successfully.",
"data": {
"id": 241,
"name": "test stage 1",
"color": "#fff",
"probability": 80,
"description": "test stage description 1",
"status": "inactive",
"created_by": 33,
"created_at": "2025-11-03T05:44:23.000000Z",
"updated_at": "2025-11-03T05:48:23.000000Z"
}
}