Campaigns

Creates a new campaign and sends it.

Set when the campaign should send, along with other options like tracking in the campaignSettings object. You must already have a campaignDraftId value from the /api/campaigndrafts method.

post/api/campaigns/{campaignDraftId}

Request

  • Base URL
    https://api.gmass.co
  • Auth
    none declared

Path parameters

campaignDraftIdstring required

Request body

openTrackingboolean

Choose whether to track opens. True or False.

clickTrackingboolean

Choose whether to track clicks. True or False.

sendTimestring

Do not specify to send a campaign right now. Otherwise, specify time with an optional time zone offset. Example: "04/27/21 14:30 -04:00" indicates April 27, 2021 at 2:30 PM EST time.

skipWeekendsboolean

Determines whether the scheduler should avoid sending this campaign on the weekend. True or False.

skipHolidaysboolean

Determines whether the scheduler should avoid sending this campaign on designated holidays. True or False.

friendlyNamestring

A friendly name by which to identify this campaign.

allowedDaysstring

Specify the days of the week on which this campaign may send. Submit full weekday names as a comma-separated string. Example: "Monday,Wednesday,Friday".

previewTextstring

Optional preview text which displays next to the subject line in most email clients. See https://www.gmass.co/blog/preview-text/

throttlinginteger

Add a pause after each individual email that is sent as part of this campaign. Specify as 1, 2, or 3. See https://www.gmass.co/blog/mail-merge-feature-throttle-your-email-campaign/

suppressionDaysinteger

Filter out recipients that have received another campaign from you in the last X days. Specify the number of days as an integer. 1=5 to 10 seconds.2=10 to 60 seconds.3=1 to 5 minutes. See https://www.gmass.co/blog/suppress-addresses-by-number-of-days-since-last-email/

suppressionCampaignsstring

Filter out recipients of a prior campaign. Specify a comma-separated string of campaign ID numbers. See https://www.gmass.co/blog/new-gmail-mail-merge-feature-use-suppression-lists-to-filter-out-recipients-of-past-campaigns/

sendAsReplyboolean

Specify whether the campaign should be sent as a new thread of an existing thread. True or False. See https://www.gmass.co/blog/send-email-campaign-as-reply-to-recent-conversation/

replyTostring

Specify a custom Reply-To header for the campaign. If a Reply-To address is already set in your Gmail account, that will be used. This setting can override what's set in your Gmail account. See https://www.gmass.co/blog/reply-to-address/

createDraftsboolean

Specify whether to actually send emails for this campaign or just create DRAFTs which can be reviewed and sent later. True or False. Default value is False. See https://www.gmass.co/blog/no-more-fear-preview-your-emails-as-drafts-then-send-them-with-one-click/

emailsPerDayinteger

Set a fixed number of emails that should be sent per day.

fromNamestring

Specify the From Name that will be seen by your recipients. This will override the From Name set for the From Address in your Gmail account.

useSMTPboolean

Specify whether the campaign should be sent through your SMTP server or natively through Gmail. True or False.

skipSentboolean

Specify whether emails should be logged in your SENT folder. True or False.

verifyboolean

Specify whether each recipient address should be verified before sending. True or False.

campaignIdToReplyTointeger

To be used in conjunction with sendAsReply. Specify an optional campaign if the replies should be threaded to a prior campaign.

imagesModestring

Specify how images should be included. d: default, h: hosted, e: embedded

stageOneDaysinteger

STAGE 1: Number of days after original campaign message that this stage follow-up is sent

stageOneCampaignTextstring

STAGE 1: Text to use for the follow-up email.

stageOneCampaignIdinteger

STAGE 1: Custom content to be used for the follow-up email. If both stageOneCampaignId and stageOneCampaignText are set, then stageOneCampaignId will be used.

stageOneActionstring

STAGE 1: Determines which behavior follow-ups should be sent based on. r=No Reply. o=No Open. c=No Click. s=No Reply or Click. a=Everyone

stageOneTimestring

STAGE 1: Optionally, specify the time of day the follow-up should be sent. Specify without a time zone offset, but in the same time zone as sendTime.

stageOneThreadstring

STAGE 1: Optionally, specify whether the message should be sent as part of the "same" thread or a "new" thread. Default is "same".

stageTwoDaysinteger

STAGE 2: Number of days after original campaign message that this stage follow-up is sent

stageTwoCampaignTextstring

STAGE 2: Text to use for the follow-up email.

stageTwoCampaignIdinteger

STAGE 2: Custom content to be used for the follow-up email. If both stageTwoCampaignId and stageTwoCampaignText are set, then stageTwoCampaignId will be used.

stageTwoActionstring

STAGE 2: Determines which behavior follow-ups should be sent based on. r=No Reply. o=No Open. c=No Click. s=No Reply or Click. a=Everyone

stageTwoTimestring

STAGE 2: Optionally, specify the time of day the follow-up should be sent. Specify without a time zone offset, but in the same time zone as sendTime.

stageTwoThreadstring

STAGE 2: Optionally, specify whether the message should be sent as part of the "same" thread or a "new" thread. Default is "same".

stageThreeDaysinteger

STAGE 3: Number of days after original campaign message that this stage follow-up is sent

stageThreeCampaignTextstring

STAGE 3: Text to use for the follow-up email.

stageThreeCampaignIdinteger

STAGE 3: Custom content to be used for the follow-up email. If both stageThreeCampaignId and stageThreeCampaignText are set, then stageThreeCampaignId will be used.

stageThreeActionstring

STAGE 3: Determines which behavior follow-ups should be sent based on. r=No Reply. o=No Open. c=No Click. s=No Reply or Click. a=Everyone

stageThreeTimestring

STAGE 3: Optionally, specify the time of day the follow-up should be sent. Specify without a time zone offset, but in the same time zone as sendTime.

stageThreeThreadstring

STAGE 3: Optionally, specify whether the message should be sent as part of the "same" thread or a "new" thread. Default is "same".

stageFourDaysinteger

STAGE 4: Number of days after original campaign message that this stage follow-up is sent

stageFourCampaignTextstring

STAGE 4: Text to use for the follow-up email.

stageFourCampaignIdinteger

STAGE 4: Custom content to be used for the follow-up email. If both stageFourCampaignId and stageFourCampaignText are set, then stageFourCampaignId will be used.

stageFourActionstring

STAGE 4: Determines which behavior follow-ups should be sent based on. r=No Reply. o=No Open. c=No Click. s=No Reply or Click. a=Everyone

stageFourTimestring

STAGE 4: Optionally, specify the time of day the follow-up should be sent. Specify without a time zone offset, but in the same time zone as sendTime.

stageFourThreadstring

STAGE 4: Optionally, specify whether the message should be sent as part of the "same" thread or a "new" thread. Default is "same".

stageFiveDaysinteger

STAGE 5: Number of days after original campaign message that this stage follow-up is sent

stageFiveCampaignTextstring

STAGE 5: Text to use for the follow-up email.

stageFiveCampaignIdinteger

STAGE 5: Custom content to be used for the follow-up email. If both stageFiveCampaignId and stageFiveCampaignText are set, then stageFiveCampaignId will be used.

stageFiveActionstring

STAGE 5: Determines which behavior follow-ups should be sent based on. r=No Reply. o=No Open. c=No Click. s=No Reply or Click. a=Everyone

stageFiveTimestring

STAGE 5: Optionally, specify the time of day the follow-up should be sent. Specify without a time zone offset, but in the same time zone as sendTime.

stageFiveThreadstring

STAGE 5: Optionally, specify whether the message should be sent as part of the "same" thread or a "new" thread. Default is "same".

stageSixDaysinteger

STAGE 6: Number of days after original campaign message that this stage follow-up is sent

stageSixCampaignTextstring

STAGE 6: Text to use for the follow-up email.

stageSixCampaignIdinteger

STAGE 6: Custom content to be used for the follow-up email. If both stageSixCampaignId and stageSixCampaignText are set, then stageSixCampaignId will be used.

stageSixActionstring

STAGE 6: Determines which behavior follow-ups should be sent based on. r=No Reply. o=No Open. c=No Click. s=No Reply or Click. a=Everyone

stageSixTimestring

STAGE 6: Optionally, specify the time of day the follow-up should be sent. Specify without a time zone offset, but in the same time zone as sendTime.

stageSixThreadstring

STAGE 6: Optionally, specify whether the message should be sent as part of the "same" thread or a "new" thread. Default is "same".

stageSevenDaysinteger

STAGE 7: Number of days after original campaign message that this stage follow-up is sent

stageSevenCampaignTextstring

STAGE 7: Text to use for the follow-up email.

stageSevenCampaignIdinteger

STAGE 7: Custom content to be used for the follow-up email. If both stageSevenCampaignId and stageSevenCampaignText are set, then stageSevenCampaignId will be used.

stageSevenActionstring

STAGE 7: Determines which behavior follow-ups should be sent based on. r=No Reply. o=No Open. c=No Click. s=No Reply or Click. a=Everyone

stageSevenTimestring

STAGE 7: Optionally, specify the time of day the follow-up should be sent. Specify without a time zone offset, but in the same time zone as sendTime.

stageSevenThreadstring

STAGE 7: Optionally, specify whether the message should be sent as part of the "same" thread or a "new" thread. Default is "same".

stageEightDaysinteger

STAGE 8: Number of days after original campaign message that this stage follow-up is sent

stageEightCampaignTextstring

STAGE 8: Text to use for the follow-up email.

stageEightCampaignIdinteger

STAGE 8: Custom content to be used for the follow-up email. If both stageEightCampaignId and stageEightCampaignText are set, then stageEightCampaignId will be used.

stageEightActionstring

STAGE 8: Determines which behavior follow-ups should be sent based on. r=No Reply. o=No Open. c=No Click. s=No Reply or Click. a=Everyone

stageEightTimestring

STAGE 8: Optionally, specify the time of day the follow-up should be sent. Specify without a time zone offset, but in the same time zone as sendTime.

stageEightThreadstring

STAGE 8: Optionally, specify whether the message should be sent as part of the "same" thread or a "new" thread. Default is "same".

ABTestboolean

Set to true or false, based on whether this campaign is being A/B tested

ABTestDecisionstring

Set to m or a, based on whether the winner should be decided manually or automatically

ABTestHoursAfterinteger

Set to the number of hours after the test portion is sent that a winner should be picked

ABTestPercentageinteger

Set the percentage of the campaign that should be sent as the test portion

ABTestDecisionFactorstring

Only required if ABTestDecision=a. The parameter by which the winner will be decided. o=opens c=clicks r=replies

MultiSendstring

Specify a comma-separated list of accounts to distribute the volume over. MultiSend accounts must already be connected to your primary account.

MultiSendSkipPrimaryboolean

If true, the primary account making the API request will not be used to send messages as part of MultiSend.

MultiSendPrimaryMaxAllowedinteger

Optional MultiSend daily maximum for the primary account. Only applies when MultiSendSkipPrimary is false. A value of 0 means no custom MultiSend maximum.

SpinMaxboolean

Determines if SpinMax is set for this campaign. True or False.

Response

OK

campaignIdinteger

The GMass-generated campaign ID number for a campaign.

subjectstring
friendlyNamestring
stageinteger
creationTimestring date-time
fromLinestring
statusstring

Will be set to one of the following: sent, scheduled, error, processing, unknown, cancelled, paused, abpaused

Changes

No recorded changes to this operation across all 1 revision of this API.