Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 7 additions & 6 deletions .apigen-state
Original file line number Diff line number Diff line change
@@ -1,16 +1,17 @@
{
"version": "1",
"algorithm": "sha256",
"generated_at": "2026-03-09T16:37:05.015868Z",
"generated_at": "2026-03-13T17:12:11.050134Z",
"spec_files": {
"resources/account-data-api.yaml": "2d366acf63b1412c3b49583b22aea07829f297332ebd1b0680954d0d248f2998",
"resources/auth-api.yaml": "d323937afd8fd9431a1075bb7ae06a28181848afd6e5278675b9a2945b9257c1",
"resources/bluefin-api.yaml": "114c8ea5a7cb58d0a53f54a8fbfe4a7c9616bfb0286a951afa057906ebd69179",
"resources/common.yaml": "f0140950057e524457e5197c5b20bf8d74342e596378043ff8b4c75b5a3fc036",
"resources/auth-api.yaml": "d26ab4c10c7c716fd7888513a5a51123f5040067d56fd7e96b55431ed2f3184c",
"resources/bluefin-api.yaml": "b81cebbb70822b4806a9c56e819d6dd1b52453f4b37d63a95a14dae7cf0edb9c",
"resources/common.yaml": "71dc565fccebcc9e71b49b48448d2583903aec7e2d16ef1d69972b50f2e4250f",
"resources/exchange-api.yaml": "a309b3a5c29fb71dcc26d6f8018883ec51b42db43c29fee7b7ed4f0997146f77",
"resources/rewards-data-api.yaml": "2c715683d080ad11aa7667d81e36b1f36839da5d2af1bd3ce0d164db6f19cb0c",
"resources/trade-api.yaml": "229ac3d9a7a30b640db928cc5d99cddc4e185e70b76e7c0d7273f94225cd1d37",
"resources/websocket-api.yaml": "eefb5b151d020ca372577927bb740b3bf1206cc2d31f8c0d8763bf6e56590330"
"resources/vera-api.yaml": "f4c51b5f6614dd4e3b9f5f1f01f945e06d9090849530ecb916ad4ae18d8f61a0",
"resources/websocket-api.yaml": "c2c51ceea701bff0b7e911e9afdb0addeb4d7f173b2a25b996d13f5462cb535b"
},
"combined_hash": "104e4eef97711bac98ad21c203db31ccd213605bda6cf241fab2c48dcffaca6d"
"combined_hash": "c9a9df6db69d3ab7c6a3c97c28336f560af1f5be224d70ff549da75c1be5e45a"
}
2 changes: 1 addition & 1 deletion python/sdk/config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@ additionalProperties:
library: asyncio
generateSourceCodeOnly: true
useOneOfDiscriminatorLookup: true
packageVersion: 1.13.0
packageVersion: 1.14.0
2 changes: 1 addition & 1 deletion python/sdk/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ description = "Python Boilerplate contains all the boilerplate you need to creat
name = "bluefin_pro_sdk"
readme = "README.rst"
requires-python = ">=3.9.2,<3.14.0"
version = "1.13.0"
version = "1.14.0"

[[project.authors]]
email = "audreyr@example.com"
Expand Down
2 changes: 1 addition & 1 deletion python/sdk/src/openapi_client/__init__.py

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion python/sdk/src/openapi_client/api_client.py

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion python/sdk/src/openapi_client/configuration.py

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion python/sdk/src/openapi_client_README.md

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions rust/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

30 changes: 15 additions & 15 deletions rust/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,14 +1,3 @@
[features]
# Default TLS mode: platform-native TLS backend.
default = ["tls-native-tls"]

# Optional rustls backend with aws-lc-rs crypto provider.
tls-rustls = ["dep:rustls", "reqwest/rustls-tls-webpki-roots"]

# Platform-native TLS backend (OpenSSL on many Linux distros,
# Security Framework on macOS, Schannel on Windows).
tls-native-tls = ["reqwest/native-tls"]

[dependencies]
base64 = "0.22.1"
bcs = "0.1.6"
Expand All @@ -20,20 +9,23 @@ sha2 = "0.10.9"

[dependencies.bluefin_api]
path = "gen/bluefin_api"
version = "1.13.0"
version = "1.14.0"

[dependencies.ed25519-dalek]
features = ["rand_core"]
version = "2.2.0"

[dependencies.reqwest]
package = "reqwest"
default-features = false
package = "reqwest"
version = "0.12"

[dependencies.rustls]
default-features = false
features = ["aws-lc-rs", "std"]
features = [
"aws-lc-rs",
"std",
]
optional = true
version = "0.23"

Expand Down Expand Up @@ -75,6 +67,14 @@ version = "1.50.0"
features = ["rustls-tls-webpki-roots"]
version = "0.24.0"

[features]
default = ["tls-native-tls"]
tls-native-tls = ["reqwest/native-tls"]
tls-rustls = [
"dep:rustls",
"reqwest/rustls-tls-webpki-roots",
]

[package]
categories = [
"api-bindings",
Expand All @@ -93,7 +93,7 @@ keywords = [
license = "Unlicense"
name = "bluefin-pro"
repository = "https://github.com/fireflyprotocol/pro-sdk"
version = "1.13.0"
version = "1.14.0"

[workspace]
members = [
Expand Down
4 changes: 2 additions & 2 deletions rust/examples/account-value-history-by-account.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ use bluefin_api::apis::account_data_api::get_account_value_history_by_account;
use bluefin_api::apis::configuration::Configuration;
use bluefin_api::models::AccountValueHistory;
use bluefin_pro::prelude::*;
use hex::FromHex;


type Error = Box<dyn std::error::Error>;
type Result<T> = std::result::Result<T, Error>;
Expand All @@ -26,7 +26,7 @@ async fn main() -> Result<()> {
let environment = Environment::Staging;
let test_account_address = environment.test_keys().unwrap().address;

let response = send_request(test_account_address.into()).await?;
let response = send_request(test_account_address).await?;

println!("{response:#?}");

Expand Down
10 changes: 4 additions & 6 deletions rust/examples/expanded-usage.rs
Original file line number Diff line number Diff line change
Expand Up @@ -56,8 +56,7 @@ async fn listen_to_account_stream_websocket(
ws_sender
.send(Message::Text(serde_json::to_string(
&AccountSubscriptionMessage::new(SubscriptionType::Subscribe, subscriptions),
)?
.into()))
)?))
.await?;

// Now, we spawn a websocket listener task to listen for messages on the subscribed topic.
Expand All @@ -75,7 +74,7 @@ async fn listen_to_account_stream_websocket(
Message::Ping(_) => {
println!("Ping received");
// Send Pong.
if let Err(error) = ws_sender.send(Message::Pong(Vec::new().into())).await {
if let Err(error) = ws_sender.send(Message::Pong(Vec::new())).await {
eprintln!("Error sending Pong: {error}");
return;
}
Expand Down Expand Up @@ -134,8 +133,7 @@ async fn listen_to_market_stream_websocket(
ws_sender
.send(Message::Text(serde_json::to_string(
&MarketSubscriptionMessage::new(SubscriptionType::Subscribe, subscriptions),
)?
.into()))
)?))
.await?;

// Now, we spawn a websocket listener task to listen for messages on the subscribed topic.
Expand All @@ -153,7 +151,7 @@ async fn listen_to_market_stream_websocket(
Message::Ping(_) => {
println!("Ping received");
// Send Pong.
if let Err(error) = ws_sender.send(Message::Pong(Vec::new().into())).await {
if let Err(error) = ws_sender.send(Message::Pong(Vec::new())).await {
eprintln!("Error sending Pong: {error}");
return;
}
Expand Down
5 changes: 2 additions & 3 deletions rust/examples/trade-cancel-order.rs
Original file line number Diff line number Diff line change
Expand Up @@ -85,8 +85,7 @@ async fn listen_to_account_order_updates(
SubscriptionType::Subscribe,
vec![AccountDataStream::AccountOrderUpdate],
),
)?
.into()))
)?))
.await?;

// Now, we spawn a websocket listener task to listen for messages on the subscribed topic.
Expand All @@ -104,7 +103,7 @@ async fn listen_to_account_order_updates(
Message::Ping(_) => {
println!("Ping received");
// Send Pong.
if let Err(error) = ws_sender.send(Message::Pong(Vec::new().into())).await {
if let Err(error) = ws_sender.send(Message::Pong(Vec::new())).await {
eprintln!("Error sending Pong: {error}");
return;
}
Expand Down
5 changes: 2 additions & 3 deletions rust/examples/trade-create-order.rs
Original file line number Diff line number Diff line change
Expand Up @@ -70,8 +70,7 @@ async fn listen_to_account_order_updates(
SubscriptionType::Subscribe,
vec![AccountDataStream::AccountOrderUpdate],
),
)?
.into()))
)?))
.await?;

// Now, we spawn a websocket listener task to listen for messages on the subscribed topic.
Expand All @@ -89,7 +88,7 @@ async fn listen_to_account_order_updates(
Message::Ping(_) => {
println!("Ping received");
// Send Pong.
if let Err(error) = ws_sender.send(Message::Pong(Vec::new().into())).await {
if let Err(error) = ws_sender.send(Message::Pong(Vec::new())).await {
eprintln!("Error sending Pong: {error}");
return;
}
Expand Down
5 changes: 2 additions & 3 deletions rust/examples/trade-withdraw.rs
Original file line number Diff line number Diff line change
Expand Up @@ -65,8 +65,7 @@ async fn listen_to_account_info(
SubscriptionType::Subscribe,
vec![AccountDataStream::AccountUpdate],
),
)?
.into()))
)?))
.await?;

// Now, we spawn a websocket listener task to listen for messages on the subscribed topic.
Expand All @@ -84,7 +83,7 @@ async fn listen_to_account_info(
Message::Ping(_) => {
println!("Ping received");
// Send Pong.
if let Err(error) = ws_sender.send(Message::Pong(Vec::new().into())).await {
if let Err(error) = ws_sender.send(Message::Pong(Vec::new())).await {
eprintln!("Error sending Pong: {error}");
return;
}
Expand Down
5 changes: 2 additions & 3 deletions rust/examples/ws-account-update-stream.rs
Original file line number Diff line number Diff line change
Expand Up @@ -65,8 +65,7 @@ async fn listen_to_account_info(
SubscriptionType::Subscribe,
vec![AccountDataStream::AccountUpdate],
),
)?
.into()))
)?))
.await?;

// Now, we spawn a websocket listener task to listen for messages on the subscribed topic.
Expand All @@ -84,7 +83,7 @@ async fn listen_to_account_info(
Message::Ping(_) => {
println!("Ping received");
// Send Pong.
if let Err(error) = ws_sender.send(Message::Pong(Vec::new().into())).await {
if let Err(error) = ws_sender.send(Message::Pong(Vec::new())).await {
eprintln!("Error sending Pong: {error}");
return;
}
Expand Down
4 changes: 2 additions & 2 deletions rust/examples/ws-candlestick-stream.rs
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ async fn listen_to_candlestick_updates(
);

ws_sender
.send(Message::Text(serde_json::to_string(&sub_message)?.into()))
.send(Message::Text(serde_json::to_string(&sub_message)?))
.await?;

// Spawn a websocket listener task to listen for messages on the subscribed topic.
Expand All @@ -60,7 +60,7 @@ async fn listen_to_candlestick_updates(
Message::Ping(_) => {
println!("Ping received");
// Send back Pong.
if let Err(error) = ws_sender.send(Message::Pong(Vec::new().into())).await {
if let Err(error) = ws_sender.send(Message::Pong(Vec::new())).await {
eprintln!("Error sending Pong: {error}");
}
println!("Pong sent");
Expand Down
5 changes: 2 additions & 3 deletions rust/examples/ws-leverage-update-failure.rs
Original file line number Diff line number Diff line change
Expand Up @@ -72,8 +72,7 @@ async fn listen_to_command_failures(
SubscriptionType::Subscribe,
vec![AccountDataStream::AccountCommandFailureUpdate],
),
)?
.into()))
)?))
.await?;

// Now, we spawn a websocket listener task to listen for messages on the subscribed topic.
Expand All @@ -91,7 +90,7 @@ async fn listen_to_command_failures(
Message::Ping(_) => {
println!("Ping received");
// Send Pong.
if let Err(error) = ws_sender.send(Message::Pong(Vec::new().into())).await {
if let Err(error) = ws_sender.send(Message::Pong(Vec::new())).await {
eprintln!("Error sending Pong: {error}");
return;
}
Expand Down
4 changes: 2 additions & 2 deletions rust/examples/ws-mark-price-stream.rs
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ async fn listen_to_mark_price_updates(
vec![MarketDataStreamName::MarkPrice],
)],
))?;
ws_sender.send(Message::Text(sub_message.into())).await?;
ws_sender.send(Message::Text(sub_message)).await?;

// Spawn a websocket listener task to listen for messages on the subscribed topic.
tokio::spawn(async move {
Expand All @@ -83,7 +83,7 @@ async fn listen_to_mark_price_updates(
Message::Ping(_) => {
println!("Ping received");
// Send back Pong.
if let Err(error) = ws_sender.send(Message::Pong(Vec::new().into())).await {
if let Err(error) = ws_sender.send(Message::Pong(Vec::new())).await {
eprintln!("Error sending Pong: {error}");
}
println!("Pong sent");
Expand Down
4 changes: 2 additions & 2 deletions rust/examples/ws-market-price-stream.rs
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ async fn listen_to_market_price_updates(
)],
))?;

ws_sender.send(Message::Text(sub_message.into())).await?;
ws_sender.send(Message::Text(sub_message)).await?;

// Spawn a websocket listener task to listen for messages on the subscribed topic.
tokio::spawn(async move {
Expand All @@ -91,7 +91,7 @@ async fn listen_to_market_price_updates(
Message::Ping(_) => {
println!("Ping received");
// Send back Pong.
if let Err(error) = ws_sender.send(Message::Pong(Vec::new().into())).await {
if let Err(error) = ws_sender.send(Message::Pong(Vec::new())).await {
eprintln!("Error sending Pong: {error}");
}
println!("Pong sent");
Expand Down
4 changes: 2 additions & 2 deletions rust/examples/ws-oracle-price-stream.rs
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ async fn listen_to_oracle_price_updates(
vec![MarketDataStreamName::OraclePrice],
)],
))?;
ws_sender.send(Message::Text(sub_message.into())).await?;
ws_sender.send(Message::Text(sub_message)).await?;

// Spawn a websocket listener task to listen for messages on the subscribed topic.
tokio::spawn(async move {
Expand All @@ -83,7 +83,7 @@ async fn listen_to_oracle_price_updates(
Message::Ping(_) => {
println!("Ping received");
// Send back Pong.
if let Err(error) = ws_sender.send(Message::Pong(Vec::new().into())).await {
if let Err(error) = ws_sender.send(Message::Pong(Vec::new())).await {
eprintln!("Error sending Pong: {error}");
}
println!("Pong sent");
Expand Down
Loading
Loading