Withdraw cancelled Contentful event promotions from SendIt

Remove the exact queued announcement when an event’s cancellation and withdrawal instruction are published in Contentful.

17 stepsMarketingOperations

Free to start, no card required.

How it works

  1. When this happens

    Receive an event publication

    Webhook

  2. Step 1 · Code

    Identify the published event

  3. Step 2

    Check the source event

    Follows the first path that matches

    • Matching event publication

      1. Step 3 · Contentful

        Read the current Contentful event

      2. Step 4 · Code

        Check the published withdrawal

      3. Step 5

        Check the withdrawal instruction

        Follows the first path that matches

        • Promotion withdrawal was approved

          1. Step 6 · SendIt

            Read the SendIt publishing queue

          2. Step 7 · Code

            Match the queued promotion

          3. Step 8

            Check the scheduled announcement

            Follows the first path that matches

            • The exact promotion is pending

              1. Step 9 · Contentful

                Recheck the event cancellation

              2. Step 10 · Code

                Check for event revisions

              3. Step 11

                Check the latest approval

                Follows the first path that matches

                • Withdrawal is still approved

                  1. Step 12 · SendIt

                    Recheck the SendIt queue

                  2. Step 13 · Code

                    Protect edited announcements

                  3. Step 14

                    Check the posting time and channels

                    Follows the first path that matches

                    • The queued announcement is unchanged

                      1. Step 15 · SendIt

                        Remove the queued promotion

                      2. Step 16 · Code

                        Confirm the cancellation receipt

                    • Otherwise

                      Nothing happens

                • Otherwise

                  Nothing happens

            • Otherwise

              Nothing happens

        • Otherwise

          Nothing happens

    • Otherwise

      Nothing happens

Before you start

Use whole-entry publishing and a Contentful Entry.publish webhook with the same secret header, then enter the space, environment, event model, locale and public events hostname. For one text-only promotion store eventStatus, withdrawPromotion (boolean), eventUrl, promotionCopy and sendItScheduleId on the event; publish cancelled with withdrawal checked. The post must match and still be at least five minutes from publication.

Accounts to connect

See all 187 in Marketing

Your first automationstarts with one sentence.

Start free with 1,000 credits, no card needed. Rather have it done for you? Our team builds it.

Use template