diff --git a/Cargo.lock b/Cargo.lock index c8584aa..3adf9c8 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -986,8 +986,9 @@ checksum = "8d79878f18e518d77cfb3126939d0e63a62cad845d51a3266f4ac866f2efe57f" [[package]] name = "fedimint-aead" -version = "0.3.0-rc.3" -source = "git+https://github.com/fedimint/fedimint?tag=v0.3.0-rc.3#c32bbe8ed8d95ae420b5879e92dda6ce48f5c914" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b6aa38d22aa2ec4a8182f781c9bdd91b899cf9c5f4f5cf4d8470ce72df4499fd" dependencies = [ "anyhow", "argon2", @@ -998,8 +999,9 @@ dependencies = [ [[package]] name = "fedimint-bitcoind" -version = "0.3.0-rc.3" -source = "git+https://github.com/fedimint/fedimint?tag=v0.3.0-rc.3#c32bbe8ed8d95ae420b5879e92dda6ce48f5c914" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "59bd38e6c7ca4c9294660037cbb4c3eaa09c2e4566f90feedcebd56b4a396a27" dependencies = [ "anyhow", "async-trait", @@ -1019,16 +1021,18 @@ dependencies = [ [[package]] name = "fedimint-build" -version = "0.3.0-rc.3" -source = "git+https://github.com/fedimint/fedimint?tag=v0.3.0-rc.3#c32bbe8ed8d95ae420b5879e92dda6ce48f5c914" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a87d1526d927524a13663e844b6a65a6bf91d619ccdf1ffa122f7ab197d32ec6" dependencies = [ "serde_json", ] [[package]] name = "fedimint-client" -version = "0.3.0-rc.3" -source = "git+https://github.com/fedimint/fedimint?tag=v0.3.0-rc.3#c32bbe8ed8d95ae420b5879e92dda6ce48f5c914" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2c291c1f8a74d52181ec996bc1954df91242af134fb690aa0c9b560462b6ffa7" dependencies = [ "anyhow", "aquamarine", @@ -1096,8 +1100,9 @@ dependencies = [ [[package]] name = "fedimint-core" -version = "0.3.0-rc.3" -source = "git+https://github.com/fedimint/fedimint?tag=v0.3.0-rc.3#c32bbe8ed8d95ae420b5879e92dda6ce48f5c914" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5664f67aee6ea8b28dc91363d602ee17c6c05f1f36f2f1d0064785e1cf1c3d0e" dependencies = [ "anyhow", "async-lock", @@ -1149,8 +1154,9 @@ dependencies = [ [[package]] name = "fedimint-derive" -version = "0.3.0-rc.3" -source = "git+https://github.com/fedimint/fedimint?tag=v0.3.0-rc.3#c32bbe8ed8d95ae420b5879e92dda6ce48f5c914" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8c3212a1f0b4f3d7a8b93bc458c9dbc591eabf8342ab44496a26d0201834140a" dependencies = [ "itertools 0.12.1", "proc-macro2", @@ -1160,8 +1166,9 @@ dependencies = [ [[package]] name = "fedimint-derive-secret" -version = "0.3.0-rc.3" -source = "git+https://github.com/fedimint/fedimint?tag=v0.3.0-rc.3#c32bbe8ed8d95ae420b5879e92dda6ce48f5c914" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7eecd4ff491a3eae9de9c8a4844febad2af2e414b0100d31fc14b6f6c3c1e0f9" dependencies = [ "anyhow", "fedimint-core", @@ -1173,16 +1180,18 @@ dependencies = [ [[package]] name = "fedimint-hkdf" -version = "0.3.0-rc.3" -source = "git+https://github.com/fedimint/fedimint?tag=v0.3.0-rc.3#c32bbe8ed8d95ae420b5879e92dda6ce48f5c914" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2303eedda2fc433b1f6a9969ec3aba0fd40f41e403fd60b7e079cab9a02232a5" dependencies = [ "bitcoin_hashes 0.11.0", ] [[package]] name = "fedimint-ln-client" -version = "0.3.0-rc.3" -source = "git+https://github.com/fedimint/fedimint?tag=v0.3.0-rc.3#c32bbe8ed8d95ae420b5879e92dda6ce48f5c914" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "11e2f9a7125f76b26edc719e87b5550b4cec41dcd4f46080f19b3e0b9cb959a1" dependencies = [ "anyhow", "aquamarine", @@ -1215,8 +1224,9 @@ dependencies = [ [[package]] name = "fedimint-ln-common" -version = "0.3.0-rc.3" -source = "git+https://github.com/fedimint/fedimint?tag=v0.3.0-rc.3#c32bbe8ed8d95ae420b5879e92dda6ce48f5c914" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bd0590df1190cfb2a53c39d2c7eb152c45f77760c2653a2e823b4c10a57c2612" dependencies = [ "anyhow", "aquamarine", @@ -1245,8 +1255,9 @@ dependencies = [ [[package]] name = "fedimint-logging" -version = "0.3.0-rc.3" -source = "git+https://github.com/fedimint/fedimint?tag=v0.3.0-rc.3#c32bbe8ed8d95ae420b5879e92dda6ce48f5c914" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a26a4aec2b4da537dad90e76eae070a066e211f11bd1d16c5d84fa16f61cf568" dependencies = [ "anyhow", "tracing-subscriber", @@ -1254,8 +1265,9 @@ dependencies = [ [[package]] name = "fedimint-mint-client" -version = "0.3.0-rc.3" -source = "git+https://github.com/fedimint/fedimint?tag=v0.3.0-rc.3#c32bbe8ed8d95ae420b5879e92dda6ce48f5c914" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7bc49a3963e108a9ee34e097d7929496cae14cf3b4e97cc3fb4b0da92e039037" dependencies = [ "anyhow", "aquamarine", @@ -1289,8 +1301,9 @@ dependencies = [ [[package]] name = "fedimint-mint-common" -version = "0.3.0-rc.3" -source = "git+https://github.com/fedimint/fedimint?tag=v0.3.0-rc.3#c32bbe8ed8d95ae420b5879e92dda6ce48f5c914" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c40186a21482c8162ddef517692b3547fddc6ab584fb4f9e90a09adf8a331e16" dependencies = [ "anyhow", "async-trait", @@ -1313,8 +1326,9 @@ dependencies = [ [[package]] name = "fedimint-rocksdb" -version = "0.3.0-rc.3" -source = "git+https://github.com/fedimint/fedimint?tag=v0.3.0-rc.3#c32bbe8ed8d95ae420b5879e92dda6ce48f5c914" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6855695fa429c4cdcdff1756ac217369f3585e3a68a2c52bcff173e656bb0325" dependencies = [ "anyhow", "async-trait", @@ -1327,8 +1341,9 @@ dependencies = [ [[package]] name = "fedimint-tbs" -version = "0.3.0-rc.3" -source = "git+https://github.com/fedimint/fedimint?tag=v0.3.0-rc.3#c32bbe8ed8d95ae420b5879e92dda6ce48f5c914" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ad90977bc2ca480371aeb395efe35c57ddabad103b10ffe418dd8c068092dd93" dependencies = [ "bitcoin_hashes 0.11.0", "bls12_381", @@ -1364,8 +1379,9 @@ dependencies = [ [[package]] name = "fedimint-wallet-client" -version = "0.3.0-rc.3" -source = "git+https://github.com/fedimint/fedimint?tag=v0.3.0-rc.3#c32bbe8ed8d95ae420b5879e92dda6ce48f5c914" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9edc4fcd7f3284fe9d89d7e94fb03d765753a66b46b53e2256de70b65f52c4f3" dependencies = [ "anyhow", "aquamarine", @@ -1395,8 +1411,9 @@ dependencies = [ [[package]] name = "fedimint-wallet-common" -version = "0.3.0-rc.3" -source = "git+https://github.com/fedimint/fedimint?tag=v0.3.0-rc.3#c32bbe8ed8d95ae420b5879e92dda6ce48f5c914" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a4d8f6767ab717bbc47ffbb2dc3bb7d68ea5d83c48f25fbfe100b6b879406b48" dependencies = [ "anyhow", "async-trait", diff --git a/fedimint-clientd/Cargo.toml b/fedimint-clientd/Cargo.toml index 20b6c22..48bc684 100644 --- a/fedimint-clientd/Cargo.toml +++ b/fedimint-clientd/Cargo.toml @@ -18,12 +18,12 @@ serde_json = "1.0.108" tokio = { version = "1.34.0", features = ["full"] } tracing = "0.1.40" tracing-subscriber = "0.3.18" -fedimint-client = { git = "https://github.com/fedimint/fedimint", tag = "v0.3.0-rc.3" } -fedimint-core = { git = "https://github.com/fedimint/fedimint", tag = "v0.3.0-rc.3" } -fedimint-wallet-client = { git = "https://github.com/fedimint/fedimint", tag = "v0.3.0-rc.3" } -fedimint-mint-client = { git = "https://github.com/fedimint/fedimint", tag = "v0.3.0-rc.3" } -fedimint-ln-client = { git = "https://github.com/fedimint/fedimint", tag = "v0.3.0-rc.3" } -fedimint-rocksdb = { git = "https://github.com/fedimint/fedimint", tag = "v0.3.0-rc.3" } +fedimint-client = "0.3.0" +fedimint-core = "0.3.0" +fedimint-wallet-client = "0.3.0" +fedimint-mint-client = "0.3.0" +fedimint-ln-client = "0.3.0" +fedimint-rocksdb = "0.3.0" url = "2.5.0" lazy_static = "1.4.0" async-utility = "0.2.0" diff --git a/flake.lock b/flake.lock index ae1e6ab..29a1549 100644 --- a/flake.lock +++ b/flake.lock @@ -188,17 +188,17 @@ "nixpkgs": "nixpkgs_4" }, "locked": { - "lastModified": 1711405975, - "narHash": "sha256-I8uUhpqN5oGDkT+sN4jztzun/wD/mN/CtzCxlV3pdjY=", + "lastModified": 1711990352, + "narHash": "sha256-IRaivPWz9SVmyFKsPT24OkNYO4WS+6WHhXyl0h0xDSM=", "owner": "fedimint", "repo": "fedimint", - "rev": "c32bbe8ed8d95ae420b5879e92dda6ce48f5c914", + "rev": "a41e3a7e31ce0f26058206a04f1cd49ef2b12fe3", "type": "github" }, "original": { "owner": "fedimint", + "ref": "v0.3.0", "repo": "fedimint", - "rev": "c32bbe8ed8d95ae420b5879e92dda6ce48f5c914", "type": "github" } }, diff --git a/flake.nix b/flake.nix index e5f0040..aae61c9 100644 --- a/flake.nix +++ b/flake.nix @@ -10,10 +10,7 @@ inputs.nixpkgs.follows = "nixpkgs"; }; - fedimint = { - url = - "github:fedimint/fedimint?rev=c32bbe8ed8d95ae420b5879e92dda6ce48f5c914"; - }; + fedimint = { url = "github:fedimint/fedimint?ref=v0.3.0"; }; flake-utils.url = "github:numtide/flake-utils"; }; diff --git a/multimint/Cargo.toml b/multimint/Cargo.toml index 5cd96e1..f3a4421 100644 --- a/multimint/Cargo.toml +++ b/multimint/Cargo.toml @@ -13,12 +13,12 @@ anyhow = "1.0.75" serde = "1.0.193" serde_json = "1.0.108" tokio = { version = "1.34.0", features = ["full"] } -fedimint-client = { git = "https://github.com/fedimint/fedimint", tag = "v0.3.0-rc.3" } -fedimint-core = { git = "https://github.com/fedimint/fedimint", tag = "v0.3.0-rc.3" } -fedimint-wallet-client = { git = "https://github.com/fedimint/fedimint", tag = "v0.3.0-rc.3" } -fedimint-mint-client = { git = "https://github.com/fedimint/fedimint", tag = "v0.3.0-rc.3" } -fedimint-ln-client = { git = "https://github.com/fedimint/fedimint", tag = "v0.3.0-rc.3" } -fedimint-rocksdb = { git = "https://github.com/fedimint/fedimint", tag = "v0.3.0-rc.3" } +fedimint-client = "0.3.0" +fedimint-core = "0.3.0" +fedimint-wallet-client = "0.3.0" +fedimint-mint-client = "0.3.0" +fedimint-ln-client = "0.3.0" +fedimint-rocksdb = "0.3.0" futures-util = "0.3.30" rand = "0.8.5" tracing = "0.1.40" diff --git a/wrappers/fedimint-ts/example.ts b/wrappers/fedimint-ts/example.ts index be1220a..dd74461 100644 --- a/wrappers/fedimint-ts/example.ts +++ b/wrappers/fedimint-ts/example.ts @@ -1,4 +1,4 @@ -import { FedimintClientBuilder } from "fedimint-ts"; +import { FedimintClientBuilder } from "./FedimintClient"; import dotenv from "dotenv"; dotenv.config(); @@ -19,14 +19,11 @@ async function main() { // You can update the federationId to call methods on a different federation const { federationIds } = await fedimintClient.federationIds(); - await fedimintClient.setActiveFederationId(federationIds[0]); + await fedimintClient.setActiveFederationId(federationIds[0], true); // Any methods that call on a specific federation can optionally take a federationId as the last argument // If no federationId is passed, the default federationId is used - const _ = await fedimintClient.listOperations( - { limit: 10 }, - federationIds[1] - ); + const _ = await fedimintClient.listOperations(10, federationIds[1]); // Admin methods give summaries by federation const response = await fedimintClient.info(); diff --git a/wrappers/fedimint-ts/types.ts b/wrappers/fedimint-ts/types.ts index dea6180..0c24d92 100644 --- a/wrappers/fedimint-ts/types.ts +++ b/wrappers/fedimint-ts/types.ts @@ -7,12 +7,13 @@ interface TieredSummary { } interface InfoResponse { - federationId: string; - network: string; - meta: { [key: string]: string }; - totalAmountMsat: number; - totalNumNotes: number; - denominationsMsat: TieredSummary; + [federationId: string]: { + network: string; + meta: { [key: string]: string }; + totalAmountMsat: number; + totalNumNotes: number; + denominationsMsat: TieredSummary; + }; } interface FederationIdsResponse {