Smartcontract documentation for onboarding
The onboarding contract is responsible for managing the invitations for ambassadors, bioregions and organizations.
Here's the process for ambassadors invitations:
- to initiate an invitation, push action `invite` with paramenters `[sponsor, transfer_quantity, sow_quantity, invite_hash]`
- the receiving user then pushes action `accept` with parameters `[account, invite_secret=invite_hash, publicKey]`
Actions
- accept / accept Accepts an invitation invite using already existing account or creating new account, based on provided `invite_secret`.
- acceptexist / acceptexist Accepts an invitation using existing account.
- acceptnew / acceptnew Accepts an invitation creating a new account.
- addauthorized / addauthorized
- campinvite / campinvite
- cancel / cancel Cancels an invitation based on `invite_hash`.
- cleanup / cleanup Cleanup very old invites
- createcampg / createcampg
- createregion / createregion
- deposit / deposit Deposit funds using another account as sponsor account
- invite / invite Creates an invitation, specifying the `sponsor`, `transfer_quantity`, `sow_quantity`(planted amount) and the unique `invite_hash`
- invitefor / invitefor Invite in the name of the referer account.
- onboardorg / onboardorg Onboards a new organization.
- remauthorized / remauthorized
- reset / reset
- returnfunds / returnfunds
- rtrnfundsaux / rtrnfundsaux
Events
Tables
ABI Extensions
Structs
accept
- account / name
- invite_secret / checksum256
- publicKey / string
acceptexist
- account / name
- invite_secret / checksum256
- publicKey / string
acceptnew
- account / name
- invite_secret / checksum256
- publicKey / string
- fullname / string
addauthorized
- id / uint64
- account / name
campaign_invite_table
- invite_id / uint64
- campaign_id / uint64
campaign_table
- campaign_id / uint64
- type / name
- origin_account / name
- owner / name
- max_amount_per_invite / asset
- planted / asset
- reward_owner / name
- reward / asset
- authorized_accounts / name[]
- total_amount / asset
- remaining_amount / asset
campinvite
- id / uint64
- authorizing_account / name
- planted / asset
- quantity / asset
- invite_hash / checksum256
cancel
- sponsor / name
- invite_hash / checksum256
cleanup
- start_id / uint64
- max_id / uint64
- batch_size / uint64
config_table
- param / name
- value / uint64
- description / string
- impact / name
createcampg
- origin_account / name
- owner / name
- max_amount_per_invite / asset
- planted / asset
- reward_owner / name
- reward / asset
- total_amount / asset
- proposal_id / uint64
createregion
- sponsor / name
- region / name
- publicKey / string
deposit
- from / name
- to / name
- quantity / asset
- memo / string
invite
- sponsor / name
- transfer_quantity / asset
- sow_quantity / asset
- invite_hash / checksum256
invite_table
- invite_id / uint64
- transfer_quantity / asset
- sow_quantity / asset
- sponsor / name
- account / name
- invite_hash / checksum256
- invite_secret / checksum256
invitefor
- sponsor / name
- referrer / name
- transfer_quantity / asset
- sow_quantity / asset
- invite_hash / checksum256
onboardorg
- sponsor / name
- account / name
- fullname / string
- publicKey / string
referrer_table
- invite_id / uint64
- referrer / name
remauthorized
- id / uint64
- account / name
reset
returnfunds
rtrnfundsaux
- account / name
- balance / asset