# Contract Architecture

**BitcoinPodManager.sol**

This contract is the entry point for the client for all actions related to BitcoinPod, aka BOD. This contract:&#x20;

1. Deploys the BOD
2. Handles bitcoin deposit/withdrawal requests
3. Interacts with the service manager&#x20;
4. Delegates to Apps

**BitcoinPod.sol**

This is a unique contract deployed everytime for a new bitcoin address created a BOD. This contract:&#x20;

1. Maps a Bitcoin address to an Ethereum address
2. Tracks Bitcoin balances in the BOD
3. Delegates to apps via `BitcoinPodManager.sol`
4. Manages bitcoin transaction storage

**BitDSMRegistry.sol**

1. Handles operator's registration/deregistration
2. Stores a mapping for operator's bitcoin pubkey

**AppRegistry.sol**

This is the entrypoint for Apps to gain access to in-kind Bitcoin. This contract&#x20;

1. Maintains a mapping of the contract address for the app and the BODs delegated to it.

**BitDSMServiceManager.sol**

This is the AVS service manager contract deployed on Eigenlayer's `AVSDirectory.sol`. This contract:

1. Manages Bitcoin pod operations through `IBitcoinPodManager`
2. Handles deposit/withdrawal confirmations from operators
3. Integrates with EigenLayer for staking and delegation


---

# 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.motif.finance/specification/contract-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.
