Official Python SDK for the Enzyme Protocol
Project description
Enzyme Python SDK
This is a work in progress. Your mileage may vary.
Installation
pip install enzymefinance
Getting started
We are currently in the process of writing thorough documentation & tutorials. In the meantime, here there are some quick start examples.
Reading Vault info
import asyncio
from enzymefinance.sdk import vault
from enzymefinance.sdk.utils.clients import PublicClient
async def main():
client = PublicClient(<RPC_URL>)
name = await vault.get_name(
client=client,
vault_proxy=<VAULT_ADDRESS>,
)
print(name)
asyncio.run(main())
<RPC_URL>: The RPC URL of the network you want to connect to.<VAULT_ADDRESS>: The checksum address of the vault you want to read.
Writing Vault info
import asyncio
from enzymefinance.sdk import vault
from enzymefinance.sdk.utils.clients import WalletClient
async def main():
client = WalletClient(<RPC_URL>, <PRIVATE_KEY>)
tx_params = await vault.set_name(
client=client,
vault_proxy=<VAULT_ADDRESS>,
name="My new vault",
)
tx_hash = await client.send_transaction(tx_params)
print(tx_hash)
asyncio.run(main())
<RPC_URL>: The RPC URL of the network you want to connect to.<VAULT_ADDRESS>: The checksum address of the vault you want to read.<PRIVATE_KEY>: The private key of the account you want to use to send the transaction.
Get environment info
from enzymefinance.environment import get_deployment
get_deployment("arbitrum")
Get one specific abi
from enzymefinance.abis import abis
abis.IVaultLib
Community
Check out the following places for support, discussions & feedback:
- Join our Discord server
- Join our Telegram group
- Join the Discussions on GitHub
Authors
License
MIT License
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file enzymefinance-0.1.0.tar.gz.
File metadata
- Download URL: enzymefinance-0.1.0.tar.gz
- Upload date:
- Size: 117.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
53a84566611768c377f1316ce3be5669912e455387240440be594615da6f3e18
|
|
| MD5 |
88838297c7da292d35217aa7e7ecfe46
|
|
| BLAKE2b-256 |
9f3e5b27c215565705ff38afc6385316a37fbe91a69e84c15ebd0507098c3a58
|
File details
Details for the file enzymefinance-0.1.0-py3-none-any.whl.
File metadata
- Download URL: enzymefinance-0.1.0-py3-none-any.whl
- Upload date:
- Size: 138.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
92ed363eec4ab46a095279bc6d7c78e4f66bb97a53a5aa728cfe164a77a4d594
|
|
| MD5 |
9463fbc0077c86eb75cd4938ab5dedbf
|
|
| BLAKE2b-256 |
6f82c96b73f78ccb69aa7d3ae07ed1d2818a2de0a480afbf0d4fc407e74924b5
|