All pages
Powered by GitBook
1 of 5

Loading...

Loading...

Loading...

Loading...

Loading...

NFTs and Marketplace

NFT marketplace in Python

Describing here the steps to verify the Marketplace_python on local or server machine.

Machine configuration : Local or server machine.

Step 1: Clone Marketplace_python binaries on machine

Project Url :

Clone binaries on Machine:

Step: 2 Install virtual env on machine

Go to project:

Run:

Step: 3 Install python requirements

Run:

And then:

then:

Step: 4 Run unit tests

Run:

Expected result should be as below:

https://gitlab.com/PBSA/PeerplaysIO/tools-libs/python-peerplays/-/tree/nft
git clone https://gitlab.com/PBSA/PeerplaysIO/tools-libs/python-peerplays.git
cd python-peerplays
virtualenv -p python3 env
source env/bin/activate
pip3 install -r requirements.txt
pip3 install -r requirements-test.txt
python -m unittest tests/test_market_place.py
(env) ubuntu@ip-172-31-13-101:~/python-peerplays$ python -m unittest tests/test_market_place.py
Not broadcasting anything!
Not broadcasting anything!
create_off Success!
Not broadcasting anything!
create_bid Success!
Not broadcasting anything!
cancel_offer Success!
All tests successful!
.
----------------------------------------------------------------------
Ran 1 test in 2.270s
OK
(env) ubuntu@ip-172-31-13-101:~/python-peerplays$

NFT command reference

Step: 1 Create Metadata

Command used : nft_metadata_create <<account_name>> <<metadata_name>> <<metadata_symbol>> <<base_uri>> true true true

For example : nft_metadata_create account01 sknft sknft sknft null null true true true

Step:2 Update Metadata

Command used : nft_metadata_update <<account_name>> <<metadata_id>> <<new_name>> <<new_symbol>> <<new_base_uri>> null null true true true

For Example :nft_metadata_update account01 1.30.1 sknft01 sknft01 sknft01 null null true true true

Step: 3 Create NFT

Command used : nft_create <<account_name>> <<metadata_id>> <<Owner_account_name>> <<approve_aacount_name>> <<token_uri>> true

For Example : nft_create account01 1.30.0 account03 account03 sknftmint true

Step:4 Get NFT balance

Command used : nft_get_balance <<account_name>>

For Example : nft_get_balance account01

Step:5 To verify the owner of created NFT

Command used : nft_owner_of <<nft_id>>

For Example : nft_owner_of 1.31.1

Step:6 Safe NFT transfer

Command Used : nft_safe_transfer_from <<Operator_account_name>> <<transfer_from_account_name>> <<transfer_to_account_name>> <<nft_id>> true true

For Example : nft_safe_transfer_from account01 account01 aaccount02 1.31.1 true true

Step: 7 NFT Transfer

Command used : nft_transfer_from <<Operator_account_id>> <<From_account_id>> <<To_account_id>> <<nft_id>> true

For Example : nft_transfer_from 1.2.31 1.2.31 1.2.28 1.31.37 true

Step:8 NFT Approve

Command used : nft_approve <<new_operator_account_id>> <<new_account_id>> <<ndt_id>> true

For Example : nft_approve 1.2.19 1.2.19 1.31.1 true

Step : 9 To approve all NFTs at once

Command used: nft_set_approval_for_all <<Owner_account_id>> <<Operator_account_id>> true true

For example : nft_set_approval_for_all 1.2.21 1.2.21 true true

Step: 10 To see the approved account details

Command used : nft_get_approved <<approve_nft_id>>

For Example: nft_get_approved 1.31.0

Step:11 Approved for all

Command used: nft_is_approved_for_all <<owner_account_id>> <<operator_account_id>>

For Example : nft_is_approved_for_all 1.2.21 1.2.21

Step :12 Get list of all created NFT

Command used : nft_get_all_tokens

With this - all the created NFTs are listed on the machine.

NFT Operations in Python

Describing the steps to verify the NFT_python on local or server machine below.

Machine configuration : Local or server machine.

Step 1: Clone NFT_python binaries on machine

Project Url :

Clone binaries on Machine :

Step: 2 Install virtual env on machine

Go to project :

Run:

Step: 3 Install python requirements

Run:

then,

And then,

Step: 4 Run unit tests

Run:

Expected result should be as below:

Cheers, all unit tests are passed and you successfully verify the NFT_python

https://gitlab.com/PBSA/PeerplaysIO/tools-libs/python-peerplays/-/tree/nft
git clone https://gitlab.com/PBSA/PeerplaysIO/tools-libs/python-peerplays.git
cd python-peerplays
virtualenv -p python3 env
source env/bin/activate
pip3 install -r requirements.txt
pip3 install -r requirements-test.txt
python3 -m unittest tests/test_nft.py
(env) ubuntu@ip-172-31-13-101:~/python-peerplays$ python3 -m unittest tests/test_nft.py
Not broadcasting anything!
nft_metadata_create Success!
Not broadcasting anything!
nft_metadata_update Success!
Not broadcasting anything!
nft_mint Success!
Not broadcasting anything!
nft_safe_transfer_from Success!
Not broadcasting anything!
nft_approve Success!
Not broadcasting anything!
nft_set_approval_for_all Success!
All tests successful!
.
----------------------------------------------------------------------
Ran 1 test in 3.449s

OK
(env) ubuntu@ip-172-31-13-101:~/python-peerplays$

NFT, Marketplace, HRP, and RBAC related Commands/Use Cases

Here we learn some commands and use cases related to NFT, Marketplace, HRP, and RBAC.

1. NFT Metadata Creation

Example NFT metadata create command without permissions,

  • account01 is the owner account of the metadata

  • “AVALON NAME” is the name of the NFT types created from the NFT metadata being created

  • “AVALON SYMBOL” is the symbol of the NFT types created from the NFT metadata being created. The symbol is reserved for future use.

  • “AVALON BASE URI” is the URI of the NFT types. Eg: avalonmeta.com

  • account02 is the revenue partner, this can be owner as well. Whenever the minted NFT is sold in the marketplace a split of the selling price goes to the revenue partner. The split can be specified in revenue_split parameter.

  • 100 is the revenue_split on the scale of 10000 being 100 percent. i.e. 100 is 1%

  • is_transferable specifies if the minted NFTs can be transferred by the owner of the NFT to other accounts

  • is_sellable specifies if the minted NFTs can be sold in the marketplace.

  • role_id is the resource permissions specifying the whitelisting accounts among which the NFTs can either be transferred or sold on marketplace.

  • broadcast either true or false, keeping it true will include the transaction in the upcoming block on the chain.

Example NFT metadata create command with permissions

First create a permission:

Example Permission:

  • account01 is the owner of the permission being created which can be attached to NFT metadata.

  • “Avalon Permissions1” is the name of the resource permission being created.

  • “Permission Metadata” is the metadata, can be a JSON as well.

Example NFT metadata create command with permissions:

  • 1.32.0 This is specified in the metadata create operation to attach permissions to all the NFTs created from this metadata.

NFT creation

NFT is always minted by the owner of the metadata object this NFT is based on. The fees associated with minting this NFT is just the transaction fee + storage fee which are both collected in core PPY token. After the NFT has been minted this can be sold on marketplace in any token of NFT owner’s choice.

Syntax:

Example NFT creation based on the metadata created above:

  • account01 is the owner of the metadata this NFT is based on

  • 1.30.0 is the metadata ID of the metadata object this NFT is based on ( Currently this works on best guess method by doing get_object 1.30.0, 1.30.1, 1.30.2 …. so on, in future a new cli command will be introduced that can list all the metadata objects by owner account ).

  • account02 is the owner of the NFT, can be one of the user of the Avalon App.

NFT Safe Transfer from owner to other account

Example command:

Note that NFTs can be transferred only when is_transferableflag is set to true, also if permissions are enabled both from and to accounts have to be whitelisted.

  • account02 operator or owner account

  • account02 from account

  • account03 to account

  • 1.31.0 Id of the NFT

Create Market Listing Offer

Example command:

Note that is_sellable of NFT metadata should be true to make listing of the NFTs created from the metadata.

Only owner of the NFT can create a listing in auction.

  • ["1.31.0","1.31.1"] - List of NFTs to sell or buy

  • account02 is the owner of the NFTs

  • {"amount":100,"asset_id":"1.3.0"} minimum bid price expected

Create Bid Offer

Example bid command:

  • account04 is the bidder

  • {"amount":10000,"asset_id":"1.3.0"} bid price

  • 1.29.0 Offer listing objected created from create_offer command

Cancel Offer

Example cancel offer command:

  • account02 is the creator of the listing

  • 1.29.0 is the offer object

  • true broadcast value mentioned above

List Offers

Returns all the sell and buy listings offer objects in the marketplace.

Example command:

  • 100 Number of items per fetch (pagination)

  • 1.29.0 Index to start the search for. (pagination)

Example command without pagination:

List Sell Offers

Returns all the sell listing offer objects in the marketplace.

Example command:

  • 10 Number of items per fetch (pagination)

  • 1.29.6 Index to start the search for. (pagination)

Example command without pagination:

List Buy Offers

Returns all the buy listing offer objects in the marketplace. (Reverse Auction offer objects).

Example command:

  • 10 Number of items per fetch (pagination)

  • 1.29.6 Index to start the search for. (pagination)

Example command without pagination:

List Offer History

Returns all the closed auction and reverse auction listings. (offers)

Example command:

  • 10Number of items per fetch (pagination)

  • 2.24.2Index to start the search for. (pagination)

Example command without pagination:

Get Offers by Issuer

Returns all the offers listed by an account.

Example command:

  • account02 issuer

  • 10 Number of items per fetch (Pagination)

  • 1.29.0 Index to start the search for. (pagination)

Example command without pagination:

Get Offers by NFT Item

Example command:

  • 1.31.0 NFT Id

  • 10 Number of items per fetch (Pagination)

  • 1.29.1 Index to start the search for. (pagination)

Example command without pagination:

Get Offer History by Issuer

Example command:

  • account06 Issuer

  • 10 Number of items per fetch (Pagination)

  • 2.24.1 Index to start the search for. (pagination)

Example command without pagination:

Get Offer History by NFT Item

Example Command:

  • 1.31.0 NFT Id

  • 10 Number of items per fetch (Pagination)

  • 2.24.1 Index to start the search for. (pagination)

Example command without pagination:

Get Offer History by Bidder

Example Command:

  • account07 Bidder

  • 10 Number of items per fetch (Pagination)

  • 2.24.1 Index to start the search for. (pagination)

Example command without pagination:

HRP User Authorities

Hierarchical role based permissions is a feature of Peerplays blockchain which helps in increasing the security of user accounts.

Users don’t have to use their active and owner keys for everything they do on the chain.

They can create role based custom permissions and map them to different keys other than active and owner keys.

They can then use these custom keys to sign transactions.

Create Custom Permissions

  • owner Owner of the account who is creating the custom permission

  • permission_name Permission name, eg. nftcreatepermission

  • auth authority is account authority, more info at , ,

Example Command:

{ "weight_threshold": 1, "account_auths": [["1.2.52",1]], "key_auths": [["TEST71ADtL4fzjGKErk9nQJrABmCPUR8QCjkCUNfdmgY5yDzQGhwto",1]], "address_auths": [] }

This represents an authority structure, account_auths represent the amount of weight each accounts have on our account, in this example 1.2.52 has weight 1

key_auths represent the amount of weight each public key has on this account, in this example TEST71ADtL4fzjGKErk9nQJrABmCPUR8QCjkCUNfdmgY5yDzQGhwto has weight 1

Weight_threshold represent the required weight for a transaction to be signed successfully.

In this example either 1.2.52 can sign with his active key or TEST71ADtL4fzjGKErk9nQJrABmCPUR8QCjkCUNfdmgY5yDzQGhwto can be used to sign a transaction successfully.

Get Custom Permissions

Example Command,

Update Custom Permissions

Example Command:

Here we removed the key_auths and added 1.2.53 with weight 1, which is equal to weight_threshold , so 1.2.53 can alone sign the transaction successfully.

Create Custom Account Authority

Creating custom authority maps the created custom permissions with the actual operations present on the blockchain.

It also has expiry time by when this custom permission is no more valid on any given account and operation combination.

Example Command:

account01 is the owner of the account and the one who created a permission 1.27.0

1.27.0 is the custom permission created

0 is the operation number, refer to operations at , here 0 is transfer_operation

"2020-11-02T17:53:25" valid from timestamp

"2020-12-03T17:53:25" valid to timestamp

true broadcast

Basically this represents a full HRP where transfer operation on account01 can be done by authorities present in 1.27.0 instead of account owner account01

Update Custom Account Authority

Can be used to update existing valid_from and valid_to times,

Example command:

Delete Custom Permission

Used to delete the existing custom permission, this will delete all the custom account authorities linked to this permission as well.( cascading delete )

Example command:

Delete Custom Account Authority

Used to delete an account authority attached to a permission.

Example command:

Resource Permissions ( Account Roles )

As opposed to HRP mentioned above, resource permissions are controlled by an owner of a resource (eg. NFT metadata is a resource).

These are similar to IAM permissions in AWS Cloud environment.

Create Account Role

Used to create an account role.

owner_account_id_or_name resource owner Eg. account creating an NFT Metadata resource

name name of the account role Eg. Movie Interstellar Permissions

metadata metadata for additional info Eg. Some JSON struct or an external URL with info

allowed_operations allowed operations that whitelisted_accounts can perform on this resource.

whitelisted_accounts All the accounts that can perform any allowed_operations on a resource

valid_to exports time of the account role, valid from is the time of creation of the account role

broadcast broadcast mentioned above

Currently valid allowed_operations are

offer_operation(88), Checks if the user who is listing an NFT for sale is in whitelisted_accounts , if not the user can’t list the NFTs in marketplace.

bid_operation(89), Checks if the user who is bidding for an NFT on sale is in whitelisted_accounts , if not the user can’t bid / buy the NFT from marketplace.

nft_safe_transfer_from_operation (95), Checks if the user who transferring i.e. owner is in whitelisted_accounts, if yes it checks the to-account is also in the whitelisted_accounts. If any of the two checks fail, the transfer fails.

More operations like NFT Lottery, RNG are to be attached to account roles.

Example Command:

This command effectively limits any NFT to be sold or transferred between only three accounts, 1.2.40, 1.2.41, 1.2.43

For attaching NFT metadata to an account role, please refer to the above NFT sections.

Get Account Roles

Example command:

Update Account Role

As a resource owner, one can update the operations and whitelisted accounts present in an account role.

This helps in blacklisting any users from selling or transferring NFTs or any resources.

operations_to_add new operations to add to the account role

operations_to_remove existing operations to remove from the account role

accounts_to_add new accounts to add to the whitelist

accounts_to_remove existing accounts to remove from the whitelist

Example command:

88 offer_operation(88) is added

95 nft_safe_transfer_from_operation is removed

1.2.42 account to the whitelist

1.2.40 account removed from the whitelist

Delete Account Role

Once account role is deleted, restrictions on resource access no longer work.

Example command:

Fee Considerations

PPY is the core token of peerplays blockchain. Blockchain users can issue their own tokens with a conversion rate to core token.

In the Peerplays blockchain, every operation executed has a fee associated with it. The majority of these fees go as payments to witnesses that run the blockchain. These fees are called transaction fees and are collected in core (PPY) tokens only.

There is also a fee for storing any data on the blockchain like metadata or names.

Currently for the operations related to NFT, Marketplace, HRP, and Account Roles:

These values are subject to change by committee members.

NFT Notes

  • In order to create an NFT, a metadata has to be created first.

  • Only the owner of the metadata can mint NFTs

  • These NFTs can be assigned to any user of metadata owner’s choice.

  • NFT Metadata owner is the owner of the metadata that mints the NFTs,

Marketplace Notes

  • Peerplays blockchain operates the marketplace through offer_operation, bid_operation, cancel_offer_operation, finalize_offer_operation operations/smart contracts.

  • Offers operate as an auction where max bid before the expiry time owns the NFT

Use Cases

Movie Tickets (For Blockchain Savvy Users)

  • I’m the owner of a movie theater where there is a premiere show for a movie Interstellar.

  • I create NFT metadata for Interstellar movie that has basic info about the genre, running time, movie posters etc

  • To maximize my profit and take a cut from the black market ticket sales, I created the metadata of the movie is_transferable to false and is_sellable to true

NFT Lottery with Geolocation restrictions (Account Roles/ Resource Permission use case)

  • I’m the issuer of the lottery which has geo restrictions saying the lottery can only be sold to residents of the state New South Wales(NSW) in Australia.

  • I do the KYC check off chain and list down all the users on the blockchain that are residents of the state.

  • While creating NFT metadata I attach the account roles with the whitelist of users along with is_transferable to true and is_sellable to false.

University Degrees

  • I’m the university issuing degrees to students that complete masters degree in two streams science and arts.

  • I create two NFT metadata one each for both Science and Arts.

  • I make both is_transferable to false and is_sellable to false.

Minting NFTs (For not so Blockchain Savvy Users)

  • I’m the owner of an NFT Metadata and my DAPP users are not blockchain savvy.

  • I mint the NFTs to my account itself.

  • I modify the URI of NFTs accordingly off chain to denote the ownership.

Example NFT creation

Core coin : PPY for fee

Purchase/Sell/Transaction token for NFTs : ava-token

PPY:ava-token = 1:10000

nft_metadata_create(string owner_account_id_or_name, string name, string symbol, string base_uri, optional<string> revenue_partner, optional<uint16_t> revenue_split, bool is_transferable, bool is_sellable, optional<account_role_id_type> role_id, bool broadcast)
nft_metadata_create account01 "AVALON NAME" "AVALON SYMBOL" "AVALON BASE URI" account02 100 false true null true
[88,89,90,95] is the list of operations this permission whitelists for accounts. 88 - List Offer operation in marketplace 89 - Bid operation in marketplace 90 - Cancel Offer operation in marketplace 95 - Safe transfer from owner to another NFT
  • [1.2.40, 1.2.41] List of accounts whitelisted for the above operations. Offer, bid and transfer operations can only be among the whitelisted accounts.

  • "2020-11-04T13:43:39" Expiry date of the permission

  • true broadcast, keep it true to include the transaction in upcoming block.

  • account02 is the approved account of the NFT, can be the owner as well.
  • "AVALON NFT URI"is the URI that has additional information about this NFT.

  • "Enjoy my NFT"is the metadata of the transfer

  • true is broadcast option mentioned above.

  • {"amount":10000,"asset_id":"1.3.0"} maximum bid price expected

  • false buying_item denotes if this is an auction or reverse auction

  • "2020-08-18T11:05:39" Listing expiry date

  • null Optional metadata, if not null assign a string value

  • true broadcast value mentioned above

  • true broadcast value mentioned above
    NFT owner
    is the one who is assigned an NFT by metadata owner after minting.
  • User who is not the metadata owner cannot mint NFTs to himself

  • is_transferable and is_sellable flags configured on metadata control the transfer and selling properties of all the NFTs minted from the metadata.

  • If is_transferable is false and is_sellable is true, then the NFT owner can only list it in marketplace and sell it. He can’t transfer to another user.

  • If is_transferable is true and is_sellable is false, then the NFT owner cannot list it in marketplace and he can freely transfer it to other users.

  • If is_transferable is false and is_sellable is false, then the NFT owner can neither be transfer nor sell the NFT. It remains with him forever.

  • If max_price is equal to min_price in offer_operation it acts as normal listing. Whoever bids the max_price gets the NFT instantly.
  • For a successful bid, revenue_partner gets the revenue_split percent of the bid. This is configured during NFT metadata creation. So for all the NFT sales that are based on the metadata, revenue_partner gets the cut.

  • Currently peerplays stakeholders don’t get the cut, this will be implemented in the future.

  • Currently there is only one marketplace i.e. Peerplays blockchain is providing a marketplace where any owner can sell his NFT based on the configuration of the parent metadata.

  • Metadata owner can customize this marketplace in the UI to show only the NFTs minted from his own metadata to his DAPP users.

  • So there are no multiple marketplaces on peerplays blockchain at the moment, only UI customization are possible.

  • Price can be set in terms of custom assets (tokens) in market place. In this case both offers and bids should be in the same asset (token). Eg. Offer price is in XCOIN token, then bid price should also be in XCOIN token.

  • I accept payment on the blockchain in multiple currencies namely PPY, XCOIN and BTC (or some off chain mechanism in FIAT currencies like USD)

  • I mint the tickets as NFTs to the users who sent me the amount in the above currencies. Users can gain entry to the movie only with these NFT tickets.

  • Users cannot transfer the tickets among themselves, they can only list them on marketplace.

  • As the demand for tickets increase, listing price increase, so I get more cut for every ticket sold.

  • I create a smart contract for minting NFTs from the metadata created.

  • This smart contract accesses the account role associated with the metadata.

  • If any user is not whitelisted he can’t purchase the NFT lottery ticket from the smart contract.

  • If the user is whitelisted and minted a lottery ticket, he can’t transfer it to non-whitelisting users who are not residents of NSW.

  • I create a draw and declare the owner of NFT as winner.

  • I mint NFT accordingly based on the stream to each student.

  • Each NFT (degree) has the info about the student grades, courses etc.

  • These NFTs (degrees) stays with the students (users) forever, they can’t be transferred or sold.

  • permissions
    public/private keys
    multi authority
    operations
    create_account_role(string owner_account_id_or_name, string name, string metadata, flat_set<int> allowed_operations, flat_set<account_id_type> whitelisted_accounts, time_point_sec valid_to, bool broadcast)
    create_account_role account01 "Avalon Permissions1" "Permission Metadata" [88,89,90,95] [1.2.40, 1.2.41] "2020-11-04T13:43:39" true
    nft_metadata_create account01 "AVALON NAME" "AVALON SYMBOL" "AVALON BASE URI" account02 100 false true 1.32.0 true
    nft_create(string metadata_owner_account_id_or_name, nft_metadata_id_type metadata_id, string owner_account_id_or_name, string approved_account_id_or_name, string token_uri, bool broadcast)
    nft_create account01 1.30.0 account02 account02 "AVALON NFT URI" true
    nft_safe_transfer_from(string operator_account_id_or_name, string from_account_id_or_name, string to_account_id_or_name, nft_id_type token_id, string data, bool broadcast)
    nft_safe_transfer_from account02 account02 account03 1.31.0 "Enjoy my NFT" true
    create_offer(set<nft_id_type> item_ids, string issuer_accound_id_or_name, asset minimum_price, asset maximum_price, bool buying_item, time_point_sec offer_expiration_date, optional<memo_data> memo, bool broadcast)
    create_offer ["1.31.0","1.31.1"] account02 {"amount":100,"asset_id":"1.3.0"} {"amount":10000,"asset_id":"1.3.0"} false "2020-08-18T11:05:39" null true 
    create_bid(string bidder_account_id_or_name, asset bid_price, offer_id_type offer_id, bool broadcast)
    create_bid account04 {"amount":10000,"asset_id":"1.3.0"} 1.29.0 true
    cancel_offer(string issuer_account_id_or_name, offer_id_type offer_id, bool broadcast)
    cancel_offer account02 1.29.0 true
    list_offers(uint32_t limit, optional<offer_id_type> lower_id)
    list_offers 100 1.29.0
    list_offers 100 null
    list_sell_offers(uint32_t limit, optional<offer_id_type> lower_id)
    list_sell_offers 10 1.29.6
    list_sell_offers 10 null
    list_buy_offers(uint32_t limit, optional<offer_id_type> lower_id)
    list_buy_offers 10 1.29.6
    list_buy_offers 10 null
    list_offer_history(uint32_t limit, optional<offer_history_id_type> lower_id)
    list_offer_history 10 2.24.2
    list_offer_history 10 null
    get_offers_by_issuer(string issuer_account_id_or_name, uint32_t limit, optional<offer_id_type> lower_id)
    get_offers_by_issuer account02 10 1.29.0
    get_offers_by_issuer account02 10 null
    get_offers_by_item(const nft_id_type item, uint32_t limit, optional<offer_id_type> lower_id)
    get_offers_by_item 1.31.0 10 1.29.1
    get_offers_by_item 1.31.0 10 null
    get_offer_history_by_issuer(string issuer_account_id_or_name, uint32_t limit, optional<offer_history_id_type> lower_id)
    get_offer_history_by_issuer account06 10 2.24.1
    get_offer_history_by_issuer account06 10 null
    get_offer_history_by_item(const nft_id_type item, uint32_t limit, optional<offer_history_id_type> lower_id)
    get_offer_history_by_item 1.31.0 10 2.24.1
    get_offer_history_by_item 1.31.0 10 null
    get_offer_history_by_bidder(string bidder_account_id_or_name, uint32_t limit, optional<offer_history_id_type> lower_id)
    get_offer_history_by_bidder account07 10 2.24.1
    get_offer_history_by_bidder account07 10 null
     create_custom_permission(string owner, string permission_name, authority auth, bool broadcast)
    create_custom_permission account01 perm1 { "weight_threshold": 1,  "account_auths": [["1.2.52",1]], "key_auths": [["TEST71ADtL4fzjGKErk9nQJrABmCPUR8QCjkCUNfdmgY5yDzQGhwto",1]], "address_auths": [] } true
    get_custom_permissions(string owner)
    get_custom_permissions account01
    update_custom_permission(string owner, custom_permission_id_type permission_id, fc::optional<authority> new_auth, bool broadcast)
    update_custom_permission account01 1.27.0 { "weight_threshold": 1,  "account_auths": [["1.2.53",1]], "key_auths": [], "address_auths": [] } true
    create_custom_account_authority(string owner, custom_permission_id_type permission_id, int operation_type, fc::time_point_sec valid_from, fc::time_point_sec valid_to, bool broadcast)
    create_custom_account_authority account01 1.27.0 0 "2020-11-02T17:53:25" "2020-12-03T17:53:25" true
    update_custom_account_authority(string owner, custom_account_authority_id_type auth_id, fc::optional<fc::time_point_sec> new_valid_from, fc::optional<fc::time_point_sec> new_valid_to, bool broadcast)
    update_custom_account_authority account01 1.28.0 "2020-06-02T17:52:25" "2020-06-03T17:52:25" true
    delete_custom_permission(string owner, custom_permission_id_type permission_id, bool broadcast)
    delete_custom_permission account01 1.27.0 true
    delete_custom_account_authority(string owner, custom_account_authority_id_type auth_id, bool broadcast)
    delete_custom_account_authority account01 1.28.0 true
    create_account_role(string owner_account_id_or_name, string name, string metadata, flat_set<int> allowed_operations, flat_set<account_id_type> whitelisted_accounts, time_point_sec valid_to, bool broadcast)
    create_account_role account01 ar1 ar1 [89,95] [1.2.40, 1.2.41, 1.2.43] "2020-09-04T13:43:39" true
    get_account_roles_by_owner(string owner_account_id_or_name)
    get_account_roles_by_owner account01
    update_account_role(string owner_account_id_or_name, account_role_id_type role_id, optional<string> name, optional<string> metadata, flat_set<int> operations_to_add, flat_set<int> operations_to_remove, flat_set<account_id_type> accounts_to_add, flat_set<account_id_type> accounts_to_remove, optional<time_point_sec> valid_to, bool broadcast)
    update_account_role account01 1.32.0 null null [88] [95] [1.2.42] [1.2.40] "2020-09-04T13:52:38" true
    delete_account_role(string owner_account_id_or_name, account_role_id_type role_id, bool broadcast)
    delete_account_role account01 1.32.0 true
     ID     Operation Name                              Fees (in PPY)
     82	custom_permission_create_operation__________0.005 + 0.01 per Kb data
     83	custom_permission_update_operation__________0.005
     84	custom_permission_delete_operation__________0.005
     85	custom_account_authority_create_operation___0.005 + 0.01 per Kb data
     86	custom_account_authority_update_operation___0.005
     87	custom_account_authority_delete_operation___0.005
     88	offer_operation_____________________________0.001 + 0.01 per Kb data
     89	bid_operation_______________________________0.001
     90	cancel_offer_operation______________________0.001
     91	finalize_offer_operation____________________0.0 (Free!)
     92	nft_metadata_create_operation_______________0.1  + 0.01 per Kb data
     93	nft_metadata_update_operation_______________0.1
     94	nft_mint_operation__________________________0.01 + 0.01 per Kb data
     95	nft_safe_transfer_from_operation____________0.01 + 0.01 per Kb data
     96	nft_approve_operation_______________________0.005
     97	nft_set_approval_for_all_operation__________0.005
     98	account_role_create_operation_______________1.0  + 1.00 per Kb data
     99	account_role_update_operation_______________1.0  + 1.00 per Kb data
     100	account_role_delete_operation_______________1.0