Skip to main content

stygian_graph/
adapters.rs

1//! Adapter implementations - infrastructure concerns
2//!
3//! Concrete implementations of port traits:
4//! - HTTP client with anti-bot features
5//! - AI providers (Claude, GPT, Gemini, Ollama, Copilot)
6//! - Storage backends
7//! - Cache backends
8
9/// HTTP scraping adapter with anti-bot capabilities
10pub mod http;
11
12/// REST API adapter — JSON APIs with auth, pagination, and data extraction
13pub mod rest_api;
14
15/// AI provider adapters
16pub mod ai;
17
18/// Storage adapters (file, S3, database)
19pub mod storage;
20
21/// Cache adapters (memory, Redis)
22pub mod cache;
23
24/// Resilience adapters (circuit breaker, retry)
25pub mod resilience;
26
27/// Fallback chain adapter — tries services in priority order with per-service circuit breakers
28pub mod fallback;
29
30/// No-op service for testing
31pub mod noop;
32
33/// JavaScript rendering adapter (headless browser via stygian-browser)
34#[cfg(feature = "browser")]
35pub mod browser;
36
37/// Multi-modal content extraction (CSV, JSON, XML, images, PDFs)
38pub mod multimodal;
39
40/// Mock AI provider for testing
41pub mod mock_ai;
42
43/// GraphQL API adapter — generic ScrapingService for any GraphQL endpoint
44pub mod graphql;
45
46/// OpenAPI 3.x introspection adapter — resolves operations from an OpenAPI spec and delegates to RestApiAdapter
47pub mod openapi;
48
49pub mod graphql_rate_limit;
50/// Proactive cost-throttle management for GraphQL APIs
51pub mod graphql_throttle;
52
53/// Distributed work queue and executor adapters
54pub mod distributed;
55
56/// GraphQL target plugin implementations (one file per API target)
57pub mod graphql_plugins;
58
59/// WASM plugin adapter (feature = "wasm-plugins")
60pub mod wasm_plugin;
61
62/// Cloudflare Browser Rendering crawl adapter (feature = "cloudflare-crawl")
63#[cfg(feature = "cloudflare-crawl")]
64pub mod cloudflare_crawl;
65
66/// Output format helpers — CSV, JSONL, JSON
67pub mod output_format;
68
69/// Request signing adapters — Noop passthrough and HTTP sidecar bridge.
70/// Covers Frida RPC, AWS Sig V4, OAuth 1.0a, custom HMAC, and device attestation.
71pub mod signing;
72
73/// OpenAPI spec generator from API discovery reports
74pub mod openapi_gen;
75
76/// PostgreSQL database source adapter (feature = "postgres")
77#[cfg(feature = "postgres")]
78pub mod database;
79
80/// File system / document source adapter
81pub mod document;
82
83/// Server-Sent Events stream source adapter
84pub mod stream;
85
86/// LLM agent source adapter — wraps AIProvider as a pipeline node
87pub mod agent_source;
88
89/// Redis / Valkey cache adapter (feature = "redis")
90#[cfg(feature = "redis")]
91pub mod cache_redis;
92
93/// Redis Streams work queue adapter (feature = "redis")
94#[cfg(feature = "redis")]
95pub mod distributed_redis;
96
97/// Sitemap / sitemap-index source adapter
98pub mod sitemap;
99
100/// RSS/Atom feed source adapter
101pub mod rss_feed;
102
103/// WebSocket stream source adapter
104pub mod websocket;
105
106/// CSV/TSV data source adapter
107pub mod csv_source;
108
109/// S3-compatible object storage adapter (feature = "object-storage")
110#[cfg(feature = "object-storage")]
111pub mod storage_s3;
112
113/// Axum-based webhook trigger adapter (feature = "api")
114#[cfg(feature = "api")]
115pub mod webhook;
116
117/// Default tiered escalation policy with challenge detection (feature = "escalation")
118#[cfg(feature = "escalation")]
119pub mod escalation;
120
121#[cfg(feature = "scrape-exchange")]
122pub mod scrape_exchange;