[package]
name = "affinidi-messaging-sdk"
version = "0.18.21"
description = "Affinidi Messaging SDK"
edition.workspace = true
authors.workspace = true
homepage.workspace = true
keywords.workspace = true
publish.workspace = true
license.workspace = true
readme = "README.md"
rust-version.workspace = true
repository.workspace = true

[features]
default = []
## Trust Spanning Protocol (TSP) client support — `atm.tsp()` ops, alongside the
## always-on DIDComm support. EXPERIMENTAL: the message-construction (pack/send)
## and receive (fetch/unpack) paths are still being built.
tsp = ["dep:affinidi-tsp"]

[dependencies]
# Affinidi Crates
affinidi-tdk-common = "0.6"
affinidi-crypto = { version = "0.2", features = ["jose"] }
affinidi-messaging-didcomm = { path = "../affinidi-messaging-didcomm", version = "0.15" }
## Trust Tasks framework — typed request/response documents for the messaging
## tasks (ping / account / acl / access-list), carried over the binding envelope.
trust-tasks-rs = "0.2"
## Optional: Trust Spanning Protocol (activated by the `tsp` feature)
affinidi-tsp = { path = "../affinidi-tsp", version = "0.1", optional = true }
## Source of truth for the mediator protocol vocabulary (ACLs, accounts,
## message types, problem reports). The SDK re-exports these so existing
## call sites continue to resolve their old paths.
affinidi-messaging-mediator-common = { path = "../affinidi-messaging-mediator/affinidi-messaging-mediator-common", version = "0.15", default-features = false }
affinidi-did-authentication = "0.3"
affinidi-did-common = { version = "0.3", features = ["key-agreement"] }
affinidi-encoding = "0.1"
affinidi-secrets-resolver = "0.5"
## Shared background-task supervision (delete-handler restart + health)
affinidi-task-utils = "0.1"

# External Crates
ahash = { version = "0.8", features = ["serde"] }
base64 = "0.22"
futures-util = "0.3"
# Non-cryptographic jitter for WebSocket reconnect backoff (anti-thundering-herd)
rand = "0.10"
regex = "1"
rustls = { version = "0.23", default-features = false, features = [
  "aws_lc_rs",
  "tls12",
] }
rustls-pemfile = "2"
serde = { version = "1", features = ["derive", "rc"] }
serde_json = "1"
sha256 = "1"
thiserror = "2"
tokio = { workspace = true, features = ["rt", "macros", "sync", "time"] }
tokio-tungstenite = { version = "0.29", features = ["rustls-tls-native-roots"] }
tracing = { version = "0.1", features = ["valuable"] }
uuid = { version = "1", features = ["v4", "fast-rng"] }

[dev-dependencies]
clap = { version = "4", features = ["derive"] }
console = "0.16"
dialoguer = "0.12"
rcgen = { version = "0.14", default-features = false, features = [
  "aws_lc_rs",
  "pem",
] }
regex = "1"
ring = { version = "0.17", features = ["std"] }
time = "0.3"
