[package]
name = "stablebond-sdk"
version = "0.3.17"
edition = "2021"
readme = "README.md"
license = "Apache-2.0"
description = "A IDL library for Etherfuse Stablebonds."

[lib]
crate-type = ["cdylib", "lib"]

[features]
serde = ["dep:serde", "dep:serde_with"]
cpi = []
sdk = ["dep:solana-sdk", "dep:solana-client", "dep:solana-account-decoder", "dep:spl-associated-token-account"]

default = []

[dependencies]
anyhow = "1.0.75"
borsh = "^0.10"
num-derive = "^0.3"
num-traits = "^0.2"
serde = { version = "^1.0", features = ["derive"], optional = true }
serde_with = { version = "^3.0", optional = true }
solana-program = "=1.17.26"
solana-account-decoder = { version = "=1.17.26", optional = true }
solana-sdk = { version = "=1.17.26", optional = true }
solana-client = { version = "=1.17.26", optional = true }
spl-token-2022 = { version = "2.0.1", features = ["no-entrypoint"] }
spl-associated-token-account = { version = "=2.3.0", features = [
    "no-entrypoint",
], optional = true }
mpl-token-metadata = { version = "4.1.2", features = ["serde"] }
thiserror = "^1.0"
base64 = "0.22.0"
cfg-if = "1.0.0"

[dev-dependencies]
assert_matches = "1.5.0"
async-trait = "0.1.77"
futures-util = "0.3.30"
solana-program-test = "=1.17.26"
solana-sdk = "=1.17.26"
solana-logger = "=1.17.26"
bincode = "^1.3.1"
serde = "^1.0.118"
spl-token = { version = "=4.0.0", features = ["no-entrypoint"] }
spl-associated-token-account = { version = "=2.3.0", features = [
    "no-entrypoint",
] }
