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

# Events Overview

> Learn how events work in Flowripple and how they trigger your workflows.

# Events Overview

Events are named identifiers that represent discrete occurrences in your system. When something happens—a user signs up, an order is created, a payment is completed—you trigger an event that carries a JSON payload with relevant data.

## How Events Work

```
Your Application          Flowripple           Workflows
     │                        │                    │
     │ trigger("user.signup") │                    │
     │───────────────────────>│                    │
     │                        │ Event captured     │
     │                        │───────────────────>│
     │                        │                    │ Workflow executes
     │                        │                    │ with event data
```

1. **Trigger**: Your application sends an event to Flowripple with an identifier and data payload
2. **Capture**: Flowripple records the event and extracts variables from the payload
3. **Execute**: All workflows configured to start on that event execute with access to the event data

## Key Concepts

<CardGroup cols={2}>
  <Card title="Identifiers" icon="tag">
    Named strings like `user.signup` or `payment.completed` that uniquely identify event types within a project.
  </Card>

  <Card title="Payloads" icon="brackets-curly">
    JSON data sent with each event containing context like user information, order details, or any relevant data.
  </Card>

  <Card title="Variables" icon="code">
    Automatically extracted from payloads, variables make event data available throughout your workflows using `{{variable.path}}` syntax.
  </Card>

  <Card title="Captures" icon="database">
    Every triggered event is recorded as a capture, creating an audit trail for monitoring and debugging.
  </Card>
</CardGroup>

## Event Identifiers

Event identifiers follow a dot notation convention that organizes related events by domain:

| Identifier          | Domain  | Action    |
| ------------------- | ------- | --------- |
| `user.signup`       | user    | signup    |
| `user.login`        | user    | login     |
| `order.created`     | order   | created   |
| `payment.completed` | payment | completed |

<Tip>
  Use consistent naming patterns across your project. Group related events by domain (`user.*`, `order.*`, `payment.*`) to keep your event library organized.
</Tip>

## Auto-Detection

Events are automatically created when you trigger them for the first time. You don't need to pre-configure events before using them—simply trigger an event with a new identifier, and Flowripple creates the event and extracts variables from your payload.

<Tabs>
  <Tab title="Node.js (SDK)">
    ```typescript theme={null}
    // First trigger creates the event automatically
    await flowripple.trigger('order.shipped', {
      orderId: 'ord_123',
      trackingNumber: 'TRK456789',
      carrier: 'fedex'
    });
    ```
  </Tab>

  <Tab title="HTTP (cURL)">
    ```bash theme={null}
    curl -X POST https://api.flowripple.com/api/v1/trigger \
      -H "Content-Type: application/json" \
      -H "x-api-key: YOUR_API_KEY" \
      -d '{
        "identifier": "order.shipped",
        "data": {
          "orderId": "ord_123",
          "trackingNumber": "TRK456789",
          "carrier": "fedex"
        }
      }'
    ```
  </Tab>
</Tabs>

<Note>
  While auto-detection is convenient for development, consider pre-creating events in the dashboard to define expected payload structures and add descriptive names.
</Note>

## What's Next?

<CardGroup cols={2}>
  <Card title="Creating Events" icon="plus" href="/events/creating-events">
    Learn how to create and configure events in the dashboard.
  </Card>

  <Card title="Event Payloads" icon="brackets-curly" href="/events/event-payloads">
    Understand payload structure and how variables are extracted.
  </Card>

  <Card title="Triggering Events" icon="play" href="/events/triggering-events">
    Trigger events from your application using the SDK or HTTP API.
  </Card>

  <Card title="Monitoring Captures" icon="chart-line" href="/events/monitoring-captures">
    Track event triggers and analyze capture data.
  </Card>
</CardGroup>

## Using Events in Workflows

Once you've created events, configure workflows to respond to them using event triggers.

<Card title="Event Trigger" icon="bolt" href="/workflows/triggers/event-trigger">
  Learn how to configure workflows to start automatically when events occur.
</Card>
