Quick Start

This walkthrough takes you from a fresh install to a working event-sourced application in a few minutes.

1. Create an administrator account

After completing the Quick Setup with Docker Compose, create the first EventSourcerer user from inside the running application container:

php bin/console app:user:register-first

This command creates the initial user account for your installation. Follow the prompts in your terminal, then sign in to EventSourcerer.

When running locally with Docker Compose, emails are captured by Mailpit. If EventSourcerer asks for a 2FA or verification code, open mailpit.docker.localhost and copy the code from the latest email.
  1. Open your EventSourcerer installation at https://eventsourcerer.docker.localhost.
  2. Register a new user — the first user becomes an administrator.
  3. Verify your email if email verification is enabled.

Seeing a broken SSL warning? Read the SSL troubleshooting guide →

2. Register an application

An application is the system (Laravel/Symfony/etc.) that will read and write events.

  1. Go to Applications → Register New Application.
  2. Give it a name and description.
  3. Copy the generated application_id — you'll need it in your client config.

3. Define your first event

See Events for the full guide. In short:

  1. Open Events → Register New Event.
  2. Name it (e.g. UserRegistered).
  3. Define properties (email: Text, id: UUID, registeredAt: DateTime).

4. Create a projection

See Projections and Mutations for details.

  1. Open Projections → Register New Projection.
  2. Declare state fields (e.g. totalUsers: Integer).
  3. Add a mutation: when UserRegistered occurs, increment totalUsers by 1.

5. Write an event from your client

php artisan eventsourcerer:write-new-event \
    user-stream UserRegistered 1 '{"email":"jane@example.com"}'

6. Listen for events

php artisan eventsourcerer:listen-for-events my-worker

Watch the dashboard — your projection updates in real time.