Describes token identity, launch route and a local policy plan; the launcher does not publish it on-chain.
How it works
h/monhook brings coin launches, market discovery and transaction limits together on Solana. The supported trade path now uses h/monhook's own Guard on mainnet. Issuer options and optional confidential transfers are separate product layers, not features of the deployed Guard binary. The source and deployment page shows the exact relationship.
A simple rule: the trade must meet the limits you signed.
The protocol does not replace a launchpad, wallet or liquidity router. It gives those systems one shared language for declaring and enforcing a transaction outcome.
h/monhook separates declaration from enforcement. The current launcher can create a coin and export a local JLM1 policy plan; it does not publish that policy on-chain. For a supported Jupiter route, a trader can turn a quote into transaction limits, and the deployed Guard checks the realized result. A future publisher could make an issuer baseline discoverable to wallets.
The six components below describe one transaction lifecycle. JLM1 describes a launch plan, Intent V1 describes one trade, the deployed Guard executes it, JHK1 defines optional policy logic, JRC1 reports what settled, and the SDK assembles and reads the formats. Issuer options and Privacy Rings are separate integrations with their own contracts and trust boundaries.
Binds authority, route, input ceiling, output floor, expiry and optional policy data.
Checks preconditions, invokes the route through CPI and verifies realized balance deltas.
Allows an external program to accept or reject before and after route execution.
Returns the intent identity and measured input/output for wallets and indexers.
Deduplicates accounts, encodes indexed routes and decodes successful receipts.
The supported trade path uses Be7RvxKN...1E2ELQ on Solana mainnet. Its ProgramData matches SBF SHA-256 f90a8834...5ac9c3ac6f.
Privacy belongs to the user, not to hidden issuer promises.
Issuer protection is a separate contract flow: compare same-name launches, verify locked supply and option terms, and use independently reviewable evidence for any violation. The deployed Guard checks the outcome of a supported trade; it does not detect developer sales or exercise options.
Privacy Rings can provide optional confidential transfers of eligible assets. In the default Ring, asset and amount can be concealed while wallet addresses remain visible. A private transfer requires its own wallet approval; the current launcher and Guard do not create one. Lock collateral, strike, expiry and forfeiture evidence must remain verifiable.
The router finds a path. The Guard checks whether its result is acceptable.
Suppose a wallet finds a route that may spend up to 1 SOL to buy a token. The user accepts only if at least 950,000 token units reach the destination account before a chosen expiry slot. The wallet encodes those limits and the selected route program into Intent V1, then asks the user to sign.
The deployed Guard records the source and destination balances, runs the router through CPI and reads the balances again. Spending 0.98 SOL and receiving 970,000 units passes. Spending 1.01 SOL or receiving 940,000 units fails. The program is not judging whether the quoted price was “good”; it is enforcing the exact boundary the user authorized.
Explore the technical protocol
Mint policy and transaction intent are complementary.
A Token-2022 Transfer Hook follows a mint. It is chosen by the issuer and runs whenever that token is transferred, regardless of which user initiated the transfer or why. That makes it useful for token-level behavior, but it cannot express the complete economic promise of a route involving several programs and assets.
A transaction-bound Intent Hook follows one user-approved transaction. It can protect a route that touches a router, multiple pools and either token program, because the final check looks at the complete realized input and output. The two mechanisms can coexist: a route may encounter a mint hook, while the deployed Guard still enforces the trader’s overall limit.
Token-2022 Transfer Hook
Belongs to the mint and runs on each transfer. The issuer chooses it when the mint is created.
- scope
- one mint
- authority
- issuer
- trigger
- every transfer
h/monhook Intent Hook
Belongs to one user transaction and protects a route across multiple programs, pools and token programs.
- scope
- one route intent
- authority
- trader
- trigger
- selected execution
The phase table below describes where a failure occurs. PRE rejects an invalid authorization before liquidity moves. EXECUTE propagates an error from the selected route. RELOAD reads the post-route token state. POST compares the realized result with the signed limits and runs any final policy. RETURN produces a compact receipt only after every condition succeeds.
| phase | on-chain action | failure effect |
|---|---|---|
| PRE | validate signer, expiry, route and optional policy program | route never executes |
| EXECUTE | invoke ordered route accounts through CPI | route error propagates |
| RELOAD | read classic SPL or Token-2022 account balances | invalid owner rejected |
| POST | enforce max input, min output and custom hook result | transaction rolls back |
| RETURN | emit JRC1 intent id, realized input and output | portable proof |
Policies are composable programs.
The base protocol always protects authority, expiry, route identity, maximum input and minimum output. A policy module is for rules that are important to a particular application but should not be permanently hard-coded into the deployed Guard—for example an approved-route registry or a ceiling on additional token-level fees.
A policy does not receive unlimited authority to rewrite the trade. It receives the declared phase and its assigned accounts and data, then either accepts or returns an error. This keeps the core settlement invariant small while allowing applications to add rules that can be independently inspected and upgraded.
Reject when realized input exceeds the signed ceiling.
Reject when destination growth falls below the floor.
Accept only approved router or market identities.
Constrain Token-2022 economic effects.
Apply treasury or jurisdiction-specific rules.
Pass an opaque payload to any JHK1 program.
Small invariants at the settlement boundary.
The wrapper measures realized state rather than trusting quoted or simulated output.
Security starts by narrowing what the deployed Guard promises. It can prove that the authorized route stayed inside measurable token-account limits; it cannot make an illiquid market liquid, verify an issuer’s marketing claims or protect a compromised wallet key. Keeping those boundaries explicit prevents a settlement guard from being mistaken for a universal token-safety system.
Enforced by the deployed Guard
- Authority, expiry and route program validation.
- Classic SPL and Token-2022 account ownership checks.
- Integer balance deltas with checked arithmetic.
- Maximum input and minimum output postconditions.
- Policy hook rejection propagation.
Outside the wrapper
- Price discovery and route optimization.
- Liquidity availability and market volatility.
- Token metadata accuracy and issuer representations.
- Wallet security and user key management.
- Independent review of third-party hook programs.
Designed for wallets, launchers and routers.
Each integrator sees a different part of the same transaction. The current launcher creates an asset and exports a local policy plan. A supported wallet flow turns a Jupiter quote into terms the user can sign. The router supplies liquidity; the guard checks the result. Separate policy programs and indexers can consume the documented interfaces when integrated.
The format-driven design lets an application add a new route or policy without rewriting the settlement receipt. Support for a route is still adapter-specific; publication of a specification is not proof that every wallet, launchpad or router has integrated it.
| consumer | input | output | integration |
|---|---|---|---|
| wallet | canonical intent constraints | signable instruction | Intent V1 |
| launcher | mint + market configuration | local policy-plan preview | JLM1 |
| router | ordered CPI accounts + data | atomic route result | execute_intent |
| policy program | phase + opaque payload | accept / reject | JHK1 |
| indexer | transaction return data | realized settlement record | JRC1 |
Boundary and compatibility.
Is the deployed Guard a new AMM?
No. It is a route wrapper and settlement guard. Existing launchpads, AMMs and routers continue to provide liquidity and execution logic.
Does the wrapper custody tokens?
The base model measures user-controlled token accounts before and after CPI execution. It does not require a protocol-owned custody balance for ordinary settlement validation.
Can policy programs change the route?
A policy hook evaluates context and may accept or reject. The signed route program and ordered accounts remain explicit inputs to the guarded execution.
Read the implementation beside the specification.
Browse the complete Rust program, TypeScript SDK, tests, specification and CI configuration.