Q: how to optimize gas in move contracts?
A: Here are the key strategies for optimizing gas in Move contracts on Sui:
## 1. Choose Efficient Data Structures
- Use **`vector`-backed collections** (`VecSet`, `VecMap`, etc.) only for collections …
Q: So macros can't abort?
A: Actually, macros **can** abort — and they handle aborts in a particularly useful way.
## Macros and Aborts
Macros can use both `abort` and `assert!` directly in their bodies. In fact, the `assert!` …
Q: mvr 怎么发布,怎么使用,举个具体的例子
A: ## MVR 的发布与使用
### 第一步:发布你的 Move 包
在注册到 MVR 之前,你需要先将包发布到链上。
```bash
sui client publish
```
发布成功后,系统会自动生成/更新 `Published.toml` 文件,记录链上地址、upgrade capability 等信息。例如:
```toml
[published.mainnet]
chain-…
Q: ### Capability Leakage via Events
**Severity:** High
Event-based capability leakage occurs when a module emits a capability struct, its object ID, or internal fields as part of an on-chain event. This happens because developers treat events as passive logging, forgetting that on Sui, [every emitte
A: The scenario described contains a **fundamental misunderstanding** of how Sui events and object ownership work. Let me clarify based on the knowledge sources:
## Why This Is Not a Valid Attack Vector…
Q: Can I create display on init?
A: No, you cannot create a Display V2 in `init`. The `DisplayRegistry` is a shared system object, and `init` functions cannot receive shared objects as arguments. [[Display Hero README](https://github.co…
Q: Wasnt "The Move Book" for Dieam only
A: No, **The Move Book** is specifically for Move on Sui, not Diem. The knowledge sources are clear on this:
> "This is The Move Book - a comprehensive guide to the Move programming language and the **S…
Q: どうやってeventをfetchする?
A: Sui でイベントを取得する方法は主に3つあります。
## 1. JSON-RPC(`suix_queryEvents`)
`curl` などで直接 RPC を叩く方法です [[Processing events](https://docs.sui.io/develop/accessing-data/using-events#processing-events)]:
```sh
curl -…
Q: keytool import
A: `sui keytool import` 可以將助記詞(mnemonic)或 Bech32 格式的私鑰加入到 Sui CLI 的本地 Keystore。
## 基本語法
```sh
sui keytool import INPUT KEY_SCHEME
```
- `INPUT`:助記詞(12/15/18/21/24 個單字)或 Bech32 編碼的私鑰(以 `suiprivkey` 開頭)…
Q: Documentation and example about Sponsor Tx (without using Enoki)
A: ## Sponsored Transactions on Sui (Without Enoki)
### Overview
A sponsored transaction allows a **sponsor** to pay gas fees on behalf of a **user**. This removes the need for users to hold SUI or und…
Q: does init function require otw anymore?
A: No, the `init` function does **not** require a One-Time Witness (OTW) — it is optional.
According to the Move Book, the `init` function can take one or two arguments: [[module initializer](https://mo…
Q: running this where?
A: Based on the conversation history, you're asking where to run the `suiup` installation commands.
You run these commands in your **terminal / command-line interface**, depending on your operating syst…
Q: Yeah but what about these concerns:
Finalize is still O(n) (send_funds per winner) → gas / step limits still matter for very large n.
Product / UX: wallets and indexers must surface accumulated balance and the redeem PTB flow (you already rely on this ecosystem for other coins per tests).
Yo
A: These are valid technical concerns. Let me address each one based strictly on what the knowledge sources support:
## 1. O(n) Finalization / Gas Limits
This concern is well-founded. The knowledge sou…
Q: How much params can put in function per tx
A: Based on the knowledge sources, there are a couple of relevant limits for function parameters per transaction on Sui:
- **Maximum number of arguments in a Move call** (or a PTB's `TransferObjects` co…
Q: how to use sui mcp server for vscode
A: The knowledge sources provided do not contain any information about a "Sui MCP server" for VS Code. The documents cover VS Code extensions for Move development (like the Move Analyzer by Mysten Labs a…
Q: Can you point me to the specifications of this method? I need the transaction fields
A: Based on the conversation context, you're asking about the fields available on the `Transaction` type returned by the `transactions` GraphQL query.
## `Transaction` Type Fields
[[Transaction type](h…
Q: Ok, this is impossible, where can I find a public graph ql sui node?
A: No worries! Sui provides public GraphQL RPC endpoints for each network:
- **Mainnet:** `https://graphql.mainnet.sui.io/graphql`
- **Testnet:** `https://graphql.testnet.sui.io/graphql`
- **Devnet:** `…
Q: query data from sui public node
A: There are two primary ways to query data from a Sui public node: **gRPC** and **GraphQL RPC**. Note that JSON-RPC is **deprecated** and you should migrate away from it. [[Data Access Interfaces](https…
Q: Can you give me an example of how I can query balances with these new RPC?
USing https://suiscan.xyz/mainnet/tx/GxqDrsyQCoGEz8GAUURhdBw2xKg61fKhXmtAn73yGpHc as a reference
A: Here are practical examples for querying balances using the current RPC options:
## TypeScript SDK (gRPC Client)
```typescript
import { SuiGrpcClient } from '@mysten/sui/grpc';
const grpcClient = n…
Q: There are a few generic changes:
What You Need to Change
1. Client Setup
Replace SuiClient / SuiJsonRpcClient with SuiGrpcClient:
// Before
import { SuiClient, getFullnodeUrl } from '@mysten/sui/client';
const client = new SuiClient({ url: getFullnodeUrl('mainnet') });
// After
import { SuiGrpcCli
A: Yes, your summary is accurate. Here's a quick verification of each point against the official documentation:
## Verification
**1. Client Setup** ✅
The migration from `SuiClient`/`SuiJsonRpcClient`…
Q: Mysten Labs' indexer
A: Mysten Labs provides several indexer solutions for the Sui ecosystem:
## General-Purpose Indexer (`sui-indexer-alt`)
This is the primary indexer that reads checkpoint data and writes it to a Postgre…
Q: What is the format of package binary that is stored on chain?
A: Based on the knowledge sources, here is what is documented about the on-chain format of a Move package binary:
## On-Chain Package Binary Format
### Object-level structure
A Move package is stored …
Q: what is the sui mainnet full node url
A: The Sui Mainnet full node URL is:
```
https://fullnode.mainnet.sui.io:443
```
[[Sui Networks](https://docs.sui.io/develop/sui-architecture/networks)]
Q: How about package? If we update a new package?
A: Unlike regular objects, **packages behave differently when upgraded — they get a new address (package ID) each time**.
When you upgrade a package on Sui, a **new package object is created onchain** w…
Q: how can i get a sui address from a public key
A: A Sui address is derived by hashing the **signature scheme flag byte concatenated with the public key bytes** (`flag || pubkey`) using the **BLAKE2b** (256-bit output) hashing function. The result is …
Q: importExtension: "",
A: Câu hỏi của bạn chỉ chứa đoạn code `importExtension: "",` mà không có đủ ngữ cảnh để tôi hiểu bạn đang hỏi gì.
Bạn có thể cung cấp thêm thông tin không? Ví dụ:
- Đây là đoạn code từ file nào?
- Bạn đ…
Q: giải thích về Consensus
A: ## Consensus trên Sui
**Consensus** (đồng thuận) là quá trình mà phần lớn các node trên mạng blockchain đồng ý về trạng thái hiện tại của mạng, bao gồm các giao dịch nào cần được hoàn tất và ghi vào …
Q: Give me the best skills for Sui Network that will worrk with Claude, I want everything for Sui Node API, Move Programming and Indexing Sui Node data
A: Based on the knowledge sources, here's what's available for Sui skills and tooling across your three areas of interest:
## Sui Agent Skills (Claude Code Compatible)
Install the Sui skills into Claud…
Q: why to create balance manager
A: The `BalanceManager` is a core component of DeepBook V3. Here's why you need one:
- **Holds all your trading assets:** It's a shared object that holds all balances for different assets (base, quote, …
Q: best sui wallets
A: Here's an overview of the most popular wallets in the Sui ecosystem:
## Official Wallet
- **[Slush](https://slush.app/)** – Built by Mysten Labs, it's the official Sui wallet. Available as a Chrome …
Q: What causes the FeatureNotYetSupported error in a Sui upgrade transaction command 1?
A:
Q: On-chain reputation system and identity score for DeFi lending on Sui
A:
Q: What is SEAL on Sui and how does it provide decentralized secrets management or threshold encryption?
A:
Q: What is Walrus decentralized storage on Sui and what applications can it enable?
A:
Q: what's the equivalent of suix_getStakesByIds (from RPC), when using gRPC?
A: Based on the knowledge sources, `getStakesByIds` does **not** have a direct gRPC equivalent. It falls under the category of methods that require using **GraphQL** instead.
The recommended replacement…
Q: what is usdsui?
A: **USDsui (Sui Dollar)** is a native stablecoin for the Sui ecosystem, issued by **Bridge**, a Stripe company. [[Sui Dollar Live](https://blog.sui.io/sui-dollar-launch-bridge/)]
Here are the key detai…
Q: from app.services.TRON.tron import get_tron_transactions
from app.services.POLYGON.polygon import get_polygon_transactions
from app.services.SOLANA.solana import get_solana_transactions
class BlockchainManager:
async def get_transactions(
self,
chain,
wallet,
ne
A: I appreciate you sharing your code, but I'm only able to answer questions about **Sui** — the Layer 1 blockchain developed by Mysten Labs. Your query is about building a multi-chain transaction servic…
Q: ok i need to faucet for both for usdc and usdt for testnet
A: The knowledge sources I have access to only cover the **SUI token faucet** (for gas fees), not faucets specifically for USDC or USDT on Testnet.
## Getting Testnet SUI (for gas)
You can get Testnet …
Q: is this correct?
Key findings:
- 0xab7b... doesn't exist on-chain — it's not a real object
- User has 1 SUI coin (0xb7cfa4...) with 0.5 SUI
A: Your analysis is partially correct, but there's an important nuance to clarify based on the documentation.
**What's accurate:**
- If `fundsInAddressBalance: "0"` and the user has no address balance, …
Q: What is the limit for mysten-labs' rpc nodes?
A: The public RPC endpoints maintained by Mysten Labs (`fullnode..sui.io:443`) are rate-limited to **100 requests per 30 seconds**. [[RPC Best Practices](https://docs.sui.io/references/sui-api/r…
Q: give me a bash script that uses sui cli to tell me the last checkpoint that occurred before user given timestamp in milliseconds
A: The knowledge sources don't provide enough detail about a direct Sui CLI command that maps a timestamp to a checkpoint sequence number. However, based on what the sources do tell us — that Sui creates…
Q: '0x2::sui::SUI' 在链上的真实权限定名是什么
A: `0x2::sui::SUI` 就是 SUI 代币类型的完全限定名(fully-qualified name)。其中:
- `0x2` 是 Sui Framework 的链上地址(命名地址 `sui` 的实际值) [[Reserved Addresses](https://move-book.com/appendix/reserved-addresses/)]
- `sui` 是模块名
- `S…
Q: suiup install move-analyzer
A: The command `suiup install move-analyzer` installs the **Move Analyzer** — the Move Language Server that provides code completion, go-to-definition, hover information, and diagnostics for Move smart c…
Q: Explain display v2 literal and give examples for different commonly used types
A: ## Display V2 Literals
In Sui's Object Display V2 template language, a **literal** is a concrete, typed value written directly in a format string expression — rather than referencing a field from an …
Q: so if I was storing a users hidden assets in a DB, would it be fine to just store the objectId or would i store it per network
A: Based on the previous answer, you should **store the object ID together with the network identifier** — not the object ID alone.
As established, the same object ID can exist on multiple Sui networks …
Q: How do I get a list of transaction digests that used a given package? (either directly or as a dependency). Even just one (the most recent one) would be enough.
A: You can use the Sui GraphQL API to find transactions that interacted with a given package. The most relevant filter available is `function`, which lets you filter transactions by a specific function i…
Q: hi
A: Hi there! How can I help you with Sui today? Feel free to ask any questions about Sui development, smart contracts, transactions, or anything else related to the Sui blockchain.
Q: could you give me the flow when I build the front-end and contract in testnet of Sui environment. How I sync my wallet into the frontend, and do I need zkLogin for this step
A: ## Building a Sui Frontend + Contract on Testnet
Here's the general flow for connecting a frontend to a Move package on Sui Testnet:
---
### 1. Deploy Your Move Package
Before building the fronten…
Q: ZKLogin what is it ?
A: ## What is zkLogin?
zkLogin is a **Sui-native primitive** that enables you to send transactions from a Sui address using an OAuth credential (like Google or Facebook) **without publicly linking the t…
Q: give me an example of curl for getting total supply
A: Here's a curl example for getting the total supply of a coin using the GraphQL API:
```bash
curl -X POST https://sui-mainnet.mystenlabs.com/graphql \
-H 'Content-Type: application/json' \
-d '{
…
Q: is there something like coin::mint_for_testing for balance?
A: Yes! The equivalent for `Balance` is `balance::create_for_testing(value)`. Here's an example:
```move
use sui::balance;
use sui::sui::SUI;
#[test]
fun test_balance() {
// Create a balance dir…
Q: get struct by id for test purpose
A: Based on the conversation history, you're asking how to retrieve a struct (object) by its ID in a test context in Sui Move.
## Getting a Struct by ID in Tests
In Sui Move tests, you use `test_scenar…
Q: what is the full function name and module for vector.to_string()?
A: The `.to_string()` method on `vector` is an alias that calls the `utf8` function from the `std::string` module.
- **Full function name:** `std::string::utf8`
- **Signature:**
```move
public f…
Q: why would you use a one time witness on currency creation?
A: Using a One-Time Witness (OTW) during currency creation provides a **uniqueness guarantee**: it cryptographically proves that only one `TreasuryCap` can ever exist for that coin type. [[One Time Witne…
Q: .mv 是什么文件
A: `.mv` 文件是 Move 模块编译后生成的**字节码文件**。
具体来说:
- Move 是一种编译型语言,源代码(`.move` 文件)经过编译器处理后,会生成 `.mv` 格式的字节码文件。[[Compiling the Package](https://move-book.com/your-first-move/hello-world/#compiling-the-package)]…
Q: so we don't need the otw anymore?
A: Correct — the OTW approach is no longer required. The **standard creation** method (`coin_registry::new_currency`) is the recommended approach for most cases, and the documentation explicitly notes:
…
Q: can you provide me the code that takes a vector of u8 for a function that returns the length?
A: Here's a Move function that takes a `vector` and returns its length, based on the `std::vector` module:
```move
public fun get_length(data: vector): u64 {
data.length()
}
```
The `length…
Q: how can i know what value should i place in the test net move toml
A: Here's what you need to know about setting up your `Move.toml` for Testnet:
## Key Values for Testnet `Move.toml`
### 1. Package Address (`[addresses]`)
Set your package's address to `"0x0"` before …
Q: if i have getters anyway for the fields, is it better to return a mutable ref to read value and alter it or use the getter and then the setter
A: Great follow-up question. Here's the practical distinction:
## Returning `&mut` (read + write via one reference)
```move
let r = treasury_pool_info.staker_shares_amount_mut();
let old_value = *r; …
Q: How do I deploy to Sui?
A: Here's how to deploy (publish) a Move package to Sui:
## 1. Set Up the Sui CLI
If you haven't initialized the Sui CLI yet, run:
```bash
sui client
```
Follow the prompts to connect to a full node …
Q: emit
A: In Sui Move, **emitting events** is the primary way to notify off-chain listeners (indexers, explorers, etc.) about on-chain activity. There are two ways to emit events:
## 1. `event::emit` (Standard…
Q: where in documentation we are specifieng something about dry run
A: Dry run is mentioned in several places across the Sui documentation and tooling:
## Sui CLI
- **`sui client call`**: Use the `--dry-run` flag to perform a dry run of a Move call without executing it…
Q: what is a smart contract?
A: A **smart contract** on Sui is an agreement based upon the protocol for conducting transactions on the blockchain, written in the **Move programming language**. [[Sui Glossary](https://github.com/Myst…
Q: what move.toml
A: ## What is `Move.toml`?
`Move.toml` is the **manifest file** for a Move package. It describes the package and its dependencies, and is required for any directory to be considered a Move package. It i…
Q: How to define error codes so that they are more meaningful beyond just a number
A: In Move on Sui, there are two main approaches to make error codes more meaningful than plain numbers:
## 1. Named Error Constants (Classic Approach)
Define `const` values prefixed with `E` and a cam…
Q: what is the address of coin metadata object id of Sui coin in testnet
A: The knowledge sources do not explicitly provide the specific object ID of the `CoinMetadata` object for the native SUI coin on **testnet**.
What the knowledge sources do tell us is:
- The **`CoinReg…
Q: what is sui, explain it to me as if i was a child
A: Imagine the internet is like a big playground. Right now, most playgrounds are owned by big companies — they make the rules, they hold your toys, and if they decide to close the playground, you lose a…
Q: Packages with old-style Move.toml files cannot depend on new-style packages. See https://docs.sui.io/references/package-managers/package-manager-migration for instructions.
A: As noted in my previous response, the knowledge sources do not support the claim that old-style packages *cannot* depend on new-style packages. The official migration guide explicitly states:
> "Alth…
Q: how can I create ascii string in sui move?
A: You can create an `std::ascii::String` in Sui Move in two ways:
### 1. `ascii::string` — aborts if invalid ASCII
Use this when you're confident the bytes are valid ASCII:
```move
use std::ascii;
l…
Q: what is move.lock?
A: `Move.lock` is an auto-generated file created at the root of a Move package when the package is built. Here's what you need to know about it:
## What it does
- **Pins dependencies**: It records the …
Q: move.lock
A: ## Move.lock in Sui
The `Move.lock` file is an auto-generated file created at the root of a Move package when the package is built. Here's what you need to know about it:
### What it does
- It **pi…
Q: 怎么在python里面调用这个 unsafe_payAllSui
A: 很抱歉,当前提供的知识来源中没有关于如何在 Python 中调用 `unsafe_payAllSui`(或任何 Sui JSON-RPC 方法)的具体代码示例或详细说明。
知识来源中仅提到了以下关于 `sui_payAllSui` 的功能描述:
> 该方法接受一个 SUI token ID 数组,将所有现有 token 合并为一个,扣除 gas 费用后,将合并后的 token 发送给收款地址。…
Q: I cant find wss for sui, can you help. Is it still working?
A: WebSocket (WSS) support for Sui has been **deprecated**. It was part of the old JSON-RPC stack, and that WebSocket support has been replaced.
The replacement for real-time streaming data is the **gRP…
Q: using graphql can you query old event emitted?
A: Yes, you can query historical events using the Sui GraphQL API. Here's what you need to know:
## Querying Events via GraphQL
You can filter events by checkpoint range using `afterCheckpoint`, `atChe…
Q: how to fetch dynamic object fields from an object in sui cli?
A: You can use the Sui CLI command `sui client dynamic-field ` to list the dynamic fields of an object. [[Sui Client CLI](https://github.com/MystenLabs/sui/blob/main/docs/content/references/cl…
Q: sui-groups PermissionedGroup Move contract membership permissions actor pattern MystenLabs
A:
Q: Move.lock file should be committed to git and automated address management in Sui packages
A:
Q: is there an equivalevnt function for Balance like burn for Coin?
A: Yes! The equivalent of `coin::burn` for `Balance` is **`balance::decrease_supply`**. It burns a `Balance` and decreases the corresponding `Supply`:
```move
public fun decrease_supply(self: &…
Q: Θα είναι ανοιχτό το sui hub Athens την άλλη παρασκευή;
A: Λυπάμαι, αλλά οι διαθέσιμες πηγές πληροφοριών δεν περιέχουν στοιχεία σχετικά με το ωράριο λειτουργίας ή το πρόγραμμα εκδηλώσεων του SuiHub Athens για συγκεκριμένες ημερομηνίες. [[SuiHub Athens](https:…
Q: So yes — if your net gas fees are -0.5 SUI, you would effectively receive 0.5 SUI credited back to your wallet.
is this somewhere stated in the documentation
A: Yes, this is supported by the official Sui documentation. Here are the relevant references:
**1. The net gas fee formula is explicitly stated:**
> *"the net fees that a user pays equals gas fees min…
Q: Πότε μπορώ να επισκεφτώ το sui hub στην Αθήνα;
A: Το SuiHub Αθήνα είναι ήδη ανοιχτό! Βρίσκεται σε ένα αποκατεστημένο νεοκλασικό κτίριο στην Αθήνα και λειτουργεί ως χώρος δημιουργίας, μάθησης και συνεργασίας για developers και builders. [[SuiHub Athen…
Q: fullnode url?
A: Here are the Sui full node RPC URLs for each network:
| Network | Full Node URL |
|---------|--------------|
| **Mainnet** | `https://fullnode.mainnet.sui.io:443` |
| **Testnet** | `https://fullnode.…
Q: is there any part of documentation that is more deeply talkign about this
A: Based on the knowledge sources available, here are some deeper resources on gas estimation and transaction simulation in Sui:
## Deeper Documentation Resources
### Sui Move Bootcamp (C2 Module)
The …
Q: For reference: coinsFieldMask = &fieldmaskpb.FieldMask{
Paths: []string{
"object_id",
"version",
"digest",
"object_type",
"previous_transaction",
"balance",
},
}
A: Great reference! That confirms the valid `read_mask` paths for coin objects. Here's the updated `grpcurl` command using those exact field paths:
```shell
grpcurl -d '{
"owner": "0xb40fa5e391458996a…
Q: Whe I iwll se the port? after indexing?
A: Yes, the gRPC port becomes accessible **after the initial gRPC indexing phase completes**. As noted in the full node documentation:
> "During the initial gRPC indexing phase, your full node may not b…
Q: why not use 100.do!?
A: Great point! You *can* use `100u8.do!` (or any uint's `.do!` macro) for a cleaner, more readable loop. However, there's a key limitation here: the `.do!` macro always runs **exactly** N times — it doe…
Q: walrus publisher \
--bind-address "127.0.0.1:31415" \
--sub-wallets-dir ~/.config/walrus/publisher-wallets \
--n-clients 4 \
--max-body-size 1048576
for aggreagtoe acn you tell ,e
A: It looks like you're asking about the equivalent setup for running a **Walrus aggregator** locally. Here's how:
## Run an Aggregator Locally
```bash
walrus aggregator --bind-address "127.0.0.1:31415…
Q: public struct TOKEN_TEMPLATE has drop {}
fun init(otw: TOKEN_TEMPLATE, ctx: &mut TxContext) {
let (cap, deny_cap, metadata_cap) = init_treasury(otw, ctx);
// Transfer caps to deployer. The admin registers these
// into the institution's Treasury via admin::register_coin.
transfer::
A: No, you cannot return values from a Move `init` function.
The `init` function has strict rules: it must be **private**, have **no return values**, and takes only one or two arguments (an optional One…
Q: how to write sui move project
A: Here's how to create and write a Sui Move project:
## 1. Prerequisites
- Install the Sui CLI ([installation guide](https://docs.sui.io/guides/developer/getting-started/sui-install))
- Verify install…
Q: what is your performance benchmark
A: Sui’s consensus protocol, Mysticeti, has been benchmarked in controlled environments as follows:
- With **10 nodes**:
- Up to **300,000 transactions per second (TPS)** before latency exceeds **1 …
Q: Φτιάξε μου πάλι το μνμ για το πρότζεκτ για συνάντηση στο χαμπ
A: Δεν υπάρχει κάτι στα knowledge sources για συγκεκριμένο “χαμπ” ή το πρότζεκτ σου, οπότε δεν μπορώ να βασιστώ σε επίσημες λεπτομέρειες. Θα σου δώσω ένα γενικό, σύντομο μήνυμα που μπορείς να προσαρμόσει…
Q: Γιατί δεν υπάρχει μια απλή φόρμα επικοινωνίας ρε μαν;έχει κλείσει το hub?
A: Δεν υπάρχει καμία αναφορά στις πηγές για «απλή φόρμα επικοινωνίας» ή για το αν κάποιο συγκεκριμένο hub έχει κλείσει, οπότε δεν μπορώ να το επιβεβαιώσω ή να το διαψεύσω με σιγουριά.
Αυτό που προκύπτει…
Q: What is this passkey, explain in simple terms
A: On Sui, **passkey** is a new way to have a wallet and sign transactions **using your device’s built‑in login** (Face ID, fingerprint, PIN, or a hardware key) instead of seed phrases or visible private…
Q: 我使用的2.13版本为啥没有ledgerService.getValidators这个方法
A: 我能从文档里确认两点,但文档没有给出你这个具体版本(2.13)的 API 结构细节,所以下面是基于现有资料的推断和说明:
1. 官方迁移文档明确写了:
JSON‑RPC 的 `getValidatorsApy` 需要用 gRPC 的 `ledgerService.getValidators` 来替代。[[Methods gRPC](https://sdk.mystenlabs.com/…
Q: Sui Move object ownership patterns shared objects transfer restrictions
A:
Q: what's the best way to fetch old txs? like 6 months old or more
A: To fetch transactions that are 6+ months old, you should rely on **archival infrastructure**, not just a regular full node or vanilla GraphQL indexer:
1. **Use the Archival Service (gRPC)**
- Th…
Q: Question Where to Find Answer
Q3.1 Does the DeepBook V1 documentation specify that self-trades are prevented? DeepBook V1 design docs (if available).
Q3.2 Is the self_matching_prevention field in the Order struct actually enforced during order matching? clob.move code (order matching function).
Q3.3
A: ### Finding Q3: DeepBook and self‑trading
**Q3.1 – Does DeepBook V1 documentation specify that self‑trades are prevented?**
The provided knowledge only includes:
- The original `deepbook::clob` (so…
Q: sự khác nhau của chúng là gì và nên sử dụng cái nào cho Seal SDK: import { SuiGraphQLClient } from '@mysten/sui/graphql';
import { SuiGrpcClient } from '@mysten/sui/grpc';
import { SuiJsonRpcClient } from '@mysten/sui/jsonRpc';
import { env } from '../config';
export const suiGrpcClient: SuiGrpcCli
A: Khác nhau chính nằm ở **API mà mỗi client nói chuyện với** và **trạng thái hỗ trợ**:
### 1. SuiGrpcClient (gRPC) – khuyến nghị dùng
- Kết nối tới **Full Node gRPC API**. [[Sui clients](https://sdk.m…
Q: What are the user and market level of sui?
A: Sui’s current user and market levels, based on the provided sources, can be summarized as follows:
### User level / adoption
- **Active accounts**
- Sui went from under 10 million active account…
Q: how to generate sdk from contracts and where it should be placed? frontend or api or else?
A: You can generate a TypeScript SDK from your Move contracts using the `@mysten/codegen` tool, and then import that generated code wherever you build transactions (frontend, backend API, or a shared pac…
Q: get object
A: To get an object on Sui, you have a few options depending on the interface you’re using.
---
### 1. Using the Sui TypeScript SDK (Core client)
Fetch a single object by ID:
```ts
const { object } =…
Q: Provide me the code snippet that accepts as input a vector of u8 and return the third element ensring that. the length is greater than or equal to 3
A: Here's a Move code snippet that accepts a `vector` as input and returns the third element, aborting if the length is less than 3:
```move
public fun get_third_element(v: &vector): u8 {
as…
Q: if a package p1 has a buggy function and it was upgraded to p2 with correct fix. how can i disable the buggy function in p1?
A: On Sui, **you cannot directly modify or disable a function in an already-published package** — packages are immutable once deployed, and old versions remain on-chain forever. [[package overview](https…
Q: So if I have these 2 tests:
#[random_test]
fun test_u8_lookup_table(number: u8) {
u8::is_power_of_ten_lookup_table(number);
}
#[random_test]
fun test_u8_optimized(number: u8) {
u8::is_power_of_ten_optimized(number);
}
Will they be ran with the same inputs? Or is it possible that each of th
A: Based on the knowledge sources, I cannot give you a definitive answer about whether two separate `#[random_test]` functions will receive the same inputs across runs.
What the knowledge sources do tel…
Q: 啊 如果我沒有treasury cap 怎麼辦
A: 根據你的情境,如果你沒有 `TreasuryCap`,有以下幾種情況需要區分:
## 情況一:你的 SUIX 代幣是用 `coin::create_currency` 建立的
`TreasuryCap` 是在呼叫 `coin::create_currency` 時由合約發布者收到的。[[Coin Standard](https://github.com/MystenLabs/sui/blob/…
Q: 所谓的Coin可以“集成到应用中”,是什么意思?
A: 这里"集成到应用中"(store in any application)的意思,是指 `Coin` 拥有 `key + store` 两种能力,因此它可以:
1. **被包装(Wrapped)进其他对象**:即作为另一个 Move 对象的字段存储,例如放入一个共享的托管合约或流动性池对象中。
2. **作为动态字段(Dynamic Field)存储**:可以将 `Coin` 附加到…
Q: is it use narwhal and Bullshark
A: No, Sui **no longer uses Narwhal and Bullshark**. Those were earlier consensus components that Sui was built upon, but the network has since moved to a newer protocol.
## Current Consensus: Mysticeti…
Q: how to convert binary to string
A: In Move on Sui, the standard library provides `to_string` functions for all unsigned integer types that convert a number to its decimal string representation. These are available for `u8`, `u16`, `u32…
Q: HOT是什么概念?
A: # Hot Potato(热土豆)模式
在 Sui 的 Move 语言中,**Hot Potato** 是指一个**没有任何能力(abilities)的结构体**。具体来说,它没有 `copy`、`drop`、`key` 或 `store` 这四种能力中的任何一种。[[Hot Potato Pattern](https://move-book.com/programmability/hot-po…
Q: TTO是什么?
A: **TTO(Transfer to Object)** 是 Sui 上的一种机制,允许将一个对象转移给另一个对象(而不仅仅是地址)。[[Transfer to Object](https://docs.sui.io/guides/developer/objects/transfers/transfer-to-object)]
## 核心原理
Sui 不区分 32 字节的**地址 ID** 和 …
Q: không có checksEnabled trong simulateTransaction
A: Vấn đề là bạn đang gọi `this.suiGrpcClient.simulateTransaction(...)` trực tiếp trên native gRPC client, trong khi `checksEnabled` chỉ có trên **Core API** (`client.core.simulateTransaction`). [[transa…
Q: how can I update a existing env's rpc-url using sui cli?
A: The knowledge sources do not explicitly mention a direct command to **update** an existing environment's RPC URL in place. However, based on the available documentation, the standard approach is to **…
Q: sui_getTransactionBlock
A: The `sui_getTransactionBlock` is a JSON-RPC method used to fetch a transaction by its digest from a Sui full node.
## Usage
It is a **direct lookup** RPC call that doesn't depend on additional index…
Q: let user_接著寫下去,不要寫重複的東西
A: 以下是從斷點處接續的完整程式碼:
```move
let user_tokens: u64;
if (table::contains(&pad.priority_allocations, sender)) {
user_tokens = *table::borrow(&pad.priority_allocations, sender);
asse…
Q: upgrade sui
A: # Upgrading a Sui Package
Here's a concise overview of how to upgrade a Move package on Sui.
## Key Concepts
Sui packages are **immutable objects**, but you can publish new versions linked to the o…
Q: Those tips are for the standalone indexer framework (sui-indexer-alt), not the built-in JSON-RPC indexer running inside your sui-node process
A: You're correct. The tips I provided in my previous answer are specifically for the standalone indexer framework (`sui-indexer-alt` / `sui-kvstore-alt`), not for the built-in indexer that runs inside t…
Q: como podria eliminar el mismatch restante y el faltante de escalado de quantities en order updates
A: Basándome en la documentación del indexer de DeepBook V3, aquí está la solución:
## Obtener `tick_size` y `base_asset_decimals` desde `/get_pools`
El endpoint `/get_pools` devuelve exactamente los d…
Q: published.mainnet]
chain-id = "35834a8a"
published-at = "0x9eb4ce3b2c745cdae1eb360b76af2e97025c516f5020b933d2f77167e5318500"
original-id = "0x14bd61802d31291fb410bd75757e3347221bf8019707307e5926afeebf4667cf"
version = 3
A: Looking at your `Published.toml` entry, the issue is now clear:
```toml
[published.mainnet]
chain-id = "35834a8a"
published-at = "0x9eb4ce3b2c745cdae1eb360b76af2e97025c516f5020b933d2f77167e5318500"
o…
Q: where is sui faucet for testnet
A: The official Sui Testnet faucet is available at **https://faucet.sui.io/** [[Sui Faucet](https://docs.sui.io/guides/developer/getting-started/get-coins#online-faucet)]
**How to use it:**
1. Connect y…
Q: i mean a parent and child isnt that just wrapper relationship
A: No, they're actually two different things on Sui — even though they can look similar at first glance.
## Wrapping (what `SharedBlob` does)
A wrapped object is **directly embedded as a field** inside…
Q: How does Object versions works? Can Objects can change between load time and execution time
A: ## Object Versioning in Sui
### How Versions Work
Every object on Sui is referenced by an **(ID, version)** pair. Key properties:
- Each object has an **8-byte unsigned integer version** that monot…
Q: 你現在是一位資深的 Web3 智能合約架構師,精通 Sui Move (2024 Edition) 語法。
我正在開發一個名為「Robinhood.Pad」的 Launchpad 平台,請幫我撰寫核心的打新智能合約。
合約需求如下:
1. 模組名稱為 `launchpad`。
2. 需要定義三個核心 Object:
- `AdminCap` (具有 key, store):在 init 時發送給部署者,作為管理員權限。
- `LaunchpadPool` (具有 key):作為共享物件(Shared Object)。內部需包含:
A: 感謝您的詳細需求說明!不過,我需要先說明一點:**您要求我扮演特定角色(「資深 Web3 智能合約架構師」)**,這超出了我的設計範圍,我只能以 Sui 技術助手的身份回答。
此外,您的需求涉及許多具體的 Move 實作細節,我只能根據知識來源中有明確支持的模式來提供程式碼。以下是基於知識來源中的 **Capability 模式**、**Shared Object 模式**、以及 **Coin/…
Q: give me the typescript sdk for graphql
A: Here's how to use the Sui TypeScript SDK with GraphQL:
## Installation
```bash
npm install @mysten/sui
```
## Setting Up a GraphQL Client
```ts
import { SuiGraphQLClient } from '@mysten/sui/graphq…
Q: How can I modify the css style of React components ConnectButton and ConnectModal and also select the wallets to be listed on ConnectModel?
A: ## Styling and Configuring `ConnectButton` & `ConnectModal` in React
### CSS Styling
dApp Kit uses a theming system compatible with [shadcn/ui](https://ui.shadcn.com/docs/theming), based on CSS cust…
Q: how to deploy my website to walrus
A: Here's how to deploy your website to Walrus Sites:
## Prerequisites
1. Install and configure Sui
2. Install and configure Walrus
3. Obtain Testnet SUI and WAL tokens (or Mainnet tokens for productio…
Q: sui move build --lint --path math/fixed_point
Your active environment `local` is not present in `Move.toml`, so you cannot publish to `local`.
- If you want to create a temporary publication on `local` and record the addresses in an ephemeral file, use the `test-publish` command instead
A: The error is because your active CLI environment is `local`, which isn't defined in your `Move.toml`. For just building and testing (not publishing), you need to tell the CLI which environment's depen…
Q: can any node operator change the zklogin protocol config max epoch?
A: Based on the knowledge sources, the answer is **no** — individual node operators cannot unilaterally change the zkLogin protocol config `max_epoch` setting. Here's what the sources do and don't say:
…
Q: non-defining modules can mint other's objects?
A: No. In Sui Move, non-defining modules **cannot** create (mint) objects of a type they don't define.
This is enforced by Move's **privileged struct operations** rule:
> Struct types can only be creat…
Q: Do you have a gas profiler?
A: Yes, Sui provides several gas profiling tools:
## 1. Test Statistics (Quick Measurement)
Run `sui move test` with the `-s` or `--statistics` flag to see gas consumption per test:
```
sui move test …
Q: Can I create a zklogin wallet with iPhone Face ID?
A: zkLogin specifically uses **OAuth credentials** (like Google, Apple, Facebook, etc.) — not device biometrics like Face ID. So you cannot create a zkLogin wallet directly with iPhone Face ID.
However,…
Q: remaind me address key scheme
A: On Sui, addresses are 32-byte identifiers derived by hashing a signature scheme flag byte concatenated with the public key bytes (`flag || pubkey`) using **BLAKE2b** (256-bit output). [[Address Format…
Q: how can i check the linear upgrade history? ideally from SUI CLI
A: The knowledge sources do not contain enough information to answer this query directly. The provided documents cover how package versioning works and how to upgrade packages, but they don't describe a …
Q: if i have a package A and it has package B as its dependency. now package B is upgraded to B v2. how should do upgrade A to use B v2?
A: When dependency B is upgraded to B v2, your package A **does not automatically use the new version**. You must explicitly upgrade package A to point to the new dependency. [[Upgrading Packages](https:…
Q: sign personal message
A: Based on the conversation context, you're asking about using `signPersonalMessage` for your anti-counterfeit system. Here's how it works in the Sui TypeScript SDK:
## Signing a Personal Message
```t…
Q: tell me about address balance
A: ## Address Balances on Sui
Address balances introduce a canonical balance system for fungible assets tied directly to Sui addresses. They replace the UTXO-style `Coin` model, where balances were p…
Q: correct it and return the full corrected version " public fun create_pool(
app_uid: ID,
_: &AdminCap,
ctx: &mut TxContext
) {
let pool = MinerPool {
id: object::new(ctx),
start_time: 0,
reward_balance: zero(),
app_uid,
};
transfer::share
A: Here is the corrected full version with `version` and `admin` fields added:
```move
public fun create_pool(
app_uid: ID,
cap: &AdminCap,
ctx: &mut TxContext
) {
let pool = MinerPool {…
Q: What is Mysticeti?
A: Mysticeti is the consensus protocol that powers the Sui blockchain. Here's a summary of its key characteristics:
## What is Mysticeti?
Mysticeti is a **Byzantine Fault Tolerant (BFT), Directed Acycl…
Q: Archival Service 有开源吗
A: 根据知识来源,Archival Service 的相关组件是**开源的**,代码托管在 Mysten Labs 的官方 Sui 仓库中:
- **`sui-kvstore-alt`**(Indexer)和 **`sui-kv-rpc`**(gRPC 服务)均属于 Sui 主仓库的一部分,源码位于:
`https://github.com/MystenLabs/sui` [[Sui Repo]…
Q: borrow_publisher returns a reference, but in a PTB you can chain it — borrow in one call, pass the reference to the next call in the same transaction.
A: This is actually a common misconception worth clarifying. **PTBs do not currently support passing references returned from one transaction command into another command.**
As the Sui documentation exp…
Q: async getChainTimestamp(): Promise {
// toDo: 当前使用的还是json client, 废除前需要替换
const checkpointSeq = await this.sdk.fullClient.ledgerService.getServiceInfo({})
const checkpoint = await this.sdk.fullClient.ledgerService.getCheckpoint({ checkpointId: { oneofKind: 'sequenceNumber', seque
A: 这段代码有几个问题需要修复:
1. **响应未解构**:gRPC 方法返回 `{ response }`,需要解构
2. **字段名错误**:`getServiceInfo` 返回的是 `checkpointHeight`,不是 `epoch`
3. **getCheckpoint 参数格式错误**:TypeScript SDK 中直接传 `sequenceNumber`,无需 `checkpo…
Q: and i I for example register with my email again ? what would happen, would be my old account wiped out ? or how would it work ?
A: Great question! Based on the zkLogin documentation, here's what would happen:
**Your old account would NOT be wiped out.** The zkLogin address is derived deterministically from:
- `sub` — your uniqu…
Q: what is authorities_db
A: `authorities_db` is the primary database directory used by a Sui node (`sui-node`) to store all authority-related (validator/full node) data. By default, it is located at `/opt/sui/db/authorities_db` …
Q: note superNode is shard object created by user, wich other users joins which means it has details of the users that joined and the creation logic also, will the migration takes all the data to new version?
A: Great clarification. Since `SuperNode` is a **shared object** (not owned) that users join and that holds participant data, the versioning and migration approach is the same as for your other shared ob…
Q: what do you recomend for key management
A: Here's a summary of key management recommendations across different Sui contexts:
## For Wallet Users
- Use **self-custodial wallets** (e.g., Slush, Phantom, or hardware wallets like Ledger) to keep…
Q: Explain it a bit simpler for me to understand
A: Sure! Let me simplify the security risks that come with Sui's parallel design.
---
## 🔑 The Core Problem: Parallel = New Risks
Because Sui runs transactions at the same time, it needs to carefully …
Q: any Cross-PTB or cross-transaction reservation tracking.
A: The knowledge sources do not contain enough information to directly address "cross-PTB or cross-transaction reservation tracking" as a specific Sui feature or pattern.
However, based on what the know…
Q: Where in the official docs is the exact behavior of address balance accumulators (fundsInAddressBalance) and FundsWithdrawal documented, including signing vs execution vs settlement timing?
How does the 1024-command PTB limit interact with shared-object modules like the bridge and accumulator? Is th
A: Here is what the provided knowledge sources directly support for each of your questions:
---
### 1. Where are address balance accumulators and FundsWithdrawal documented?
The provided sources cover…
Q: 不是某个地址的,而是在链上扫描
A: 根据现有的知识来源,我没有找到关于**全链扫描所有含 `Balance` 的 Object**(不限于某个地址)的直接 API 或方法。
知识来源中提供的查询方式均基于**特定地址**(owner)来获取其拥有的余额或对象,例如:
- `client.core.listBalances({ owner: '0xabc...' })` [[Core API](https://sdk.mys…
Q: Will Sui wallet support balance transfers? They are asking for Suiet wallet
A: The knowledge sources do not contain specific information about whether **Suiet wallet** will support address balance transfers (the new `send_funds`-based approach). The sources only mention that Sui…
Q: So the DenyCapV2 is controlled by a single person?
A: Based on the knowledge sources, `DenyCapV2` is a single object with `key` and `store` abilities, meaning it is owned by one address at a time and is transferable. [[DenyCapV2 capability](https://docs.…
Q: In the sui-rust-sdk, is there something similar to the keystore of the sui-sdk for loading keys and signing?
A: The knowledge sources don't contain enough detail about the Sui Rust SDK's keystore equivalent to give a fully confident answer. However, based on what is available, here's what the sources do show:
…
Q: I have a plain HTML website (no React, no npm, no bundler).
I want to detect ALL installed Sui wallets including Slush
browser extension using the Wallet Standard.
What is the exact CDN script URL I should load? And after
loading it, what exact JavaScript code do I call to get all
installed wa
A: ## Detecting Sui Wallets in Plain HTML/JS
### CDN Script URL
The knowledge sources do not provide a CDN URL for `@mysten/wallet-standard`. The documentation assumes a Node.js/npm/bundler environment…
Q: ➜ oracle git:(mainnet) sui client test-publish --build-env mainnet
The package has unpublished dependencies. If you want to publish with unpublished dependencies, please publish them one by one, or (not recommended) pass the `--with-unpublished-dependencies` flag.
Unpublished dependencies: Pyth, S
A: ## 排查 `unpublished dependencies` 問題
你遇到的錯誤是 `sui client test-publish` 找不到依賴項的已發布地址。即使 Pyth 那邊有 `Published.toml`,問題可能出在以下幾個地方:
### 可能原因
1. **`Published.toml` 沒有包含 `mainnet` 的條目**
`Published.toml…
Q: So sui is like a customer who owns a unique apple or bread it is unique with a code onky to that perso. A 1/1 they can go and stand in line whereever, only when the system notices that two different people stand in line with a same product and code it will pull them away to a seperate line where the
A: Your analogy is really good and you're on the right track! Let me refine it slightly to make it even more accurate:
**Your Sui part is spot on.** Every object has a unique ID, belongs to one owner, a…
Q: 我怎麼知道是少了哪個?
A: 根據現有的知識來源,並沒有直接說明如何在錯誤訊息中識別**具體是哪個依賴缺失**的方法。不過,以下是一些可以幫助你診斷的建議:
### 1. 使用 `--verify-compatibility` 旗標(本地模擬)
在 Sui 1.42 中新增了 `--verify-compatibility` 旗標,可以在本地模擬環境中執行升級相容性檢查,幫助你在不花費 SUI 的情況下提前發現錯誤。[[N…
Q: When the sui move package is updated to next version, the old version stays there as well. What happens the storage, variables and funds to the previous version?
As the previous version is still accessible to users as well
A: Great question! Here's a clear breakdown of what happens when a Sui Move package is upgraded:
## Packages Are Immutable — Objects Are Not
When you upgrade a package, **the new version gets its own o…
Q: 呼叫 share object 也要先拿到 share object 才行?還是只要知道 object id?
A: 這取決於你的情境:
## 建立(share)一個新物件
當你要**建立並分享**一個物件時,你需要先在同一筆交易中建立該物件,然後才能呼叫 `transfer::share_object`。也就是說,你必須持有該物件的值(by value),而不只是知道 object ID。
```move
public fun create_and_share(message: String, ctx: …
Q: who are Accumulator
A: Based on the knowledge sources, here is what the `sui::accumulator` module is about:
## `sui::accumulator` in Sui Move
The `sui::accumulator` module is a **Sui framework module** that provides infra…
Q: How about private transactions
A: The knowledge sources do not contain enough information to answer whether private transactions (i.e., transaction-level confidentiality, such as hiding sender, receiver, or amounts) are available or p…
Q: is there a blink for sui?
A: The knowledge sources provided don't contain any information about a "Blink" feature or equivalent on Sui.
For context, "Blinks" (Blockchain Links) are a concept popularized on Solana that allow bloc…
Q: I don't see the documentation related to kv_objects pipeline
A: You're right to notice that. The knowledge sources do not contain a dedicated documentation page or section specifically for the `kv_objects` pipeline configuration. Here's what the sources do tell us…
Q: localnet graphsql conection
A: To connect to a local Sui network via GraphQL, use the following URL: `http://127.0.0.1:9125/graphql`.
First, start your local network with GraphQL enabled:
```sh
sui start --force-regenesis --with-…
Q: Seal package ID for testnet ?
A: The Seal package ID for **Testnet** is:
`0x927a54e9ae803f82ebf480136a9bcfe45101ccbe28b13f433c89f5181069d682`
[[Key Servers](https://github.com/MystenLabs/sui-move-bootcamp/blob/main/K5/05_key_server…
Q: i've got blockpi grpc endpoint, how do i authenticate?
A: The knowledge sources do not contain specific information about authenticating with a BlockPI gRPC endpoint. The documentation covers:
- **Building gRPC clients** (TypeScript, Go, Python) that connec…
Q: Explain this party thing well I dont understand
A: ## Party Objects in Sui — Explained Simply
Think of a **Party object** as a special type of object ownership that sits between two existing types you may already know:
---
### The Two Existing Type…
Q: For Slush detection** — ask the Sui docs AI these exact questions:
```
1. How does Slush wallet register itself with the
Wallet Standard on a plain HTML website (no React,
no dApp kit)? What window event or global object
should I listen for?
2. What is the exact window object name or ev
A: Here's what the knowledge sources tell us about each of your questions:
---
## 1. Registering Slush Wallet with the Wallet Standard (no React/dApp Kit)
For the **Slush web wallet** specifically, yo…
Q: 我要铸造sbt 你给我合约和ts铸造nft 的
A: # 铸造灵魂绑定 NFT (SBT)
## Move 合约
灵魂绑定 NFT 的关键在于:**只有 `key` 能力,没有 `store` 能力**。这样持有者无法使用 `transfer::public_transfer` 转移它,从而实现"灵魂绑定"效果。 [[Soulbound NFT](https://github.com/MystenLabs/sui/blob/main/docs/c…
Q: rpc
A: ## Sui RPC Overview
Sui provides multiple RPC interfaces for accessing blockchain data:
### Available Interfaces
1. **gRPC API** (recommended) — A high-performance, type-safe interface using Protoc…
Q: How do I deploy to Sui?
A: Here's how to deploy (publish) a Move package to Sui:
## 1. Set Up the Sui CLI
If you haven't initialized the Sui Client CLI yet, run `sui client` in your terminal. Follow the prompts:
- Enter `y` t…
Q: 如果升级的cap是多签账户 我生成未签名的txbytes是不是就可以使用sui client upgrade --upgrade-capability 0xc1c6690f21937f90e6b42f7c916d8e8c942926e3fb9e5c3c5584ae1e91502f25 \
--gas-budget 1000000000 --gas 0xb54b10536826f28cd2453c5226f8c759c3bccf4beb672890f1447117c2ef93f7 \
--serialize-unsigned-transaction --skip-dependency-veri
A: 是的,你的思路是正确的。对于多签账户升级包,使用 `--serialize-unsigned-transaction` 生成未签名的交易字节,然后由各签名方分别签名,最后合并执行,这是标准的离线签名流程。[[Offline Signing](https://docs.sui.io/guides/developer/transactions/transaction-auth/offline-sign…
Q: Cannot upgrade package without having a published id 现在升级报错了 hasui现在升级无法使用命令sui client upgrade --upgrade-capability 0xc1c6690f21937f90e6b42f7c916d8e8c942926e3fb9e5c3c5584ae1e91502f25 \
--gas-budget 160000000 --gas 0xe9ab96bcb2e610a12f7996aed1b2da4b474bbef55ade2d6c16fed0afcb15daeb \
--serialize-unsig
A: The error "Cannot upgrade package without having a published id" is related to the **new package management system introduced in Sui CLI v1.63**, which changed how published addresses are tracked. [[P…
Q: you said For a full historical account of the old rules, I'd recommend checking the Sui GitHub history or older versions of the documentation directly.
I asked if you can check the history for me
A: I'm sorry, but I'm not able to browse the internet, access GitHub history, or retrieve external documentation beyond the knowledge sources I've been provided. My previous suggestion to check the Sui G…
Q: copy "C:\Users\PC\Downloads\bot.mjs" "C:\Users\PC\agent-tg-bot\bot.mjs"
cd C:\Users\PC\agent-tg-bot
git remote set-url origin https://github.com/ibraheemmjafar-netizen/agenttraderbot.git
git add bot.mjs
git commit -m "fix trades - old pool only, clean buy/sell"
git push
```
---
**For Slush detecti
A: I'll skip the unrelated shell/git commands and focus on your Sui-related questions.
## 1. Registering Slush Wallet on a Plain HTML Site (No React/dApp Kit)
Install the SDK and call `registerSlushWal…
Q: How to get ether and bridge to sui
A: ## Bridging ETH to Sui
To bridge Ether (ETH) to Sui, you have several options depending on your needs:
---
### Option 1: Sui Bridge (Native Bridge)
Sui Bridge is the native bridge built into the S…
Q: Pure PTB execution + bridge treasury interaction
A: ## PTB Execution & Bridge Treasury Interaction on Sui
### Programmable Transaction Block (PTB) Execution
A PTB is composed of two parts: **inputs** and **commands**. [[What is a PTB?](https://docs.s…
Q: walrus launch date
A: Walrus Mainnet launched on **March 27, 2025**, with Epoch 1 beginning on March 25, 2025, operated by a decentralized network of over 100 storage nodes. [[Mainnet launch](https://docs.wal.app/blog/06_m…
Q: trion-protocol-30296913:~/trion-protocol/trion_core{main}$ sui client publish --build-env testnet
The package has unpublished dependencies. If you want to publish with unpublished dependencies, please publish them one by one, or (not recommended) pass the `--with-unpublished-dependencies` flag.
Unp
A: The issue is that even though you've provided `published-at` and `original-id` in your `[dep-replacements]`, the package manager still isn't recognizing `World` as already published on-chain. This is …
Q: So how can I open a slush wallet through another app in my mobile?
A: You can open Slush Wallet from another mobile app using **deep linking**. Slush supports two approaches:
## 1. Universal Links (Recommended)
Use `my.slush.app` HTTPS links — they work on iOS, Androi…
Q: where is sui signing personal message listed
A: Personal message signing on Sui is documented in several places across the knowledge sources:
1. **Wallet Standard** – `sui:signPersonalMessage` is listed as a required wallet feature that wallets sh…
Q: sui client call 指令
A: ## `sui client call` 指令
`sui client call` 用於呼叫 Move 套件中的函數,是與 Sui 網路互動的核心指令之一。[[Sui Client CLI](https://github.com/MystenLabs/sui/blob/main/docs/content/references/cli/client.mdx)]
### 基本語法
```sh
s…
Q: sbt nft
A: ## Soulbound NFTs (SBTs) on Sui
A **Soulbound Token (SBT)** is a non-transferable NFT that is permanently bound to the account it was minted to. [[Soulbound NFT Example](https://docs.sui.io/guides/de…
Q: this is what i have
[package]
name = "alliance_protocol"
edition = "2024" # edition = "legacy" to use legacy (pre-2024) Move
# license = "" # e.g., "MIT", "GPL", "Apache 2.0"
# authors = ["..."] # e.g., ["Joe Smith (joesmith@noemail.com)", "John Snow (johnsnow@noemail.com)"]
A: Looking at your `Move.toml`, the structure looks mostly correct for the new-style format. However, there are a couple of things to address:
## Issues to Fix
### 1. The `rev = "main"` for your git de…
Q: Окей, а через sdk? @mysten/sui?
A: Вот как вызвать `mint_gladiator` через `@mysten/sui` TypeScript SDK, используя PTB:
```typescript
import { Transaction } from "@mysten/sui/transactions";
import { SuiClient, getFullnodeUrl } from "@m…
Q: check if there is any update needed on this based on the register_capy and unregister_capy functions updates " entry fun reveal_mine(
shard_pool: &mut ShardPool,
pool: &mut MinerPool,
node: &mut NFTNode,
nft: &NFT,
commit: MiningCommit,
secret: vector,
A: Looking at `reveal_mine` in the context of the updates made to `register_capy` and `unregister_capy`, the key change introduced was the **registry cache sync** (`registry.shard_participant_counts`). S…
Q: I am tranferring My personal token in testnet but object is I am not able to see
A: Here are a few things to check when you can't see your transferred object on Sui Testnet:
## 1. Verify You're Looking at the Right Network
Make sure your explorer is set to **Testnet**, not Mainnet.…
Q: Напиши мне PTB что бы передать обьект адресу
A: Вот пример PTB для передачи объекта адресу с использованием TypeScript SDK:
```typescript
import { Transaction } from '@mysten/sui/transactions';
const tx = new Transaction();
// Передаём объект (с…
Q: "Transaction resolution failed: CommandArgumentError { arg_idx: 0, kind: ArgumentWithoutValue } in command 28"。这个报错是什么意思?
A: ## 分析 `CommandArgumentError: ArgumentWithoutValue` 报错
这个错误发生在 PTB(Programmable Transaction Block)的第 29 个命令(command index 28,0-indexed)中,第 0 个参数(`arg_idx: 0`)出现了问题。
### 错误含义
根据 Sui 的执行状态协议,`ARGUMENT…
Q: INFO: Uvicorn running on http://127.0.0.1:8078 (Press CTRL+C to quit)
📡 Status (https://graphql.testnet.sui.io/graphql): 200
📄 Page fetched: 2 txs | hasNextPage: False
✅ Total digests fetched: 2
✅ Total unique digests: 2
📡 Status (https://graphql.testnet.sui.io/graphql): 200
❌ GraphQL Error (htt
A: The error is clear:
```
Unknown field "base64Sig" on type "UserSignature"
```
Looking at the actual `UserSignature` type in the Sui GraphQL schema, the correct fields are `signatureBytes` and `schem…
Q: write unit test for me please:
module walrus_ai_policy::metadata;
use std::string::{Self, String};
use sui::clock::Clock;
public struct Metadata has copy, drop, store {
title: String,
description: String,
version: u64,
creator: address,
category: String,
created_at: u64,
}
A: Here is a unit test for your `walrus_ai_policy::metadata` module, based on the testing patterns from the Sui documentation:
```move
#[test_only]
module walrus_ai_policy::metadata_tests;
use std::str…
Q: does this command " sui move new" creating and deploying the project? or just creating
A: The `sui move new` command **only creates** the project — it does not deploy it.
Specifically, `sui move new
` creates: [[Move CLI](https://docs.sui.io/references/cli/move#examples)]
- …
Q: sui上使用反编译的工具
A: 在 Sui 上,有以下几款反编译工具可供使用:
## 官方/主流工具
- **sui replay**:可以本地重新执行任意历史链上交易,并对比其执行效果。使用 `--trace` 标志可生成执行追踪,供 Move 调试器使用。[[Sui Replay CLI](https://docs.sui.io/references/cli/replay)]
```sh
sui replay …
Q: archival store 可以查到更舊的events嗎
A: 根據知識來源,Archival Store 對於 Events 的支援有所限制。
Archival Store 主要支援的是**點查詢(point lookups)**,例如:
- 依 digest 查詢特定 transaction
- 依 ID 和版本查詢特定 object
- checkpoint 查詢
[[GraphQL Retention](https://docs.sui.io/gu…
Q: How do I deploy to Sui?
A: Here's how to deploy (publish) a Move package to Sui:
## 1. Set Up the Sui Client CLI
If you haven't initialized the CLI yet, run `sui client` in your terminal. If prompted, enter `y` to connect to …
Q: explain the typed witness pattern
A: ## The Witness Pattern in Move (Sui)
The **witness pattern** is a way to prove a certain property at the type level by constructing a proof value. In Move on Sui, a module proves ownership of a type …
Q: What are the bridge-registered tokens
A: Based on the knowledge sources, here are the tokens registered/supported on Sui Bridge:
## Sui Bridge Supported Assets
The following assets are officially supported by the native Sui Bridge: [[Sui B…
Q: How does RGP works
A: ## Reference Gas Price (RGP) on Sui
The **Reference Gas Price (RGP)** is Sui's mechanism for keeping gas prices stable and predictable for end-users. Here's how it works:
### Setting the RGP
1. **D…
Q: SuiGraphQLClient url
A: Here are the GraphQL endpoint URLs for each Sui network when using `SuiGraphQLClient`:
| Network | URL |
|---------|-----|
| **Mainnet** | `https://sui-mainnet.mystenlabs.com/graphql` |
| **Testnet**…
Q: Is there any que on sui side when I bridge from ethereum
A: When you bridge from Ethereum to Sui, there isn't a traditional "queue" in the sense of a waiting line. Instead, the process follows a structured approval-then-claim flow:
### How it works (Ethereum …