# Technical Architecture

#### Smart Contract Design

EvoPay’s core infrastructure is built on Ethereum using modular, non-custodial smart contracts. These contracts govern payment flows, wallet logic, and future integrations like fundraising and lending — all without third-party custody. The contracts are optimized for simplicity and auditability, with upgrade pathways for adding ERC-20 token privacy routing and on-chain governance.

#### Bot-Chain Communication Layer

EvoPay connects its Telegram bot to the Ethereum blockchain via secure backend relays. Every on-chain action (e.g., private routing trigger, donation confirmation, lending record) is synced with the bot in real time. This dual-recording model ensures verifiability for all transactions.

#### Wallet Generation

Users can generate new ETH wallets inside the bot using ECDSA-based methods. Private keys are never stored on EvoPay servers. Wallets are stored locally and encrypted within the telegram account using standard AES-256 encryption models. Advanced users can also operate in ephemeral, connectionless mode.

#### Ecosystem Compatibility

EvoPay is EVM-compatible by design. Future support includes additional chains like Polygon, Arbitrum, and Base — enabling cross-chain payments and fundraising using the same bot interface. Smart contract standards remain compliant with ERC-20/ERC-721 to maximize dApp and DEX interoperability.

#### Developer-Facing Modules

A structured API and SDK are planned for Phase 4, allowing builders to integrate EvoPay's payment layer into third-party dApps, bots, and platforms. Modular plugin-style components will allow for merchant checkout flows, automated invoicing, and white-label fundraising widgets.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.evopay.me/technical-architecture.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
