scaffold-integration-event

Generates C# IntegrationEvent record classes for RabbitMQ and MassTransit async messaging.

1|Updated Apr 27, 2026
One-click install
npx skills add https://github.com/GSU26SE55/backend --skill scaffold-integration-event-gsu26se55
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: scaffold-integration-event
Source: https://github.com/GSU26SE55/backend/tree/main/.claude/skills/dev/be/scaffold-integration-event
Command: npx skills add https://github.com/GSU26SE55/backend --skill scaffold-integration-event-gsu26se55

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Manually creating integration event contracts for async messaging is repetitive and error-prone: developers must remember the correct base class, file location, naming conventions, and publish-after-commit ordering. This Skill scaffolds a consistent IntegrationEvent record in the shared contracts project so cross-service events follow one standard. ## Core Features & Use Cases - Event Record Scaffolding: Generates a C# record extending the IntegrationEvent base class with Id and OccurredAt auto-set, placed in shared/SharedContracts/EventModels/. - Publisher Documentation: Embeds XML comments documenting which service publishes the event and which consumes it, keeping contracts self-describing. - Publishing Pattern Guidance: Shows the correct publish-after-CommitTransactionAsync pattern via _messageProducer.PublishAsync for services without an Outbox. - Use Case: When a battery anomaly is detected in BatteryService and TicketService must react, run the scaffold to create BatteryAnomalyDetectedEvent, then follow up with the consumer scaffold command. ## Quick Start Ask the AI to scaffold an integration event named BatteryAnomalyDetectedEvent for RabbitMQ messaging between services.

Frequently Asked Questions about scaffold-integration-event

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I create an integration event for MassTransit in .NET?▼

Create a C# record extending the IntegrationEvent base class in the SharedContracts/EventModels folder, then publish it via the message producer after committing the transaction. The base class auto-sets Id and OccurredAt so you only define business properties.

Should integration events be records or classes in C#?▼

Use records, not classes, for integration events. Records provide value semantics and immutability suited to message contracts, and this convention is enforced for all events extending the IntegrationEvent base record.

When should I publish an event relative to the database transaction?▼

Publish after CommitTransactionAsync completes, not before. In services without an Outbox pattern this ordering prevents consumers from reacting to events whose underlying data was never persisted.

Where should shared event contracts live in a microservices solution?▼

Place them in a shared contracts project such as shared/SharedContracts/EventModels so both publisher and consumer services reference the same type. Document the publishing and consuming services in the record's XML comment.

What properties does the IntegrationEvent base class provide?▼

The base record provides Id initialized to a new Guid and OccurredAt set to the current UTC time. Derived events add business properties like UserId, RelatedId, and EntityName.