> ## Documentation Index
> Fetch the complete documentation index at: https://www.courier.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

> ## Agent Instructions
> Install the Courier skill before writing code: `npx skills add trycourier/courier-skills`. It carries the verified SDK shapes and the rules you cannot get wrong.
> Authenticate every request with `Authorization: Bearer <API_KEY>`. A workspace has several environments and each has its own keys, which are plain `pk_` strings with no environment prefix. Start with Test.
> Send with `client.send.message`, the default import of the v7 Node SDK. Reference a template by its `nt_` id or its alias.
> A send accepts a bare Elemental element list, but storing content on a template requires the top-level elements wrapped in a channel element.
> Templates and journeys can be built in the Courier app or created through the API. Either way they live in the workspace and are referenced by ID when you send.
> The hosted MCP server is https://mcp.courier.com. For a briefing on what Courier is and when to use it, read https://www.courier.com/llms.txt.
> Prefer the Guides tab for how-do-I questions and the Docs tab for how-does-it-behave questions. The API reference lives under /api-reference.

# Journey nodes

> The steps on a journey canvas: send, branch, delay, digest, batch, AI, fetch data, throttle, cancel.

export const Doc = ({href, children, name, bare}) => {
  const label = children || name || href;
  if (bare) {
    return <a href={href}>{label}</a>;
  }
  return <a className="cx-endpoint" data-kind="doc" href={href}>
      <span className="cx-endpoint-label">{label}</span>
      <span className="cx-endpoint-method">DOC</span>
    </a>;
};

Nodes are the steps on a journey canvas. They send messages, branch on data, wait, aggregate events, call external services, and cancel runs.

| Node                                                    | Use it to                                                       |
| ------------------------------------------------------- | --------------------------------------------------------------- |
| <Doc href="/docs/journeys/nodes/send">Send</Doc>             | Deliver a message on one channel, from a journey template.      |
| <Doc href="/docs/journeys/nodes/branch">Branch</Doc>         | Split the path on a condition.                                  |
| <Doc href="/docs/journeys/nodes/delay">Delay</Doc>           | Wait for a duration, or until a timestamp.                      |
| <Doc href="/docs/journeys/nodes/digest">Digest</Doc>         | Roll repeated events into one message on a schedule.            |
| <Doc href="/docs/journeys/nodes/batch">Batch</Doc>           | Collect events and release them together as one payload.        |
| <Doc href="/docs/journeys/nodes/ai">AI</Doc>                 | Generate content or make a decision with a model.               |
| <Doc href="/docs/journeys/nodes/fetch-data">Fetch data</Doc> | Call an external service and use the response later in the run. |
| <Doc href="/docs/journeys/nodes/throttle">Throttle</Doc>     | Cap how often a run sends.                                      |
| <Doc href="/docs/journeys/nodes/cancel">Cancel</Doc>         | End this run, or a group of runs sharing a token.               |

For how a run moves through them at runtime, see <Doc href="/docs/journeys/overview">how journeys run</Doc>. To split traffic across variants and promote a winner, see <Doc href="/docs/journeys/experiments">experiments</Doc>.

## Digest and Batch are not the same node

Both hold events back and release them together, and the difference decides which one you want.

A Digest releases on a **schedule** set on the topic, so a reader gets their nine o'clock summary whether two events arrived or twenty. A Batch releases on a **condition**, either a count or a window, so it fires as soon as enough has accumulated.

Reach for Digest when the cadence belongs to the recipient, and Batch when it belongs to the event volume.

## Every node reads the same run context

A node acts on the data the run already carries: the payload it was invoked with, the profile, and anything a <Doc href="/docs/journeys/nodes/fetch-data">Fetch data</Doc> node added earlier. That is why order matters. A node cannot read what a later node produces.

**A condition that references missing data does not error.** It evaluates false, the run takes the other path, and nothing marks it. Check a branch's decisions against a real run before trusting a path that never fires.
