aiway_protocol/common/
constants.rs1use std::collections::HashSet;
2use std::sync::LazyLock;
3
4pub const ENCRYPT_KEY: &[u8; 32] = b"00000000000000000000000000000000";
6
7pub const REPORT_STATE_INTERVAL: u64 = 5;
9
10pub static BAN_HEADERS: LazyLock<HashSet<&'static str>> = LazyLock::new(|| {
12 [
13 "content-length",
14 "x-frame-options",
15 "x-content-type-options",
16 "x-xss-protection",
17 "server",
18 "transfer-encoding",
19 "connection",
20 "te",
21 "trailer",
22 "permissions-policy",
23 ]
24 .iter()
25 .copied()
26 .collect()
27});
28
29pub const GATEWAY_LOCAL_SOCK_PATH: &str = "/tmp/aiway.sock";
30
31pub const LOCAL_SERVICE: &str = "__local__";
32
33pub const MODEL_API_PREFIX: &str = "/v1/model/";
34pub const MCP_API_PREFIX: &str = "/v1/mcp/";