Expand description
§StateSet SDK
Rust-facing facade for the StateSet iCommerce platform.
This crate provides a curated set of feature-gated re-exports for Rust consumers who want a single dependency for the core commerce engine and optional sync, crypto, policy, and macro surfaces.
§Quick Start
[dependencies]
stateset-sdk = "1.23.3"ⓘ
use stateset_sdk::prelude::*;
let commerce = Commerce::new("store.db")?;
let customer = commerce.customers().create(CreateCustomer {
email: "alice@example.com".into(),
first_name: "Alice".into(),
last_name: "Smith".into(),
..Default::default()
})?;§Features
| Feature | Description | Default |
|---|---|---|
core | Primitives + Core + DB + Embedded + Observability | Yes |
crypto | VES v1.0 cryptographic operations | No |
policy | Declarative policy engine | No |
macros | Proc macros (StateSetId, GenerateDto, JsonSchema) | No |
sync | Outbox-driven sync engine and sequencer transport facade | No |
full | All features enabled | No |
With sync enabled, [SyncRuntime] and [SyncRuntimeConfig] bundle the
sync engine, sequencer HTTP transport, and runtime auth/options into a
single Rust-facing helper surface for config loading, sync operations,
JSON-ready runtime snapshots, kernel receipt queries, and local
confirmation/dead-letter inspection. [SyncRuntimeConfig] can also load
from JSON or environment variables via from_file, from_json_str, and
from_env.
Re-exports§
pub use stateset_primitives as primitives;corepub use stateset_core as core;corepub use stateset_db as db;corepub use stateset_embedded as embedded;corepub use stateset_observability as observability;core
Modules§
- prelude
core - Commonly used types, re-exported for convenience.