Skip to main content
This recipe builds an agent that your CI pipeline runs. When you push a release tag, a GitHub Actions job collects the commits since the previous tag and sends them to Guild through an API trigger. The agent writes release notes from them and posts the notes to a Slack channel. It uses a Native agent: you write a prompt and a tool list, no code.

Before you start

  • The Guild CLI, logged in.
  • Slack connected in your workspace, and the Slack agent invited to the channel it will post in. See Slack setup.
  • A GitHub repository where you can add Actions workflows and secrets.

1. Create the agent

Replace PROMPT.md:
Replace guild.yaml:
The agent gets the commits from its input, so it needs no GitHub tools.

2. Save it and install it in your workspace

3. Create the API trigger

API triggers and their keys are created in the web UI:
  1. Open the workspace, click Triggers, then Add Trigger.
  2. Select API, choose <your-name>~release-notes, and name it, for example Release notes from CI.
  3. Copy the credentials string, <api_key_id>:<api_key_secret>. It’s shown only once.
In your GitHub repository, add the string as an Actions secret named GUILD_TRIGGER_KEY. The key can read and post to every session in the workspace, so keep it out of logs and code.

4. Add the workflow

Add .github/workflows/release-notes.yml, with your Guild workspace’s owner and name and the Slack channel ID filled in:
fetch-depth: 0 fetches the history and tags that git describe needs. On the first tag there’s no previous one, so the job lists every commit up to it. shell: bash turns on pipefail, so a failed request fails the step instead of passing null along. A Native agent takes text, so agent_input is {"text": ...}. jq builds the body so quotes and newlines in commit messages stay valid JSON.

5. Try it

Push a tag:
The job prints the session URL as soon as Guild accepts the request, and the notes appear in the Slack channel when the agent finishes. Open the session URL to see what the agent did.

Variations

  • Fail the job when the run errors. Save the session ID instead of printing the URL (session=$(curl ... | jq -r .id)), then poll session status until root_task.status is DONE, ERROR or INTERRUPTED:
    WAITING isn’t terminal: the task waits there on sub-agents or hooks. A failed Slack post doesn’t make the run fail: the agent sees the tool’s error and can still finish DONE. To catch that too, tell the agent to say in its final answer whether the post succeeded, and read it from the session events.
  • Run it after a deploy instead. Call the same endpoint from your deploy job, with the commits between the previous and the new deployed SHA.
  • Use one trigger for several agents. Add "agent_id": "<owner>~<agent>" to the body to run another agent installed in the workspace with the same key. agent_input must then match that agent’s input.
Last modified on October 15, 2026