https://github.com/dennohpeter/hyperliquid
A Rust library for the Hyperliquid API
https://github.com/dennohpeter/hyperliquid
api blockchain cryptocurrency exchange hyperliquid rust trading
Last synced: about 1 month ago
JSON representation
A Rust library for the Hyperliquid API
- Host: GitHub
- URL: https://github.com/dennohpeter/hyperliquid
- Owner: dennohpeter
- License: mit
- Created: 2023-09-10T16:41:12.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2024-09-19T19:19:37.000Z (8 months ago)
- Last Synced: 2025-04-05T03:56:36.648Z (about 2 months ago)
- Topics: api, blockchain, cryptocurrency, exchange, hyperliquid, rust, trading
- Language: Rust
- Homepage: https://crates.io/crates/hyperliquid
- Size: 194 KB
- Stars: 17
- Watchers: 1
- Forks: 6
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
### Hyperliquid
[](https://github.com/dennohpeter/hyperliquid/actions/workflows/general.yml)
[](https://github.com/dennohpeter/hyperliquid/actions/workflows/audit.yml)
[](./LICENSE)
[](https://crates.io/crates/hyperliquid)### About
A Rust library for Hyperliquid API
### Install
`Cargo.toml`
```toml
[dependencies]hyperliquid = { version = "0.2.4" }
```### Usage
```rust
use hyperliquid::{Hyperliquid, Chain, Info};#[tokio::main]
async fn main() {
let user: Address = "0xc64cc00b46101bd40aa1c3121195e85c0b0918d8"
.parse()
.expect("Invalid address");let info:Info = Hyperliquid::new(Chain::Dev);
// Retrieve exchange metadata
let metadata = info.metadata().await.unwrap();
println!("Metadata \n{:?}", metadata.universe);
}
```### Examples
See `examples/` for examples. You can run any example with `cargo run --example `.