Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/Emurgo/age-usd
/ functions
Functions
105 in github.com/Emurgo/age-usd
⨍
Functions
105
◇
Types & classes
10
↓ 13 callers
Method
num_circulating_stablecoins
(&self)
ageusd-headless/src/bank.rs:98
↓ 11 callers
Function
get_protocol_scans
Small error checking function for acquiring `Scan`s by using the IDs from a local file.
ageusd-cli/src/main.rs:592
↓ 10 callers
Method
base_reserves
(&self)
ageusd-headless/src/bank.rs:61
↓ 5 callers
Method
base_cost_to_mint_reservecoin
( &self, amount_to_mint: u64, oracle_box: &ErgUsdOraclePoolBox, )
ageusd-headless/src/bank.rs:423
↓ 5 callers
Function
reserve_ratio
Calculates the Reserve Ratio based on provided inputs.
ageusd-headless/src/equations.rs:4
↓ 4 callers
Method
base_cost_to_mint_stablecoin
( &self, amount_to_mint: u64, oracle_box: &ErgUsdOraclePoolBox, )
ageusd-headless/src/bank.rs:373
↓ 4 callers
Method
liabilities
(&self, oracle_box: &ErgUsdOraclePoolBox)
ageusd-headless/src/bank.rs:72
↓ 4 callers
Method
min_box_value
(&self)
ageusd-headless/src/protocol.rs:37
↓ 4 callers
Method
num_circulating_reservecoins
(&self)
ageusd-headless/src/bank.rs:108
↓ 4 callers
Method
reservecoin_nominal_price
(&self, oracle_box: &ErgUsdOraclePoolBox)
ageusd-headless/src/bank.rs:130
↓ 4 callers
Method
stablecoin_nominal_price
(&self, oracle_box: &ErgUsdOraclePoolBox)
ageusd-headless/src/bank.rs:117
↓ 3 callers
Method
action_mint_reservecoin
Action: Mint ReserveCoin by providing Ergs
ageusd-headless/src/protocol.rs:352
↓ 3 callers
Method
action_mint_stablecoin
Action: Mint StableCoin by providing Ergs
ageusd-headless/src/protocol.rs:487
↓ 3 callers
Method
action_redeem_reservecoin
Action: Redeem ReserveCoin for Ergs
ageusd-headless/src/protocol.rs:624
↓ 3 callers
Method
action_redeem_stablecoin
Action: Redeem StableCoin for Ergs
ageusd-headless/src/protocol.rs:772
↓ 3 callers
Method
base_amount_from_redeeming_reservecoin
( &self, amount_to_redeem: u64, oracle_box: &ErgUsdOraclePoolBox, )
ageusd-headless/src/bank.rs:478
↓ 3 callers
Method
base_amount_from_redeeming_stablecoin
( &self, amount_to_redeem: u64, oracle_box: &ErgUsdOraclePoolBox, )
ageusd-headless/src/bank.rs:533
↓ 3 callers
Method
equity
(&self, oracle_box: &ErgUsdOraclePoolBox)
ageusd-headless/src/bank.rs:88
↓ 3 callers
Method
redeem_reservecoin_reserve_ratio
( &self, oracle_box: &ErgUsdOraclePoolBox, num_to_redeem: u64, )
ageusd-headless/src/bank.rs:319
↓ 2 callers
Method
able_to_mint_reservecoin_amount
( &self, oracle_box: &ErgUsdOraclePoolBox, amount: u64, current_height: BlockH
ageusd-headless/src/bank.rs:199
↓ 2 callers
Method
able_to_mint_stablecoin_amount
( &self, oracle_box: &ErgUsdOraclePoolBox, amount: u64, )
ageusd-headless/src/bank.rs:139
↓ 2 callers
Method
create_update_protocol_candidate
Create an `ErgoBoxCandidate` for the output Update box for the `Update Protocol` Action
ageusd-headless/src/update.rs:163
↓ 2 callers
Function
get_ergs_boxes_to_cover
Wrapper function to acquire boxes to cover a given NanoErg amount already wrapped as `ErgsBox`
ageusd-cli/src/main.rs:644
↓ 2 callers
Function
get_reservecoin_boxes
Acquire all of the boxes holding ReserveCoins
ageusd-cli/src/main.rs:615
↓ 2 callers
Function
get_stablecoin_boxes
Acquire all of the boxes holding StableCoins
ageusd-cli/src/main.rs:629
↓ 2 callers
Method
mint_reservecoin_reserve_ratio
( &self, oracle_box: &ErgUsdOraclePoolBox, num_to_mint: u64, )
ageusd-headless/src/bank.rs:256
↓ 2 callers
Method
mint_stablecoin_reserve_ratio
( &self, oracle_box: &ErgUsdOraclePoolBox, num_to_mint: u64, )
ageusd-headless/src/bank.rs:183
↓ 2 callers
Function
new_reservecoin_token
Creates a new ReserveCoin token with a custom amount
ageusd-headless/src/receipt.rs:212
↓ 2 callers
Function
new_stablecoin_token
Creates a new StableCoin token with a custom amount
ageusd-headless/src/receipt.rs:207
↓ 2 callers
Method
token_amount
(&self)
ageusd-headless/src/input_boxes.rs:29
↓ 1 callers
Method
able_to_redeem_reservecoin_amount
( &self, oracle_box: &ErgUsdOraclePoolBox, amount: u64, )
ageusd-headless/src/bank.rs:272
↓ 1 callers
Method
action_collect_votes
Action: Collect Votes
ageusd-headless/src/update.rs:239
↓ 1 callers
Method
action_update_protocol
Action: Update Protocol
ageusd-headless/src/update.rs:314
↓ 1 callers
Method
action_vote_for_update
Action: Vote For Update
ageusd-headless/src/update.rs:185
↓ 1 callers
Method
address_hash_voted_for
The hash of the address which is being voted for in the Ballot Box
ageusd-headless/src/update.rs:45
↓ 1 callers
Function
collect_votes_for_update
Collect Votes for an Update
ageusd-cli/src/main.rs:315
↓ 1 callers
Method
create_collect_votes_candidate
Create an `ErgoBoxCandidate` for the output Update box for the `Collect Votes` Action
ageusd-headless/src/update.rs:134
↓ 1 callers
Method
create_mint_reservecoin_candidate
Create an `ErgoBoxCandidate` for the output Bank box for the `Mint ReserveCoin` action
ageusd-headless/src/bank.rs:549
↓ 1 callers
Method
create_mint_stablecoin_candidate
Create an `ErgoBoxCandidate` for the output Bank box for the `Mint StableCoin` action
ageusd-headless/src/bank.rs:590
↓ 1 callers
Method
create_redeem_reservecoin_candidate
Create an `ErgoBoxCandidate` for the output Bank box for the `Redeem ReserveCoin` action
ageusd-headless/src/bank.rs:629
↓ 1 callers
Method
create_redeem_stablecoin_candidate
Create an `ErgoBoxCandidate` for the output Bank box for the `Redeem StableCoin` action
ageusd-headless/src/bank.rs:670
↓ 1 callers
Method
create_vote_for_update_candidate
Create an `ErgoBoxCandidate` for the output Ballot box for the `Vote For Update` action
ageusd-headless/src/update.rs:78
↓ 1 callers
Function
get_node_interface
Small error checking function for acquiring data for a `NodeInterface` / from a local file.
ageusd-cli/src/main.rs:571
↓ 1 callers
Method
is_voting_for_address
Verify that the `BallotBox` is voting for a given P2S address
ageusd-headless/src/update.rs:66
↓ 1 callers
Method
max_reserve_ratio
(&self)
ageusd-headless/src/protocol.rs:52
↓ 1 callers
Method
min_reserve_ratio
(&self)
ageusd-headless/src/protocol.rs:47
↓ 1 callers
Function
mint_reservecoins
Mint ReserveCoins
ageusd-cli/src/main.rs:410
↓ 1 callers
Function
mint_stablecoins
Mint StableCoins
ageusd-cli/src/main.rs:452
↓ 1 callers
Function
redeem_reservecoins
Redeem ReserveCoins
ageusd-cli/src/main.rs:494
↓ 1 callers
Function
redeem_stablecoins
Redeem StableCoins
ageusd-cli/src/main.rs:532
↓ 1 callers
Function
register_all_ballot_tokens_scan
Register to find all boxes that hold ballot tokens
ageusd-cli/src/scan.rs:115
↓ 1 callers
Function
register_bank_scan
Register the scan to find the `Bank` box via the provided `NodeInterface`
ageusd-cli/src/scan.rs:6
↓ 1 callers
Function
register_oracle_pool_scan
Register to find the Oracle Pool Box
ageusd-cli/src/scan.rs:74
↓ 1 callers
Function
register_reservecoin_scan
Register to find the ReserveCoins that the user owns in the very first address of their Ergo node wallet via the provided `NodeInterface`
ageusd-cli/src/scan.rs:48
↓ 1 callers
Function
register_stablecoin_scan
Register to find the StableCoins that the user owns in the very first address of their Ergo node wallet via the provided `NodeInterface`
ageusd-cli/src/scan.rs:21
↓ 1 callers
Function
register_update_box_scan
Register to find the Update box
ageusd-cli/src/scan.rs:129
↓ 1 callers
Function
register_user_ballot_token_scan
Register to find the user's vote token. (Must be held by the first address in the Ergo Node wallet)
ageusd-cli/src/scan.rs:89
↓ 1 callers
Method
total_cost_to_mint_reservecoin
( &self, amount_to_mint: u64, oracle_box: &ErgUsdOraclePoolBox, transaction_fe
ageusd-headless/src/bank.rs:390
↓ 1 callers
Method
total_cost_to_mint_stablecoin
( &self, amount_to_mint: u64, oracle_box: &ErgUsdOraclePoolBox, transaction_fe
ageusd-headless/src/bank.rs:341
↓ 1 callers
Method
update_box_id
The box id of the Update Box when the vote was cast
ageusd-headless/src/update.rs:50
↓ 1 callers
Function
update_protocol
Update Protocol
ageusd-cli/src/main.rs:274
↓ 1 callers
Function
vote_for_update
Vote for an Update
ageusd-cli/src/main.rs:364
Method
bank_nft_id
(&self)
ageusd-headless/src/protocol.rs:67
Method
box_spec
A `BoxSpec` that checks that the box is a valid BankBox via looking that it holds the correct StableCoin/ReserveCoin tokens and the Bank NFT.
ageusd-headless/src/bank.rs:35
Method
box_spec
A `BoxSpec` that checks that ReserveCoins are in the box via a predicate.
ageusd-headless/src/input_boxes.rs:38
Method
box_spec
A `BoxSpec` that checks that the box is a valid BallotBox
ageusd-headless/src/update.rs:34
Method
convert_from_ergo_boxes
Converts from the WASM wrapper `ErgoBoxes`.
ageusd-headless/src/input_boxes.rs:74
Method
create_mint_reservecoin_candidate
Create an `ErgoBoxCandidate` for an output Receipt box for the `Mint ReserveCoin` action
ageusd-headless/src/receipt.rs:23
Method
create_mint_stablecoin_candidate
Create an `ErgoBoxCandidate` for an output Receipt box for the `Mint StableCoin` action
ageusd-headless/src/receipt.rs:61
Method
create_placeholder_box
Create a placeholder box. This is useful for using with protocols as a placeholder so that an assembler spec can be created (and this placeholder box
ageusd-headless/src/input_boxes.rs:87
Method
create_redeem_reservecoin_candidate
Create an `ErgoBoxCandidate` for an output Receipt box for the `Redeem ReserveCoin` action
ageusd-headless/src/receipt.rs:99
Method
create_redeem_stablecoin_candidate
Create an `ErgoBoxCandidate` for an output Receipt box for the `Redeem StableCoin` action
ageusd-headless/src/receipt.rs:153
Method
create_update_protocol_candidate
Create an `ErgoBoxCandidate` for the output Bank Box for the `Update Protocol` Action
ageusd-headless/src/bank.rs:709
Method
current_reserve_ratio
(&self, oracle_box: &ErgUsdOraclePoolBox)
ageusd-headless/src/bank.rs:49
Method
extract_token_amount
Acquires the token amount
ageusd-headless/src/input_boxes.rs:51
Method
fees_from_minting_reservecoin
( &self, amount_to_mint: u64, oracle_box: &ErgUsdOraclePoolBox, transaction_fe
ageusd-headless/src/bank.rs:406
Method
fees_from_minting_stablecoin
( &self, amount_to_mint: u64, oracle_box: &ErgUsdOraclePoolBox, transaction_fe
ageusd-headless/src/bank.rs:357
Method
fees_from_redeeming_reservecoin
( &self, amount_to_redeem: u64, oracle_box: &ErgUsdOraclePoolBox, transaction_
ageusd-headless/src/bank.rs:460
Method
fees_from_redeeming_stablecoin
( &self, amount_to_redeem: u64, oracle_box: &ErgUsdOraclePoolBox, transaction_
ageusd-headless/src/bank.rs:515
Function
fetch_all_ballot_boxes
Fetch all `BallotBox`es from the public Ergo Explorer API
ageusd-cli/src/fetch_boxes.rs:21
Function
fetch_update_box
Fetch the `UpdateBox` from the public Ergo Explorer API
ageusd-cli/src/fetch_boxes.rs:30
Function
fetch_user_ballot_box
Fetch the user's `BallotBox` from the public Ergo Explorer API
ageusd-cli/src/fetch_boxes.rs:6
Function
main
()
ageusd-cli/src/main.rs:74
Method
new
()
ageusd-headless/src/protocol.rs:32
Method
num_able_to_mint_reservecoin
( &self, oracle_box: &ErgUsdOraclePoolBox, current_height: BlockHeight, )
ageusd-headless/src/bank.rs:218
Method
num_able_to_mint_stablecoin
(&self, oracle_box: &ErgUsdOraclePoolBox)
ageusd-headless/src/bank.rs:153
Method
num_able_to_redeem_reservecoin
(&self, oracle_box: &ErgUsdOraclePoolBox)
ageusd-headless/src/bank.rs:288
Method
predicate
Predicate to check that the box has ReserveCoins in it
ageusd-headless/src/input_boxes.rs:46
Method
predicate
A simple predicate to check the registers
ageusd-headless/src/update.rs:61
Method
reservecoin_default_price
(&self)
ageusd-headless/src/protocol.rs:42
Method
reservecoin_token_id
(&self)
ageusd-headless/src/protocol.rs:62
Method
stablecoin_token_id
(&self)
ageusd-headless/src/protocol.rs:57
Method
sum_nano_ergs_value
Sums the nanoErg value of a list of `ReserveCoinBox`es
ageusd-headless/src/input_boxes.rs:64
Method
sum_token_amount
Sums the token amount of a list of `ReserveCoinBox`es
ageusd-headless/src/input_boxes.rs:69
Method
total_amount_from_redeeming_reservecoin
( &self, amount_to_redeem: u64, oracle_box: &ErgUsdOraclePoolBox, transaction_
ageusd-headless/src/bank.rs:441
Method
total_amount_from_redeeming_stablecoin
( &self, amount_to_redeem: u64, oracle_box: &ErgUsdOraclePoolBox, transaction_
ageusd-headless/src/bank.rs:496
Method
voting_power
(&self)
ageusd-headless/src/update.rs:54
Method
w_action_mint_reservecoin
Action: Mint ReserveCoin by providing Ergs. This is the WASM wrapper function for said Action.
ageusd-headless/src/protocol.rs:219
Method
w_action_mint_stablecoin
Action: Mint StableCoins by providing Ergs. This is the WASM wrapper function for said Action.
ageusd-headless/src/protocol.rs:252
Method
w_action_redeem_reservecoin
Action: Redeem ReserveCoins for Ergs. This is the WASM wrapper function for said Action.
ageusd-headless/src/protocol.rs:285
next →
1–100 of 105, ranked by callers