Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bsip#43 Market fee sharing #107

Merged
merged 6 commits into from
Oct 24, 2018
Merged
Show file tree
Hide file tree
Changes from 5 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,5 +49,6 @@ Number | Title |
[39](bsip-0039.md) | Automatically approve proposals by the proposer | Fabian Schuh | Protocol | Draft
[40](bsip-0040.md) | Custom active permission | Stefan Schießl | Protocol | Draft
[42](bsip-0042.md) | Adjust price feed to influence trading price of SmartCoins | Abit More | Protocol | Draft
[43](bsip-0043.md) | Market fee sharing | OpenLedgerApp | Protocol | Draft
[44](bsip-0044.md) | Hashed Time-Locked Contract | Ryan R. Fox | Protocol | Draft
[45](bsip-0045.md) | Introduce 'allow use as bitasset backing collateral' flag/permission to assets | Customminer | Protocol | Draft
[45](bsip-0045.md) | Introduce 'allow use as bitasset backing collateral' flag/permission to assets | Customminer | Protocol | Draft
64 changes: 64 additions & 0 deletions bsip-0043.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
BSIP: 0043
Title: Market fee sharing
Authors: OpenLedgerApp <https://github.com/OpenLedgerApp>
Status: Draft
Type: Protocol
Created: 2018-08-23
Updated: 2018-10-19
Discussion: https://github.com/bitshares/bsips/issues/102
Worker:


# Abstract

When creating a new asset, the asset owner is the only beneficiary of the market fees in the current implementation. And one of the ways to increase the community growth is the market fee percentage. For example, one can decrease the market fee and it will result in somewhat larger number of trades with this asset. In this way the asset owner might get a bigger profit during to increasing the trade volume with this asset.

However, there might be another opportunity to promote the asset and stimulate the trading - use native Bitshares referral program. At this time unfortunately an assets owner is not able to share market fees with registrars and referrers to stimulate them to market the asset trading, so we suggest to add this possibility. Furthermore, enabling this feature for MPAs (e.g. bitCNY or bitUSD) can provide additional bounty for Bitshares registrars and referrals which can lead to more traders joining to the ecosystem.

An asset owner defines the **market_fee_reward_percent** in asset options - what percentage of the market fee he wants to share with the registrar.
**market_fee** * **market_fee_reward_percent** goes the registar's fee pool.
**market_fee** * (1 - **market_fee_reward_percent**) goes to the asset owner.
abitmore marked this conversation as resolved.
Show resolved Hide resolved


Registrar defines **reward_percent** - for the referrer for each user (using the already existing BitShares mechanism).

Market fee reward is accumulated on the user account.

Each user decides when he wants to claim the market fee reward and move it to their active balance.

# Motivation

To make promoting BitShares and bringing new users much more attractive to registrars and referrers by sharing UIAs and MPAs market fees with them.

# Rationale
When *fill_order_operation* executing at the moment of market fee calculation there will be calculate the reward for the registrar used the parameter **market_fee_reward_percent**. Then this **market_fee_reward_percent** of the market fee is split between the registrar and referrer according to the referrer_rewards_percentage, which is set up during the new account registration by registrar (please see the parameters for *register_account*).

# Specifications
Market fee rewards accumulated on special vesting balances.

## **market_fee_reward_percent** asset option
Percent of market fee that will be paid to buyer's registrar. Set by asset owner.
if **market_fee_reward_percent** = 0 or absent - the old mechanism is used. Market fees are accumulated in the asset and can be claimed.

## **market_sharing_whitelist** asset option
An optional list of accounts (configurable by the asset owner) could provide increased control over who is eligible to get market rewards.
If whitelist empty or absent - there is no filtering. This means that everyone is in the whitelist by default if it is empty.

## graphene::chain::database modifications
**pay_market_fees(seller, recv_asset_object, receives_amount)** - Split pay to asset owner fee, registrar fee and referrer fee. If the registrar is not in the **market_sharing_whitelist**, *split_pay* will not happen and the entire fee goes to Asset owner.
**calculate_market_fee(trade_asset, trade_amount)** - Calculate value for previous function.
**fill_limit_order(order, pays, receives, cull_if_small, fill_price, is_maker)** - Append hardfork (HARDFORK_REWARD_TIME) check. Use old or new version of *pay_market_fees()* function.

## asset_create_evaluator, asset_update_evaluator modifications
Append hardfork (HARDFORK_REWARD_TIME) check. Validate additional asset options. Apply additional asset options (**market_fee_reward_percent**, **market_sharing_whitelist**)

# Description

# Summary for Shareholders
The new modification - market fee sharing - will allow to bring in new clients for BitShares by making it financially lucrative for registrars and referrers. This modification is interesting mostly so asset owners and registrars/referrers.

# Copyright
This document is placed in the public domain.

# See Also
https://github.com/bitshares/bitshares-core/issues/1268