BulletinBoard
Hierarchy
- unknown
- BulletinBoard
Index
Constructors
constructor
Returns BulletinBoard
Properties
admin
events
Type declaration
bid: typeof BB_BidEvent
cancelBid: typeof BB_CancelBidEvent
cancelOffer: typeof BB_CancelOfferEvent
changeAdmin: typeof BB_ChangeAdminEvent
newCollection: typeof BB_NewCollectionEvent
offer: typeof BB_OfferEvent
sale: typeof BB_SaleEvent
setFee: any
upgradeVerificationKey: typeof BB_UpgradeVerificationKeyEvent
withdraw: any
fee
Methods
bid
Emits a bid event.
Parameters
collection: PublicKey
The collection address.
nft: PublicKey
The NFT address.
bid: PublicKey
The bid address.
price: UInt64
The price.
Returns Promise<void>
cancelBid
Emits a cancel bid event.
Parameters
collection: PublicKey
The collection address.
nft: PublicKey
The NFT address.
bid: PublicKey
The bid address.
Returns Promise<void>
cancelOffer
Emits a cancel offer event.
Parameters
collection: PublicKey
The collection address.
nft: PublicKey
The NFT address.
Returns Promise<void>
changeAdmin
Changes the contract's admin
Parameters
admin: PublicKey
The new admin.
Returns Promise<void>
deploy
Parameters
args: BulletinBoardDeployProps
Returns Promise<void>
ensureOwnerSignature
Ensures that the transaction is authorized by the contract owner.
Returns Promise<AccountUpdate>
A signed
AccountUpdate
from the admin.
newCollection
Emits a new collection event.
Parameters
collection: PublicKey
The collection address.
Returns Promise<void>
offer
Emits an offer event.
Parameters
collection: PublicKey
The collection address.
nft: PublicKey
The NFT address.
offer: PublicKey
The offer address.
price: UInt64
The price.
Returns Promise<void>
payFee
Pays the fee to prevent spamming the BulletinBoard with fake events.
Returns Promise<any>
sale
Emits a sale event.
Parameters
collection: PublicKey
The collection address.
nft: PublicKey
The NFT address.
buyer: PublicKey
The buyer address.
price: UInt64
The price.
Returns Promise<void>
setFee
Changes the contract's fee
Parameters
fee: UInt64
The new fee.
Returns Promise<void>
upgradeVerificationKey
Upgrades the contract's verification key after validating with the upgrade authority.
Parameters
vk: VerificationKey
The new verification key to upgrade to.
Returns Promise<void>
withdraw
Withdraws the fee by admin
Parameters
amount: UInt64
Returns Promise<void>
The BulletinBoard contract serves as a centralized event emitter for NFT marketplace activities. It provides a standardized way to broadcast and track various marketplace events such as:
While anyone can emit events through this contract, all events are prefixed with "BB_" to distinguish them from events emitted directly by NFT contracts. This helps maintain clarity in event tracking and marketplace activity monitoring.