This commit is contained in:
2026-04-29 15:54:03 +02:00
parent 5813c526ae
commit f8a2309173
17 changed files with 1281 additions and 10 deletions

View File

@@ -0,0 +1,32 @@
// file: kb_lib/src/db/entities/wallet_participation.rs
//! Wallet-participation entity.
/// Persisted wallet-participation row.
#[derive(Debug, Clone, serde::Serialize, serde::Deserialize, sqlx::FromRow)]
pub struct KbWalletParticipationEntity {
/// Numeric primary key.
pub id: i64,
/// Related wallet id.
pub wallet_id: i64,
/// Related transaction id.
pub transaction_id: i64,
/// Optional related decoded event id.
pub decoded_event_id: std::option::Option<i64>,
/// Optional related pool id.
pub pool_id: std::option::Option<i64>,
/// Optional related pair id.
pub pair_id: std::option::Option<i64>,
/// Stable participation role.
pub role: std::string::String,
/// Stable unique key used for idempotent upserts.
pub unique_key: std::string::String,
/// Observation source kind.
pub source_kind: i16,
/// Optional logical source endpoint name.
pub source_endpoint_name: std::option::Option<std::string::String>,
/// Creation timestamp encoded as RFC3339 UTC text.
pub created_at: std::string::String,
/// Update timestamp encoded as RFC3339 UTC text.
pub updated_at: std::string::String,
}