Repository navigation
Document transfer hooks - #355
Merged
Merged
Conversation
Core v3.3 adds a per-project contract that Engine cores call on every mint and transfer. Nothing described it outside the contract source. Covers what a hook is, the v3.3 compatibility floor and why existing contracts cannot gain support, configuring and locking, reading the configuration on and off chain, and writing a hook. The security and cost constraints get their own weight: a hook must authenticate the calling core itself, it cannot reenter the core, its gas is paid by whoever moves the token, and locking freezes the hook address rather than the hook's behavior. Cross-linked from the protocol overview alongside PostParams, the closest existing extension point. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01C6jcGQ48oJZddVVQFpShAz
|
Running a hook is not a signal to the rendering pipeline. Syncing a PostParam write is: it calls triggerTokenProcessing with render and features set, and an owner change has no equivalent. That gap lands hardest on the projects most likely to want a hook. An artwork that reacts to its owner renders correctly in the live generator the moment it transfers, while the stored thumbnail on artblocks.io and in marketplaces keeps showing the previous owner's output. Documents the way out — an Address-authorized PostParam whose authorized address is the hook contract, written from inside onTokenTransfer — along with the two things that make it viable or not: the core blocks reentrant mints and transfers but not calls to other contracts, and it doubles the storage cost carried by every transfer for the life of the project. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01C6jcGQ48oJZddVVQFpShAz
mattetre
approved these changes
Sep 11, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.


Core v3.3 adds a per-project contract that Engine cores call on every mint and transfer. Nothing described it outside the contract source.
Covers what a hook is, the v3.3 compatibility floor and why existing contracts cannot gain support, configuring and locking, reading the configuration on and off chain, and writing a hook. The security and cost constraints get their own weight: a hook must authenticate the calling core itself, it cannot reenter the core, its gas is paid by whoever moves the token, and locking freezes the hook address rather than the hook's behavior.
Cross-linked from the protocol overview alongside PostParams, the closest existing extension point.