sui-move-patterns

Community

Apply Sui Move design patterns safely.

Authorwidnyana
Version1.0.0
Installs0

System Documentation

What problem does it solve?

Sui Move projects often ship with inconsistent event emission, brittle error handling, and low-composability core logic, which makes off-chain integrations harder and future upgrades riskier.

Core Features & Use Cases

  • Event emission for state changes: Emit typed events for client-visible changes like liquidity additions and other mutations.
  • Consistent error handling: Use predictable error constants and optional #[error] clever errors for readable abort messages.
  • Composability-focused design: Keep core logic pure by returning results instead of transferring them inside library-style functions.
  • Safer authority and publishing: Use the one-time witness (OTW) pattern for unique proofs and capability objects (AdminCap-style) instead of ctx.sender checks.
  • Use Case: Standardize a DeFi protocol module so indexers can reliably subscribe to events, clients get meaningful abort messages, and privileged actions are gated by capabilities.

Quick Start

Use the sui-move-patterns skill to review your Move module and rewrite its event emission, error constants, OTW initialization, capability gating, and pure-function boundaries for safer composability.

Dependency Matrix

Required Modules

None required

Components

Standard package

💻 Claude Code Installation

Recommended: Let Claude install automatically. Simply copy and paste the text below to Claude Code.

Please help me install this Skill:
Name: sui-move-patterns
Download link: https://github.com/widnyana/eyay-toolkits/archive/main.zip#sui-move-patterns

Please download this .zip file, extract it, and install it in the .claude/skills/ directory.
View Source Repository

Agent Skills Search Helper

Install a tiny helper to your Agent, search and equip skill from 471,000+ vetted skills library on demand.