Skip to content

Arc

Arc

CQRS application framework for ASP.NET Core, Spring Boot, and Node.js

Arc is an opinionated CQRS application framework with commands, queries, validation, authorization, and TypeScript proxy generation. Write the backend in C#, Kotlin or Java, or the TypeScript source preview; each can generate a typed frontend client. Event sourcing is not required.

When commands, queries, validation, authorization, frontend contracts, and persistence each grow their own conventions, Arc gives them one application boundary. Start with current-state persistence or application services. Add Chronicle only where event sourcing fits, and add Components only where its React compositions fit.

Arc runs on ASP.NET Core and Spring Boot; a third implementation for TypeScript on Node.js is a source preview with no published npm package or full parity yet. Choose a backend below and check its capabilities before relying on a shared example. The shared HTTP contract is verified for C# and JVM; TypeScript’s coverage is documented separately.

Starting the host verifies the setup path only. Commands, queries, generated proxies, persistence integrations, and frontend packages each have additional configuration and version requirements.

Arc supports model-bound records and methods as well as controller-based endpoints. The command and query pipelines handle dependency injection, validation, authorization, filters, execution scopes, result conversion, and HTTP exposure in C# and on the JVM. TypeScript implements a subset of these capabilities; consult its capability reference. The scenario recipes show the same task, such as validating a command, with backend examples where the capability is available.

Queries can return one result or use Arc’s observable-query APIs. The TypeScript generator creates clients for recognized commands, queries, referenced types, validation rules, and identity details. See the detailed product documentation for the exact transport, subscription, and lifecycle behavior.

@cratis/arc supplies the TypeScript command, query, validation, identity, and messaging runtime used by generated proxies. @cratis/arc.react adds hooks, command forms, dialog infrastructure, identity composition, and query components. The composed CommandDialog used in the tutorial comes from the separate @cratis/components package. The optional React/MVVM package adds view models, dependency injection, route parameters, and browser abstractions.

Explore Arc’s frontend packages to choose the TypeScript, React, or React/MVVM path. Components is separate: applications may use Arc without Components, and may use the generated TypeScript clients without Arc’s React packages.

Arc includes pluggable identity and access behavior, identity-detail providers, server-side authorization and role checks, and frontend identity context. Tenant resolution can use a header, query parameter, claim, subdomain, fixed value, or development setting before provider-specific database or namespace mapping — see tenancy on C# or tenancy on Kotlin and Java.

Frontend visibility helpers do not replace server-side authorization. Tenant resolution also does not by itself establish isolation for an application or storage topology.

Arc does not depend on Chronicle. Commands and queries can use application services or current-state persistence without an event log. Each backend integrates with the data access its own ecosystem already uses.

Arc can describe registered commands, queries, identity schemas, and OpenAPI operations at runtime. Repository packages also include analyzers, source generators, command-scenario testing, proxy-generation checks, Vite helpers, and Arc-specific ESLint rules.