Note this constructor should not be called directly. Use getPod()
instead.
Can be either podId or safe address
Mints and burns members simultaneously.
Burns member(s) from this pod, or returns an unsigned transaction to do so.
Can be a single address or an array of addresses
If a signer is provided, then the tx will execute. Otherwise, an unsigned transaction will be returned.
Calls a Pod method via a persona.
The persona object can be fetched by using Pod.getPersonas(address)
E.g.,
callAsPersona(
pod.mintMember,
[newMember],
{ type: 'admin', address: userAddress },
signer,
)
The sender must be a signer in the admin case, or the address of the sender. The sender must be a member of the relevant pod.
Changes the threshold for the safe associated with this pod. If a signer is provided, it will execute the transaction. Otherwise it will return the unsigned tx.
new threshold
Signer of admin
Creates a reject proposal at a given nonce, mostly used to un-stuck the transaction queue
nonce to create the reject transaction at
Signer or address of pod member
Ejects a safe from the Orca ecosystem. This zeroes out all ENS + Controller data, removes the Orca module, and burns the pod's MemberTokens If a signer is provided, it will execute the transaction. Otherwise it will return the unsigned tx.
This function can also clean up data for safes that have already removed the Orca module, but note that the reverse resolver must be zeroed out by the safe manually in this case.
Returns list of all member EOAs, not including any smart contract/pod members.
Returns Pod objects of all member pods.
Returns of list of all member addresses. Members include member pods and member EOAs
Fetches all personas for a given address related to this pod. All personas return as an object indicating the type of the persona and the address of the persona. For members and admins, the persona address is the user's address. For admin pods and sub pods, the persona address is the pod address.
Gets a specific proposal by either nonce or the safeTxHash.
Can be either the proposal id/nonce (preferred), or the safeTxHash
Returns an array of Proposal objects in reverse chronological order. Defaults to returning 5, which can be overridden by passing { limit: 10 } for example in the options.
By default, the first Proposal will be the active proposal, if there is one, and then any executed proposals.
Queued proposals can be fetched by passing { status: 'queued' } in the options. This will return queued proposals, then the active proposal, then executed proposals (up to the requested limit).
Executed proposals can be fetched by passing { status: 'passed' } or { status: 'rejected' } in the options. This will return only executed proposals.
Returns all sub pods of this pod that an address is the member of.
Returns an array of this pod's super pods, i.e., pods that this pod is a member of
Returns an array of all active super proposals, i.e., active proposals of any super pods
Checks if user is admin of this pod
Checks if given address is a member of the admin pod (if there is one) Returns false if there is no admin pod.
Checks if user is a member of this pod
Checks if given address is a member of any subpods. Returns false if the user is a member of this pod, but not any sub pods
Migrates the pod to the latest version. Signer must be the admin of pod. If a signer is provided, it will execute the transaction. Otherwise it will return the unsigned tx.
Signer of pod admin
Mints member(s) to this pod, or returns an unsigned transaction to do so.
Can be a single address or an array of addresses
If a signer is provided, then the tx will execute. Otherwise, an unsigned transaction will be returned.
Creates a proposal on the pod.
If the proposal parameter is in the { data, to } format, this will create a proposal to execute an arbitrary smart contract function on this pod.
The data
parameter is unsigned encoded function data. You can generate this function data a number of ways,
our recommended way would be through ethers.Interface.encodeFunctionData. The to
parameter should be the smart contract
that the function being called belongs to.
The pod object can also populate these transactions by using the supplied methods with no signer (i.e., pod.mint()
)
To create a proposal on the current pod, you can chain the method and the propose method like so:
await pod.propose(await pod.mint(newMember), podMember);
To create a proposal on the admin pod to mint to a managed pod, you can call the managed pod's method: Note that the pod you call the functions on is important: it determines which pod you are attempting to mint to.
// It is important that you call mint() from managedPod here
await adminPod.propose(await managedPod.mint(newMember), adminPodMember);
In order to create a sub proposal of an existing proposal, you can pass the proposal object to the sub pod's propose method:
const [superProposal] = await superPod.getProposals();
// This creates a sub proposal to approve the super proposal.
await subPod.propose(superProposal, signer);
// The propose function also returns a Propose object, so you can chain `propose` like so:
await subPod.propose(
await superPod.propose(
await superPod.mint(newMember),
superPodMember,
),
subPodMember,
);
The sender parameter should be the address the proposal is being sent from. This should be a member of the pod for creating a proposal, or a member of a sub pod to create sub proposals.
Address of sender
Optional nonce. This will create a proposal with the given nonce.
Transfers admin role from signer's account to addressToTransferTo If a signer is provided, it will execute the transaction. Otherwise it will return the unsigned tx.
Address that will receive admin role
Signer of admin
Transfers a membership. If a signer is provided, it will execute the transaction. Otherwise it will return the unsigned tx.
Address that is giving up membership
Address that will receive membership
If a signer is provided, then the tx will execute. Otherwise, an unsigned transaction will be returned.
Generated using TypeDoc
The
Pod
object is the interface for fetching pod data.The Pod object should not be instantiated directly, use getPod instead.
The following properties are on the object itself:
Members, EOAs and member Pods can be fetched with the following functions:
You can also check if a user is a member, admin, or member of those pods with the following functions: