/** * This is the doc comment for pallet `Treasury`'s calls. * * `Treasury`'s storages: {@link: module:pangolin/treasury/storages} * * @module pangolin/treasury/calls */ import { Dispatch } from "../../../index"; import { ethers, BytesLike } from "ethers"; import { Metadata } from "@polkadot/types"; export declare const getTreasury: (dispatch: Dispatch, metadata: Metadata) => { /** * Put forward a suggestion for spending. A deposit proportional to the value * is reserved and slashed if the proposal is rejected. It is returned once the * proposal is awarded. * * ## Complexity * - O(1) * * @param {unknown} _value Compact * @param {unknown} _beneficiary [U8; 20] * @instance */ proposeSpend: (signer: ethers.Signer, _value: unknown, _beneficiary: unknown) => Promise; /** * Similar to {@link: pangolin/treasury/calls/proposeSpend}, but with scale encoded args. * * @param {BytesLike} argsBytes the args bytes * @instance */ proposeSpendH: (signer: ethers.Signer, argsBytes: BytesLike) => Promise; /** * Build a call object to be used as a call param in other functions, such as `utilities.batchAll`. * * @returns {CallAsParam} */ buildProposeSpendCall: (_value: unknown, _beneficiary: unknown) => import("../../../index").CallAsParam; /** * Build a call object to be used as a call param in other functions, such as `utilities.batchAll`. * Similar to buildProposeSpendCall, but with scale encoded args. * * @returns {CallAsParam} */ buildProposeSpendCallH: (argsBytes: BytesLike) => import("../../../index").CallAsParam; /** * Reject a proposed spend. The original deposit will be slashed. * * May only be called from `T::RejectOrigin`. * * ## Complexity * - O(1) * * @param {unknown} _proposal_id Compact * @instance */ rejectProposal: (signer: ethers.Signer, _proposal_id: unknown) => Promise; /** * Similar to {@link: pangolin/treasury/calls/rejectProposal}, but with scale encoded args. * * @param {BytesLike} argsBytes the args bytes * @instance */ rejectProposalH: (signer: ethers.Signer, argsBytes: BytesLike) => Promise; /** * Build a call object to be used as a call param in other functions, such as `utilities.batchAll`. * * @returns {CallAsParam} */ buildRejectProposalCall: (_proposal_id: unknown) => import("../../../index").CallAsParam; /** * Build a call object to be used as a call param in other functions, such as `utilities.batchAll`. * Similar to buildRejectProposalCall, but with scale encoded args. * * @returns {CallAsParam} */ buildRejectProposalCallH: (argsBytes: BytesLike) => import("../../../index").CallAsParam; /** * Approve a proposal. At a later time, the proposal will be allocated to the beneficiary * and the original deposit will be returned. * * May only be called from `T::ApproveOrigin`. * * ## Complexity * - O(1). * * @param {unknown} _proposal_id Compact * @instance */ approveProposal: (signer: ethers.Signer, _proposal_id: unknown) => Promise; /** * Similar to {@link: pangolin/treasury/calls/approveProposal}, but with scale encoded args. * * @param {BytesLike} argsBytes the args bytes * @instance */ approveProposalH: (signer: ethers.Signer, argsBytes: BytesLike) => Promise; /** * Build a call object to be used as a call param in other functions, such as `utilities.batchAll`. * * @returns {CallAsParam} */ buildApproveProposalCall: (_proposal_id: unknown) => import("../../../index").CallAsParam; /** * Build a call object to be used as a call param in other functions, such as `utilities.batchAll`. * Similar to buildApproveProposalCall, but with scale encoded args. * * @returns {CallAsParam} */ buildApproveProposalCallH: (argsBytes: BytesLike) => import("../../../index").CallAsParam; /** * Propose and approve a spend of treasury funds. * * - `origin`: Must be `SpendOrigin` with the `Success` value being at least `amount`. * - `amount`: The amount to be transferred from the treasury to the `beneficiary`. * - `beneficiary`: The destination account for the transfer. * * NOTE: For record-keeping purposes, the proposer is deemed to be equivalent to the * beneficiary. * * @param {unknown} _amount Compact * @param {unknown} _beneficiary [U8; 20] * @instance */ spend: (signer: ethers.Signer, _amount: unknown, _beneficiary: unknown) => Promise; /** * Similar to {@link: pangolin/treasury/calls/spend}, but with scale encoded args. * * @param {BytesLike} argsBytes the args bytes * @instance */ spendH: (signer: ethers.Signer, argsBytes: BytesLike) => Promise; /** * Build a call object to be used as a call param in other functions, such as `utilities.batchAll`. * * @returns {CallAsParam} */ buildSpendCall: (_amount: unknown, _beneficiary: unknown) => import("../../../index").CallAsParam; /** * Build a call object to be used as a call param in other functions, such as `utilities.batchAll`. * Similar to buildSpendCall, but with scale encoded args. * * @returns {CallAsParam} */ buildSpendCallH: (argsBytes: BytesLike) => import("../../../index").CallAsParam; /** * Force a previously approved proposal to be removed from the approval queue. * The original deposit will no longer be returned. * * May only be called from `T::RejectOrigin`. * - `proposal_id`: The index of a proposal * * ## Complexity * - O(A) where `A` is the number of approvals * * Errors: * - `ProposalNotApproved`: The `proposal_id` supplied was not found in the approval queue, * i.e., the proposal has not been approved. This could also mean the proposal does not * exist altogether, thus there is no way it would have been approved in the first place. * * @param {unknown} _proposal_id Compact * @instance */ removeApproval: (signer: ethers.Signer, _proposal_id: unknown) => Promise; /** * Similar to {@link: pangolin/treasury/calls/removeApproval}, but with scale encoded args. * * @param {BytesLike} argsBytes the args bytes * @instance */ removeApprovalH: (signer: ethers.Signer, argsBytes: BytesLike) => Promise; /** * Build a call object to be used as a call param in other functions, such as `utilities.batchAll`. * * @returns {CallAsParam} */ buildRemoveApprovalCall: (_proposal_id: unknown) => import("../../../index").CallAsParam; /** * Build a call object to be used as a call param in other functions, such as `utilities.batchAll`. * Similar to buildRemoveApprovalCall, but with scale encoded args. * * @returns {CallAsParam} */ buildRemoveApprovalCallH: (argsBytes: BytesLike) => import("../../../index").CallAsParam; };