-
Notifications
You must be signed in to change notification settings - Fork 6
Actions
- Admin actions
- Misc actions
- Sale actions
- Auction actions
- Buyoffer actions
- Template buyoffer actions
- RAM actions
None
Initializes the config table if it hasn't been initialized before, otherwise does nothing. Has to be called once after deploying the contract.
atomicmarket account.
Type | Name | Description |
---|---|---|
double | minimum_bid_increase | New minimum bid increase |
Set the minimum bid increase that will be stored in the config table.
atomicmarket account.
Type | Name | Description |
---|---|---|
string | new_version | New version |
Updates the version in the config table.
atomicmarket account.
Type | Name | Description |
---|---|---|
name | token_contract | Contract that the token is stored in |
symbol | token_symbol | Symbol of the token |
Adds a new TOKEN to the supported_tokens vector in the config.
atomicmarket account.
Type | Name | Description |
---|---|---|
name | delphi_pair_name | Name of the pair in the delphioracle account |
bool | invert_delphi_pair | If true, the price coming from the delphioracle is inverted |
symbol | listing_symbol | Symbol that the sales using this pair will be listed for |
symbol | settlement_symbol | Symbol that the sales using this pair will be paid in |
Adds a new SYMBOLPAIR to the supported_symbol_pairs vector in the config. See Sales for more details.
atomicmarket account.
Type | Name | Description |
---|---|---|
double | maker_market_fee | Fee that the maker market of a sale / auction will receive |
double | taker_market_fee | Fee that the taker market of a sale / auction will receive |
Sets the maker_market_fee and taker_market_fee values in the config.
atomicmarket account.
Type | Name | Description |
---|---|---|
name | creator | Creator of the marketplace. This account will get any fees generated. |
name | marketplace_name | Name of the marketplace |
Creates a new marketplace. See Creating a marketplace for more details.
<creator>
Type | Name | Description |
---|---|---|
name | owner | Account to withdraw balance from |
asset | token_to_withdraw | The token and amount to withdraw |
Withdraws a token from owner's balance
<owner>
Type | Name | Description |
---|---|---|
name | seller | Seller |
vector<uint64_t> | asset_ids | IDs of the assets to sell. They must all belong to the same collection. |
asset | listing_price | Listing price of the sale |
symbol | settlement_symbol | Symbol that the sale will be paid in. See Sales for more details. |
name | maker_marketplace | Name of the marketplace facilitating the listing. Can be left empty, then a default marketplace will be used. |
Announces a sale. The seller needs to own all of the assets specified in the asset_ids vector, they must all belong to the same collection and must all be transferable. See Sales for more details.
<seller>
Type | Name | Description |
---|---|---|
uint64_t | sale_id | ID of the sale to cancel |
Cancels a sale. If an offer for this sale has already been created by the seller which still exists, it is declined.
A sale is considered invalid if either an offer for it has been created in the past but has been cancelled by the seller, or if the seller does not own at least one of the assets listed in this sale. If a sale is invalid, no authorization is required to cancel it.
Seller of the sale if the sale is valid, otherwise none
Type | Name | Description |
---|---|---|
name | buyer | Buyer |
uint64_t | sale_id | ID of the sale to purchase |
uint64_t | intended_delphi_median | 0 when the sale is a direct sale, delphi median to use when the sale is a delphi sale. See Sales for more details |
name | taker_marketplace | Name of the marketplace facilitating the purchase. Can be left empty, then a default marketplace will be used. |
Purchases a sale. The price is deducted from the buyer's balance table entry.
If the sale is a direct sale (symbol of listing_price is the same as settlement_symbol), the intended_delphi_median must be 0.
Otherwise, intended_delphi_median is the delphi median to use for the sale. This value must be present in the delphioracle's datapoints table for the delphi pair used, otherwise the purchase action will throw.
This system (instead of e.g. always using the newest median in the delphioracle contract) is used in order to know for certain the price that will be paid for the asset at the time of signing the action.
<buyer>
Type | Name | Description |
---|---|---|
name | seller | Seller / Creator of the auction |
vector<uint64_t> | asset_ids | IDs of the assets to auction |
asset | starting_bid | Starting bid |
uint32_t | duration | Duration until the auction ends in seconds |
name | maker_marketplace | Name of the marketplace facilitating the listing. Can be left empty, then a default marketplace will be used. |
Announces an auction. The seller needs to own all of the assets specified in the asset_ids vector, they must all belong to the same collection and must all be transferable.
<seller>
Type | Name | Description |
---|---|---|
uint64_t | auction_id | ID of the auction to cancel |
Cancels an auction. An auction can only be cancelled if nobody has bid on it yet. If the seller has already transferred the assets for this auction to the AtomicMarket account, they are sent back.
An auction is considered invalid if the assets have not yet been transferred to the AtomicMarket account and the seller does not own at least one of the assets listed in this auction. If an auction is invalid, no authorization is required to cancel it.
Seller / Creator of the auction if the auction is valid, otherwise none
Type | Name | Description |
---|---|---|
name | bidder | Bidder |
uint64_t | auction_id | ID of the auction to bid on |
asset | bid | Bid to place |
name | taker_marketplace | Name of the marketplace facilitating the bid. Can be left empty, then a default marketplace will be used. |
Places a bid on an auction.
If the auction has no previous bidders, the bid must be at least as big as the starting bid (stored in the current_bid field).
If the auction has a previous bidder, the bid must be bigger than the previous bid by at least minimum_bid_increase (stored in the config singleton).
If the auction would end in less than auction_reset_duration seconds (stored in the config singleton), the auction's end time is set to auction_reset_duration seconds in the future.
<bidder>
Type | Name | Description |
---|---|---|
uint64_t | auction_id | ID of the auction to claim the assets of |
Claims the assets won in an auction as the highest bidder.
The buyer / highest bidder of the auction
Type | Name | Description |
---|---|---|
uint64_t | auction_id | ID of the auction to claim the tokens of |
Claims the tokens won in an auction as the seller.
The seller / creator of the auction
Type | Name | Description |
---|---|---|
uint64_t | buyoffer_id | ID of the buyoffer |
vector<uint64_t> | expected_asset_ids | Asset IDs included in the buyoffer |
asset | expected_price | Price of the buyoffer |
name | taker_marketplace | Name of the marketplace facilitating the purchase. Can be left empty, then a default marketplace will be used. |
Accepts a buyoffer. The assets and price must match the ones specified in the buyoffer. See Buyoffers for more details.
<recipient>
Type | Name | Description |
---|---|---|
uint64_t | buyoffer_id | ID of the buyoffer |
Cancels a buyoffer.
<buyer>
Type | Name | Description |
---|---|---|
name | buyer | Buyer |
name | recipient | Owner of the assets |
asset | price | Price of the buyoffer |
vector<uint64_t> | asset_ids | IDs of the assets |
string | memo | Message for the recipient (256 chars max) |
name | maker_marketplace | Name of the marketplace facilitating the listing. Can be left empty, then a default marketplace will be used. |
Creates a buyoffer. The recipient needs to own all the assets specified in the asset_ids vector, they must all belong to the same collection and must all be transferable. See Buyoffers for more details.
<buyer>
Type | Name | Description |
---|---|---|
uint64_t | buyoffer_id | IDs of the buyoffer |
string | decline_memo | Message for buyer |
Declines a buyoffer.
<recipient>
Type | Name | Description |
---|---|---|
uint64_t | buyoffer_id | ID of the template buyoffer |
Cancels a template buyoffer.
<buyer>
Type | Name | Description |
---|---|---|
name | buyer | Buyer |
asset | price | Price of the buyoffer |
name | collection_name | Collection name of the template |
uint64 | template_id | Template ID to buy |
name | maker_marketplace | Name of the marketplace facilitating the listing. Can be left empty, then a default marketplace will be used. |
Creates a template buyoffer. See Template Buyoffers for more details.
<buyer>
Type | Name | Description |
---|---|---|
name | seller | Seller, owner of the template |
uint64_t | buyoffer_id | ID of the template buyoffer |
uint64_t | asset_id | Asset ID to be sold |
asset | expected_price | Price of the buyoffer |
name | taker_marketplace | Name of the marketplace facilitating the purchase. Can be left empty, then a default marketplace will be used. |
Fulfills a buyoffer. The price and the asset's template_id must match the ones specified in the template buyoffer. See Template Buyoffers for more details.
<seller>
Type | Name | Description |
---|---|---|
name | payer | Account that will pay for the RAM |
uint64_t | sale_id | ID of the sale to pay the RAM for |
Pays for the RAM costs of a sale. This is useful e.g. for dapps that want to pay the RAM of sales of assets of their collection by running an off-chain script that automatically calls this action.
<payer>
Type | Name | Description |
---|---|---|
name | payer | Account that will pay for the RAM |
uint64_t | auction_id | ID of the auction to pay the RAM for |
Pays for the RAM costs of an auction. This is useful e.g. for dapps that want to pay the RAM of auctions of assets of their collection by running an off-chain script that automatically calls this action.
<payer>
Type | Name | Description |
---|---|---|
name | payer | Account that will pay for the RAM |
uint64_t | buyoffer_id | ID of the buyoffer to pay the RAM for |
Pays for the RAM costs of a buyoffer. This is useful e.g. for dapps that want to pay the RAM of auctions of assets of their collection by running an off-chain script that automatically calls this action.
<payer>
Marketplace for atomicassets.io - developed with ❤️ by pink.network