Skip to content

Commit

Permalink
Cleanup CongestionResponse documentation (iotaledger#2017)
Browse files Browse the repository at this point in the history
* Cleanup CongestionResponse documentation

* Update bindings/nodejs/lib/types/models/api/congestion-response.ts

Co-authored-by: Thoralf-M <[email protected]>

---------

Co-authored-by: Thoralf-M <[email protected]>
  • Loading branch information
thibault-martinez and Thoralf-M authored Feb 19, 2024
1 parent 257bcff commit 9a6ba79
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 13 deletions.
10 changes: 5 additions & 5 deletions bindings/nodejs/lib/types/models/api/congestion-response.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,19 +9,19 @@ import { u64 } from '../../utils';
*/
export class CongestionResponse {
/**
* The slot index for which the congestion estimate is provided.
* Slot for which the estimate is provided.
*/
slot!: SlotIndex;
/**
* Indicates if a node is ready to issue a block in a current congestion or should wait.
* Indicates if a node is ready to schedule a block issued by the specified account, or if the issuer should wait.
*/
ready!: boolean;
/**
* The cost in mana for issuing a block in a current congestion estimated based on RMC and slot index.
* Mana cost a user needs to burn to issue a block in the slot.
*/
referenceManaCost!: u64;
/**
* The Block Issuance Credits of the requested account.
* BIC of the account in the slot. This balance needs to be non-negative, otherwise account is locked.
*/
blockIssuanceCredits!: u64;
blockIssuanceCredits!: bigint;
}
8 changes: 4 additions & 4 deletions bindings/python/iota_sdk/client/responses.py
Original file line number Diff line number Diff line change
Expand Up @@ -164,10 +164,10 @@ class CongestionResponse:
Response of GET /api/core/v3/accounts/{accountId}/congestion.
Attributes:
slot: The slot index for which the congestion estimate is provided.
ready: Indicates if a node is ready to issue a block in a current congestion or should wait.
reference_mana_cost: The cost in mana for issuing a block in a current congestion estimated based on RMC and slot index.
block_issuance_credits: The Block Issuance Credits of the requested account.
slot: Slot for which the estimate is provided.
ready: Indicates if a node is ready to schedule a block issued by the specified account, or if the issuer should wait.
reference_mana_cost: Mana cost a user needs to burn to issue a block in the slot.
block_issuance_credits: BIC of the account in the slot. This balance needs to be non-negative, otherwise account is locked.
"""
slot: SlotIndex
ready: bool
Expand Down
8 changes: 4 additions & 4 deletions sdk/src/types/api/core.rs
Original file line number Diff line number Diff line change
Expand Up @@ -334,14 +334,14 @@ impl IssuanceBlockHeaderResponse {
#[derive(Clone, Debug, Eq, PartialEq, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct CongestionResponse {
/// The slot index for which the congestion estimate is provided.
/// Slot for which the estimate is provided.
pub slot: SlotIndex,
/// Indicates if a node is ready to issue a block in a current congestion or should wait.
/// Indicates if a node is ready to schedule a block issued by the specified account, or if the issuer should wait.
pub ready: bool,
/// The cost in mana for issuing a block in a current congestion estimated based on RMC and slot index.
/// Mana cost a user needs to burn to issue a block in the slot.
#[serde(with = "string")]
pub reference_mana_cost: u64,
/// The Block Issuance Credits of the requested account.
/// BIC of the account in the slot. This balance needs to be non-negative, otherwise account is locked.
#[serde(with = "string")]
pub block_issuance_credits: i128,
}
Expand Down

0 comments on commit 9a6ba79

Please sign in to comment.