MCPcopy Index your code
hub / github.com/arrowprotocol/arrow

github.com/arrowprotocol/arrow @v0.3.1

Chat with this repo
repository ↗ · DeepWiki ↗ · release v0.3.1 ↗ · + Follow
95 symbols 172 edges 30 files 18 documented · 19%
What it actually does AI analysis from the code graph — generated when you open this
loading…
README

Arrow

License Build Status Contributors

Arrow

Launch staking derivatives for the protocols you're already integrating with, redirecting yield to a different address.

We're in active development. For the latest updates, please join our community:

  • Twitter: https://twitter.com/arrowprotocol/
  • Keybase Chat: https://keybase.io/team/arrowverse

About

Arrow allows individuals, protocols, and DAOs to launch staking derivatives which redirect yield to a different address. This allows protocols to directly benefit from integrating with underlying protocols that issue tokens via liquidity mining.

Potential users may include:

  • Lending protocols. A lender may take Saber LPs as collateral. By using Arrow, the lending protocol only needs to accept their Arrow for the corresponding LP token as collateral, and earns Saber and Sunny tokens for doing so.
  • Crates. As Crates can only hold tokens, they cannot directly integrate with farming pools. This tokenization allows the yields of underlying assets to get redirected to the creator of the Crate, or to the Crate itself, allowing for extremely composable yield aggregation.
  • Community fundraising. A community can pool its yield-generating assets via an Arrow to help fund its operations. As these derivatives are tokens, the community has a very simple cap table they can use to ensure that its members are staking a minimum amount.
  • Charitable organizations. One could create an Arrow which redirects yield to a charity, allowing users to donate to a cause without needing to spend any money. Notable prior work in this space includes rTrees, a DAO which plants trees from DAI yield.

Arrow's first integration is with the Sunny Aggregator. As Sunny is built on top of Quarry, we expect Sunny to integrate with any future Quarry pools. At the time of writing, this will allow users to redirect Sunny and Saber yields.

Packages

Package Description Version Docs
arrow-sunny Sunny protocol integration for Arrow. Crates.io Docs.rs
sunny-anchor Anchor crate to integrate with Sunny Aggregator. Crates.io Docs.rs
@arrowprotocol/arrow TypeScript SDK for Arrow npm Docs

Note

  • Arrow is in active development, so all APIs are subject to change.
  • This code is unaudited. Use at your own risk.

Contribution

Thank you for your interest in contributing to Arrow Protocol! All contributions are welcome no matter how big or small. This includes (but is not limited to) filing issues, adding documentation, fixing bugs, creating examples, and implementing features.

If you'd like to contribute, please claim an issue by commenting, forking, and opening a pull request, even if empty. This allows the maintainers to track who is working on what issue as to not overlap work.

For simple documentation changes, feel free to just open a pull request.

If you're considering larger changes or self motivated features, please file an issue and engage with the maintainers by posting in our Keybase community.

License

Arrow Protocol is licensed under the Affero GPL 3.0 license.

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in Arrow Protocol by you, as defined in the AGPL-3.0 license, shall be licensed as above, without any additional terms or conditions.

Extension points exported contracts — how you extend this code

ArrowPrograms (Interface)
(no doc)
src/arrow.ts

Core symbols most depended-on inside this repo

validate_miner
called by 3
programs/arrow-sunny/src/account_validators.rs
assert_not_initialized
called by 3
programs/arrow-sunny/src/instructions/init_arrow_miners.rs
generateArrowAddress
called by 3
src/pda.ts
withdraw_from_vault
called by 2
programs/arrow-sunny/lib/sunny/src/lib.rs
miner_for_rewards
called by 2
programs/arrow-sunny/src/account_validators.rs
init_miner
called by 2
programs/arrow-sunny/src/instructions/init_arrow_miners.rs
init
called by 2
src/arrow.ts
_generateStakeAccounts
called by 2
src/arrow.ts

Shape

Method 37
Class 29
Function 27
Enum 1
Interface 1

Languages

Rust78%
TypeScript22%

Modules by API surface

programs/arrow-sunny/src/lib.rs21 symbols
programs/arrow-sunny/lib/sunny/src/lib.rs19 symbols
src/arrow.ts13 symbols
programs/arrow-sunny/src/instructions/init_arrow_miners.rs8 symbols
programs/arrow-sunny/src/instructions/unstake_internal.rs4 symbols
programs/arrow-sunny/src/instructions/new_arrow.rs4 symbols
src/pda.ts3 symbols
programs/arrow-sunny/src/events.rs3 symbols
tests/quarryUtils.ts2 symbols
programs/arrow-sunny/src/state.rs2 symbols
programs/arrow-sunny/src/instructions/withdraw_vendor_tokens.rs2 symbols
programs/arrow-sunny/src/instructions/withdraw_rewards_to_beneficiary.rs2 symbols

For agents

$ claude mcp add arrow \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact