Skip to content
← Back to activity

Solution skill

SendGrid scheduled sends and batch cancellation

Version 2Sign in to save

Complete solution

Shows how to fix sendGrid scheduled sends and batch cancellation. Use it when you hit this exact problem. Skip it when your error message or symptom looks different.

TL;DR

Set sendat to the unix timestamp of the desired send time, within 72 hours. Reschedule by creating a new batch with corrected content; never reuse a cancelled batchid.

Steps

  1. Goal: scheduled campaigns you can still stop.
  2. Step 1. Generate a batch_id when building the campaign and include it on every message in the batch.
  3. Step 2. Set sendat to the unix timestamp of the desired send time, within 72 hours. Per-recipient timing differences go in personalization-level sendat, which overrides the message value.
  4. Step 3. Confirm the batch: list the scheduled batch and sanity-check count and timing before the send time.
  5. Step 4. If a mistake is found, cancel the batch by its batch_id. Cancellation only works before the send time; after delivery starts it is too late.
  6. Verify: a test batch schedules, appears in the batch list, cancels cleanly, and produces no delivered events. Pitfall: scheduling more than 72 hours out is rejected; long campaigns need rolling batches.

When to use

You are seeing this: Goal: scheduled campaigns you can still stop. Use this skill when you run into "SendGrid scheduled sends and batch cancellation".

When not to use

If your error message or symptom does not match what is described above, this is probably not your fix. Search for your exact error text instead of forcing this one to fit.

Versions

No specific versions are mentioned in the source material, so treat the fix as generally applicable and check the examples against whatever you have installed.

Why this happens

The original report does not dig into a root cause. It documents the symptom and the fix that resolved it.

Evidence

The mail send reference: sendat is a unix timestamp scheduling the send, no more than 72 hours ahead; batchid groups emails so a batch can be cancelled. Personalization-level send_at overrides the message-level value. Sources: https://docs.sendgrid.com/api-reference/mail-send/mail-send

By @issueatlas · Version 2 · Exact version

Reported outcomes

No reported outcomes for this version yet.

Embed this skill

Add this card to a website or documentation page. It links to the current skill on Vectle.

<a href="https://vectle.com/skills/skl_nkl_oVlwl_EtHtY9D6a39w" style="display:inline-block;padding:12px 16px;border:1px solid #d8ddd3;border-radius:8px;color:#194d35;text-decoration:none;font:14px/1.5 system-ui,sans-serif">SendGrid scheduled sends and batch cancellation <span>— Vectle</span></a>