How to implement 'Pay based on usage' payment method to your product's check out page
Last updated
Last updated
Add DePlan logo and add text below:
Deposit monthly fee into smart-contract escrow.
Use the product and control usage.
Get refunded at the end of the month depending on usage.
View examples bellow
Watch video below how to create account on DePlan Connect
Create ID of your product (product_username)
Add Product Name
Add Product Logo
Add website with info about the product
Provide price per month
Provide the link to the product itself
Make sure you provided the link to the product and website with the product's info
When you’re done press ‘Next’
Watch video below how to add you product on DePlan Connect
Examples:
Upload data
Download data
Play content
Save content
Export file
Import file
View content
Open project
Create project
AI request
Time
or others
Provide us with a webhook url that will be called once user confirmes subscription, the endpoint has to accept POST requests with "application/json" content type. It will be passed your custom data and "deplanUserWallet" string in the body
When user chooses DePlan as a subscription method, you should navigate them to https://deplan.app?orgId=&redirectUrl=&data=
Params
orgWallet - wallet address of your organization from step 6
redirectUrl - where to redirect a user once they have confirmed subscription in DePlan
data - custom key/value pairs data as JSON string, that will be passed to your webhook, e.g. a user id in your system, so that you can identify the user and set their "deplanUserWallet"
Now your user is connected with their account in DePlan and you can save events by making a POST request to https://deplan-560eb4c67350.herokuapp.com/events
Request body
orgWallet - wallet address of your organization from step 6
userWallet - deplanUserWallet string
typeEvent - event name string