NYM-1199: generate TypeScript types for node-families contract via ts-rs
This commit is contained in:
Generated
+2
@@ -7709,6 +7709,7 @@ dependencies = [
|
||||
"schemars 0.8.22",
|
||||
"serde",
|
||||
"thiserror 2.0.18",
|
||||
"ts-rs",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
@@ -13090,6 +13091,7 @@ dependencies = [
|
||||
"anyhow",
|
||||
"nym-api-requests",
|
||||
"nym-mixnet-contract-common",
|
||||
"nym-node-families-contract-common",
|
||||
"nym-types",
|
||||
"nym-validator-client",
|
||||
"nym-vesting-contract-common",
|
||||
|
||||
@@ -24,9 +24,11 @@ cw-utils = { workspace = true }
|
||||
|
||||
nym-contracts-common = { workspace = true }
|
||||
nym-mixnet-contract-common = { workspace = true }
|
||||
ts-rs = { workspace = true, optional = true }
|
||||
|
||||
[features]
|
||||
schema = []
|
||||
generate-ts = ['ts-rs']
|
||||
|
||||
[lints]
|
||||
workspace = true
|
||||
|
||||
@@ -13,8 +13,21 @@ pub type NodeFamilyId = u32;
|
||||
|
||||
/// Runtime configuration of the node families contract.
|
||||
#[cw_serde]
|
||||
#[cfg_attr(feature = "generate-ts", derive(ts_rs::TS))]
|
||||
#[cfg_attr(
|
||||
feature = "generate-ts",
|
||||
ts(
|
||||
export,
|
||||
export_to = "ts-packages/types/src/types/rust/FamilyConfig.ts",
|
||||
rename = "FamilyConfig"
|
||||
)
|
||||
)]
|
||||
pub struct Config {
|
||||
/// Fee charged on each successful `create_family` execution.
|
||||
#[cfg_attr(
|
||||
feature = "generate-ts",
|
||||
ts(type = "{ denom: string, amount: string }")
|
||||
)]
|
||||
pub create_family_fee: Coin,
|
||||
|
||||
/// Maximum allowed length, in characters, of a family name.
|
||||
@@ -26,11 +39,17 @@ pub struct Config {
|
||||
/// Default lifetime, in seconds, used by `invite_to_family` when the
|
||||
/// sender doesn't supply an explicit value. Senders may override this
|
||||
/// per-invitation via the optional `validity_secs` argument.
|
||||
#[cfg_attr(feature = "generate-ts", ts(type = "number"))]
|
||||
pub default_invitation_validity_secs: u64,
|
||||
}
|
||||
|
||||
/// On-chain representation of a node family.
|
||||
#[cw_serde]
|
||||
#[cfg_attr(feature = "generate-ts", derive(ts_rs::TS))]
|
||||
#[cfg_attr(
|
||||
feature = "generate-ts",
|
||||
ts(export, export_to = "ts-packages/types/src/types/rust/NodeFamily.ts")
|
||||
)]
|
||||
pub struct NodeFamily {
|
||||
/// The id of the node family
|
||||
pub id: NodeFamilyId,
|
||||
@@ -45,17 +64,24 @@ pub struct NodeFamily {
|
||||
pub description: String,
|
||||
|
||||
/// The owner of the node family
|
||||
#[cfg_attr(feature = "generate-ts", ts(type = "string"))]
|
||||
pub owner: Addr,
|
||||
|
||||
/// Records the fee paid when the family was created,
|
||||
/// so that the appropriate amount could be returned upon it getting disbanded.
|
||||
#[cfg_attr(
|
||||
feature = "generate-ts",
|
||||
ts(type = "{ denom: string, amount: string }")
|
||||
)]
|
||||
pub paid_fee: Coin,
|
||||
|
||||
/// Memoized value of the current number of members in the node family
|
||||
/// Used to detect if the family is empty
|
||||
#[cfg_attr(feature = "generate-ts", ts(type = "number"))]
|
||||
pub members: u64,
|
||||
|
||||
/// Timestamp of the creation of the node family
|
||||
#[cfg_attr(feature = "generate-ts", ts(type = "number"))]
|
||||
pub created_at: u64,
|
||||
}
|
||||
|
||||
@@ -68,6 +94,14 @@ pub struct NodeFamily {
|
||||
/// issues a fresh invitation for the same node, which archives the stale one as
|
||||
/// `Expired` and supersedes it.
|
||||
#[cw_serde]
|
||||
#[cfg_attr(feature = "generate-ts", derive(ts_rs::TS))]
|
||||
#[cfg_attr(
|
||||
feature = "generate-ts",
|
||||
ts(
|
||||
export,
|
||||
export_to = "ts-packages/types/src/types/rust/FamilyInvitation.ts"
|
||||
)
|
||||
)]
|
||||
pub struct FamilyInvitation {
|
||||
/// The family that issued the invitation.
|
||||
pub family_id: NodeFamilyId,
|
||||
@@ -76,6 +110,7 @@ pub struct FamilyInvitation {
|
||||
pub node_id: NodeId,
|
||||
|
||||
/// Block timestamp (unix seconds) after which the invitation is no longer valid.
|
||||
#[cfg_attr(feature = "generate-ts", ts(type = "number"))]
|
||||
pub expires_at: u64,
|
||||
}
|
||||
|
||||
@@ -85,18 +120,35 @@ pub struct FamilyInvitation {
|
||||
/// `NodeId` alone — `family_id` is carried in the value to support reverse
|
||||
/// lookups (all nodes in a given family) via a secondary index.
|
||||
#[cw_serde]
|
||||
#[cfg_attr(feature = "generate-ts", derive(ts_rs::TS))]
|
||||
#[cfg_attr(
|
||||
feature = "generate-ts",
|
||||
ts(
|
||||
export,
|
||||
export_to = "ts-packages/types/src/types/rust/FamilyMembership.ts"
|
||||
)
|
||||
)]
|
||||
pub struct FamilyMembership {
|
||||
/// The family the node is currently a member of.
|
||||
pub family_id: NodeFamilyId,
|
||||
|
||||
/// Block timestamp (unix seconds) at which the node accepted its
|
||||
/// invitation and joined the family.
|
||||
#[cfg_attr(feature = "generate-ts", ts(type = "number"))]
|
||||
pub joined_at: u64,
|
||||
}
|
||||
|
||||
/// Historical record of a node that used to be part of a family but has since been
|
||||
/// removed (kicked, left voluntarily, or because the family was disbanded).
|
||||
#[cw_serde]
|
||||
#[cfg_attr(feature = "generate-ts", derive(ts_rs::TS))]
|
||||
#[cfg_attr(
|
||||
feature = "generate-ts",
|
||||
ts(
|
||||
export,
|
||||
export_to = "ts-packages/types/src/types/rust/PastFamilyMember.ts"
|
||||
)
|
||||
)]
|
||||
pub struct PastFamilyMember {
|
||||
/// The family the node used to belong to.
|
||||
pub family_id: NodeFamilyId,
|
||||
@@ -105,6 +157,7 @@ pub struct PastFamilyMember {
|
||||
pub node_id: NodeId,
|
||||
|
||||
/// Block timestamp (unix seconds) at which the membership was terminated.
|
||||
#[cfg_attr(feature = "generate-ts", ts(type = "number"))]
|
||||
pub removed_at: u64,
|
||||
}
|
||||
|
||||
@@ -115,6 +168,14 @@ pub struct PastFamilyMember {
|
||||
/// reaches `Expired` if the family issues a fresh invitation for the same node, which
|
||||
/// supersedes and archives the stale one.
|
||||
#[cw_serde]
|
||||
#[cfg_attr(feature = "generate-ts", derive(ts_rs::TS))]
|
||||
#[cfg_attr(
|
||||
feature = "generate-ts",
|
||||
ts(
|
||||
export,
|
||||
export_to = "ts-packages/types/src/types/rust/FamilyInvitationStatus.ts"
|
||||
)
|
||||
)]
|
||||
pub enum FamilyInvitationStatus {
|
||||
/// Still awaiting a response. Recorded with a timestamp for completeness even
|
||||
/// though pending invitations live in a separate map.
|
||||
@@ -137,6 +198,14 @@ pub enum FamilyInvitationStatus {
|
||||
/// archived here only when a fresh invitation for the same node supersedes it
|
||||
/// (status `Expired`); otherwise it stays in the pending map until explicitly cleared.
|
||||
#[cw_serde]
|
||||
#[cfg_attr(feature = "generate-ts", derive(ts_rs::TS))]
|
||||
#[cfg_attr(
|
||||
feature = "generate-ts",
|
||||
ts(
|
||||
export,
|
||||
export_to = "ts-packages/types/src/types/rust/PastFamilyInvitation.ts"
|
||||
)
|
||||
)]
|
||||
pub struct PastFamilyInvitation {
|
||||
/// The original invitation as it was issued.
|
||||
pub invitation: FamilyInvitation,
|
||||
@@ -147,6 +216,14 @@ pub struct PastFamilyInvitation {
|
||||
|
||||
/// Response to [`QueryMsg::GetFamilyById`](crate::QueryMsg::GetFamilyById).
|
||||
#[cw_serde]
|
||||
#[cfg_attr(feature = "generate-ts", derive(ts_rs::TS))]
|
||||
#[cfg_attr(
|
||||
feature = "generate-ts",
|
||||
ts(
|
||||
export,
|
||||
export_to = "ts-packages/types/src/types/rust/NodeFamilyResponse.ts"
|
||||
)
|
||||
)]
|
||||
pub struct NodeFamilyResponse {
|
||||
/// The id that was queried, echoed back so paginated callers can correlate.
|
||||
pub family_id: NodeFamilyId,
|
||||
@@ -157,9 +234,18 @@ pub struct NodeFamilyResponse {
|
||||
|
||||
/// Response to [`QueryMsg::GetFamilyByOwner`](crate::QueryMsg::GetFamilyByOwner).
|
||||
#[cw_serde]
|
||||
#[cfg_attr(feature = "generate-ts", derive(ts_rs::TS))]
|
||||
#[cfg_attr(
|
||||
feature = "generate-ts",
|
||||
ts(
|
||||
export,
|
||||
export_to = "ts-packages/types/src/types/rust/NodeFamilyByOwnerResponse.ts"
|
||||
)
|
||||
)]
|
||||
pub struct NodeFamilyByOwnerResponse {
|
||||
/// The (validated) owner address that was queried, echoed back so callers
|
||||
/// can correlate.
|
||||
#[cfg_attr(feature = "generate-ts", ts(type = "string"))]
|
||||
pub owner: Addr,
|
||||
|
||||
/// The matching family, or `None` if `owner` does not currently own one.
|
||||
@@ -178,6 +264,14 @@ pub struct NodeFamilyByNameResponse {
|
||||
|
||||
/// Response to [`QueryMsg::GetFamilyMembership`](crate::QueryMsg::GetFamilyMembership).
|
||||
#[cw_serde]
|
||||
#[cfg_attr(feature = "generate-ts", derive(ts_rs::TS))]
|
||||
#[cfg_attr(
|
||||
feature = "generate-ts",
|
||||
ts(
|
||||
export,
|
||||
export_to = "ts-packages/types/src/types/rust/NodeFamilyMembershipResponse.ts"
|
||||
)
|
||||
)]
|
||||
pub struct NodeFamilyMembershipResponse {
|
||||
/// The node that was queried.
|
||||
pub node_id: NodeId,
|
||||
@@ -190,6 +284,14 @@ pub struct NodeFamilyMembershipResponse {
|
||||
/// A pending [`FamilyInvitation`] paired with whether it has already timed
|
||||
/// out at the time the query was served.
|
||||
#[cw_serde]
|
||||
#[cfg_attr(feature = "generate-ts", derive(ts_rs::TS))]
|
||||
#[cfg_attr(
|
||||
feature = "generate-ts",
|
||||
ts(
|
||||
export,
|
||||
export_to = "ts-packages/types/src/types/rust/PendingFamilyInvitationDetails.ts"
|
||||
)
|
||||
)]
|
||||
pub struct PendingFamilyInvitationDetails {
|
||||
/// The stored invitation as it was issued.
|
||||
pub invitation: FamilyInvitation,
|
||||
@@ -201,6 +303,14 @@ pub struct PendingFamilyInvitationDetails {
|
||||
|
||||
/// Response to [`QueryMsg::GetPendingInvitation`](crate::QueryMsg::GetPendingInvitation).
|
||||
#[cw_serde]
|
||||
#[cfg_attr(feature = "generate-ts", derive(ts_rs::TS))]
|
||||
#[cfg_attr(
|
||||
feature = "generate-ts",
|
||||
ts(
|
||||
export,
|
||||
export_to = "ts-packages/types/src/types/rust/PendingFamilyInvitationResponse.ts"
|
||||
)
|
||||
)]
|
||||
pub struct PendingFamilyInvitationResponse {
|
||||
/// The family component of the queried `(family_id, node_id)` key.
|
||||
pub family_id: NodeFamilyId,
|
||||
@@ -216,6 +326,14 @@ pub struct PendingFamilyInvitationResponse {
|
||||
/// One entry in a [`FamilyMembersPagedResponse`] page — pairs a node id with
|
||||
/// its [`FamilyMembership`] record (notably its `joined_at` timestamp).
|
||||
#[cw_serde]
|
||||
#[cfg_attr(feature = "generate-ts", derive(ts_rs::TS))]
|
||||
#[cfg_attr(
|
||||
feature = "generate-ts",
|
||||
ts(
|
||||
export,
|
||||
export_to = "ts-packages/types/src/types/rust/FamilyMemberRecord.ts"
|
||||
)
|
||||
)]
|
||||
pub struct FamilyMemberRecord {
|
||||
/// The node currently in the family.
|
||||
pub node_id: NodeId,
|
||||
@@ -226,6 +344,14 @@ pub struct FamilyMemberRecord {
|
||||
|
||||
/// Response to [`QueryMsg::GetFamilyMembersPaged`](crate::QueryMsg::GetFamilyMembersPaged).
|
||||
#[cw_serde]
|
||||
#[cfg_attr(feature = "generate-ts", derive(ts_rs::TS))]
|
||||
#[cfg_attr(
|
||||
feature = "generate-ts",
|
||||
ts(
|
||||
export,
|
||||
export_to = "ts-packages/types/src/types/rust/FamilyMembersPagedResponse.ts"
|
||||
)
|
||||
)]
|
||||
pub struct FamilyMembersPagedResponse {
|
||||
/// The family whose members were queried, echoed back so paginated
|
||||
/// callers can correlate.
|
||||
@@ -253,6 +379,14 @@ pub struct AllFamilyMembersPagedResponse {
|
||||
|
||||
/// Response to [`QueryMsg::GetPendingInvitationsForFamilyPaged`](crate::QueryMsg::GetPendingInvitationsForFamilyPaged).
|
||||
#[cw_serde]
|
||||
#[cfg_attr(feature = "generate-ts", derive(ts_rs::TS))]
|
||||
#[cfg_attr(
|
||||
feature = "generate-ts",
|
||||
ts(
|
||||
export,
|
||||
export_to = "ts-packages/types/src/types/rust/PendingFamilyInvitationsPagedResponse.ts"
|
||||
)
|
||||
)]
|
||||
pub struct PendingFamilyInvitationsPagedResponse {
|
||||
/// The family whose pending invitations were queried, echoed back so
|
||||
/// paginated callers can correlate.
|
||||
@@ -270,6 +404,14 @@ pub struct PendingFamilyInvitationsPagedResponse {
|
||||
|
||||
/// Response to [`QueryMsg::GetPendingInvitationsForNodePaged`](crate::QueryMsg::GetPendingInvitationsForNodePaged).
|
||||
#[cw_serde]
|
||||
#[cfg_attr(feature = "generate-ts", derive(ts_rs::TS))]
|
||||
#[cfg_attr(
|
||||
feature = "generate-ts",
|
||||
ts(
|
||||
export,
|
||||
export_to = "ts-packages/types/src/types/rust/PendingInvitationsForNodePagedResponse.ts"
|
||||
)
|
||||
)]
|
||||
pub struct PendingInvitationsForNodePagedResponse {
|
||||
/// The node whose pending invitations were queried, echoed back so
|
||||
/// paginated callers can correlate.
|
||||
@@ -316,6 +458,14 @@ pub type GlobalPastFamilyInvitationCursor = ((NodeFamilyId, NodeId), u64);
|
||||
|
||||
/// Response to [`QueryMsg::GetPastInvitationsForFamilyPaged`](crate::QueryMsg::GetPastInvitationsForFamilyPaged).
|
||||
#[cw_serde]
|
||||
#[cfg_attr(feature = "generate-ts", derive(ts_rs::TS))]
|
||||
#[cfg_attr(
|
||||
feature = "generate-ts",
|
||||
ts(
|
||||
export,
|
||||
export_to = "ts-packages/types/src/types/rust/PastFamilyInvitationsPagedResponse.ts"
|
||||
)
|
||||
)]
|
||||
pub struct PastFamilyInvitationsPagedResponse {
|
||||
/// The family whose archived invitations were queried, echoed back so
|
||||
/// paginated callers can correlate.
|
||||
@@ -327,6 +477,7 @@ pub struct PastFamilyInvitationsPagedResponse {
|
||||
|
||||
/// Cursor to pass as `start_after` on the next call, or `None` if this
|
||||
/// page is empty (treat as end-of-list).
|
||||
#[cfg_attr(feature = "generate-ts", ts(type = "[number, number] | null"))]
|
||||
pub start_next_after: Option<PastFamilyInvitationCursor>,
|
||||
}
|
||||
|
||||
@@ -371,6 +522,14 @@ pub type PastFamilyMemberForNodeCursor = (NodeFamilyId, u64);
|
||||
|
||||
/// Response to [`QueryMsg::GetPastMembersForFamilyPaged`](crate::QueryMsg::GetPastMembersForFamilyPaged).
|
||||
#[cw_serde]
|
||||
#[cfg_attr(feature = "generate-ts", derive(ts_rs::TS))]
|
||||
#[cfg_attr(
|
||||
feature = "generate-ts",
|
||||
ts(
|
||||
export,
|
||||
export_to = "ts-packages/types/src/types/rust/PastFamilyMembersPagedResponse.ts"
|
||||
)
|
||||
)]
|
||||
pub struct PastFamilyMembersPagedResponse {
|
||||
/// The family whose archived memberships were queried, echoed back so
|
||||
/// paginated callers can correlate.
|
||||
@@ -382,6 +541,7 @@ pub struct PastFamilyMembersPagedResponse {
|
||||
|
||||
/// Cursor to pass as `start_after` on the next call, or `None` if this
|
||||
/// page is empty (treat as end-of-list).
|
||||
#[cfg_attr(feature = "generate-ts", ts(type = "[number, number] | null"))]
|
||||
pub start_next_after: Option<PastFamilyMemberCursor>,
|
||||
}
|
||||
|
||||
|
||||
@@ -9,7 +9,7 @@
|
||||
|
||||
## 2. Types reconciliation
|
||||
|
||||
- [ ] 2.1 Generate ts-rs exports for the node-families contract types into `nym-wallet-types` (as other wallet types) and diff against `src/types/families.ts` (cursors, paged envelope, membership, `FamilyTxResult`).
|
||||
- [x] 2.1 **Generated ts-rs exports** for the node-families contract types. Added a `generate-ts` feature + optional `ts-rs` dep to `nym-node-families-contract-common`, annotated 18 types in `types.rs` (`derive(ts_rs::TS)` + `export_to` under `ts-packages/types/src/types/rust/`, with overrides: `Coin → { denom, amount }`, `Addr → string`, `u64 → number`, tuple cursors `→ [number, number] | null`, `Config` renamed to `FamilyConfig`), wired them into `tools/ts-rs-cli` (dep + `use` + `do_export!`), and ran it → 18 `*.ts` files emitted (FamilyConfig, NodeFamily, NodeFamilyResponse, paged/membership/pending/past responses, etc.). Verified shapes (e.g. `NodeFamily.members: number`, `paid_fee: { denom, amount }`).
|
||||
- [ ] 2.2 Reconcile divergences toward the contract-truth shape; update `src/types/families.ts` (and the mock fixtures/engine if a field changes) so mock and real stay at parity.
|
||||
- [ ] 2.3 Add/confirm a contract-shape guard (test or ts-rs check) so future contract drift is caught.
|
||||
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
|
||||
export type AppEnv = { ADMIN_ADDRESS: string | null; SHOW_TERMINAL: string | null; ENABLE_QA_MODE: string | null };
|
||||
export type AppEnv = { ADMIN_ADDRESS: string | null, SHOW_TERMINAL: string | null, ENABLE_QA_MODE: string | null, };
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
|
||||
export type AppVersion = { current_version: string; latest_version: string; is_update_available: boolean };
|
||||
export type AppVersion = { current_version: string, latest_version: string, is_update_available: boolean, };
|
||||
|
||||
@@ -1,10 +1,3 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
|
||||
export type Interval = {
|
||||
id: number;
|
||||
epochs_in_interval: number;
|
||||
current_epoch_start_unix: bigint;
|
||||
current_epoch_id: number;
|
||||
epoch_length_seconds: bigint;
|
||||
total_elapsed_epochs: number;
|
||||
};
|
||||
export type Interval = { id: number, epochs_in_interval: number, current_epoch_start_unix: bigint, current_epoch_id: number, epoch_length_seconds: bigint, total_elapsed_epochs: number, };
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
|
||||
export type Network = 'QA' | 'SANDBOX' | 'MAINNET';
|
||||
export type Network = "SANDBOX" | "MAINNET";
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
import type { DecCoin } from '@nymproject/types/src/types/rust/DecCoin';
|
||||
import type { DecCoin } from "../../../../ts-packages/types/src/types/rust/DecCoin";
|
||||
|
||||
export type TauriOperatingCostRange = { minimum: DecCoin; maximum: DecCoin };
|
||||
export type TauriOperatingCostRange = { minimum: DecCoin, maximum: DecCoin, };
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
|
||||
export type TauriProfitMarginRange = { minimum: string; maximum: string };
|
||||
export type TauriProfitMarginRange = { minimum: string, maximum: string, };
|
||||
|
||||
@@ -1,11 +1,6 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
import type { DecCoin } from '@nymproject/types/src/types/rust/DecCoin';
|
||||
import type { TauriOperatingCostRange } from './OperatingCostRange';
|
||||
import type { TauriProfitMarginRange } from './ProfitMarginRange';
|
||||
import type { DecCoin } from "../../../../ts-packages/types/src/types/rust/DecCoin";
|
||||
import type { TauriOperatingCostRange } from "./OperatingCostRange";
|
||||
import type { TauriProfitMarginRange } from "./ProfitMarginRange";
|
||||
|
||||
export type TauriContractStateParams = {
|
||||
minimum_pledge: DecCoin;
|
||||
minimum_delegation: DecCoin | null;
|
||||
operating_cost: TauriOperatingCostRange;
|
||||
profit_margin: TauriProfitMarginRange;
|
||||
};
|
||||
export type TauriContractStateParams = { minimum_pledge: DecCoin, minimum_delegation: DecCoin | null, operating_cost: TauriOperatingCostRange, profit_margin: TauriProfitMarginRange, };
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
|
||||
export type ValidatorUrl = { url: string; name: string | null };
|
||||
export type ValidatorUrl = { url: string, name: string | null, };
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
import type { ValidatorUrl } from './ValidatorUrl';
|
||||
import type { ValidatorUrl } from "./ValidatorUrl";
|
||||
|
||||
export type Validator = { nyxd_url: string; nyxd_name: string | null; api_url: string | null };
|
||||
export type Validator = { nyxd_url: string, nyxd_name: string | null, api_url: string | null, };
|
||||
|
||||
export type ValidatorUrls = { urls: Array<ValidatorUrl> };
|
||||
export type ValidatorUrls = { urls: Array<ValidatorUrl>, };
|
||||
|
||||
@@ -17,6 +17,7 @@ nym-validator-client = { workspace = true, features = [
|
||||
] }
|
||||
nym-api-requests = { workspace = true, features = ["generate-ts"] }
|
||||
nym-mixnet-contract-common = { workspace = true, features = ["generate-ts"] }
|
||||
nym-node-families-contract-common = { workspace = true, features = ["generate-ts"] }
|
||||
nym-vesting-contract-common = { workspace = true, features = ["generate-ts"] }
|
||||
nym-types = { workspace = true, features = ["generate-ts"] }
|
||||
nym-wallet-types = { path = "../../nym-wallet/nym-wallet-types", features = ["generate-ts"] }
|
||||
|
||||
@@ -18,6 +18,14 @@ use nym_mixnet_contract_common::{
|
||||
IntervalRewardingParamsUpdate, MixNode, MixNodeConfigUpdate, NymNode, PendingNodeChanges,
|
||||
RewardingParams, UnbondedMixnode,
|
||||
};
|
||||
use nym_node_families_contract_common::{
|
||||
Config as NodeFamiliesConfig, FamilyInvitation, FamilyInvitationStatus, FamilyMemberRecord,
|
||||
FamilyMembersPagedResponse, FamilyMembership, NodeFamily, NodeFamilyByOwnerResponse,
|
||||
NodeFamilyMembershipResponse, NodeFamilyResponse, PastFamilyInvitation,
|
||||
PastFamilyInvitationsPagedResponse, PastFamilyMember, PastFamilyMembersPagedResponse,
|
||||
PendingFamilyInvitationDetails, PendingFamilyInvitationResponse,
|
||||
PendingFamilyInvitationsPagedResponse, PendingInvitationsForNodePagedResponse,
|
||||
};
|
||||
use nym_types::account::{Account, AccountEntry, AccountWithMnemonic, Balance};
|
||||
use nym_types::currency::{CurrencyDenom, DecCoin};
|
||||
use nym_types::delegation::{
|
||||
@@ -96,6 +104,26 @@ fn main() -> anyhow::Result<()> {
|
||||
do_export!(NodeConfigUpdate);
|
||||
do_export!(Role);
|
||||
|
||||
// common/cosmwasm-smart-contracts/node-families-contract/src
|
||||
do_export!(NodeFamiliesConfig);
|
||||
do_export!(NodeFamily);
|
||||
do_export!(FamilyInvitation);
|
||||
do_export!(FamilyMembership);
|
||||
do_export!(FamilyInvitationStatus);
|
||||
do_export!(PastFamilyInvitation);
|
||||
do_export!(PastFamilyMember);
|
||||
do_export!(NodeFamilyResponse);
|
||||
do_export!(NodeFamilyByOwnerResponse);
|
||||
do_export!(NodeFamilyMembershipResponse);
|
||||
do_export!(PendingFamilyInvitationDetails);
|
||||
do_export!(PendingFamilyInvitationResponse);
|
||||
do_export!(FamilyMemberRecord);
|
||||
do_export!(FamilyMembersPagedResponse);
|
||||
do_export!(PendingFamilyInvitationsPagedResponse);
|
||||
do_export!(PendingInvitationsForNodePagedResponse);
|
||||
do_export!(PastFamilyInvitationsPagedResponse);
|
||||
do_export!(PastFamilyMembersPagedResponse);
|
||||
|
||||
// common/types/src
|
||||
do_export!(Account);
|
||||
do_export!(AccountEntry);
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
import type { CurrencyDenom } from './CurrencyDenom';
|
||||
import type { CurrencyDenom } from "./CurrencyDenom";
|
||||
|
||||
export type Account = { client_address: string; base_mix_denom: string; display_mix_denom: CurrencyDenom };
|
||||
export type Account = { client_address: string, base_mix_denom: string, display_mix_denom: CurrencyDenom, };
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
|
||||
export type AccountEntry = { id: string; address: string };
|
||||
export type AccountEntry = { id: string, address: string, };
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
import type { Account } from './Account';
|
||||
import type { Account } from "./Account";
|
||||
|
||||
export type AccountWithMnemonic = { account: Account; mnemonic: string };
|
||||
export type AccountWithMnemonic = { account: Account, mnemonic: string, };
|
||||
|
||||
@@ -3,17 +3,16 @@
|
||||
/**
|
||||
* Specification on how the active set should be updated.
|
||||
*/
|
||||
export type ActiveSetUpdate = {
|
||||
/**
|
||||
* The expected number of nodes assigned entry gateway role (i.e. [`Role::EntryGateway`])
|
||||
*/
|
||||
entry_gateways: number;
|
||||
/**
|
||||
* The expected number of nodes assigned exit gateway role (i.e. [`Role::ExitGateway`])
|
||||
*/
|
||||
exit_gateways: number;
|
||||
/**
|
||||
* The expected number of nodes assigned the 'mixnode' role, i.e. total of [`Role::Layer1`], [`Role::Layer2`] and [`Role::Layer3`].
|
||||
*/
|
||||
mixnodes: number;
|
||||
};
|
||||
export type ActiveSetUpdate = {
|
||||
/**
|
||||
* The expected number of nodes assigned entry gateway role (i.e. [`Role::EntryGateway`])
|
||||
*/
|
||||
entry_gateways: number,
|
||||
/**
|
||||
* The expected number of nodes assigned exit gateway role (i.e. [`Role::ExitGateway`])
|
||||
*/
|
||||
exit_gateways: number,
|
||||
/**
|
||||
* The expected number of nodes assigned the 'mixnode' role, i.e. total of [`Role::Layer1`], [`Role::Layer2`] and [`Role::Layer3`].
|
||||
*/
|
||||
mixnodes: number, };
|
||||
|
||||
@@ -0,0 +1,4 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
import type { NodeAnnotationV1 } from "./NodeAnnotationV1";
|
||||
|
||||
export type AnnotationResponseV1 = { node_id: number, annotation: NodeAnnotationV1 | null, };
|
||||
@@ -0,0 +1,4 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
import type { NodeAnnotationV2 } from "./NodeAnnotationV2";
|
||||
|
||||
export type AnnotationResponseV2 = { node_id: number, annotation: NodeAnnotationV2 | null, };
|
||||
@@ -1,4 +1,4 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
import type { DecCoin } from './DecCoin';
|
||||
import type { DecCoin } from "./DecCoin";
|
||||
|
||||
export type Balance = { amount: DecCoin; printable_balance: string };
|
||||
export type Balance = { amount: DecCoin, printable_balance: string, };
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
|
||||
export type Coin = { denom: string; amount: bigint };
|
||||
export type Coin = { denom: string, amount: bigint, };
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
import type { Coin } from './Coin';
|
||||
import type { Coin } from "./Coin";
|
||||
|
||||
export type CosmosFee = { amount: Array<Coin>; gas_limit: bigint; payer: string | null; granter: string | null };
|
||||
export type CosmosFee = { amount: Array<Coin>, gas_limit: bigint, payer: string | null, granter: string | null, };
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
|
||||
export type CurrencyDenom = 'unknown' | 'nym' | 'nymt' | 'nyx' | 'nyxt';
|
||||
export type CurrencyDenom = "unknown" | "nym" | "nymt" | "nyx" | "nyxt";
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
import type { CurrencyDenom } from './CurrencyDenom';
|
||||
import type { CurrencyDenom } from "./CurrencyDenom";
|
||||
|
||||
export type DecCoin = { denom: CurrencyDenom; amount: string };
|
||||
export type DecCoin = { denom: CurrencyDenom, amount: string, };
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
|
||||
export type DeclaredRoles = { mixnode: boolean; entry: boolean; exit_nr: boolean; exit_ipr: boolean };
|
||||
export type DeclaredRolesV1 = { mixnode: boolean, entry: boolean, exit_nr: boolean, exit_ipr: boolean, };
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
import type { DecCoin } from './DecCoin';
|
||||
import type { DecCoin } from "./DecCoin";
|
||||
|
||||
export type Delegation = { owner: string; mix_id: number; amount: DecCoin; height: bigint; proxy: string | null };
|
||||
export type Delegation = { owner: string, mix_id: number, amount: DecCoin, height: bigint, proxy: string | null, };
|
||||
|
||||
@@ -1,11 +1,5 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
import type { DecCoin } from './DecCoin';
|
||||
import type { DelegationEventKind } from './DelegationEventKind';
|
||||
import type { DecCoin } from "./DecCoin";
|
||||
import type { DelegationEventKind } from "./DelegationEventKind";
|
||||
|
||||
export type DelegationEvent = {
|
||||
kind: DelegationEventKind;
|
||||
mix_id: number;
|
||||
address: string;
|
||||
amount: DecCoin | null;
|
||||
proxy: string | null;
|
||||
};
|
||||
export type DelegationEvent = { kind: DelegationEventKind, mix_id: number, address: string, amount: DecCoin | null, proxy: string | null, };
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
|
||||
export type DelegationEventKind = 'Delegate' | 'Undelegate';
|
||||
export type DelegationEventKind = "Delegate" | "Undelegate";
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
import type { DecCoin } from './DecCoin';
|
||||
import type { DecCoin } from "./DecCoin";
|
||||
|
||||
export type DelegationResult = { source_address: string; target_address: string; amount: DecCoin | null };
|
||||
export type DelegationResult = { source_address: string, target_address: string, amount: DecCoin | null, };
|
||||
|
||||
@@ -1,9 +1,5 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
import type { DecCoin } from './DecCoin';
|
||||
import type { DelegationWithEverything } from './DelegationWithEverything';
|
||||
import type { DecCoin } from "./DecCoin";
|
||||
import type { DelegationWithEverything } from "./DelegationWithEverything";
|
||||
|
||||
export type DelegationsSummaryResponse = {
|
||||
delegations: Array<DelegationWithEverything>;
|
||||
total_delegations: DecCoin;
|
||||
total_rewards: DecCoin;
|
||||
};
|
||||
export type DelegationsSummaryResponse = { delegations: Array<DelegationWithEverything>, total_delegations: DecCoin, total_rewards: DecCoin, };
|
||||
|
||||
@@ -1,24 +1,10 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
import type { DecCoin } from './DecCoin';
|
||||
import type { DelegationEvent } from './DelegationEvent';
|
||||
import type { NodeCostParams } from './MixNodeCostParams';
|
||||
import type { DecCoin } from "./DecCoin";
|
||||
import type { DelegationEvent } from "./DelegationEvent";
|
||||
import type { NodeCostParams } from "./MixNodeCostParams";
|
||||
|
||||
export type DelegationWithEverything = {
|
||||
owner: string;
|
||||
mix_id: number;
|
||||
node_identity: string;
|
||||
historical_node_identity: string | null;
|
||||
amount: DecCoin;
|
||||
accumulated_by_delegates: DecCoin | null;
|
||||
accumulated_by_operator: DecCoin | null;
|
||||
block_height: bigint;
|
||||
delegated_on_iso_datetime: string | null;
|
||||
cost_params: NodeCostParams | null;
|
||||
avg_uptime_percent: number | null;
|
||||
stake_saturation: string | null;
|
||||
uses_vesting_contract_tokens: boolean;
|
||||
unclaimed_rewards: DecCoin | null;
|
||||
errors: string | null;
|
||||
pending_events: Array<DelegationEvent>;
|
||||
mixnode_is_unbonding: boolean | null;
|
||||
};
|
||||
export type DelegationWithEverything = { owner: string, mix_id: number, node_identity: string,
|
||||
/**
|
||||
* Prior node identity when `node_identity` is synthetic (registry miss after unbond).
|
||||
*/
|
||||
historical_node_identity: string | null, amount: DecCoin, accumulated_by_delegates: DecCoin | null, accumulated_by_operator: DecCoin | null, block_height: bigint, delegated_on_iso_datetime: string | null, cost_params: NodeCostParams | null, avg_uptime_percent: number | null, stake_saturation: string | null, uses_vesting_contract_tokens: boolean, unclaimed_rewards: DecCoin | null, errors: string | null, pending_events: Array<DelegationEvent>, mixnode_is_unbonding: boolean | null, };
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
|
||||
export type DescribedNodeType = 'legacy_mixnode' | 'legacy_gateway' | 'nym_node';
|
||||
export type DescribedNodeTypeV1 = "legacy_mixnode" | "legacy_gateway" | "nym_node";
|
||||
|
||||
@@ -0,0 +1,24 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
|
||||
/**
|
||||
* Runtime configuration of the node families contract.
|
||||
*/
|
||||
export type FamilyConfig = {
|
||||
/**
|
||||
* Fee charged on each successful `create_family` execution.
|
||||
*/
|
||||
create_family_fee: { denom: string, amount: string },
|
||||
/**
|
||||
* Maximum allowed length, in characters, of a family name.
|
||||
*/
|
||||
family_name_length_limit: number,
|
||||
/**
|
||||
* Maximum allowed length, in characters, of a family description.
|
||||
*/
|
||||
family_description_length_limit: number,
|
||||
/**
|
||||
* Default lifetime, in seconds, used by `invite_to_family` when the
|
||||
* sender doesn't supply an explicit value. Senders may override this
|
||||
* per-invitation via the optional `validity_secs` argument.
|
||||
*/
|
||||
default_invitation_validity_secs: number, };
|
||||
@@ -0,0 +1,22 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
|
||||
/**
|
||||
* A pending invitation for a node to join a particular family.
|
||||
*
|
||||
* Invitations are stored until they are accepted, rejected, revoked, or until the
|
||||
* chain advances past `expires_at` (in which case they remain in storage but are
|
||||
* treated as inert — there is no background process clearing expired invitations).
|
||||
*/
|
||||
export type FamilyInvitation = {
|
||||
/**
|
||||
* The family that issued the invitation.
|
||||
*/
|
||||
family_id: number,
|
||||
/**
|
||||
* The node being invited.
|
||||
*/
|
||||
node_id: number,
|
||||
/**
|
||||
* Block timestamp (unix seconds) after which the invitation is no longer valid.
|
||||
*/
|
||||
expires_at: number, };
|
||||
@@ -0,0 +1,9 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
|
||||
/**
|
||||
* Terminal status for an invitation that has been moved out of the pending set.
|
||||
*
|
||||
* Note: timed-out invitations are not represented here — they are simply left in
|
||||
* the pending set (see `FamilyInvitation::expires_at`).
|
||||
*/
|
||||
export type FamilyInvitationStatus = { "pending": { at: bigint, } } | { "accepted": { at: bigint, } } | { "rejected": { at: bigint, } } | { "revoked": { at: bigint, } };
|
||||
@@ -0,0 +1,16 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
import type { FamilyMembership } from "./FamilyMembership";
|
||||
|
||||
/**
|
||||
* One entry in a [`FamilyMembersPagedResponse`] page — pairs a node id with
|
||||
* its [`FamilyMembership`] record (notably its `joined_at` timestamp).
|
||||
*/
|
||||
export type FamilyMemberRecord = {
|
||||
/**
|
||||
* The node currently in the family.
|
||||
*/
|
||||
node_id: number,
|
||||
/**
|
||||
* The membership record (carries `family_id` and `joined_at`).
|
||||
*/
|
||||
membership: FamilyMembership, };
|
||||
@@ -0,0 +1,21 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
import type { FamilyMemberRecord } from "./FamilyMemberRecord";
|
||||
|
||||
/**
|
||||
* Response to [`QueryMsg::GetFamilyMembersPaged`](crate::QueryMsg::GetFamilyMembersPaged).
|
||||
*/
|
||||
export type FamilyMembersPagedResponse = {
|
||||
/**
|
||||
* The family whose members were queried, echoed back so paginated
|
||||
* callers can correlate.
|
||||
*/
|
||||
family_id: number,
|
||||
/**
|
||||
* The members on this page, in ascending [`NodeId`] order.
|
||||
*/
|
||||
members: Array<FamilyMemberRecord>,
|
||||
/**
|
||||
* Cursor to pass as `start_after` on the next call, or `None` if this
|
||||
* page is empty (which the caller should treat as end-of-list).
|
||||
*/
|
||||
start_next_after: number | null, };
|
||||
@@ -0,0 +1,19 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
|
||||
/**
|
||||
* On-chain record of a node's current family membership.
|
||||
*
|
||||
* A node belongs to at most one family at a time, so this is keyed by
|
||||
* `NodeId` alone — `family_id` is carried in the value to support reverse
|
||||
* lookups (all nodes in a given family) via a secondary index.
|
||||
*/
|
||||
export type FamilyMembership = {
|
||||
/**
|
||||
* The family the node is currently a member of.
|
||||
*/
|
||||
family_id: number,
|
||||
/**
|
||||
* Block timestamp (unix seconds) at which the node accepted its
|
||||
* invitation and joined the family.
|
||||
*/
|
||||
joined_at: number, };
|
||||
@@ -1,4 +1,4 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
import type { CosmosFee } from './CosmosFee';
|
||||
import type { CosmosFee } from "./CosmosFee";
|
||||
|
||||
export type Fee = { Manual: CosmosFee } | { Auto: number | null };
|
||||
export type Fee = { "Manual": CosmosFee } | { "Auto": number | null };
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
import type { DecCoin } from './DecCoin';
|
||||
import type { Fee } from './Fee';
|
||||
import type { DecCoin } from "./DecCoin";
|
||||
import type { Fee } from "./Fee";
|
||||
|
||||
export type FeeDetails = { amount: DecCoin | null; fee: Fee };
|
||||
export type FeeDetails = { amount: DecCoin | null, fee: Fee, };
|
||||
|
||||
@@ -1,8 +1,7 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
|
||||
export type Gas = {
|
||||
/**
|
||||
* units of gas used
|
||||
*/
|
||||
gas_units: bigint;
|
||||
};
|
||||
export type Gas = {
|
||||
/**
|
||||
* units of gas used
|
||||
*/
|
||||
gas_units: bigint, };
|
||||
|
||||
@@ -1,13 +1,12 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
import type { Gas } from './Gas';
|
||||
import type { Gas } from "./Gas";
|
||||
|
||||
export type GasInfo = {
|
||||
/**
|
||||
* GasWanted is the maximum units of work we allow this tx to perform.
|
||||
*/
|
||||
gas_wanted: Gas;
|
||||
/**
|
||||
* GasUsed is the amount of gas actually consumed.
|
||||
*/
|
||||
gas_used: Gas;
|
||||
};
|
||||
export type GasInfo = {
|
||||
/**
|
||||
* GasWanted is the maximum units of work we allow this tx to perform.
|
||||
*/
|
||||
gas_wanted: Gas,
|
||||
/**
|
||||
* GasUsed is the amount of gas actually consumed.
|
||||
*/
|
||||
gas_used: Gas, };
|
||||
|
||||
@@ -1,14 +1,7 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
|
||||
export type Gateway = {
|
||||
host: string;
|
||||
mix_port: number;
|
||||
clients_port: number;
|
||||
location: string;
|
||||
sphinx_key: string;
|
||||
/**
|
||||
* Base58 encoded ed25519 EdDSA public key of the gateway used to derive shared keys with clients
|
||||
*/
|
||||
identity_key: string;
|
||||
version: string;
|
||||
};
|
||||
export type Gateway = { host: string, mix_port: number, clients_port: number, location: string, sphinx_key: string,
|
||||
/**
|
||||
* Base58 encoded ed25519 EdDSA public key of the gateway used to derive shared keys with clients
|
||||
*/
|
||||
identity_key: string, version: string, };
|
||||
|
||||
@@ -1,11 +1,5 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
import type { DecCoin } from './DecCoin';
|
||||
import type { Gateway } from './Gateway';
|
||||
import type { DecCoin } from "./DecCoin";
|
||||
import type { Gateway } from "./Gateway";
|
||||
|
||||
export type GatewayBond = {
|
||||
pledge_amount: DecCoin;
|
||||
owner: string;
|
||||
block_height: bigint;
|
||||
gateway: Gateway;
|
||||
proxy: string | null;
|
||||
};
|
||||
export type GatewayBond = { pledge_amount: DecCoin, owner: string, block_height: bigint, gateway: Gateway, proxy: string | null, };
|
||||
|
||||
@@ -1,9 +1,3 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
|
||||
export type GatewayConfigUpdate = {
|
||||
host: string;
|
||||
mix_port: number;
|
||||
clients_port: number;
|
||||
location: string;
|
||||
version: string;
|
||||
};
|
||||
export type GatewayConfigUpdate = { host: string, mix_port: number, clients_port: number, location: string, version: string, };
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
|
||||
export type GatewayCoreStatusResponse = { identity: string; count: number };
|
||||
export type GatewayCoreStatusResponse = { identity: string, count: bigint, };
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
|
||||
export type HistoricalPerformanceResponse = { date: string; performance: number };
|
||||
export type HistoricalPerformanceResponse = { date: string, performance: number, };
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
|
||||
export type HistoricalUptimeResponse = { date: string; uptime: number };
|
||||
export type HistoricalUptimeResponse = { date: string, uptime: number, };
|
||||
|
||||
@@ -3,29 +3,28 @@
|
||||
/**
|
||||
* Specification of a rewarding interval.
|
||||
*/
|
||||
export type Interval = {
|
||||
/**
|
||||
* Monotonously increasing id of this interval.
|
||||
*/
|
||||
id: number;
|
||||
/**
|
||||
* Number of epochs in this interval.
|
||||
*/
|
||||
epochs_in_interval: number;
|
||||
/**
|
||||
* The timestamp indicating the start of the current rewarding epoch.
|
||||
*/
|
||||
current_epoch_start: string;
|
||||
/**
|
||||
* Monotonously increasing id of the current epoch in this interval.
|
||||
*/
|
||||
current_epoch_id: number;
|
||||
/**
|
||||
* The duration of all epochs in this interval.
|
||||
*/
|
||||
epoch_length: { secs: number; nanos: number };
|
||||
/**
|
||||
* The total amount of elapsed epochs since the first epoch of the first interval.
|
||||
*/
|
||||
total_elapsed_epochs: number;
|
||||
};
|
||||
export type Interval = {
|
||||
/**
|
||||
* Monotonously increasing id of this interval.
|
||||
*/
|
||||
id: number,
|
||||
/**
|
||||
* Number of epochs in this interval.
|
||||
*/
|
||||
epochs_in_interval: number,
|
||||
/**
|
||||
* The timestamp indicating the start of the current rewarding epoch.
|
||||
*/
|
||||
current_epoch_start: string,
|
||||
/**
|
||||
* Monotonously increasing id of the current epoch in this interval.
|
||||
*/
|
||||
current_epoch_id: number,
|
||||
/**
|
||||
* The duration of all epochs in this interval.
|
||||
*/
|
||||
epoch_length: { secs: number; nanos: number; },
|
||||
/**
|
||||
* The total amount of elapsed epochs since the first epoch of the first interval.
|
||||
*/
|
||||
total_elapsed_epochs: number, };
|
||||
|
||||
@@ -3,50 +3,49 @@
|
||||
/**
|
||||
* Parameters required by the mix-mining reward distribution that do not change during an interval.
|
||||
*/
|
||||
export type IntervalRewardParams = {
|
||||
/**
|
||||
* Current value of the rewarding pool.
|
||||
* It is expected to be constant throughout the interval.
|
||||
*/
|
||||
reward_pool: string;
|
||||
/**
|
||||
* Current value of the staking supply.
|
||||
* It is expected to be constant throughout the interval.
|
||||
*/
|
||||
staking_supply: string;
|
||||
/**
|
||||
* Defines the percentage of stake needed to reach saturation for all of the nodes in the rewarded set.
|
||||
* Also known as `beta`.
|
||||
*/
|
||||
staking_supply_scale_factor: string;
|
||||
/**
|
||||
* Current value of the computed reward budget per epoch, per node.
|
||||
* It is expected to be constant throughout the interval.
|
||||
*/
|
||||
epoch_reward_budget: string;
|
||||
/**
|
||||
* Current value of the stake saturation point.
|
||||
* It is expected to be constant throughout the interval.
|
||||
*/
|
||||
stake_saturation_point: string;
|
||||
/**
|
||||
* Current value of the sybil resistance percent (`alpha`).
|
||||
* It is not really expected to be changing very often.
|
||||
* As a matter of fact, unless there's a very specific reason, it should remain constant.
|
||||
*/
|
||||
sybil_resistance: string;
|
||||
/**
|
||||
* Current active set work factor.
|
||||
* It is not really expected to be changing very often.
|
||||
* As a matter of fact, unless there's a very specific reason, it should remain constant.
|
||||
*/
|
||||
active_set_work_factor: string;
|
||||
/**
|
||||
* Current maximum interval pool emission.
|
||||
* Assuming all nodes in the rewarded set are fully saturated and have 100% performance,
|
||||
* this % of the reward pool would get distributed in rewards to all operators and its delegators.
|
||||
* It is not really expected to be changing very often.
|
||||
* As a matter of fact, unless there's a very specific reason, it should remain constant.
|
||||
*/
|
||||
interval_pool_emission: string;
|
||||
};
|
||||
export type IntervalRewardParams = {
|
||||
/**
|
||||
* Current value of the rewarding pool.
|
||||
* It is expected to be constant throughout the interval.
|
||||
*/
|
||||
reward_pool: string,
|
||||
/**
|
||||
* Current value of the staking supply.
|
||||
* It is expected to be constant throughout the interval.
|
||||
*/
|
||||
staking_supply: string,
|
||||
/**
|
||||
* Defines the percentage of stake needed to reach saturation for all of the nodes in the rewarded set.
|
||||
* Also known as `beta`.
|
||||
*/
|
||||
staking_supply_scale_factor: string,
|
||||
/**
|
||||
* Current value of the computed reward budget per epoch, per node.
|
||||
* It is expected to be constant throughout the interval.
|
||||
*/
|
||||
epoch_reward_budget: string,
|
||||
/**
|
||||
* Current value of the stake saturation point.
|
||||
* It is expected to be constant throughout the interval.
|
||||
*/
|
||||
stake_saturation_point: string,
|
||||
/**
|
||||
* Current value of the sybil resistance percent (`alpha`).
|
||||
* It is not really expected to be changing very often.
|
||||
* As a matter of fact, unless there's a very specific reason, it should remain constant.
|
||||
*/
|
||||
sybil_resistance: string,
|
||||
/**
|
||||
* Current active set work factor.
|
||||
* It is not really expected to be changing very often.
|
||||
* As a matter of fact, unless there's a very specific reason, it should remain constant.
|
||||
*/
|
||||
active_set_work_factor: string,
|
||||
/**
|
||||
* Current maximum interval pool emission.
|
||||
* Assuming all nodes in the rewarded set are fully saturated and have 100% performance,
|
||||
* this % of the reward pool would get distributed in rewards to all operators and its delegators.
|
||||
* It is not really expected to be changing very often.
|
||||
* As a matter of fact, unless there's a very specific reason, it should remain constant.
|
||||
*/
|
||||
interval_pool_emission: string, };
|
||||
|
||||
@@ -1,36 +1,35 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
import type { RewardedSetParams } from './RewardedSetParams';
|
||||
import type { RewardedSetParams } from "./RewardedSetParams";
|
||||
|
||||
/**
|
||||
* Specification on how the rewarding params should be updated.
|
||||
*/
|
||||
export type IntervalRewardingParamsUpdate = {
|
||||
/**
|
||||
* Defines the new value of the reward pool.
|
||||
*/
|
||||
reward_pool: string | null;
|
||||
/**
|
||||
* Defines the new value of the staking supply.
|
||||
*/
|
||||
staking_supply: string | null;
|
||||
/**
|
||||
* Defines the new value of the staking supply scale factor.
|
||||
*/
|
||||
staking_supply_scale_factor: string | null;
|
||||
/**
|
||||
* Defines the new value of the sybil resistance percent.
|
||||
*/
|
||||
sybil_resistance_percent: string | null;
|
||||
/**
|
||||
* Defines the new value of the active set work factor.
|
||||
*/
|
||||
active_set_work_factor: string | null;
|
||||
/**
|
||||
* Defines the new value of the interval pool emission rate.
|
||||
*/
|
||||
interval_pool_emission: string | null;
|
||||
/**
|
||||
* Defines the parameters of the rewarded set.
|
||||
*/
|
||||
rewarded_set_params: RewardedSetParams | null;
|
||||
};
|
||||
export type IntervalRewardingParamsUpdate = {
|
||||
/**
|
||||
* Defines the new value of the reward pool.
|
||||
*/
|
||||
reward_pool: string | null,
|
||||
/**
|
||||
* Defines the new value of the staking supply.
|
||||
*/
|
||||
staking_supply: string | null,
|
||||
/**
|
||||
* Defines the new value of the staking supply scale factor.
|
||||
*/
|
||||
staking_supply_scale_factor: string | null,
|
||||
/**
|
||||
* Defines the new value of the sybil resistance percent.
|
||||
*/
|
||||
sybil_resistance_percent: string | null,
|
||||
/**
|
||||
* Defines the new value of the active set work factor.
|
||||
*/
|
||||
active_set_work_factor: string | null,
|
||||
/**
|
||||
* Defines the new value of the interval pool emission rate.
|
||||
*/
|
||||
interval_pool_emission: string | null,
|
||||
/**
|
||||
* Defines the parameters of the rewarded set.
|
||||
*/
|
||||
rewarded_set_params: RewardedSetParams | null, };
|
||||
|
||||
@@ -1,13 +1,5 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
import type { DecCoin } from './DecCoin';
|
||||
import type { MixNode } from './Mixnode';
|
||||
import type { DecCoin } from "./DecCoin";
|
||||
import type { MixNode } from "./Mixnode";
|
||||
|
||||
export type MixNodeBond = {
|
||||
mix_id: number;
|
||||
owner: string;
|
||||
original_pledge: DecCoin;
|
||||
mix_node: MixNode;
|
||||
proxy: string | null;
|
||||
bonding_height: bigint;
|
||||
is_unbonding: boolean;
|
||||
};
|
||||
export type MixNodeBond = { mix_id: number, owner: string, original_pledge: DecCoin, mix_node: MixNode, proxy: string | null, bonding_height: bigint, is_unbonding: boolean, };
|
||||
|
||||
@@ -1,9 +1,3 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
|
||||
export type MixNodeConfigUpdate = {
|
||||
host: string;
|
||||
mix_port: number;
|
||||
verloc_port: number;
|
||||
http_api_port: number;
|
||||
version: string;
|
||||
};
|
||||
export type MixNodeConfigUpdate = { host: string, mix_port: number, verloc_port: number, http_api_port: number, version: string, };
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
import type { DecCoin } from './DecCoin';
|
||||
import type { DecCoin } from "./DecCoin";
|
||||
|
||||
export type NodeCostParams = { profit_margin_percent: string; interval_operating_cost: DecCoin };
|
||||
export type NodeCostParams = { profit_margin_percent: string, interval_operating_cost: DecCoin, };
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
import type { MixNodeBond } from './MixNodeBond';
|
||||
import type { NodeRewarding } from './NodeRewarding';
|
||||
import type { MixNodeBond } from "./MixNodeBond";
|
||||
import type { NodeRewarding } from "./NodeRewarding";
|
||||
|
||||
export type MixNodeDetails = { bond_information: MixNodeBond; rewarding_details: NodeRewarding };
|
||||
export type MixNodeDetails = { bond_information: MixNodeBond, rewarding_details: NodeRewarding, };
|
||||
|
||||
@@ -3,33 +3,32 @@
|
||||
/**
|
||||
* Information provided by the node operator during bonding that are used to allow other entities to use the services of this node.
|
||||
*/
|
||||
export type MixNode = {
|
||||
/**
|
||||
* Network address of this mixnode, for example 1.1.1.1 or foo.mixnode.com
|
||||
*/
|
||||
host: string;
|
||||
/**
|
||||
* Port used by this mixnode for listening for mix packets.
|
||||
*/
|
||||
mix_port: number;
|
||||
/**
|
||||
* Port used by this mixnode for listening for verloc requests.
|
||||
*/
|
||||
verloc_port: number;
|
||||
/**
|
||||
* Port used by this mixnode for its http(s) API
|
||||
*/
|
||||
http_api_port: number;
|
||||
/**
|
||||
* Base58-encoded x25519 public key used for sphinx key derivation.
|
||||
*/
|
||||
sphinx_key: string;
|
||||
/**
|
||||
* Base58-encoded ed25519 EdDSA public key.
|
||||
*/
|
||||
identity_key: string;
|
||||
/**
|
||||
* The self-reported semver version of this mixnode.
|
||||
*/
|
||||
version: string;
|
||||
};
|
||||
export type MixNode = {
|
||||
/**
|
||||
* Network address of this mixnode, for example 1.1.1.1 or foo.mixnode.com
|
||||
*/
|
||||
host: string,
|
||||
/**
|
||||
* Port used by this mixnode for listening for mix packets.
|
||||
*/
|
||||
mix_port: number,
|
||||
/**
|
||||
* Port used by this mixnode for listening for verloc requests.
|
||||
*/
|
||||
verloc_port: number,
|
||||
/**
|
||||
* Port used by this mixnode for its http(s) API
|
||||
*/
|
||||
http_api_port: number,
|
||||
/**
|
||||
* Base58-encoded x25519 public key used for sphinx key derivation.
|
||||
*/
|
||||
sphinx_key: string,
|
||||
/**
|
||||
* Base58-encoded ed25519 EdDSA public key.
|
||||
*/
|
||||
identity_key: string,
|
||||
/**
|
||||
* The self-reported semver version of this mixnode.
|
||||
*/
|
||||
version: string, };
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
|
||||
export type MixnodeCoreStatusResponse = { mix_id: number; count: number };
|
||||
export type MixnodeCoreStatusResponse = { mix_id: number, count: bigint, };
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
|
||||
export type MixnodeStatus = 'active' | 'standby' | 'inactive' | 'not_found';
|
||||
export type MixnodeStatus = "active" | "standby" | "inactive" | "not_found";
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
import type { MixnodeStatus } from './MixnodeStatus';
|
||||
import type { MixnodeStatus } from "./MixnodeStatus";
|
||||
|
||||
export type MixnodeStatusResponse = { status: MixnodeStatus };
|
||||
export type MixnodeStatusResponse = { status: MixnodeStatus, };
|
||||
|
||||
@@ -0,0 +1,5 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
import type { DetailedNodePerformanceV1 } from "./DetailedNodePerformanceV1";
|
||||
import type { DisplayRole } from "./DisplayRole";
|
||||
|
||||
export type NodeAnnotationV1 = { last_24h_performance: string, current_role: DisplayRole | null, detailed_performance: DetailedNodePerformanceV1, };
|
||||
@@ -0,0 +1,5 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
import type { DetailedNodePerformanceV2 } from "./DetailedNodePerformanceV2";
|
||||
import type { DisplayRole } from "./DisplayRole";
|
||||
|
||||
export type NodeAnnotationV2 = { current_role: DisplayRole | null, detailed_performance: DetailedNodePerformanceV2, };
|
||||
@@ -1,7 +1,3 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
|
||||
export type NodeConfigUpdate = {
|
||||
host: string | null;
|
||||
custom_http_port: number | null;
|
||||
restore_default_http_port: boolean;
|
||||
};
|
||||
export type NodeConfigUpdate = { host: string | null, custom_http_port: number | null, restore_default_http_port: boolean, };
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
|
||||
export type NodeDatePerformanceResponse = { node_id: number; date: string; performance: number | null };
|
||||
export type NodeDatePerformanceResponse = { node_id: number, date: string, performance: number | null, };
|
||||
|
||||
@@ -0,0 +1,40 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
|
||||
/**
|
||||
* On-chain representation of a node family.
|
||||
*/
|
||||
export type NodeFamily = {
|
||||
/**
|
||||
* The id of the node family
|
||||
*/
|
||||
id: number,
|
||||
/**
|
||||
* The name of the node family
|
||||
*/
|
||||
name: string,
|
||||
/**
|
||||
* Normalised name of the node family used for uniqueness checks
|
||||
*/
|
||||
normalised_name: string,
|
||||
/**
|
||||
* The optional description of the node family
|
||||
*/
|
||||
description: string,
|
||||
/**
|
||||
* The owner of the node family
|
||||
*/
|
||||
owner: string,
|
||||
/**
|
||||
* Records the fee paid when the family was created,
|
||||
* so that the appropriate amount could be returned upon it getting disbanded.
|
||||
*/
|
||||
paid_fee: { denom: string, amount: string },
|
||||
/**
|
||||
* Memoized value of the current number of members in the node family
|
||||
* Used to detect if the family is empty
|
||||
*/
|
||||
members: number,
|
||||
/**
|
||||
* Timestamp of the creation of the node family
|
||||
*/
|
||||
created_at: number, };
|
||||
@@ -0,0 +1,16 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
import type { NodeFamily } from "./NodeFamily";
|
||||
|
||||
/**
|
||||
* Response to [`QueryMsg::GetFamilyByOwner`](crate::QueryMsg::GetFamilyByOwner).
|
||||
*/
|
||||
export type NodeFamilyByOwnerResponse = {
|
||||
/**
|
||||
* The (validated) owner address that was queried, echoed back so callers
|
||||
* can correlate.
|
||||
*/
|
||||
owner: string,
|
||||
/**
|
||||
* The matching family, or `None` if `owner` does not currently own one.
|
||||
*/
|
||||
family: NodeFamily | null, };
|
||||
@@ -0,0 +1,15 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
|
||||
/**
|
||||
* Response to [`QueryMsg::GetFamilyMembership`](crate::QueryMsg::GetFamilyMembership).
|
||||
*/
|
||||
export type NodeFamilyMembershipResponse = {
|
||||
/**
|
||||
* The node that was queried.
|
||||
*/
|
||||
node_id: number,
|
||||
/**
|
||||
* The id of the family the node currently belongs to, or `None` if the
|
||||
* node is not currently a member of any family.
|
||||
*/
|
||||
family_id: number | null, };
|
||||
@@ -0,0 +1,15 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
import type { NodeFamily } from "./NodeFamily";
|
||||
|
||||
/**
|
||||
* Response to [`QueryMsg::GetFamilyById`](crate::QueryMsg::GetFamilyById).
|
||||
*/
|
||||
export type NodeFamilyResponse = {
|
||||
/**
|
||||
* The id that was queried, echoed back so paginated callers can correlate.
|
||||
*/
|
||||
family_id: number,
|
||||
/**
|
||||
* The matching family, or `None` if no family with `family_id` exists.
|
||||
*/
|
||||
family: NodeFamily | null, };
|
||||
@@ -1,3 +1,3 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
|
||||
export type NodePerformanceResponse = { node_id: number; performance: number | null };
|
||||
export type NodePerformanceResponse = { node_id: number, performance: number | null, };
|
||||
|
||||
@@ -1,12 +1,4 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
import type { NodeCostParams } from './MixNodeCostParams';
|
||||
import type { NodeCostParams } from "./MixNodeCostParams";
|
||||
|
||||
export type NodeRewarding = {
|
||||
cost_params: NodeCostParams;
|
||||
operator: string;
|
||||
delegates: string;
|
||||
total_unit_reward: string;
|
||||
unit_delegation: string;
|
||||
last_rewarded_epoch: number;
|
||||
unique_delegations: number;
|
||||
};
|
||||
export type NodeRewarding = { cost_params: NodeCostParams, operator: string, delegates: string, total_unit_reward: string, unit_delegation: string, last_rewarded_epoch: number, unique_delegations: number, };
|
||||
|
||||
@@ -3,14 +3,13 @@
|
||||
/**
|
||||
* Parameters used for rewarding particular node.
|
||||
*/
|
||||
export type NodeRewardingParameters = {
|
||||
/**
|
||||
* Performance of the particular node in the current epoch.
|
||||
*/
|
||||
performance: string;
|
||||
/**
|
||||
* Amount of work performed by this node in the current epoch
|
||||
* also known as 'omega' in the paper
|
||||
*/
|
||||
work_factor: string;
|
||||
};
|
||||
export type NodeRewardingParameters = {
|
||||
/**
|
||||
* Performance of the particular node in the current epoch.
|
||||
*/
|
||||
performance: string,
|
||||
/**
|
||||
* Amount of work performed by this node in the current epoch
|
||||
* also known as 'omega' in the paper
|
||||
*/
|
||||
work_factor: string, };
|
||||
|
||||
@@ -3,19 +3,18 @@
|
||||
/**
|
||||
* Information provided by the node operator during bonding that are used to allow other entities to use the services of this node.
|
||||
*/
|
||||
export type NymNode = {
|
||||
/**
|
||||
* Network address of this nym-node, for example 1.1.1.1 or foo.mixnode.com
|
||||
* that is used to discover other capabilities of this node.
|
||||
*/
|
||||
host: string;
|
||||
/**
|
||||
* Allow specifying custom port for accessing the http, and thus self-described, api
|
||||
* of this node for the capabilities discovery.
|
||||
*/
|
||||
custom_http_port: number | null;
|
||||
/**
|
||||
* Base58-encoded ed25519 EdDSA public key.
|
||||
*/
|
||||
identity_key: string;
|
||||
};
|
||||
export type NymNode = {
|
||||
/**
|
||||
* Network address of this nym-node, for example 1.1.1.1 or foo.mixnode.com
|
||||
* that is used to discover other capabilities of this node.
|
||||
*/
|
||||
host: string,
|
||||
/**
|
||||
* Allow specifying custom port for accessing the http, and thus self-described, api
|
||||
* of this node for the capabilities discovery.
|
||||
*/
|
||||
custom_http_port: number | null,
|
||||
/**
|
||||
* Base58-encoded ed25519 EdDSA public key.
|
||||
*/
|
||||
identity_key: string, };
|
||||
|
||||
@@ -1,40 +1,39 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
import type { DecCoin } from './DecCoin';
|
||||
import type { DecCoin } from "./DecCoin";
|
||||
|
||||
export type NymNodeBond = {
|
||||
/**
|
||||
* Unique id assigned to the bonded node.
|
||||
*/
|
||||
node_id: number;
|
||||
/**
|
||||
* Address of the owner of this nym-node.
|
||||
*/
|
||||
owner: string;
|
||||
/**
|
||||
* Original amount pledged by the operator of this node.
|
||||
*/
|
||||
original_pledge: DecCoin;
|
||||
/**
|
||||
* Block height at which this nym-node has been bonded.
|
||||
*/
|
||||
bonding_height: bigint;
|
||||
/**
|
||||
* Flag to indicate whether this node is in the process of unbonding,
|
||||
* that will conclude upon the epoch finishing.
|
||||
*/
|
||||
is_unbonding: boolean;
|
||||
/**
|
||||
* Network address of this nym-node, for example 1.1.1.1 or foo.mixnode.com
|
||||
* that is used to discover other capabilities of this node.
|
||||
*/
|
||||
host: string;
|
||||
/**
|
||||
* Allow specifying custom port for accessing the http, and thus self-described, api
|
||||
* of this node for the capabilities discovery.
|
||||
*/
|
||||
custom_http_port: number | null;
|
||||
/**
|
||||
* Base58-encoded ed25519 EdDSA public key.
|
||||
*/
|
||||
identity_key: string;
|
||||
};
|
||||
export type NymNodeBond = {
|
||||
/**
|
||||
* Unique id assigned to the bonded node.
|
||||
*/
|
||||
node_id: number,
|
||||
/**
|
||||
* Address of the owner of this nym-node.
|
||||
*/
|
||||
owner: string,
|
||||
/**
|
||||
* Original amount pledged by the operator of this node.
|
||||
*/
|
||||
original_pledge: DecCoin,
|
||||
/**
|
||||
* Block height at which this nym-node has been bonded.
|
||||
*/
|
||||
bonding_height: bigint,
|
||||
/**
|
||||
* Flag to indicate whether this node is in the process of unbonding,
|
||||
* that will conclude upon the epoch finishing.
|
||||
*/
|
||||
is_unbonding: boolean,
|
||||
/**
|
||||
* Network address of this nym-node, for example 1.1.1.1 or foo.mixnode.com
|
||||
* that is used to discover other capabilities of this node.
|
||||
*/
|
||||
host: string,
|
||||
/**
|
||||
* Allow specifying custom port for accessing the http, and thus self-described, api
|
||||
* of this node for the capabilities discovery.
|
||||
*/
|
||||
custom_http_port: number | null,
|
||||
/**
|
||||
* Base58-encoded ed25519 EdDSA public key.
|
||||
*/
|
||||
identity_key: string, };
|
||||
|
||||
@@ -1,22 +1,21 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
import type { NodeRewarding } from './NodeRewarding';
|
||||
import type { NymNodeBond } from './NymNodeBond';
|
||||
import type { PendingNodeChanges } from './PendingNodeChanges';
|
||||
import type { NodeRewarding } from "./NodeRewarding";
|
||||
import type { NymNodeBond } from "./NymNodeBond";
|
||||
import type { PendingNodeChanges } from "./PendingNodeChanges";
|
||||
|
||||
/**
|
||||
* Full details associated with given node.
|
||||
*/
|
||||
export type NymNodeDetails = {
|
||||
/**
|
||||
* Basic bond information of this node, such as owner address, original pledge, etc.
|
||||
*/
|
||||
bond_information: NymNodeBond;
|
||||
/**
|
||||
* Details used for computation of rewarding related data.
|
||||
*/
|
||||
rewarding_details: NodeRewarding;
|
||||
/**
|
||||
* Adjustments to the node that are scheduled to happen during future epoch/interval transitions.
|
||||
*/
|
||||
pending_changes: PendingNodeChanges;
|
||||
};
|
||||
export type NymNodeDetails = {
|
||||
/**
|
||||
* Basic bond information of this node, such as owner address, original pledge, etc.
|
||||
*/
|
||||
bond_information: NymNodeBond,
|
||||
/**
|
||||
* Details used for computation of rewarding related data.
|
||||
*/
|
||||
rewarding_details: NodeRewarding,
|
||||
/**
|
||||
* Adjustments to the node that are scheduled to happen during future epoch/interval transitions.
|
||||
*/
|
||||
pending_changes: PendingNodeChanges, };
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
import type { DecCoin } from './DecCoin';
|
||||
import type { DecCoin } from "./DecCoin";
|
||||
|
||||
export type OriginalVestingResponse = { amount: DecCoin; number_of_periods: number; period_duration: bigint };
|
||||
export type OriginalVestingResponse = { amount: DecCoin, number_of_periods: number, period_duration: bigint, };
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
import type { Pagination } from './Pagination';
|
||||
import type { Pagination } from "./Pagination";
|
||||
|
||||
export type PaginatedResponse<T> = { pagination: Pagination; data: Array<T> };
|
||||
export type PaginatedResponse<T> = { pagination: Pagination, data: Array<T>, };
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
|
||||
export type Pagination = { total: number; page: number; size: number };
|
||||
export type Pagination = { total: number, page: number, size: number, };
|
||||
|
||||
@@ -0,0 +1,18 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
import type { FamilyInvitation } from "./FamilyInvitation";
|
||||
import type { FamilyInvitationStatus } from "./FamilyInvitationStatus";
|
||||
|
||||
/**
|
||||
* Historical record of an invitation that has reached a terminal state
|
||||
* (`Accepted`, `Rejected`, or `Revoked`). Timed-out invitations are **not**
|
||||
* archived here — they remain in the pending map until explicitly cleared.
|
||||
*/
|
||||
export type PastFamilyInvitation = {
|
||||
/**
|
||||
* The original invitation as it was issued.
|
||||
*/
|
||||
invitation: FamilyInvitation,
|
||||
/**
|
||||
* What ultimately happened to it.
|
||||
*/
|
||||
status: FamilyInvitationStatus, };
|
||||
@@ -0,0 +1,22 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
import type { PastFamilyInvitation } from "./PastFamilyInvitation";
|
||||
|
||||
/**
|
||||
* Response to [`QueryMsg::GetPastInvitationsForFamilyPaged`](crate::QueryMsg::GetPastInvitationsForFamilyPaged).
|
||||
*/
|
||||
export type PastFamilyInvitationsPagedResponse = {
|
||||
/**
|
||||
* The family whose archived invitations were queried, echoed back so
|
||||
* paginated callers can correlate.
|
||||
*/
|
||||
family_id: number,
|
||||
/**
|
||||
* The archived invitations on this page, in ascending
|
||||
* `(node_id, counter)` order across all terminal statuses.
|
||||
*/
|
||||
invitations: Array<PastFamilyInvitation>,
|
||||
/**
|
||||
* Cursor to pass as `start_after` on the next call, or `None` if this
|
||||
* page is empty (treat as end-of-list).
|
||||
*/
|
||||
start_next_after: [number, number] | null, };
|
||||
@@ -0,0 +1,19 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
|
||||
/**
|
||||
* Historical record of a node that used to be part of a family but has since been
|
||||
* removed (kicked, left voluntarily, or because the family was disbanded).
|
||||
*/
|
||||
export type PastFamilyMember = {
|
||||
/**
|
||||
* The family the node used to belong to.
|
||||
*/
|
||||
family_id: number,
|
||||
/**
|
||||
* The node that was removed.
|
||||
*/
|
||||
node_id: number,
|
||||
/**
|
||||
* Block timestamp (unix seconds) at which the membership was terminated.
|
||||
*/
|
||||
removed_at: number, };
|
||||
@@ -0,0 +1,22 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
import type { PastFamilyMember } from "./PastFamilyMember";
|
||||
|
||||
/**
|
||||
* Response to [`QueryMsg::GetPastMembersForFamilyPaged`](crate::QueryMsg::GetPastMembersForFamilyPaged).
|
||||
*/
|
||||
export type PastFamilyMembersPagedResponse = {
|
||||
/**
|
||||
* The family whose archived memberships were queried, echoed back so
|
||||
* paginated callers can correlate.
|
||||
*/
|
||||
family_id: number,
|
||||
/**
|
||||
* The archived membership records on this page, in ascending
|
||||
* `(node_id, counter)` order.
|
||||
*/
|
||||
members: Array<PastFamilyMember>,
|
||||
/**
|
||||
* Cursor to pass as `start_after` on the next call, or `None` if this
|
||||
* page is empty (treat as end-of-list).
|
||||
*/
|
||||
start_next_after: [number, number] | null, };
|
||||
@@ -1,4 +1,4 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
import type { PendingEpochEventData } from './PendingEpochEventData';
|
||||
import type { PendingEpochEventData } from "./PendingEpochEventData";
|
||||
|
||||
export type PendingEpochEvent = { id: number; created_at: bigint; event: PendingEpochEventData };
|
||||
export type PendingEpochEvent = { id: number, created_at: bigint, event: PendingEpochEventData, };
|
||||
|
||||
@@ -1,10 +1,5 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
import type { DecCoin } from './DecCoin';
|
||||
import type { ActiveSetUpdate } from "./ActiveSetUpdate";
|
||||
import type { DecCoin } from "./DecCoin";
|
||||
|
||||
export type PendingEpochEventData =
|
||||
| { Delegate: { owner: string; mix_id: number; amount: DecCoin; proxy: string | null } }
|
||||
| { Undelegate: { owner: string; mix_id: number; proxy: string | null } }
|
||||
| { PledgeMore: { mix_id: number; amount: DecCoin } }
|
||||
| { DecreasePledge: { mix_id: number; decrease_by: DecCoin } }
|
||||
| { UnbondMixnode: { mix_id: number } }
|
||||
| { UpdateActiveSetSize: { new_size: number } };
|
||||
export type PendingEpochEventData = { "Delegate": { owner: string, mix_id: number, amount: DecCoin, proxy: string | null, } } | { "Undelegate": { owner: string, mix_id: number, proxy: string | null, } } | { "PledgeMore": { mix_id: number, amount: DecCoin, } } | { "DecreasePledge": { mix_id: number, decrease_by: DecCoin, } } | { "UnbondMixnode": { mix_id: number, } } | { "UpdateActiveSetSize": { new_size: number, } } | { "NymNodePledgeMore": { node_id: number, amount: DecCoin, } } | { "NymNodeDecreasePledge": { node_id: number, decrease_by: DecCoin, } } | { "UnbondNymNode": { node_id: number, } } | { "UpdateActiveSet": { update: ActiveSetUpdate, } };
|
||||
|
||||
@@ -0,0 +1,17 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
import type { FamilyInvitation } from "./FamilyInvitation";
|
||||
|
||||
/**
|
||||
* A pending [`FamilyInvitation`] paired with whether it has already timed
|
||||
* out at the time the query was served.
|
||||
*/
|
||||
export type PendingFamilyInvitationDetails = {
|
||||
/**
|
||||
* The stored invitation as it was issued.
|
||||
*/
|
||||
invitation: FamilyInvitation,
|
||||
/**
|
||||
* `true` iff `now >= invitation.expires_at` at query time, i.e. the
|
||||
* invitation is still in the pending map but can no longer be acted on.
|
||||
*/
|
||||
expired: boolean, };
|
||||
@@ -0,0 +1,20 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
import type { PendingFamilyInvitationDetails } from "./PendingFamilyInvitationDetails";
|
||||
|
||||
/**
|
||||
* Response to [`QueryMsg::GetPendingInvitation`](crate::QueryMsg::GetPendingInvitation).
|
||||
*/
|
||||
export type PendingFamilyInvitationResponse = {
|
||||
/**
|
||||
* The family component of the queried `(family_id, node_id)` key.
|
||||
*/
|
||||
family_id: number,
|
||||
/**
|
||||
* The node component of the queried `(family_id, node_id)` key.
|
||||
*/
|
||||
node_id: number,
|
||||
/**
|
||||
* The matching pending invitation along with an explicit expiry flag,
|
||||
* or `None` if no such invitation exists.
|
||||
*/
|
||||
invitation: PendingFamilyInvitationDetails | null, };
|
||||
@@ -0,0 +1,23 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
import type { PendingFamilyInvitationDetails } from "./PendingFamilyInvitationDetails";
|
||||
|
||||
/**
|
||||
* Response to [`QueryMsg::GetPendingInvitationsForFamilyPaged`](crate::QueryMsg::GetPendingInvitationsForFamilyPaged).
|
||||
*/
|
||||
export type PendingFamilyInvitationsPagedResponse = {
|
||||
/**
|
||||
* The family whose pending invitations were queried, echoed back so
|
||||
* paginated callers can correlate.
|
||||
*/
|
||||
family_id: number,
|
||||
/**
|
||||
* The pending invitations on this page, in ascending invitee
|
||||
* [`NodeId`] order, each stamped with whether it had already timed out
|
||||
* at the time the query was served.
|
||||
*/
|
||||
invitations: Array<PendingFamilyInvitationDetails>,
|
||||
/**
|
||||
* Cursor (last invitee node id) to pass as `start_after` on the next
|
||||
* call, or `None` if this page is empty (treat as end-of-list).
|
||||
*/
|
||||
start_next_after: number | null, };
|
||||
@@ -1,4 +1,4 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
import type { PendingIntervalEventData } from './PendingIntervalEventData';
|
||||
import type { PendingIntervalEventData } from "./PendingIntervalEventData";
|
||||
|
||||
export type PendingIntervalEvent = { id: number; created_at: bigint; event: PendingIntervalEventData };
|
||||
export type PendingIntervalEvent = { id: number, created_at: bigint, event: PendingIntervalEventData, };
|
||||
|
||||
@@ -1,8 +1,5 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
import type { IntervalRewardingParamsUpdate } from './IntervalRewardingParamsUpdate';
|
||||
import type { NodeCostParams } from './MixNodeCostParams';
|
||||
import type { IntervalRewardingParamsUpdate } from "./IntervalRewardingParamsUpdate";
|
||||
import type { NodeCostParams } from "./MixNodeCostParams";
|
||||
|
||||
export type PendingIntervalEventData =
|
||||
| { ChangeMixCostParams: { mix_id: number; new_costs: NodeCostParams } }
|
||||
| { UpdateRewardingParams: { update: IntervalRewardingParamsUpdate } }
|
||||
| { UpdateIntervalConfig: { epochs_in_interval: number; epoch_duration_secs: bigint } };
|
||||
export type PendingIntervalEventData = { "ChangeMixCostParams": { mix_id: number, new_costs: NodeCostParams, } } | { "ChangeNymNodeCostParams": { node_id: number, new_costs: NodeCostParams, } } | { "UpdateRewardingParams": { update: IntervalRewardingParamsUpdate, } } | { "UpdateIntervalConfig": { epochs_in_interval: number, epoch_duration_secs: bigint, } };
|
||||
|
||||
@@ -0,0 +1,23 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
import type { PendingFamilyInvitationDetails } from "./PendingFamilyInvitationDetails";
|
||||
|
||||
/**
|
||||
* Response to [`QueryMsg::GetPendingInvitationsForNodePaged`](crate::QueryMsg::GetPendingInvitationsForNodePaged).
|
||||
*/
|
||||
export type PendingInvitationsForNodePagedResponse = {
|
||||
/**
|
||||
* The node whose pending invitations were queried, echoed back so
|
||||
* paginated callers can correlate.
|
||||
*/
|
||||
node_id: number,
|
||||
/**
|
||||
* The pending invitations addressed to this node on this page, in
|
||||
* ascending [`NodeFamilyId`] order, each stamped with whether it had
|
||||
* already timed out at the time the query was served.
|
||||
*/
|
||||
invitations: Array<PendingFamilyInvitationDetails>,
|
||||
/**
|
||||
* Cursor (last issuing family id) to pass as `start_after` on the
|
||||
* next call, or `None` if this page is empty (treat as end-of-list).
|
||||
*/
|
||||
start_next_after: number | null, };
|
||||
@@ -1,3 +1,3 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
|
||||
export type PendingNodeChanges = { pledge_change: number | null; cost_params_change: number | null };
|
||||
export type PendingNodeChanges = { pledge_change: number | null, cost_params_change: number | null, };
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
import type { HistoricalPerformanceResponse } from './HistoricalPerformanceResponse';
|
||||
import type { PaginatedResponse } from './PaginatedResponse';
|
||||
import type { HistoricalPerformanceResponse } from "./HistoricalPerformanceResponse";
|
||||
import type { PaginatedResponse } from "./PaginatedResponse";
|
||||
|
||||
export type PerformanceHistoryResponse = { node_id: number; history: PaginatedResponse<HistoricalPerformanceResponse> };
|
||||
export type PerformanceHistoryResponse = { node_id: number, history: PaginatedResponse<HistoricalPerformanceResponse>, };
|
||||
|
||||
@@ -3,4 +3,4 @@
|
||||
/**
|
||||
* The vesting period.
|
||||
*/
|
||||
export type Period = 'Before' | { In: number } | 'After';
|
||||
export type Period = "Before" | { "In": number } | "After";
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
import type { DecCoin } from './DecCoin';
|
||||
import type { DecCoin } from "./DecCoin";
|
||||
|
||||
export type PledgeData = { amount: DecCoin; block_time: bigint };
|
||||
export type PledgeData = { amount: DecCoin, block_time: bigint, };
|
||||
|
||||
@@ -1,21 +1,20 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
|
||||
export type RewardEstimate = {
|
||||
/**
|
||||
* The amount of **decimal** coins that are going to get distributed to the node,
|
||||
* i.e. the operator and all its delegators.
|
||||
*/
|
||||
total_node_reward: string;
|
||||
/**
|
||||
* The share of the reward that is going to get distributed to the node operator.
|
||||
*/
|
||||
operator: string;
|
||||
/**
|
||||
* The share of the reward that is going to get distributed among the node delegators.
|
||||
*/
|
||||
delegates: string;
|
||||
/**
|
||||
* The operating cost of this node. Note: it's already included in the operator reward.
|
||||
*/
|
||||
operating_cost: string;
|
||||
};
|
||||
export type RewardEstimate = {
|
||||
/**
|
||||
* The amount of **decimal** coins that are going to get distributed to the node,
|
||||
* i.e. the operator and all its delegators.
|
||||
*/
|
||||
total_node_reward: string,
|
||||
/**
|
||||
* The share of the reward that is going to get distributed to the node operator.
|
||||
*/
|
||||
operator: string,
|
||||
/**
|
||||
* The share of the reward that is going to get distributed among the node delegators.
|
||||
*/
|
||||
delegates: string,
|
||||
/**
|
||||
* The operating cost of this node. Note: it's already included in the operator reward.
|
||||
*/
|
||||
operating_cost: string, };
|
||||
|
||||
@@ -1,20 +1,19 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
|
||||
export type RewardedSetParams = {
|
||||
/**
|
||||
* The expected number of nodes assigned entry gateway role (i.e. [`Role::EntryGateway`])
|
||||
*/
|
||||
entry_gateways: number;
|
||||
/**
|
||||
* The expected number of nodes assigned exit gateway role (i.e. [`Role::ExitGateway`])
|
||||
*/
|
||||
exit_gateways: number;
|
||||
/**
|
||||
* The expected number of nodes assigned the 'mixnode' role, i.e. total of [`Role::Layer1`], [`Role::Layer2`] and [`Role::Layer3`].
|
||||
*/
|
||||
mixnodes: number;
|
||||
/**
|
||||
* Number of nodes in the 'standby' set. (i.e. [`Role::Standby`])
|
||||
*/
|
||||
standby: number;
|
||||
};
|
||||
export type RewardedSetParams = {
|
||||
/**
|
||||
* The expected number of nodes assigned entry gateway role (i.e. [`Role::EntryGateway`])
|
||||
*/
|
||||
entry_gateways: number,
|
||||
/**
|
||||
* The expected number of nodes assigned exit gateway role (i.e. [`Role::ExitGateway`])
|
||||
*/
|
||||
exit_gateways: number,
|
||||
/**
|
||||
* The expected number of nodes assigned the 'mixnode' role, i.e. total of [`Role::Layer1`], [`Role::Layer2`] and [`Role::Layer3`].
|
||||
*/
|
||||
mixnodes: number,
|
||||
/**
|
||||
* Number of nodes in the 'standby' set. (i.e. [`Role::Standby`])
|
||||
*/
|
||||
standby: number, };
|
||||
|
||||
@@ -1,14 +1,12 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
import type { IntervalRewardParams } from './IntervalRewardParams';
|
||||
import type { RewardedSetParams } from './RewardedSetParams';
|
||||
import type { IntervalRewardParams } from "./IntervalRewardParams";
|
||||
import type { RewardedSetParams } from "./RewardedSetParams";
|
||||
|
||||
/**
|
||||
* Parameters used for reward calculation.
|
||||
*/
|
||||
export type RewardingParams = {
|
||||
/**
|
||||
* Parameters that should remain unchanged throughout an interval.
|
||||
*/
|
||||
interval: IntervalRewardParams;
|
||||
rewarded_set: RewardedSetParams;
|
||||
};
|
||||
export type RewardingParams = {
|
||||
/**
|
||||
* Parameters that should remain unchanged throughout an interval.
|
||||
*/
|
||||
interval: IntervalRewardParams, rewarded_set: RewardedSetParams, };
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
|
||||
export type Role = 'EntryGateway' | 'Layer1' | 'Layer2' | 'Layer3' | 'ExitGateway' | 'Standby';
|
||||
export type Role = "eg" | "l1" | "l2" | "l3" | "xg" | "stb";
|
||||
|
||||
@@ -1,13 +1,5 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
import type { DecCoin } from './DecCoin';
|
||||
import type { Gas } from './Gas';
|
||||
import type { DecCoin } from "./DecCoin";
|
||||
import type { Gas } from "./Gas";
|
||||
|
||||
export type RpcTransactionResponse = {
|
||||
index: number;
|
||||
tx_result_json: string;
|
||||
block_height: bigint;
|
||||
transaction_hash: string;
|
||||
gas_used: Gas;
|
||||
gas_wanted: Gas;
|
||||
fee: DecCoin | null;
|
||||
};
|
||||
export type RpcTransactionResponse = { index: number, tx_result_json: string, block_height: bigint, transaction_hash: string, gas_used: Gas, gas_wanted: Gas, fee: DecCoin | null, };
|
||||
|
||||
@@ -1,14 +1,6 @@
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
import type { DecCoin } from './DecCoin';
|
||||
import type { Gas } from './Gas';
|
||||
import type { TransactionDetails } from './TransactionDetails';
|
||||
import type { DecCoin } from "./DecCoin";
|
||||
import type { Gas } from "./Gas";
|
||||
import type { TransactionDetails } from "./TransactionDetails";
|
||||
|
||||
export type SendTxResult = {
|
||||
block_height: bigint;
|
||||
code: number;
|
||||
details: TransactionDetails;
|
||||
gas_used: Gas;
|
||||
gas_wanted: Gas;
|
||||
tx_hash: string;
|
||||
fee: DecCoin | null;
|
||||
};
|
||||
export type SendTxResult = { block_height: bigint, code: number, details: TransactionDetails, gas_used: Gas, gas_wanted: Gas, tx_hash: string, fee: DecCoin | null, };
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user