CollectionApprovalPermission defines what collection approved transfers can be updated vs. are locked.

Each transfer is broken down to a (from, to, initiatedBy, transferTime, badgeId) tuple. For a transfer to match, we need to match ALL of the fields in the combination. These are determined by the fromListId, toListId, initiatedByListId, transferTimes, badgeIds fields. AddressLists are used for (from, to, initiatedBy) which are a permanent list of addresses identified by an ID (see AddressLists).

TimelineTimes: which timeline times of the collection's approvalsTimeline field can be updated or not? permanentlyPermitted/ForbiddenTimes: when can the manager execute this permission?

Ex: Let's say we are updating the transferability for timelineTime 1 and the transfer tuple ("AllWithoutMint", "AllWithoutMint", "AllWithoutMint", 10, 1000). We would check to find the FIRST CollectionApprovalPermission that matches this combination. If we find a match, we would check the permitted/forbidden times to see if we can execute this permission (default is ALLOWED).

Ex: So if you wanted to freeze the transferability to enforce that badge ID 1 will always be transferable, you could set the combination ("AllWithoutMint", "AllWithoutMint", "AllWithoutMint", "All Transfer Times", 1) to always be forbidden at all timelineTimes.

from message badges.CollectionApprovalPermission

Hierarchy

Constructors

Properties

approvalId: string = ""

Identifier for the approvalId. You can use "All" or "!approvalId" for shorthand. If you use "All", this approval will match to all approvalIds. If you use "!approvalId", this approval will match to all approvalIds except for approvalId. If you use "approvalId", this approval will match to only the specified approvalId and fail on all others.

from field: string approvalId = 9;

badgeIds: proto.badges.UintRange[] = []

Specifies the badge IDs involved in the transfer.

from field: repeated badges.UintRange badgeIds = 5;

fromListId: string = ""

Identifier for the sender list.

from field: string fromListId = 1;

initiatedByListId: string = ""

Identifier for the initiator list (who is approved?).

from field: string initiatedByListId = 3;

ownershipTimes: proto.badges.UintRange[] = []

Specifies the ownership times for the badges in the transfer.

from field: repeated badges.UintRange ownershipTimes = 6;

permanentlyForbiddenTimes: proto.badges.UintRange[] = []

Specifies the times when this permission is forbidden. Can not overlap with permanentlyPermittedTimes.

from field: repeated badges.UintRange permanentlyForbiddenTimes = 11;

permanentlyPermittedTimes: proto.badges.UintRange[] = []

Specifies the times when this permission is permitted. Can not overlap with permanentlyForbiddenTimes.

from field: repeated badges.UintRange permanentlyPermittedTimes = 10;

toListId: string = ""

Identifier for the recipient list.

from field: string toListId = 2;

transferTimes: proto.badges.UintRange[] = []

Specifies the times when the transfer can occur.

from field: repeated badges.UintRange transferTimes = 4;

fields: FieldList = ...
runtime: ProtoRuntime = proto3
typeName: "badges.CollectionApprovalPermission" = "badges.CollectionApprovalPermission"

Methods