Extrinsics
The following sections contain Extrinsics methods are part of the default runtime. On the api, these are exposed via api.tx.<module>.<method>.
Control
create_org(name: String, cid: String, org_type: OrgType, access_model: AccessModel, fee_model: FeeModel, member_limit: Option<MemberLimit>, membership_fee: Option<Balance>, gov_currency: Option<CurrencyId>, pay_currency: Option<CurrencyId>, deposit: Option<Balance>)
String, cid: String, org_type: OrgType, access_model: AccessModel, fee_model: FeeModel, member_limit: Option<MemberLimit>, membership_fee: Option<Balance>, gov_currency: Option<CurrencyId>, pay_currency: Option<CurrencyId>, deposit: Option<Balance>)interface:
api.tx.control.create_orgsummary: Create an on chain organization
name: org name.cid: ipfs content identifier.org_type: individual | company | dao | hybrid.access_model:fee_model:member_limit: max members. default: maxmembers.membership_fee:gov_currency:pay_currency:deposit: initial deposit for the org treasury (in protocol tokens).
Emits
OrgCreatedevent when successful.Weight:
O(1)
update_org(org_id: Hash, prime_id: Option<AccountId>, org_type: Option<OrgType>, access_model: Option<AccessModel>, member_limit: Option<MemberLimit>, fee_model: Option<FeeModel>, membership_fee: Option<Balance>)
Hash, prime_id: Option<AccountId>, org_type: Option<OrgType>, access_model: Option<AccessModel>, member_limit: Option<MemberLimit>, fee_model: Option<FeeModel>, membership_fee: Option<Balance>)interface:
api.tx.control.update_orgsummary: Update Org
Allowed origins: Root or prime if OrgType::Individual
org_id: org hash.prime_id: new prime id.org_type:access_model: new access model.member_limit: new member limit.fee_model: new fee model.membership_fee: new membership fee.
Emits
OrgUpdatedevent when successful.Weight:
O(1)
enable_org(org_id: Hash)
Hash)interface:
api.tx.control.enable_orgsummary: Enable Org
Enables an Org to be used and changes it's state to Active. Allowed origins: Root or prime if OrgType::Individual
org_id: org hash.
Emits
OrgEnabledevent when successful.Weight:
O(1)
disable_org(org_id: Hash)
Hash)interface:
api.tx.control.disable_orgsummary: Disable Org
Disables an Org to be used and changes it's state to Inactive. Allowed origins: Root or prime if OrgType::Individual
org_id: org hash.
Emits
OrgDisabledevent when successful.Weight:
O(1)
add_member(org_id: Hash, who: AccountId)
Hash, who: AccountId)interface:
api.tx.control.add_membersummary: Add Member to Org
Allowed origins: Root or prime if OrgType::Individual
org_id: org id.who: account to be added.
Emits
MemberAddedevent when successful.Weight:
O(log n)
remove_member(org_id: Hash, who: AccountId)
Hash, who: AccountId)interface:
api.tx.control.remove_membersummary: Remove member from Org
Allowed origins: Root or prime if OrgType::Individual
org_id: org id.who: account to be removed.
Emits
MemberRemovedevent when successful.Weight:
O(log n)
spend_funds(org_id: Hash, currency_id: CurrencyId, beneficiary: AccountId, amount: Balance)
Hash, currency_id: CurrencyId, beneficiary: AccountId, amount: Balance)interface:
api.tx.control.spend_fundssummary: Make spending from the org treasury
Allowed origins: Root or prime if OrgType::Individual
org_id: org id.currency_id: currency to be spent.beneficiary: receiver account.amount: amount to be spent.
Emits
FundsSpendedevent when successful.Weight:
O(1)
Flow
create_campaign(org_id: Hash, admin_id: AccountId, name: BoundedVec<u8, StringLimit>, target: Balance, deposit: Balance, expiry: BlockNumber, protocol: FlowProtocol, governance: FlowGovernance, cid: BoundedVec<u8, StringLimit>, start: Option<BlockNumber>, token_symbol: Option<BoundedVec<u8, StringLimit>>, token_name: Option<BoundedVec<u8, StringLimit>>)
Hash, admin_id: AccountId, name: BoundedVec<u8, StringLimit>, target: Balance, deposit: Balance, expiry: BlockNumber, protocol: FlowProtocol, governance: FlowGovernance, cid: BoundedVec<u8, StringLimit>, start: Option<BlockNumber>, token_symbol: Option<BoundedVec<u8, StringLimit>>, token_name: Option<BoundedVec<u8, StringLimit>>)interface:
api.tx.flow.create_campaignsummary:
contribute(campaign_id: Hash, contribution: Balance)
Hash, contribution: Balance)interface:
api.tx.flow.contributesummary: Contribute to project
campaign_id:contribution:
Emits
CampaignContributedevent when successful.Weight: O(1)
Sense
create_entity(account_id: AccountId, cid: BoundedVec<u8, StringLimit>)
AccountId, cid: BoundedVec<u8, StringLimit>)interface:
api.tx.sense.create_entitysummary: Create a Sense Entity for the account.
account_id: account id.cid: ipfs content identifier.
Emits
EntityCreatedevent when successful.Weight:
O(1)
update_property(account_id: AccountId, property_type: PropertyType, value: u8)
AccountId, property_type: PropertyType, value: u8)interface:
api.tx.sense.update_propertysummary: Modifies a property of the account.
account_id: account id.property_type: property type (experience, reputation, trust).value: value to be incremented to property.
Emits
PropertyUpdatedevent when successful.Weight:
O(1)
Signal
proposal(proposal_type: ProposalType, org_id: Hash, title: BoundedVec<u8, StringLimit>, cid: BoundedVec<u8, StringLimit>, expiry: BlockNumber, majority: Majority, unit: Unit, scale: Scale, start: Option<BlockNumber>, quorum: Option<Permill>, deposit: Option<Balance>, campaign_id: Option<Hash>, amount: Option<Balance>, beneficiary: Option<AccountId>, currency_id: Option<CurrencyId>)
ProposalType, org_id: Hash, title: BoundedVec<u8, StringLimit>, cid: BoundedVec<u8, StringLimit>, expiry: BlockNumber, majority: Majority, unit: Unit, scale: Scale, start: Option<BlockNumber>, quorum: Option<Permill>, deposit: Option<Balance>, campaign_id: Option<Hash>, amount: Option<Balance>, beneficiary: Option<AccountId>, currency_id: Option<CurrencyId>)interface:
api.tx.signal.proposalsummary:
vote(proposal_id: Hash, approve: bool, deposit: Option<Balance>)
Hash, approve: bool, deposit: Option<Balance>)interface:
api.tx.signal.votesummary:
Last updated