SmartCampaigns
Query Smart Campaigns for a Marketo organization.
Select
Note: Filters provided with one of the supported operators listed in the "Operators" column are processed server-side, all the other filters are processed client-side.
SELECT * FROM SmartCampaigns WHERE IsActive='False'
SELECT * FROM SmartCampaigns WHERE FolderId=5318 AND FolderType='Folder' AND IsActive='true'
SELECT * FROM SmartCampaigns WHERE UpdatedAt >'2024-01-17T19:19:51Z'
SELECT * FROM SmartCampaigns WHERE UpdatedAt >='2024-01-17T19:19:51Z'
SELECT * FROM SmartCampaigns WHERE UpdatedAt <'2024-01-17T19:19:51Z'
SELECT * FROM SmartCampaigns WHERE UpdatedAt <='2024-01-17T19:19:51Z'
SELECT * FROM SmartCampaigns WHERE UpdatedAt = '2024-01-17T19:19:51Z'
Insert
INSERT INTO SmartCampaigns (Name, FolderId, FolderType, Description)
VALUES ('test insert smart campaign', '6152', 'Program', 'Test Insert Description')
Update
UPDATE SmartCampaigns Set Name = 'UpdatedSmartCampaignName', Description = 'CData Campaign' WHERE Id = 1109
Delete
DELETE FROM SmartCampaigns WHERE Id=1106
DELETE FROM SmartCampaigns WHERE Name='JET - Test email link reports'
DELETE FROM SmartCampaigns WHERE ID IN (1043, 5318)
DELETE FROM SmartCampaigns WHERE Name IN ('TestCampaign1', 'RCM Success Only (v1) Known --> Engaged', 'Update Segmentation [1001](1001)')
Columns
Name | Type | ReadOnly | Operators | Description |
Id [KEY] | Int | True | = |
Id of the smart campaign. |
ParentProgramId | Int | True |
The id of the parent program. Present if smart campaign is under program or nested folder | |
Name | String | False |
Name of the smart campaign. | |
Description | String | False |
Description of the smart campaign. | |
Type | String | True |
The type of the the smart campaign. Batch: has at least one filter and no triggers. Trigger: has at least one trigger. Default: has no smart list rules. | |
ComputedUrl | String | True |
The Computed Url of the Smart Campaign | |
Status | String | True |
The status of the smart campaign. | |
IsSystem | Bool | True |
Whether smart campaign is system managed. | |
IsActive | Bool | True | = |
Whether smart campaign is active. |
IsRequestable | Bool | True |
Whether smart campaign is requestable (is active and contains 'Campaign is Requested' trigger with Source of 'Web Service API'). | |
IsCommunicationLimitEnabled | Bool | True |
Whether smart campaign communication limit is enabled (i.e. block non-operational emails). | |
MaxMembers | Int | True |
The smart campaign membership limit. | |
SmartListId | Int | True |
The Id of the smart campaign's child smart list. | |
FlowId | Int | True |
The Id of the smart campaign's child flow. | |
FolderId | Int | False | = |
The unique, Marketo-assigned identifier of the parent folder/program. |
FolderType | String | False | = |
The type of folder (Folder,Program) |
WorkspaceName | String | True |
Name of the workspace the smart campaign is part of. | |
QualificationRuleType | String | True |
The type of qualification rule. | |
QualificationRuleInterval | Int | True |
The interval of qualification rule. Only set when qualificationRuleType is 'interval' | |
QualificationRuleUnit | String | True |
The unit of measure of qualification rule. Only set when qualificationRuleType is 'interval' = ['hour', 'day', 'week', 'month'] | |
RecurrenceStartAt | Datetime | True |
The datetime of the first scheduled campaign to run. Required if setting recurrence. Not required to create a smart campaign that has no recurrence. | |
RecurrenceEndAt | Datetime | True |
The datetime after which no further runs will be automatically scheduled. | |
RecurrenceIntervalType | String | True |
The recurrence interval. Not required to create a smart campaign that has no recurrence = ['Daily', 'Weekly', 'Monthly']. | |
RecurrenceInterval | Int | True |
The number of interval units between recurrences. | |
RecurrenceWeekDayOnly | Bool | True |
Only run smart campaign on weekdays. May only be set if intervalType is 'Daily'. | |
RecurrenceWeekDayMask | String | True |
String array of empty or one or more of 'Monday', 'Tuesday', 'Wednesday', 'Thursday', 'Friday', 'Saturday', 'Sunday'. May only be set if intervalType is 'Weekly'. | |
RecurrenceDayOfMonth | Int | True |
The day of the month to recur. Permissible range 1-31. May only be set if intervalType is 'Monthly' and dayOfWeek and weekOfMonth are unset. | |
RecurrenceDayOfWeek | String | True |
The day of the week to recur. May only be set if dayOfMonth is not set, and weekOfMonth is set = ['Monday', 'Tuesday', 'Wednesday', 'Thursday', 'Friday', 'Saturday', 'Sunday']. | |
RecurrenceWeekOfMonth | Int | True |
The week of the month to recur. Permissible range 1-4. May only be set if dayOfMonth is not set, and dayOfWeek is set. | |
CreatedAt | Datetime | True |
Datetime the smart campaign was created. | |
UpdatedAt | Datetime | True | =,>,<,>=,<= |
Datetime the smart campaign was most recently updated. |