API ReferencePipelines
Create pipeline
Create a new pipeline for an organization with optional custom stages.
Authorization
sessionAuth AuthorizationBearer <token>
NextAuth session token
In: header
Path Parameters
orgId*string
Format
uuidRequest Body
application/json
name*string
Pipeline name
Length
1 <= lengthdescription?string
triggerCriteria?object
Auto-assignment conditions
stages?array<>
Custom stages (if not provided, defaults are used)
Response Body
application/json
curl -X POST "https://platform.autophone.org/api/organizations/497f6eca-6276-4993-bfeb-53cbbbba6f08/pipelines" \ -H "Content-Type: application/json" \ -d '{ "name": "Sales Pipeline", "description": "Main sales funnel", "stages": [ { "name": "Lead", "color": "#6366f1", "sortOrder": 0 }, { "name": "Qualified", "color": "#06b6d4", "sortOrder": 1 }, { "name": "Closed Won", "color": "#10b981", "sortOrder": 2, "isWonStage": true } ] }'{
"pipeline": {
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
"organizationId": "7bc05553-4b68-44e8-b7bc-37be63c6d9e9",
"name": "string",
"description": "string",
"isDefault": false,
"triggerCriteria": {},
"sortOrder": 0,
"createdAt": "2019-08-24T14:15:22Z",
"stages": [
{
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
"pipelineId": "621ef2b0-ba1d-48e5-89dc-b778e6ed42fd",
"name": "string",
"color": "#6366f1",
"goal": 0,
"sortOrder": 0,
"isWonStage": false,
"isLostStage": false,
"createdAt": "2019-08-24T14:15:22Z"
}
]
}
}Empty
Empty
Empty