Complete the rule receipts for a Sui Kiosk purchase

Receiving the asset from purchase is only part of a Kiosk transaction. The associated TransferRequest must be consumed by a policy whose rule set is satisfied.

Resolve rules on the same request

The skeleton assumes a policy for Art and a coin matching the listed price. Between purchase and confirmation, call the rule-specific functions required by the chosen policy, supplying any additional fee or proofs. The remainder of the transaction must also deliver or store asset.

let (asset, request) = kiosk::purchase<Art>(shop, item_id, exact_payment);
// Execute each rule's public resolver against this request.
let (_item, _paid, _from) =
    transfer_policy::confirm_request(policy, request);

Diagnose a missing receipt at confirmation

If the policy requires royalty and destination checks, satisfying only the royalty rule leaves the request incomplete. Inspect the policy’s actual rules at execution and the resolver calls in the transaction. A failed confirmation aborts the transaction, so avoid marking a sale complete when the purchase command is merely assembled.

Sources