Subscriptions
Status: Draft
Last updated
Was this helpful?
Status: Draft
Last updated
Was this helpful?
Subscriptions contracts manage the on ramp to the platform, charging participants an amount of DAI, and letting them participate in the platform with fresh new . They work as a slightly modified version of an , additionally issuing an amount of tokens to subscribers. They will be deeply interconnected with the cron contract, automatically identifying if a payment was done for a month, or another, thus moving the tokens to the competition bounty pool.
The Subscription contract has the ability to issue new P+ tokens every time it receives new subscription. In order to do that, the P+ token will delegate the issuance ability to this Smart Contract.
The subscription contract (open to public in v2) will enable users to subscribe Monthly to Helena, to have access to our prediction markets. The following simple generic interface will be used in order to subscribe to our contract:
Where:
The subscribe
function enable gives access (via approve
) to the pool to take DAI every epoch
Execute
is an external function called by our services to redirect DAI to the epoch Pool
setTarget
: sets the target contract to be executed whenever the payment is received. In Helena, this will mean
This contract takes the ownership of the issue function on P+, creating fresh new tokens if a successful execution comes from the susbcription contract, and letting the user participate in the prediction markets for a month.