Table of Contents

Class InvoiceCreatedEvent

Namespace
Compendium.Core.Domain.Events.Integration
Assembly
Compendium.Core.dll

Integration event raised when an invoice is created.

public sealed record InvoiceCreatedEvent : IntegrationEventBase, IIntegrationEvent, IEquatable<IntegrationEventBase>, IEquatable<InvoiceCreatedEvent>
Inheritance
InvoiceCreatedEvent
Implements
Inherited Members

Constructors

InvoiceCreatedEvent(string, string, string?, long, string, DateTimeOffset)

Integration event raised when an invoice is created.

public InvoiceCreatedEvent(string InvoiceId, string CustomerId, string? SubscriptionId, long Amount, string Currency, DateTimeOffset DueDate)

Parameters

InvoiceId string

The unique identifier of the invoice.

CustomerId string

The unique identifier of the customer.

SubscriptionId string

The subscription identifier, if applicable.

Amount long

The invoice amount in the smallest currency unit (e.g., cents).

Currency string

The currency code (e.g., USD, EUR).

DueDate DateTimeOffset

The due date of the invoice.

Properties

Amount

The invoice amount in the smallest currency unit (e.g., cents).

public long Amount { get; init; }

Property Value

long

Currency

The currency code (e.g., USD, EUR).

public string Currency { get; init; }

Property Value

string

CustomerId

The unique identifier of the customer.

public string CustomerId { get; init; }

Property Value

string

DueDate

The due date of the invoice.

public DateTimeOffset DueDate { get; init; }

Property Value

DateTimeOffset

EventType

Gets the name of the event type for serialization and routing purposes.

public override string EventType { get; }

Property Value

string

InvoiceId

The unique identifier of the invoice.

public string InvoiceId { get; init; }

Property Value

string

SubscriptionId

The subscription identifier, if applicable.

public string? SubscriptionId { get; init; }

Property Value

string