[package]
name = "nintypes"
version = "0.2.4"
edition = "2021"
license = "MIT"
description = "Nintondo shared types"

[dependencies]

anyhow = "1.0.95"
thiserror = "2.0.11"

dutils = "0.1.6"

serde = { version = "1.0.217", features = ["derive", "rc"] }
serde_json = "1.0.137"
serde_with = "3.12.0"
num-format = "0.4.4"

tokio = { version = "1.43.0", features = ["full"] }
tokio-graceful-shutdown = "0.15.3"
futures = "0.3.31"

tracing = "0.1.41"

postcard = { version = "1.1.1", features = ["alloc", "embedded-io", "use-std"] }
bytemuck = { version = "1.21.0", features = ["derive"] }

hex = "0.4.3"

itertools = "0.14.0"
primitive-types = "0.13.1"
parking_lot = { version = "0.12.3", features = ["serde"] }
ordered-float = "4.6.0"

lazy_static = "1.5.0"
derive_more = { version = "1.0.0", features = ["full"] }
binary-heap-plus = "0.5.0"
bitflags = { version = "2.8.0", features = ["serde", "bytemuck"] }
fixedbitset = "0.5.7"
ahash = "0.8.11"
aligned = "0.4.2"
indexmap = "2.7.1"
superslice = "1.0.0"
bytes = "1.9.0"
pin-project = "1.1.8"

rust_decimal = { version = "1.36.0", features = ["serde-bincode"] }
kanal = "0.1.0-pre8"
arc-swap = "1.7.1"
smallvec = { version = "1.13.2", features = ["union"] }
fixedstr = { version = "0.5.8", features = ["flex-str", "serde"] }
static_assertions = "1.1.0"
strum = { version = "0.26.3", features = ["derive"] }
num-traits = "0.2.19"
int-enum = "1.1.2"
rand = "0.8.5"

sha256 = "1.5.0"
sha2 = "0.10.8"
bellscoin = { version = "0.30.7", optional = true }
nintondo-dogecoin = { version = "0.30.6", optional = true }
nintondo-pepecoin = { version = "0.30.7", optional = true }
bitcoin_hashes = { version = "0.12.0", optional = true } # used 0.12 because of bellscoin types
tokio-postgres = { version = "0.7.12", features = [
    "array-impls",
], optional = true }
schemars = { version = "0.9.0", optional = true }
utoipa = { version = "5.3.1", optional = true }
utoipa-axum = { version = "0.2.0", optional = true }
axum = { version = "0.8.1", optional = true }
validator = { version = "0.20.0", optional = true }
bigdecimal = { version = "0.4.8", optional = true }
bitcode = { version = "0.6.6", optional = true }

# JWT
jsonwebtoken = { version = "9.3.0", optional = true }
tower-cookies = { version = "0.11.0", optional = true }
http = "1.3.1"

[features]
default = []
full = [
    "bellscoin",
    "dogecoin",
    "pepecoin",
    "pg",
    "utoipa",
    "utoipa-axum",
    "validator",
    "bigdecimal",
    "jwt",
    "bitcode",
]
bellscoin = ["dep:bellscoin", "dep:bitcoin_hashes"]
dogecoin = ["dep:nintondo-dogecoin", "dep:bitcoin_hashes"]
pepecoin = ["dep:nintondo-pepecoin", "dep:bitcoin_hashes"]
pg = ["dep:tokio-postgres"]
utoipa = ["dep:utoipa"]
utoipa-axum = ["utoipa", "dep:utoipa-axum", "dep:axum"]
validator = ["dep:validator"]
bigdecimal = ["dep:bigdecimal"]
jwt = ["dep:jsonwebtoken", "dep:tower-cookies"]
bitcode = ["dep:bitcode"]
schema = ["dep:schemars"]
