# THIS FILE IS AUTOMATICALLY GENERATED BY CARGO
#
# When uploading crates to the registry Cargo will automatically
# "normalize" Cargo.toml files for maximal compatibility
# with all versions of Cargo and also rewrite `path` dependencies
# to registry (e.g., crates.io) dependencies.
#
# If you are reading this file be aware that the original Cargo.toml
# will likely look very different (and much more reasonable).
# See Cargo.toml.orig for the original contents.

[package]
edition = "2024"
rust-version = "1.93"
name = "nab"
version = "0.10.1"
authors = ["Mikko Parkkola"]
build = "build.rs"
exclude = [
    "benches/",
    "tests/",
    ".github/",
    ".claude/",
    "HomebrewFormula/",
    "python/",
    "man/",
]
autolib = false
autobins = false
autoexamples = false
autotests = false
autobenches = false
description = "Token-optimized HTTP client for LLMs — fetches any URL as clean markdown"
homepage = "https://github.com/MikkoParkkola/nab"
documentation = "https://docs.rs/nab"
readme = "README.md"
keywords = [
    "http3",
    "quic",
    "llm",
    "markdown",
    "browser",
]
categories = [
    "web-programming::http-client",
    "command-line-utilities",
    "development-tools",
]
license = "MIT"
repository = "https://github.com/MikkoParkkola/nab"

[package.metadata.binstall]
pkg-url = "{ repo }/releases/download/v{ version }/{ name }-{ target }{ archive-suffix }"
bin-dir = "{ bin }{ binary-ext }"
pkg-fmt = "bin"

[features]
analyze = []
analyze-sherpa = [
    "analyze",
    "dep:sherpa-onnx",
    "dep:hound",
]
analyze-whisper = [
    "analyze",
    "dep:whisper-rs",
    "dep:hound",
]
browser = ["chromiumoxide"]
browser-launcher = ["webbrowser"]
cli = []
default = [
    "cli",
    "http3",
    "impersonate",
    "analyze",
    "browser-launcher",
    "js-dom-full",
]
http3 = [
    "quinn",
    "h3",
    "h3-quinn",
]
impersonate = [
    "rquest",
    "rquest-util",
]
js-dom-full = []
pdf = ["pdfium-render"]
wasm-providers = ["wasmtime"]

[lib]
name = "nab"
path = "src/lib.rs"

[[bin]]
name = "nab"
path = "src/main.rs"
required-features = ["cli"]

[[bin]]
name = "nab-mcp"
path = "src/bin/mcp_server/main.rs"

[[bin]]
name = "test_autoupdate"
path = "src/bin/test_autoupdate.rs"

[[example]]
name = "arena_usage"
path = "examples/arena_usage.rs"

[[example]]
name = "scan_html"
path = "examples/scan_html.rs"

[[example]]
name = "spa_login_demo"
path = "examples/spa_login_demo.rs"

[[example]]
name = "stream_ffmpeg"
path = "examples/stream_ffmpeg.rs"

[dependencies.addr]
version = "0.15"

[dependencies.aes]
version = "0.9"

[dependencies.aes-gcm]
version = "0.10.3"

[dependencies.anyhow]
version = "1"

[dependencies.argon2]
version = "0.5.3"

[dependencies.async-trait]
version = "0.1"

[dependencies.base64]
version = "0.22"

[dependencies.bumpalo]
version = "3.16"
features = ["collections"]

[dependencies.bytes]
version = "1"

[dependencies.cbc]
version = "0.2"
features = ["block-padding"]

[dependencies.chromiumoxide]
version = "0.9"
features = [
    "rustls",
    "zip8",
]
optional = true
default-features = false

[dependencies.chrono]
version = "0.4"
features = ["serde"]

[dependencies.clap]
version = "4"
features = ["derive"]

[dependencies.cookie_store]
version = "0.22"

[dependencies.dirs]
version = "6.0.0"

[dependencies.ego-tree]
version = "0.11"

[dependencies.futures]
version = "0.3"

[dependencies.h3]
version = "0.0.8"
optional = true

[dependencies.h3-quinn]
version = "0.0.10"
optional = true

[dependencies.hex]
version = "0.4"

[dependencies.hmac]
version = "0.13"

[dependencies.hound]
version = "3"
optional = true

[dependencies.html2md]
version = "0.2"

[dependencies.http]
version = "1.4.0"

[dependencies.pdfium-render]
version = "0.9"
optional = true
default-features = true

[dependencies.quinn]
version = "0.11"
optional = true

[dependencies.rand]
version = "0.10"

[dependencies.readability]
version = "0.3"
default-features = false

[dependencies.regex]
version = "1"

[dependencies.reqwest]
version = "0.13"
features = [
    "cookies",
    "brotli",
    "zstd",
    "gzip",
    "deflate",
    "rustls",
    "http2",
    "stream",
    "hickory-dns",
    "charset",
    "blocking",
    "json",
    "multipart",
    "socks",
]
default-features = false

[dependencies.reqwest_cookie_store]
version = "0.10"

[dependencies.roxmltree]
version = "0.21"

[dependencies.rquest]
version = "5.3"
features = [
    "cookies",
    "brotli",
    "zstd",
    "gzip",
    "deflate",
    "webpki-roots",
]
optional = true
default-features = false
package = "wreq"

[dependencies.rquest-util]
version = "2.2.6"
optional = true
package = "wreq-util"

[dependencies.rquickjs]
version = "0.11"
features = [
    "bindgen",
    "classes",
    "futures",
    "macro",
    "parallel",
    "loader",
]

[dependencies.rust-mcp-sdk]
version = "0.9"
features = [
    "server",
    "macros",
    "stdio",
    "streamable-http",
    "hyper-server",
]
default-features = false

[dependencies.rustls]
version = "0.23"
features = ["aws_lc_rs"]

[dependencies.rustls-native-certs]
version = "0.8"

[dependencies.scraper]
version = "0.26"

[dependencies.scrypt]
version = "0.11"
features = ["std"]
default-features = false

[dependencies.serde]
version = "1"
features = ["derive"]

[dependencies.serde_json]
version = "1"

[dependencies.sha1]
version = "0.11"

[dependencies.sha2]
version = "0.11"

[dependencies.sherpa-onnx]
version = "1.12"
optional = true

[dependencies.tempfile]
version = "3"

[dependencies.thiserror]
version = "2"

[dependencies.tokio]
version = "1"
features = ["full"]

[dependencies.tokio-tungstenite]
version = "0.29"
features = ["rustls-tls-webpki-roots"]

[dependencies.toml]
version = "1.1"

[dependencies.tracing]
version = "0.1"

[dependencies.tracing-subscriber]
version = "0.3"
features = ["env-filter"]

[dependencies.tungstenite]
version = "0.29"

[dependencies.url]
version = "2"

[dependencies.urlencoding]
version = "2"

[dependencies.uuid]
version = "1"
features = ["v4"]

[dependencies.wasmtime]
version = "43"
features = [
    "cranelift",
    "runtime",
    "component-model",
]
optional = true
default-features = false

[dependencies.webbrowser]
version = "1"
optional = true

[dependencies.which]
version = "8"

[dependencies.whisper-rs]
version = "0.16"
optional = true

[dependencies.zip]
version = "8.4"
features = ["deflate"]
default-features = false

[dev-dependencies.assert_cmd]
version = "2"

[dev-dependencies.criterion]
version = "0.8"

[dev-dependencies.predicates]
version = "3"

[dev-dependencies.tokio-test]
version = "0.4"

[dev-dependencies.wat]
version = "1"
optional = false

[target.'cfg(target_os = "macos")'.dependencies.objc2]
version = "0.6"

[target.'cfg(target_os = "macos")'.dependencies.objc2-core-graphics]
version = "0.3.2"
features = ["CGImage"]

[target.'cfg(target_os = "macos")'.dependencies.objc2-foundation]
version = "0.3.2"
features = [
    "NSArray",
    "NSError",
    "NSString",
    "NSData",
    "NSDictionary",
]

[target.'cfg(target_os = "macos")'.dependencies.objc2-vision]
version = "0.3.2"
features = [
    "VNRecognizeTextRequest",
    "VNRequest",
    "VNRequestHandler",
    "VNObservation",
    "VNTypes",
]

[target.'cfg(target_os = "macos")'.dependencies.security-framework]
version = "3.5"

[lints.clippy]
missing_errors_doc = "allow"
missing_panics_doc = "allow"
module_name_repetitions = "allow"
must_use_candidate = "allow"
unnecessary_wraps = "allow"

[lints.clippy.pedantic]
level = "warn"
priority = -1

[profile.release]
opt-level = 3
lto = true
codegen-units = 1
strip = true
