From dc59d4dd91ac12da35e8b1451b98ba219adc3e6b Mon Sep 17 00:00:00 2001 From: Bowen Wang Date: Tue, 30 Jun 2020 17:51:17 -0700 Subject: [PATCH] add example to staking pool factory readme --- staking-pool-factory/README.md | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/staking-pool-factory/README.md b/staking-pool-factory/README.md index eec98238..b11c755e 100644 --- a/staking-pool-factory/README.md +++ b/staking-pool-factory/README.md @@ -61,3 +61,18 @@ pub fn on_staking_pool_create( predecessor_account_id: AccountId, ) -> PromiseOrValue; ``` + +### Usage + +Contract initialization: +```bash +near call new '{"staking_pool_whitelist_account_id": }' +``` +where `` it the account id of the whitelist contract that this factory +is associated with. + +Staking pool creation: +```bash +near call create_staking_pool '{"staking_pool_id": , "owner_id": , "stake_public_key": , "reward_fee_fraction": }' +``` +Here `reward_fee_fraction` is an object like `{"numerator": 10, "denominator": 100}`.