# Using Trigger Conditions to Control an Automate Execution

### About this export

| Field | Value |
| --- | --- |
| **content_type** | lesson |
| **platform** | contentstack-academy |
| **source_url** | https://www.contentstack.com/academy/courses/automate-foundations/using-trigger-conditions-to-control-an-automate-execution |
| **course_slug** | automate-foundations |
| **lesson_slug** | using-trigger-conditions-to-control-an-automate-execution |
| **markdown_file_url** | /academy/md/courses/automate-foundations/using-trigger-conditions-to-control-an-automate-execution.md |
| **generated_at** | 2026-05-11T07:02:18.531Z |

> Part of **[Automate Foundations](https://www.contentstack.com/academy/courses/automate-foundations)** on Contentstack Academy. **Academy MD v3** — structured for retrieval; no quiz or assessment keys.

<!-- ai_metadata: {"lesson_id":"13","type":"video","duration_seconds":218,"video_url":"https://cdn.jwplayer.com/previews/dCjBIaBC","thumbnail_url":"https://cdn.jwplayer.com/v2/media/dCjBIaBC/poster.jpg?width=720","topics":["Using","Trigger","Conditions","Control","Automate","Execution"]} -->

#### Video details

#### At a glance

- **Title:** Ah-trigger Conditions
- **Duration:** 3m 38s
- **Media link:** https://cdn.jwplayer.com/previews/dCjBIaBC
- **Publish date (unix):** 1713750111

#### Streaming renditions

- application/vnd.apple.mpegurl
- audio/mp4 · AAC Audio · 113596 kbps
- video/mp4 · 180p · 180p · 145328 kbps
- video/mp4 · 270p · 270p · 165019 kbps
- video/mp4 · 360p · 360p · 183880 kbps
- video/mp4 · 406p · 406p · 198911 kbps
- video/mp4 · 540p · 540p · 235825 kbps
- video/mp4 · 720p · 720p · 295556 kbps
- video/mp4 · 1080p · 1080p · 431697 kbps

#### Timed text tracks (delivery)

- **thumbnails:** `https://cdn.jwplayer.com/strips/dCjBIaBC-120.vtt`

#### Video transcript

Welcome to Automation Hub. In this video, we'll take a look at using trigger conditions to determine when our automation is run and reduce the number of executions. First, go into Automation Hub and open a project. Next, create new automation. Here I'm going to say notify on publish. I'm going to start with the content stack connector here because I want to trigger it on entry published. Here, select entry trigger and for event, choose entry published. Select your stack and then go ahead and proceed. Next, we want to test our trigger, so hit test trigger here and then log in the content stack and publish an entry. Let's hit retest. We see the JSON is loaded. Hit save and exit and under trigger conditions, this is the really magic part that we can specify when this automation actually will be run. So under input, I'm going to go down here and I'm going to search for my environment. I only want to run that when it's published to a certain environment. So I'm going to go down here and choose environment.name and we'll say matches and then preview. So that's all we want to do. Hit save and exit and go ahead and turn on the automation. Oh, we need an action here. So in a second action step, we could do, for example, HTTP to our webhook.site. We have our endpoint from earlier. If you don't, you can come into webhook.site, click new, and then create a new endpoint. Over here under unique URL, copy that over here and paste it in. Post and then in the body, we'll access our entry data. So again, over here, search for entry and it's going to be body.data.entry. There we go. And let's go ahead and hit proceed. And so now what should happen is, well, you get the JSON over here, but let's go ahead and save and exit and now turn on our automation. So just to review this, in our entry trigger, settings here, this is when we're triggering it, and then down here in the conditions, we have the setting to only trigger this when it executes to publish it to preview. So go over here and hit publish to test this out. Let's publish to development and see what happens. Nothing should be happening, so let's go over here to automation hub, go back here to our dashboard and look at our execution log. And you can see here I've got only action connector examples, but I don't have that new one we just made. So let's go ahead back over here and then hit publish and publish out to preview. Go look at webhook.site, we get a new notification here. And also, if you come back here to execution log and refresh, then we see our notify and publish running right there. Let's test it one more time. So go ahead and hit publish again and publish out to something that's not preview. So I do instant preview, for example, and then go over here to the dashboard, hit refresh, and I still only have one notify and publish because I only publish one time to preview. That's an overview of how these trigger conditions can work. They can really save you a lot of executions and are a great thing to use when you build your automation hub projects.

#### Key takeaways

- Connect **Using Trigger Conditions to Control an Automate Execution** back to your stack configuration before moving to the next module.
- Capture one concrete artifact (screenshot, Postman call, or code snippet) that proves the step works in your environment.
- Re-read the delivery versus management boundary for anything you changed in the entry model.

## Supplement for indexing

### Content summary

Using Trigger Conditions to Control an Automate Execution. Using Trigger Conditions to Control an Automate Execution in Automate Foundations (automate-foundations).

### Retrieval tags

- Using
- Trigger
- Conditions
- Control
- Automate
- Execution
- automate-foundations
- lesson 13
- Using Trigger Conditions to Control an Automate Execution
- automate-foundations lesson

### Indexing notes

Index this lesson as a primary chunk tagged with lesson_id "13" and topics: [Using, Trigger, Conditions, Control, Automate, Execution].
Parent course slug: automate-foundations. Use asset_references URLs as thumbnail hints in search results when present.
Never surface LMS quiz content or assessment answers from this file.

### Asset references

| Label | URL |
| --- | --- |
| Video thumbnail: Using Trigger Conditions to Control an Automate Execution | `https://cdn.jwplayer.com/v2/media/dCjBIaBC/poster.jpg?width=720` |

### External links

| Label | URL |
| --- | --- |
| Contentstack Academy home | `https://www.contentstack.com/academy/` |
| Training instance setup | `https://www.contentstack.com/academy/training-instance` |
| Academy playground (GitHub) | `https://github.com/contentstack/contentstack-academy-playground` |
| Contentstack documentation | `https://www.contentstack.com/docs/` |
