get https://api.mailerlite.com/api/v2/campaigns/
Returns all campaigns you have in your account by :status
which is required. Also basic summary for each campaign including the ID. [Rate limited]
Request
There are three possible values of :status
parameter:
sent
- campaigns which are sent alreadydraft
- campaigns which aren't completed or sent to subscribersoutbox
- campaigns which are being sent right now or scheduled campaigns
If you do not specify :status
parameter, it defaults to sent
.
There are some optional parameters which are described above.
Response Body Parameters
Parameter | Type | Description |
---|---|---|
id | Integer | ID of a campaign |
total_recipients | Integer | Total count of receivers in campaign |
type | String | Possible values:regular ab followup rss |
date_created | String | When the campaign was created |
date_send | String | When the email was sent. If campaign type is outbox , this parameter will show the scheduled date. |
name | String | The internal campaign name. |
subject | String | The subject of the email. |
status | String | Possible values: - sent - draft - outbox |
opened | Object | |
opened.count | Integer | Total opens of campaign. Available only for sent campaigns.Default value: 0 |
opened.rate | Float | Open rate of campaign. Available only for sent campaigns.Default value: 0 |
clicked | Object | |
clicked.count | Integer | Total clicks of campaign. Available only for sent campaigns.Default value: 0 |
clicked.rate | Float | Click rate of campaign. Available only for sent campaigns.Default value: 0 |
/campaigns/:status/count
You can retrieve only the number of campaigns by type. If you do not specify :status
, it defaults to sent
.
Response example
{
"count": 3
}