{"id":25040938,"url":"https://github.com/zacksff/vault","last_synced_at":"2025-10-17T11:16:13.343Z","repository":{"id":275829187,"uuid":"914749961","full_name":"zacksfF/Vault","owner":"zacksfF","description":"Vault is a decentralized, overcollateralized stablecoin protocol 🧞‍♂️","archived":false,"fork":false,"pushed_at":"2025-02-04T19:18:56.000Z","size":32,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-02-04T20:26:31.593Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Solidity","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/zacksfF.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":"audit/Audit.md","citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2025-01-10T08:27:39.000Z","updated_at":"2025-02-04T19:20:33.000Z","dependencies_parsed_at":"2025-02-04T20:27:31.196Z","dependency_job_id":"e6b62ceb-3cfd-4d09-9bf8-3755a0f2a114","html_url":"https://github.com/zacksfF/Vault","commit_stats":null,"previous_names":["zacksff/vault"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zacksfF%2FVault","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zacksfF%2FVault/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zacksfF%2FVault/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zacksfF%2FVault/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/zacksfF","download_url":"https://codeload.github.com/zacksfF/Vault/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246386247,"owners_count":20768809,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2025-02-06T03:57:51.656Z","updated_at":"2025-10-17T11:16:13.316Z","avatar_url":"https://github.com/zacksfF.png","language":"Solidity","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Vault Protocol\n\n**A decentralized, overcollateralized stablecoin protocol built on Ethereum**\n\n## What is Vault?\n\nVault Protocol allows users to deposit **WETH** and **WBTC** as collateral to mint **vUSD**, a USD-pegged stablecoin. The protocol ensures stability through **200% overcollateralization** and **automatic liquidation** mechanisms.\n\n## How It Works\n\n```\n1. Deposit Collateral (WETH/WBTC) → 2. Mint vUSD (up to 50% of collateral value) → 3. Maintain Health Factor \u003e 1.0\n```\n\n- **Deposit**: Lock WETH or WBTC as collateral\n- **Mint**: Create vUSD stablecoins (max 50% of collateral value)\n- **Health Factor**: Must stay above 1.0 to avoid liquidation\n- **Liquidation**: 10% bonus for liquidators who restore protocol health\n\n## Technical Architecture\n\n| Component | Purpose |\n|-----------|---------|\n| **VaultEngine** | Core protocol logic, collateral management |\n| **VaultStablecoin (vUSD)** | ERC20 stablecoin token pegged to USD |\n| **PriceOracle** | Chainlink price feeds with staleness protection |\n| **MockERC20** | Test tokens for development |\n\n## Key Parameters\n\n- **Liquidation Threshold**: 50% (200% overcollateralization)\n- **Liquidation Bonus**: 10%\n- **Minimum Health Factor**: 1.0\n- **Supported Collateral**: WETH, WBTC\n- **Price Feeds**: Chainlink ETH/USD, BTC/USD\n\n## Quick Start\n\n### **Local Development**\n```bash\n# Start local blockchain\nmake anvil\n\n# Deploy contracts\nmake deploy-local\n\n# Run tests\nmake test-basic\n```\n\n### **Basic Operations**\n```bash\n# Get test tokens\ncast send $WETH \"faucet(uint256)\" 10000000000000000000 --rpc-url $LOCAL_RPC_URL --private-key $ANVIL_PRIVATE_KEY\n\n# Deposit collateral\ncast send $WETH \"approve(address,uint256)\" $VAULT_ENGINE 5000000000000000000 --rpc-url $LOCAL_RPC_URL --private-key $ANVIL_PRIVATE_KEY\ncast send $VAULT_ENGINE \"depositCollateral(address,uint256)\" $WETH 3000000000000000000 --rpc-url $LOCAL_RPC_URL --private-key $ANVIL_PRIVATE_KEY\n\n# Mint stablecoins\ncast send $VAULT_ENGINE \"mintStablecoin(uint256)\" 1000000000000000000000 --rpc-url $LOCAL_RPC_URL --private-key $ANVIL_PRIVATE_KEY\n```\n\n## Contract Addresses (Local)\n\nUpdate your `.env` after deployment:\n```bash\nVAULT_ENGINE=0x...\nVAULT_STABLECOIN=0x...\nWETH=0x...\nWBTC=0x...\n```\n\n## 🛡️ Security Features\n\n- **Reentrancy Protection**: All state-changing functions protected\n- **Price Feed Validation**: 3-hour staleness timeout\n- **Overcollateralization**: 200% minimum ratio\n- **Liquidation Mechanism**: Automatic position closure\n- **Access Control**: Owner-based minting restrictions\n\n## 🎯 Make Commands\n\n| Command | Description |\n|---------|-------------|\n| `make anvil` | Start local blockchain |\n| `make deploy-local` | Deploy to local Anvil |\n| `make test-basic` | Run basic functionality tests |\n| `make monitor` | Real-time vault monitoring |\n| `make status` | Check contract status |\n\n\n## ⚡ Example Usage\n\n```bash\n# Complete user journey\nmake deploy-local           # Deploy contracts\nmake test-basic            # Test all functions\nmake monitor               # Watch your positions\n```","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fzacksff%2Fvault","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fzacksff%2Fvault","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fzacksff%2Fvault/lists"}