[package]
name = "tgbot"
version = "0.45.0"
edition = "2024"
description = "A Telegram Bot library"
documentation = "https://docs.rs/tgbot"
readme = "README.md"
repository = "https://github.com/tg-rs/tgbot"
license = "MIT"

[package.metadata.docs.rs]
all-features = true
rustdoc-args = ["--cfg", "nightly"]

[[example]]
name = "webhook"
required-features = ["webhook"]

[dependencies]
async-stream = "0.3"
axum = { version = "0.8", optional = true }
bytes = "1"
derive_more = { version = "2", features = ["from"] }
futures-util = "0.3"
log = "0.4"
mime = "0.3"
mime_guess = "2"
reqwest = { version = "0.13", default-features = false, features = [
  "json",
  "multipart",
  "rustls",
  "socks",
  "stream"
] }
serde = { version = "1", features = ["derive"] }
serde_json = "1"
serde_with = { version = "3", default-features = false, features = ["macros"] }
shellwords = "1"
tokio = { version = "1", features = ["fs", "sync", "time"] }
tokio-util = { version = "0.7", features = ["codec"] }
webpki-roots = { version = "1", optional = true }
rustls = { version = "0.23", optional = true, default-features = false, features = ["std", "tls12"] }

[dev-dependencies]
dotenvy = "0.15"
env_logger = "0.11"
insta = { version = "1", features = ["json"] }
mockito = "1"
regex = "1"
tempfile = "3"
tokio = { version = "1", features = [
  "fs",
  "io-util",
  "macros",
  "rt-multi-thread"
] }
toml = "1"

[features]
webhook = ["dep:axum"]
webpki-roots = ["dep:webpki-roots", "dep:rustls"]

[lints.rust]
missing_docs = "warn"
unexpected_cfgs = { level = "allow", check-cfg = ["cfg(nightly)"] }
