polyester/chain/
environment.rs1#[derive(Debug, Clone, PartialEq, Eq)]
5pub struct EntryPointConfig {
6 pub address: &'static str,
7 pub version: &'static str,
8}
9
10#[derive(Debug, Clone, PartialEq, Eq)]
12pub struct SafeDeploymentConfig {
13 pub version: &'static str,
14 pub safe_module_setup_address: &'static str,
15 pub safe_4337_module_address: &'static str,
16 pub safe_proxy_factory_address: &'static str,
17 pub safe_singleton_address: &'static str,
18 pub multi_send_address: &'static str,
19 pub multi_send_call_only_address: Option<&'static str>,
20}
21
22#[derive(Debug, Clone, PartialEq, Eq)]
24pub struct AccountAbstractionEnvironment {
25 pub bundler_url: &'static str,
26 pub paymaster_url: &'static str,
27 pub entry_point: EntryPointConfig,
28 pub safe: SafeDeploymentConfig,
29}
30
31#[derive(Debug, Clone, PartialEq, Eq)]
33pub struct ContractsEnvironment {
34 pub trading_gateway_address: &'static str,
35 pub funding_account_address: &'static str,
36 pub guard_registry_address: &'static str,
37 pub zipper_endpoint_address: &'static str,
38}
39
40#[derive(Debug, Clone, PartialEq, Eq)]
42pub struct PolyesterChainEnvironment {
43 pub name: &'static str,
44 pub api_url: &'static str,
45 pub websocket_url: &'static str,
46 pub rpc_url: &'static str,
47 pub chain_id: u64,
48 pub account_abstraction: AccountAbstractionEnvironment,
49 pub contracts: ContractsEnvironment,
50}
51
52pub const POLYESTER_TESTNET_ENVIRONMENT: PolyesterChainEnvironment = PolyesterChainEnvironment {
54 name: "polyester-testnet",
55 api_url: "https://api-devnet.polyester.ai",
56 websocket_url: "wss://api-devnet.polyester.ai",
57 rpc_url: "https://rpc.polyester.tech",
58 chain_id: 888168,
59 account_abstraction: AccountAbstractionEnvironment {
60 bundler_url: "https://bundler.polyester.tech",
61 paymaster_url: "https://paymaster.polyester.tech",
62 entry_point: EntryPointConfig {
63 address: "0x59a4B77766509c4507D79eFF8089474eC3daC174",
64 version: "0.7",
65 },
66 safe: SafeDeploymentConfig {
67 version: "1.4.1",
68 safe_module_setup_address: "0x80791683D9C079A37Debc67EaDdbFcBC6f0FF2bB",
69 safe_4337_module_address: "0x0713FF3d4c1b4f177833a372b1e3cb977540EA11",
70 safe_proxy_factory_address: "0xF8F0F649Dd3bFa9095206691E9fb2356c26216dE",
71 safe_singleton_address: "0x92abEa238FEA8908c397cE65366ea9278f0AeC7A",
72 multi_send_address: "0x70C8a8CcB45a8E2589B0f019374fc923dA34E4c7",
73 multi_send_call_only_address: Some("0x375C86a08DA98d1944D7B3c736307A72186CcAf1"),
74 },
75 },
76 contracts: ContractsEnvironment {
77 trading_gateway_address: "0xD3fecf5D39131e23b6B0f872cA0a21c8A5a30932",
78 funding_account_address: "0xBfF4F6224BC10f233dDB1E61E770d9832aabC7c4",
79 guard_registry_address: "0xd71F60FD6f784Cc0aD8c25441568C48705D95f64",
80 zipper_endpoint_address: "0xae6B981BE9B73421eB1ba5372d1A4A937d63ffFB",
81 },
82};