The Email Campaign object

Attributes

id string

Unique identifier for the object.

created_at string

ISO 8601 timestamp of when the object was created.

updated_at string

ISO 8601 timestamp of when the object was last updated.

campaign_name string required
status string
start_date string required
end_date string
email_campaign_for string

Default: Lead

recipient string required
sender string

Default: __user

The Email Campaign object
{
  "id": "email-campaign_abc123",
  "created_at": "2024-01-15T09: 30: 00Z",
  "updated_at": "2024-01-15T09: 30: 00Z",
  "campaign_name": "campaign_name_example",
  "status": "draft",
  "start_date": "2024-01-15",
  "end_date": "2024-01-15",
  "email_campaign_for": "Lead",
  "recipient": "recipient_example",
  "sender": "__user"
}
GET /api/crm/email-campaign/{id}

Retrieve a email campaign

Retrieves the details of an existing email campaign. Supply the unique email campaign ID that was returned from a previous request.

Path parameters

id string required

The identifier of the email campaign to retrieve.

Returns

Returns the email campaign object if a valid identifier was provided.

GET /api/crm/email-campaign/{id}
curl https://api.overplane.dev/api/crm/email-campaign/email-campaign_abc123 \
  -H "Authorization: Bearer sk_test_..."
Response
{
  "id": "email-campaign_abc123",
  "created_at": "2024-01-15T09: 30: 00Z",
  "updated_at": "2024-01-15T09: 30: 00Z",
  "campaign_name": "campaign_name_example",
  "status": "draft",
  "start_date": "2024-01-15",
  "end_date": "2024-01-15",
  "email_campaign_for": "Lead",
  "recipient": "recipient_example",
  "sender": "__user"
}
GET /api/crm/email-campaign

List all email campaigns

Returns a list of email campaigns. The results are sorted by creation date, with the most recently created appearing first.

Query parameters

limit integer

Maximum number of objects to return. Default: 20.

offset integer

Number of objects to skip for pagination. Default: 0.

Returns

A paginated list of email campaign objects.

GET /api/crm/email-campaign
curl https://api.overplane.dev/api/crm/email-campaign \
  -H "Authorization: Bearer sk_test_..."
Response
{
  "data": [
    {
      "id": "email-campaign_abc123",
      "created_at": "2024-01-15T09: 30: 00Z",
      "updated_at": "2024-01-15T09: 30: 00Z",
      "campaign_name": "campaign_name_example",
      "status": "draft",
      "start_date": "2024-01-15",
      "end_date": "2024-01-15",
      "email_campaign_for": "Lead",
      "recipient": "recipient_example",
      "sender": "__user"
    }
  ],
  "has_more": false,
  "total": 1
}
POST /api/crm/email-campaign

Create a email campaign

Creates a new email campaign object.

Body parameters

campaign_name string required
status string
start_date string required
end_date string
email_campaign_for string

Default: Lead

recipient string required
sender string

Default: __user

Returns

Returns the newly created email campaign object if the call succeeded.

POST /api/crm/email-campaign
curl https://api.overplane.dev/api/crm/email-campaign \
  -H "Authorization: Bearer sk_test_..." \
  -X POST \
  -H "Content-Type: application/json" \
  -d '{"campaign_name":"campaign_name_example","start_date":"2024-01-15","recipient":"recipient_example"}'
Response
{
  "id": "email-campaign_abc123",
  "created_at": "2024-01-15T09: 30: 00Z",
  "updated_at": "2024-01-15T09: 30: 00Z",
  "campaign_name": "campaign_name_example",
  "status": "draft",
  "start_date": "2024-01-15",
  "end_date": "2024-01-15",
  "email_campaign_for": "Lead",
  "recipient": "recipient_example",
  "sender": "__user"
}
PATCH /api/crm/email-campaign/{id}

Update a email campaign

Updates the specified email campaign by setting the values of the parameters passed. Any parameters not provided will be left unchanged.

Path parameters

id string required

The identifier of the email campaign to update.

Body parameters

campaign_name string
status string
start_date string
end_date string
email_campaign_for string

Default: Lead

recipient string
sender string

Default: __user

Returns

Returns the updated email campaign object.

PATCH /api/crm/email-campaign/{id}
curl https://api.overplane.dev/api/crm/email-campaign/email-campaign_abc123 \
  -H "Authorization: Bearer sk_test_..." \
  -X PATCH \
  -H "Content-Type: application/json" \
  -d '{"campaign_name":"campaign_name_example","status":"draft"}'
Response
{
  "id": "email-campaign_abc123",
  "created_at": "2024-01-15T09: 30: 00Z",
  "updated_at": "2024-01-15T09: 30: 00Z",
  "campaign_name": "campaign_name_example",
  "status": "draft",
  "start_date": "2024-01-15",
  "end_date": "2024-01-15",
  "email_campaign_for": "Lead",
  "recipient": "recipient_example",
  "sender": "__user"
}
DELETE /api/crm/email-campaign/{id}

Delete a email campaign

Permanently deletes a email campaign. This cannot be undone.

Path parameters

id string required

The identifier of the email campaign to delete.

Returns

Returns a confirmation that the email campaign has been deleted.

DELETE /api/crm/email-campaign/{id}
curl https://api.overplane.dev/api/crm/email-campaign/email-campaign_abc123 \
  -H "Authorization: Bearer sk_test_..." \
  -X DELETE
Response
{
  "id": "email-campaign_abc123",
  "deleted": true
}