[package]
name = "dlsite-rs-next"
version = "0.2.0"
edition = "2021"
rust-version = "1.75"
description = "High-performance DLsite client with caching, parallel parsing, and streaming support"
license = "MIT"
repository = "https://github.com/BK927/dlsite-rs-next"
homepage = "https://github.com/BK927/dlsite-rs-next"
documentation = "https://docs.rs/dlsite-rs-next"
readme = "README.md"
keywords = ["dlsite", "api", "async", "japan", "doujin"]
categories = ["api-bindings", "web-programming::http-client"]
include = [
    "/src/**/*.rs",
    "/tests/**/*.rs",
    "/tests/**/*.json",
    "/tests/**/*.html",
    "/tests/**/*.txt",
    "/Cargo.toml",
    "/README.md",
    "/LICENSE",
]

[dependencies]
tokio = { version = "1", features = ["macros", "time", "sync"] }
chrono = { version = "0.4.39", features = ["serde"] }
reqwest = { version = "0.12.9", default-features = false }

serde = "1.0.216"
serde-aux = "4.5.0"
serde_json = "1.0.133"
serde_with = { version = "3.11.0", features = ["macros"] }
serde_path_to_error = "0.1"
serde_repr = "0.1.19"
serde_ignored = { version = "0.1.10", optional = true }

thiserror = "2.0.9"
strum = { version = "0.27.1", features = ["derive"] }
url = "2.3.1"
tracing = "0.1"
document-features = { version = "0.2.11", optional = true }
lru = "0.16.2"
futures = "0.3.31"

# Optional dependencies (enabled by features)
scraper = { version = "0.23.1", optional = true }
rayon = { version = "1.11.0", optional = true }

[dev-dependencies]
tokio = { version = "1", features = ["full"] }
anyhow = { version = "1", features = ["backtrace", "std"] }
tracing-subscriber = "0.3"
rand = "0.9"
test-case = "3.1.0"
wiremock = "0.6"
insta = { version = "1.42", features = ["json"] }

[features]
default = ["unknown-field-log", "reqwest-rustls-tls"]

## Outputs log when unknown fields are found in response.
unknown-field-log = ["dep:serde_ignored"]
## Fails when unknown fields are found in response.
unknown-field-error = []
## Enables cookie store support for session-based auth (reqwest/cookies).
cookie-store = ["reqwest/cookies"]

## Enables search and circle functionality with HTML parsing.
## This adds scraper and rayon dependencies.
search-html = ["dep:scraper", "dep:rayon"]

#! ### TLS Backend
## Enables rustls-tls (pure Rust TLS implementation, recommended).
reqwest-rustls-tls = ["reqwest/rustls-tls"]
## Enables native-tls (platform's native TLS implementation).
reqwest-native-tls = ["reqwest/native-tls"]

document-features = ["dep:document-features"]

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