When a new client sends a message, a deal is created. In which funnel the deal will be created depends on the settings in Wazzup interface. To download or update sales funnels with stages, you need to call:
https://api.wazzup24.com/v3/pipelinesPOST https://api.wazzup24.com/v3/pipelines
└── [array of objects]
├── id
├── name
└── stages[]
├── id
└── name
| Parameter | Type | Description |
| id | any | ID funnel, no more than 100 characters |
| name | string | Funnel name, which will be displayed in the integration settings. No more than 100 characters |
| stages | array of objects stages | Array with funnel stages. If there are no stages in the CRM, but there are several funnels, the "stages" parameter shouldn't be sent. If stages exists, but equals an empty array, an error will occur |
| Parameter | Type | Description |
| id | string | Funnel stage ID, max 100 characters |
| name | string | Name of the funnel stage, no more than 100 characters |
fetch("https://api.wazzup24.com/v3/pipelines", {
method: "POST",
headers: {
"Content-Type": "application/json",
"Authorization": "Bearer {apiKey}",
},
body: [
{
id: "string-id",
name: "Signed up"
stages: [
{
id: "1"
name: "Test period"
},
...
]
},
...
]
});
To get a list of loaded funnels, call:
https://api.wazzup24.com/v3/pipelinesHTTP/1.1 200 OK
[
{
id: "string-id",
name: "Signed up"
stages: [
{
id: "1"
name: "Test period"
},
...
]
},
...
]