Campaign List
Endpoint
GET /api/v6.1/campaigns
Request Example
curl --location 'https://demo.getflycrm.com/api/v6.1/campaigns?fields=id%2Ccampaign_code%2Ccampaign_name%2Ccreate_user%2Cresponsible%2Ctime_registed%2Callow_duplicate_opp%2Copportunity_status%2Crelated_users%2Cis_lock' \
--header 'X-API-KEY: ADP8QgZR2f0dd6ryjfrXQhtM38Z7MP'
Query Parameters
Name | Type | Description |
---|---|---|
fields | string | List of fields to retrieve |
Response
{
"data": {
"id": 25,
"campaign_code": "CD_OAN",
"campaign_name": "Campaign 1",
"create_user": 2,
"responsible": 2,
"time_registed": 0,
"allow_duplicate_opp": 1,
"is_lock": 0,
"related_users": [
{
"user_id": 1,
"accept_opp": 1,
"divided_percent": 50
},
{
"user_id": 2,
"accept_opp": 0,
"divided_percent": 0
},
{
"user_id": 4,
"accept_opp": 1,
"divided_percent": 50
}
],
"opportunity_status": [
{
"status_id": 98,
"name": "Customer Information",
"description": "",
"order": 1
},
{
"status_id": 99,
"name": "Customer Approach",
"description": "",
"order": 2
},
{
"status_id": 100,
"name": "Meeting and Care",
"description": "",
"order": 3
},
{
"status_id": 101,
"name": "Closing Sales - Selling",
"description": "",
"order": 4
}
]
},
"offset": 0,
"limited": false,
"sorted": {
"updated_at": "DESC"
}
}
Field Explanations
Field | Type | Description |
---|---|---|
id | int | Campaign ID |
campaign_code | string | Campaign code |
campaign_name | string | Campaign name |
create_user | int | Campaign creator ID |
responsible | int | Main responsible person ID |
time_registed | int | Registration time (0 if none) |
allow_duplicate_opp | int | Allow duplicate opportunities (1 = yes) |
is_lock | int | Campaign lock status (1 = yes) |
related_users | array | List of campaign related users |
opportunity_status | array | List of opportunity processing statuses |
Notes
divided_percent
can be 0 or null if the user does not accept division.- Opportunity statuses are sorted by the
order
field.