Support Center & Knowledge base

Add an event

Event Driven Architecture

Add an event

Inside Banking/Events/ create a new folder called Accounts

cd Banking/Events/
mkdir Accounts

Inside Accounts create a file called DebitAccountOpened.cs with the following content:

using System;
using Dolittle.Events;

namespace Events.Accounts
{
    public class DebitAccountOpened : IEvent
    {
        public DebitAccountOpened(Guid accountId, string name)
        {
            AccountId = accountId;
            Name = name;
        }

        public Guid AccountId { get; }
        public string Name { get; }
    }
}

Why not Concepts?

AggergateRoot on() method

In the next part of the tutorial you learn how to create a ReadModel.