Skip to main content
Enterprise Edition

Overview

Object storage triggers start a workflow or an agent when an object is created in an S3 bucket. S3 publishes each event to an SNS topic in your AWS account, and the topic delivers it to a Tracecat HTTPS endpoint. Tracecat stores one event per object, then starts the triggers bound to it.
Tracecat never reads your bucket on ingest. The triggered workflow or agent fetches the object with your workspace’s AWS credentials.

Set up the event source

  1. Create an SNS event source in Tracecat with your topic ARN, such as arn:aws:sns:us-east-1:123456789012:bucket-events. Tracecat accepts messages from that topic only.
  2. Copy the source’s endpoint URL. It has the form https://<your-tracecat-api>/ingest/sns/<token>. Only members with the trigger:update scope see it; for others the field is empty. Treat the URL as a secret.
  3. Allow only your bucket to publish to the topic. Add this statement to the topic’s access policy, with your topic ARN, bucket name and account ID:
    Keep both conditions. Without them, any S3 bucket in any AWS account can publish to your topic, and Tracecat accepts its events because SNS signs them for your topic.
  4. In S3, add an event notification on the bucket for s3:ObjectCreated:* events with your SNS topic as the destination. Set a key prefix to limit which objects send events. S3 checks that it may publish to the topic, so add the topic policy first.
  5. Subscribe the endpoint URL to the topic with the HTTPS protocol. Leave raw message delivery off.
  6. Set the subscription’s delivery retry policy to retry for one hour, and attach a dead-letter queue (an SQS queue) to the subscription. If you also throttle delivery (maxReceivesPerSecond), keep the limit high enough that a backlog drains within 24 hours: Tracecat refuses messages older than that.
Tracecat confirms the subscription by itself through the SNS ConfirmSubscription API. The source shows the subscription as confirmed when it is done. Turn the source online to start queuing events.

Delivery rules

Tracecat checks every message before it stores anything:
  • The message must be signed by SNS. Tracecat verifies the signature against the SNS signing certificate for your topic’s region.
  • The message must come from the source’s topic.
  • The message must be less than 24 hours old.
  • Raw message delivery is refused, because raw messages carry no signature.
Only ObjectCreated:* records become events. Tracecat acknowledges the S3 test event and other event types without storing them. A redelivered message for an object already queued is stored once. An offline source refuses notifications with 409, so events sent while it is offline go to your dead-letter queue instead of being dropped. Subscription confirmations work while the source is offline, so you can confirm the subscription before you turn the source online. Each source accepts up to 6,000 new notifications per minute by default; redeliveries of events still queued do not count. Past that, Tracecat answers 503 and SNS retries later. Messages that are still refused when your retry policy runs out go to your dead-letter queue.
A workflow or agent that writes objects under the prefix it watches triggers itself in a loop. Write outputs under a different prefix or to a different bucket. The per-source rate cap slows a loop but does not stop it.

Event payload

Each event has the same shape: Object keys come from whoever writes to the bucket. Treat them as untrusted data in your workflow.