@t2000/sdk 10.6.0 → 10.8.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs +18 -17
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +9 -9
- package/dist/index.d.ts +9 -9
- package/dist/index.js +18 -17
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.d.cts
CHANGED
|
@@ -1159,10 +1159,16 @@ declare function buildAgentCoinModule(params: AgentCoinParams): Promise<AgentCoi
|
|
|
1159
1159
|
* layer (`registry::bind/finalize` re-check agent-or-confirmed-owner on
|
|
1160
1160
|
* `ctx.sender()` every call).
|
|
1161
1161
|
*/
|
|
1162
|
-
/** The published `agent_capital` package id (mainnet,
|
|
1163
|
-
* tx `
|
|
1162
|
+
/** The published `agent_capital` package id (mainnet, FRESH deploy
|
|
1163
|
+
* 2026-07-25 from the t2000 deployer `0xe7ac…`, tx `3FvSLERmmTLp396D…` —
|
|
1164
|
+
* supersedes the orphaned 2026-07-24 `0x33a04c67…` publish, which was cut
|
|
1165
|
+
* from the wrong wallet and never bound a token). Env-overridable for
|
|
1164
1166
|
* testnet/dev (same pattern as `A2A_ESCROW_PACKAGE_ID`). */
|
|
1165
1167
|
declare const AGENT_CAPITAL_PACKAGE_ID: string;
|
|
1168
|
+
/** Latest upgraded package id — moveCall targets MUST use this (v1 lacks
|
|
1169
|
+
* the `vesting` module; Sui routes calls by the id you name). Original id
|
|
1170
|
+
* above stays for type/event references. v3 = batch-safe vesting claim. */
|
|
1171
|
+
declare const AGENT_CAPITAL_PUBLISHED_AT: string;
|
|
1166
1172
|
/** The shared `CapitalRegistry` object id (mainnet). */
|
|
1167
1173
|
declare const CAPITAL_REGISTRY_ID: string;
|
|
1168
1174
|
/** `initial_shared_version` of the CapitalRegistry — lets builders reference
|
|
@@ -1197,10 +1203,6 @@ interface TokenizeArgs {
|
|
|
1197
1203
|
coinType: string;
|
|
1198
1204
|
/** The launcher-owned Coin object holding the full 1B supply (from PTB 1). */
|
|
1199
1205
|
supplyCoinId: string;
|
|
1200
|
-
/** The published coin's CoinMetadata object id (frozen, from PTB 1). */
|
|
1201
|
-
coinMetadataId: string;
|
|
1202
|
-
/** USDC CoinMetadata object id (constant on mainnet, arg for testnet). */
|
|
1203
|
-
usdcMetadataId?: string;
|
|
1204
1206
|
/** Raw USDC (6dp) the launcher seeds the pool with (≥ MIN_LP_USDC) —
|
|
1205
1207
|
* selected from the launcher's own coins, never platform funds. */
|
|
1206
1208
|
lpUsdcAmount: bigint;
|
|
@@ -1213,8 +1215,6 @@ interface TokenizeArgs {
|
|
|
1213
1215
|
/** Client for USDC coin selection (gRPC). */
|
|
1214
1216
|
client: SuiCoreClient;
|
|
1215
1217
|
}
|
|
1216
|
-
/** USDC CoinMetadata on mainnet (immutable, well-known). */
|
|
1217
|
-
declare const USDC_COIN_METADATA_ID = "0x75cfbbf8c962d542e99a1d15731e6069f60a00db895407785b15d14f606f2b4a";
|
|
1218
1218
|
/**
|
|
1219
1219
|
* PTB 2 — bind + split 50/50 + pool + 10y lock + finalize, atomically.
|
|
1220
1220
|
*/
|
|
@@ -1250,4 +1250,4 @@ declare const CETUS_POSITION_TYPE: string;
|
|
|
1250
1250
|
*/
|
|
1251
1251
|
declare const AGENT_POOL_TICK_SPACING = 200;
|
|
1252
1252
|
|
|
1253
|
-
export { AGENT_CAPITAL_PACKAGE_ID, AGENT_ID_PARENT, AGENT_ID_PARENT_NAME, AGENT_ID_PARENT_NFT_ID, AGENT_POOL_TICK_SPACING, AGENT_TOKEN_DECIMALS, AGENT_TOKEN_LP_ALLOCATION, AGENT_TOKEN_TOTAL_SUPPLY, AGENT_TOKEN_TREASURY_ALLOCATION, AUDRIC_PARENT, AUDRIC_PARENT_NAME, AUDRIC_PARENT_NFT_ID, type AgentCoinModule, type AgentCoinParams, type ApiModel, type AppenderContext, BalanceResponse, type BuildAddLeafParams, type BuildRevokeLeafParams, CAPITAL_REGISTRY_ID, CAPITAL_REGISTRY_VERSION, CETUS_CLMM_PACKAGE_ID, CETUS_GLOBAL_CONFIG_ID, CETUS_POOLS_ID, CETUS_POSITION_TYPE, type ChatMessage, type ChatParams, type ChatResult, type ChatUsage, type CheckStatus, type ComposeTxOptions, type ComposeTxResult, DEFAULT_API_BASE, type DailySpend, DepositInfo, InvalidAddressError, type LabelValidationResult, type LimitAssertInput, LimitEnforcer, LimitExceededError, type LimitKind, type LimitOperation, type LimitsConfig, type LimitsFile, MIN_LP_USDC, type NormalizedAddress, OverlayFeeConfig, PayOptions, PayResult, PaymentRequest, type PublishAgentCoinArgs, type PublishAgentCoinResult, SPONSORED_PYTH_DEPENDENT_PROVIDERS, SUINS_NAME_REGEX, SUI_ADDRESS_REGEX, SUI_ADDRESS_STRICT_REGEX, SYMBOL_BLOCKLIST, SendResult, type SendTransferInput, SendableAsset, type StepPreview, SuinsNotRegisteredError, type SuinsParent, SuinsRpcError, SupportedAsset, type SwapExecuteInput, SwapQuoteResult, SwapResult, SwapRouteResult, T2000, T2000Error, T2000Options, type TokenizeArgs, TransactionRecord, TransactionSigner, type TrustMode,
|
|
1253
|
+
export { AGENT_CAPITAL_PACKAGE_ID, AGENT_CAPITAL_PUBLISHED_AT, AGENT_ID_PARENT, AGENT_ID_PARENT_NAME, AGENT_ID_PARENT_NFT_ID, AGENT_POOL_TICK_SPACING, AGENT_TOKEN_DECIMALS, AGENT_TOKEN_LP_ALLOCATION, AGENT_TOKEN_TOTAL_SUPPLY, AGENT_TOKEN_TREASURY_ALLOCATION, AUDRIC_PARENT, AUDRIC_PARENT_NAME, AUDRIC_PARENT_NFT_ID, type AgentCoinModule, type AgentCoinParams, type ApiModel, type AppenderContext, BalanceResponse, type BuildAddLeafParams, type BuildRevokeLeafParams, CAPITAL_REGISTRY_ID, CAPITAL_REGISTRY_VERSION, CETUS_CLMM_PACKAGE_ID, CETUS_GLOBAL_CONFIG_ID, CETUS_POOLS_ID, CETUS_POSITION_TYPE, type ChatMessage, type ChatParams, type ChatResult, type ChatUsage, type CheckStatus, type ComposeTxOptions, type ComposeTxResult, DEFAULT_API_BASE, type DailySpend, DepositInfo, InvalidAddressError, type LabelValidationResult, type LimitAssertInput, LimitEnforcer, LimitExceededError, type LimitKind, type LimitOperation, type LimitsConfig, type LimitsFile, MIN_LP_USDC, type NormalizedAddress, OverlayFeeConfig, PayOptions, PayResult, PaymentRequest, type PublishAgentCoinArgs, type PublishAgentCoinResult, SPONSORED_PYTH_DEPENDENT_PROVIDERS, SUINS_NAME_REGEX, SUI_ADDRESS_REGEX, SUI_ADDRESS_STRICT_REGEX, SYMBOL_BLOCKLIST, SendResult, type SendTransferInput, SendableAsset, type StepPreview, SuinsNotRegisteredError, type SuinsParent, SuinsRpcError, SupportedAsset, type SwapExecuteInput, SwapQuoteResult, SwapResult, SwapRouteResult, T2000, T2000Error, T2000Options, type TokenizeArgs, TransactionRecord, TransactionSigner, type TrustMode, type UpstreamClaim, type VerifyAnchor, type VerifyCheck, type VerifyOptions, type VerifyResult, type VerifyUpstream, WRITE_APPENDER_REGISTRY, type WriteStep, type WriteToolName, ZkLoginProof, approxUsdValue, assertLimitConfig, buildAddLeafTx, buildAgentCoinModule, buildPublishAgentCoinTx, buildRevokeLeafTx, buildTokenizeTx, chatCompletion, chatCompletionStream, clearLimits, composeTx, dailySpentToday, deriveAllowedAddressesFromPtb, displayHandle, exportPrivateKey, fullHandle, generateKeypair, getAddress, getLimits, getSponsoredSwapProviders, getSwapQuote, hasLimits, keypairFromPrivateKey, listModels, loadKey, looksLikeSuiNs, normalizeAddressInput, queryBalance, readLimitsFile, recordDailySpend, resolveAddressToSuinsViaRpc, resolveSuinsViaRpc, saveBech32, saveKey, setLimits, validateAgentCoinParams, validateLabel, verifyReceipt, walletExists, writeLimitsFile };
|
package/dist/index.d.ts
CHANGED
|
@@ -1159,10 +1159,16 @@ declare function buildAgentCoinModule(params: AgentCoinParams): Promise<AgentCoi
|
|
|
1159
1159
|
* layer (`registry::bind/finalize` re-check agent-or-confirmed-owner on
|
|
1160
1160
|
* `ctx.sender()` every call).
|
|
1161
1161
|
*/
|
|
1162
|
-
/** The published `agent_capital` package id (mainnet,
|
|
1163
|
-
* tx `
|
|
1162
|
+
/** The published `agent_capital` package id (mainnet, FRESH deploy
|
|
1163
|
+
* 2026-07-25 from the t2000 deployer `0xe7ac…`, tx `3FvSLERmmTLp396D…` —
|
|
1164
|
+
* supersedes the orphaned 2026-07-24 `0x33a04c67…` publish, which was cut
|
|
1165
|
+
* from the wrong wallet and never bound a token). Env-overridable for
|
|
1164
1166
|
* testnet/dev (same pattern as `A2A_ESCROW_PACKAGE_ID`). */
|
|
1165
1167
|
declare const AGENT_CAPITAL_PACKAGE_ID: string;
|
|
1168
|
+
/** Latest upgraded package id — moveCall targets MUST use this (v1 lacks
|
|
1169
|
+
* the `vesting` module; Sui routes calls by the id you name). Original id
|
|
1170
|
+
* above stays for type/event references. v3 = batch-safe vesting claim. */
|
|
1171
|
+
declare const AGENT_CAPITAL_PUBLISHED_AT: string;
|
|
1166
1172
|
/** The shared `CapitalRegistry` object id (mainnet). */
|
|
1167
1173
|
declare const CAPITAL_REGISTRY_ID: string;
|
|
1168
1174
|
/** `initial_shared_version` of the CapitalRegistry — lets builders reference
|
|
@@ -1197,10 +1203,6 @@ interface TokenizeArgs {
|
|
|
1197
1203
|
coinType: string;
|
|
1198
1204
|
/** The launcher-owned Coin object holding the full 1B supply (from PTB 1). */
|
|
1199
1205
|
supplyCoinId: string;
|
|
1200
|
-
/** The published coin's CoinMetadata object id (frozen, from PTB 1). */
|
|
1201
|
-
coinMetadataId: string;
|
|
1202
|
-
/** USDC CoinMetadata object id (constant on mainnet, arg for testnet). */
|
|
1203
|
-
usdcMetadataId?: string;
|
|
1204
1206
|
/** Raw USDC (6dp) the launcher seeds the pool with (≥ MIN_LP_USDC) —
|
|
1205
1207
|
* selected from the launcher's own coins, never platform funds. */
|
|
1206
1208
|
lpUsdcAmount: bigint;
|
|
@@ -1213,8 +1215,6 @@ interface TokenizeArgs {
|
|
|
1213
1215
|
/** Client for USDC coin selection (gRPC). */
|
|
1214
1216
|
client: SuiCoreClient;
|
|
1215
1217
|
}
|
|
1216
|
-
/** USDC CoinMetadata on mainnet (immutable, well-known). */
|
|
1217
|
-
declare const USDC_COIN_METADATA_ID = "0x75cfbbf8c962d542e99a1d15731e6069f60a00db895407785b15d14f606f2b4a";
|
|
1218
1218
|
/**
|
|
1219
1219
|
* PTB 2 — bind + split 50/50 + pool + 10y lock + finalize, atomically.
|
|
1220
1220
|
*/
|
|
@@ -1250,4 +1250,4 @@ declare const CETUS_POSITION_TYPE: string;
|
|
|
1250
1250
|
*/
|
|
1251
1251
|
declare const AGENT_POOL_TICK_SPACING = 200;
|
|
1252
1252
|
|
|
1253
|
-
export { AGENT_CAPITAL_PACKAGE_ID, AGENT_ID_PARENT, AGENT_ID_PARENT_NAME, AGENT_ID_PARENT_NFT_ID, AGENT_POOL_TICK_SPACING, AGENT_TOKEN_DECIMALS, AGENT_TOKEN_LP_ALLOCATION, AGENT_TOKEN_TOTAL_SUPPLY, AGENT_TOKEN_TREASURY_ALLOCATION, AUDRIC_PARENT, AUDRIC_PARENT_NAME, AUDRIC_PARENT_NFT_ID, type AgentCoinModule, type AgentCoinParams, type ApiModel, type AppenderContext, BalanceResponse, type BuildAddLeafParams, type BuildRevokeLeafParams, CAPITAL_REGISTRY_ID, CAPITAL_REGISTRY_VERSION, CETUS_CLMM_PACKAGE_ID, CETUS_GLOBAL_CONFIG_ID, CETUS_POOLS_ID, CETUS_POSITION_TYPE, type ChatMessage, type ChatParams, type ChatResult, type ChatUsage, type CheckStatus, type ComposeTxOptions, type ComposeTxResult, DEFAULT_API_BASE, type DailySpend, DepositInfo, InvalidAddressError, type LabelValidationResult, type LimitAssertInput, LimitEnforcer, LimitExceededError, type LimitKind, type LimitOperation, type LimitsConfig, type LimitsFile, MIN_LP_USDC, type NormalizedAddress, OverlayFeeConfig, PayOptions, PayResult, PaymentRequest, type PublishAgentCoinArgs, type PublishAgentCoinResult, SPONSORED_PYTH_DEPENDENT_PROVIDERS, SUINS_NAME_REGEX, SUI_ADDRESS_REGEX, SUI_ADDRESS_STRICT_REGEX, SYMBOL_BLOCKLIST, SendResult, type SendTransferInput, SendableAsset, type StepPreview, SuinsNotRegisteredError, type SuinsParent, SuinsRpcError, SupportedAsset, type SwapExecuteInput, SwapQuoteResult, SwapResult, SwapRouteResult, T2000, T2000Error, T2000Options, type TokenizeArgs, TransactionRecord, TransactionSigner, type TrustMode,
|
|
1253
|
+
export { AGENT_CAPITAL_PACKAGE_ID, AGENT_CAPITAL_PUBLISHED_AT, AGENT_ID_PARENT, AGENT_ID_PARENT_NAME, AGENT_ID_PARENT_NFT_ID, AGENT_POOL_TICK_SPACING, AGENT_TOKEN_DECIMALS, AGENT_TOKEN_LP_ALLOCATION, AGENT_TOKEN_TOTAL_SUPPLY, AGENT_TOKEN_TREASURY_ALLOCATION, AUDRIC_PARENT, AUDRIC_PARENT_NAME, AUDRIC_PARENT_NFT_ID, type AgentCoinModule, type AgentCoinParams, type ApiModel, type AppenderContext, BalanceResponse, type BuildAddLeafParams, type BuildRevokeLeafParams, CAPITAL_REGISTRY_ID, CAPITAL_REGISTRY_VERSION, CETUS_CLMM_PACKAGE_ID, CETUS_GLOBAL_CONFIG_ID, CETUS_POOLS_ID, CETUS_POSITION_TYPE, type ChatMessage, type ChatParams, type ChatResult, type ChatUsage, type CheckStatus, type ComposeTxOptions, type ComposeTxResult, DEFAULT_API_BASE, type DailySpend, DepositInfo, InvalidAddressError, type LabelValidationResult, type LimitAssertInput, LimitEnforcer, LimitExceededError, type LimitKind, type LimitOperation, type LimitsConfig, type LimitsFile, MIN_LP_USDC, type NormalizedAddress, OverlayFeeConfig, PayOptions, PayResult, PaymentRequest, type PublishAgentCoinArgs, type PublishAgentCoinResult, SPONSORED_PYTH_DEPENDENT_PROVIDERS, SUINS_NAME_REGEX, SUI_ADDRESS_REGEX, SUI_ADDRESS_STRICT_REGEX, SYMBOL_BLOCKLIST, SendResult, type SendTransferInput, SendableAsset, type StepPreview, SuinsNotRegisteredError, type SuinsParent, SuinsRpcError, SupportedAsset, type SwapExecuteInput, SwapQuoteResult, SwapResult, SwapRouteResult, T2000, T2000Error, T2000Options, type TokenizeArgs, TransactionRecord, TransactionSigner, type TrustMode, type UpstreamClaim, type VerifyAnchor, type VerifyCheck, type VerifyOptions, type VerifyResult, type VerifyUpstream, WRITE_APPENDER_REGISTRY, type WriteStep, type WriteToolName, ZkLoginProof, approxUsdValue, assertLimitConfig, buildAddLeafTx, buildAgentCoinModule, buildPublishAgentCoinTx, buildRevokeLeafTx, buildTokenizeTx, chatCompletion, chatCompletionStream, clearLimits, composeTx, dailySpentToday, deriveAllowedAddressesFromPtb, displayHandle, exportPrivateKey, fullHandle, generateKeypair, getAddress, getLimits, getSponsoredSwapProviders, getSwapQuote, hasLimits, keypairFromPrivateKey, listModels, loadKey, looksLikeSuiNs, normalizeAddressInput, queryBalance, readLimitsFile, recordDailySpend, resolveAddressToSuinsViaRpc, resolveSuinsViaRpc, saveBech32, saveKey, setLimits, validateAgentCoinParams, validateLabel, verifyReceipt, walletExists, writeLimitsFile };
|
package/dist/index.js
CHANGED
|
@@ -3912,10 +3912,10 @@ function bigintSqrt(n) {
|
|
|
3912
3912
|
}
|
|
3913
3913
|
return prev;
|
|
3914
3914
|
}
|
|
3915
|
-
function
|
|
3915
|
+
function createPoolV3(tx, args) {
|
|
3916
3916
|
const [tickLower, tickUpper] = fullRangeTickRange(tx);
|
|
3917
3917
|
return tx.moveCall({
|
|
3918
|
-
target: `${CETUS_CLMM_PUBLISHED_AT}::pool_creator::
|
|
3918
|
+
target: `${CETUS_CLMM_PUBLISHED_AT}::pool_creator::create_pool_v3`,
|
|
3919
3919
|
typeArguments: [args.coinTypeA, args.coinTypeB],
|
|
3920
3920
|
arguments: [
|
|
3921
3921
|
tx.object(CETUS_GLOBAL_CONFIG_ID),
|
|
@@ -3927,8 +3927,6 @@ function createPoolV2(tx, args) {
|
|
|
3927
3927
|
tickUpper,
|
|
3928
3928
|
args.coinA,
|
|
3929
3929
|
args.coinB,
|
|
3930
|
-
tx.object(args.metadataA),
|
|
3931
|
-
tx.object(args.metadataB),
|
|
3932
3930
|
tx.pure.bool(args.fixAmountA),
|
|
3933
3931
|
tx.object.clock()
|
|
3934
3932
|
]
|
|
@@ -4092,10 +4090,11 @@ async function buildAgentCoinModule(params) {
|
|
|
4092
4090
|
}
|
|
4093
4091
|
|
|
4094
4092
|
// src/capital/launch.ts
|
|
4095
|
-
var AGENT_CAPITAL_PACKAGE_ID = process.env.AGENT_CAPITAL_PACKAGE_ID ?? "
|
|
4096
|
-
var
|
|
4093
|
+
var AGENT_CAPITAL_PACKAGE_ID = process.env.AGENT_CAPITAL_PACKAGE_ID ?? "0xa83ecc4e530594f8e184faf6a4c3da6791267f6791a653644d59e2e603c055b8";
|
|
4094
|
+
var AGENT_CAPITAL_PUBLISHED_AT = process.env.AGENT_CAPITAL_PUBLISHED_AT ?? "0x2974c16bda8f148ef5f8c3177d3d63eec060b1048648ae3b6c1fb495c2a602dd";
|
|
4095
|
+
var CAPITAL_REGISTRY_ID = process.env.CAPITAL_REGISTRY_ID ?? "0xef4057baac856d65b47f14a1ba14211299637955ea5bc15d7708f6eef27ee0df";
|
|
4097
4096
|
var CAPITAL_REGISTRY_VERSION = Number(
|
|
4098
|
-
process.env.CAPITAL_REGISTRY_VERSION ??
|
|
4097
|
+
process.env.CAPITAL_REGISTRY_VERSION ?? 931861908
|
|
4099
4098
|
);
|
|
4100
4099
|
function assertDeployed() {
|
|
4101
4100
|
if (!AGENT_CAPITAL_PACKAGE_ID || !CAPITAL_REGISTRY_ID) {
|
|
@@ -4108,6 +4107,7 @@ function assertDeployed() {
|
|
|
4108
4107
|
var MIN_LP_USDC = 5000000n;
|
|
4109
4108
|
var REGISTRY_MODULE = "registry";
|
|
4110
4109
|
var LP_LOCK_MODULE = "lp_lock";
|
|
4110
|
+
var VESTING_MODULE = "vesting";
|
|
4111
4111
|
async function buildPublishAgentCoinTx(args) {
|
|
4112
4112
|
if (!isValidSuiAddress(args.launcher)) {
|
|
4113
4113
|
throw new T2000Error("INVALID_ADDRESS", `bad launcher: ${args.launcher}`);
|
|
@@ -4131,7 +4131,6 @@ async function buildPublishAgentCoinTx(args) {
|
|
|
4131
4131
|
});
|
|
4132
4132
|
return { tx, moduleName: mod.moduleName, otw: mod.otw };
|
|
4133
4133
|
}
|
|
4134
|
-
var USDC_COIN_METADATA_ID = "0x75cfbbf8c962d542e99a1d15731e6069f60a00db895407785b15d14f606f2b4a";
|
|
4135
4134
|
async function buildTokenizeTx(args) {
|
|
4136
4135
|
assertDeployed();
|
|
4137
4136
|
if (!isValidSuiAddress(args.agent)) {
|
|
@@ -4154,7 +4153,7 @@ async function buildTokenizeTx(args) {
|
|
|
4154
4153
|
mutable: true
|
|
4155
4154
|
});
|
|
4156
4155
|
tx.moveCall({
|
|
4157
|
-
target: `${
|
|
4156
|
+
target: `${AGENT_CAPITAL_PUBLISHED_AT}::${REGISTRY_MODULE}::bind`,
|
|
4158
4157
|
typeArguments: [args.coinType],
|
|
4159
4158
|
arguments: [
|
|
4160
4159
|
registryArg(),
|
|
@@ -4176,12 +4175,9 @@ async function buildTokenizeTx(args) {
|
|
|
4176
4175
|
);
|
|
4177
4176
|
const usdcFirst = args.usdcFirst ?? false;
|
|
4178
4177
|
const sqrtPrice = usdcFirst ? sqrtPriceX64FromAmounts(args.lpUsdcAmount, AGENT_TOKEN_LP_ALLOCATION) : sqrtPriceX64FromAmounts(AGENT_TOKEN_LP_ALLOCATION, args.lpUsdcAmount);
|
|
4179
|
-
const
|
|
4180
|
-
const poolResult = createPoolV2(tx, {
|
|
4178
|
+
const poolResult = createPoolV3(tx, {
|
|
4181
4179
|
coinTypeA: usdcFirst ? USDC_TYPE : args.coinType,
|
|
4182
4180
|
coinTypeB: usdcFirst ? args.coinType : USDC_TYPE,
|
|
4183
|
-
metadataA: usdcFirst ? usdcMeta : args.coinMetadataId,
|
|
4184
|
-
metadataB: usdcFirst ? args.coinMetadataId : usdcMeta,
|
|
4185
4181
|
coinA: usdcFirst ? lpUsdc : lpCoin,
|
|
4186
4182
|
coinB: usdcFirst ? lpCoin : lpUsdc,
|
|
4187
4183
|
sqrtPriceX64: sqrtPrice,
|
|
@@ -4194,12 +4190,12 @@ async function buildTokenizeTx(args) {
|
|
|
4194
4190
|
const refundB = poolResult[2];
|
|
4195
4191
|
const poolId = positionPoolId(tx, position);
|
|
4196
4192
|
const [lockId] = tx.moveCall({
|
|
4197
|
-
target: `${
|
|
4193
|
+
target: `${AGENT_CAPITAL_PUBLISHED_AT}::${LP_LOCK_MODULE}::lock`,
|
|
4198
4194
|
typeArguments: [CETUS_POSITION_TYPE],
|
|
4199
4195
|
arguments: [position, tx.pure.address(args.agent), tx.object.clock()]
|
|
4200
4196
|
});
|
|
4201
4197
|
tx.moveCall({
|
|
4202
|
-
target: `${
|
|
4198
|
+
target: `${AGENT_CAPITAL_PUBLISHED_AT}::${REGISTRY_MODULE}::finalize`,
|
|
4203
4199
|
typeArguments: [args.coinType],
|
|
4204
4200
|
arguments: [
|
|
4205
4201
|
registryArg(),
|
|
@@ -4212,11 +4208,16 @@ async function buildTokenizeTx(args) {
|
|
|
4212
4208
|
});
|
|
4213
4209
|
const agentRefund = usdcFirst ? refundB : refundA;
|
|
4214
4210
|
const usdcRefund = usdcFirst ? refundA : refundB;
|
|
4215
|
-
tx.
|
|
4211
|
+
tx.mergeCoins(supplyCoin, [agentRefund]);
|
|
4212
|
+
tx.moveCall({
|
|
4213
|
+
target: `${AGENT_CAPITAL_PUBLISHED_AT}::${VESTING_MODULE}::lock`,
|
|
4214
|
+
typeArguments: [args.coinType],
|
|
4215
|
+
arguments: [supplyCoin, tx.pure.address(args.agent), tx.object.clock()]
|
|
4216
|
+
});
|
|
4216
4217
|
tx.transferObjects([usdcRefund], tx.pure.address(args.launcher));
|
|
4217
4218
|
return tx;
|
|
4218
4219
|
}
|
|
4219
4220
|
|
|
4220
|
-
export { A2A_ESCROW_FEE_CONFIG_ID, A2A_ESCROW_PACKAGE_ID, AGENT_CAPITAL_PACKAGE_ID, AGENT_ID_PARENT, AGENT_ID_PARENT_NAME, AGENT_ID_PARENT_NFT_ID, AGENT_POOL_TICK_SPACING, AGENT_TOKEN_DECIMALS, AGENT_TOKEN_LP_ALLOCATION, AGENT_TOKEN_TOTAL_SUPPLY, AGENT_TOKEN_TREASURY_ALLOCATION, AUDRIC_PARENT, AUDRIC_PARENT_NAME, AUDRIC_PARENT_NFT_ID, CAPITAL_REGISTRY_ID, CAPITAL_REGISTRY_VERSION, CETUS_CLMM_PACKAGE_ID, CETUS_GLOBAL_CONFIG_ID, CETUS_POOLS_ID, CETUS_POSITION_TYPE, CETUS_USDC_SUI_POOL, CLOCK_ID, COIN_REGISTRY, DEFAULT_API_BASE, DEFAULT_COMMERCE_API_BASE, DEFAULT_GRPC_URL, DEFAULT_NETWORK, ETH_TYPE, GASLESS_MIN_STABLE_AMOUNT, GASLESS_STABLE_TYPES, GAS_RESERVE_MIN, IKA_TYPE, InvalidAddressError, JOB_STATES, KNOWN_TARGETS, KeypairSigner, LABEL_PATTERNS, LOFI_TYPE, LimitEnforcer, LimitExceededError, MANIFEST_TYPE, MAX_DELIVER_HORIZON_MS, MAX_JOB_USDC, MAX_REVIEW_WINDOW_MS, MIN_LP_USDC, MIST_PER_SUI, NAVX_TYPE, OPERATION_ASSETS, OVERLAY_FEE_RATE, PREFLIGHT_MAX_AMOUNT, PREFLIGHT_OK, SENDABLE_ASSETS, SPONSORED_PYTH_DEPENDENT_PROVIDERS, STABLE_ASSETS, SUINS_NAME_REGEX, SUI_ADDRESS_REGEX, SUI_ADDRESS_STRICT_REGEX, SUI_DECIMALS, SUI_TYPE, SUPPORTED_ASSETS, SYMBOL_BLOCKLIST, SuinsNotRegisteredError, SuinsRpcError, T2000, T2000Error, T2000_OVERLAY_FEE_WALLET, TOKEN_MAP,
|
|
4221
|
+
export { A2A_ESCROW_FEE_CONFIG_ID, A2A_ESCROW_PACKAGE_ID, AGENT_CAPITAL_PACKAGE_ID, AGENT_CAPITAL_PUBLISHED_AT, AGENT_ID_PARENT, AGENT_ID_PARENT_NAME, AGENT_ID_PARENT_NFT_ID, AGENT_POOL_TICK_SPACING, AGENT_TOKEN_DECIMALS, AGENT_TOKEN_LP_ALLOCATION, AGENT_TOKEN_TOTAL_SUPPLY, AGENT_TOKEN_TREASURY_ALLOCATION, AUDRIC_PARENT, AUDRIC_PARENT_NAME, AUDRIC_PARENT_NFT_ID, CAPITAL_REGISTRY_ID, CAPITAL_REGISTRY_VERSION, CETUS_CLMM_PACKAGE_ID, CETUS_GLOBAL_CONFIG_ID, CETUS_POOLS_ID, CETUS_POSITION_TYPE, CETUS_USDC_SUI_POOL, CLOCK_ID, COIN_REGISTRY, DEFAULT_API_BASE, DEFAULT_COMMERCE_API_BASE, DEFAULT_GRPC_URL, DEFAULT_NETWORK, ETH_TYPE, GASLESS_MIN_STABLE_AMOUNT, GASLESS_STABLE_TYPES, GAS_RESERVE_MIN, IKA_TYPE, InvalidAddressError, JOB_STATES, KNOWN_TARGETS, KeypairSigner, LABEL_PATTERNS, LOFI_TYPE, LimitEnforcer, LimitExceededError, MANIFEST_TYPE, MAX_DELIVER_HORIZON_MS, MAX_JOB_USDC, MAX_REVIEW_WINDOW_MS, MIN_LP_USDC, MIST_PER_SUI, NAVX_TYPE, OPERATION_ASSETS, OVERLAY_FEE_RATE, PREFLIGHT_MAX_AMOUNT, PREFLIGHT_OK, SENDABLE_ASSETS, SPONSORED_PYTH_DEPENDENT_PROVIDERS, STABLE_ASSETS, SUINS_NAME_REGEX, SUI_ADDRESS_REGEX, SUI_ADDRESS_STRICT_REGEX, SUI_DECIMALS, SUI_TYPE, SUPPORTED_ASSETS, SYMBOL_BLOCKLIST, SuinsNotRegisteredError, SuinsRpcError, T2000, T2000Error, T2000_OVERLAY_FEE_WALLET, TOKEN_MAP, USDC_DECIMALS, USDC_TYPE, USDE_TYPE, USDSUI_TYPE, USDT_TYPE, WAL_TYPE, WBTC_TYPE, WRITE_APPENDER_REGISTRY, ZkLoginSigner, addSendToTx, addSwapToTx, approxUsdValue, assertAllowedAsset, assertLimitConfig, buildAddLeafTx, buildAgentCoinModule, buildCreateJobTx, buildDeliverJobTx, buildPublishAgentCoinTx, buildRefundJobTx, buildRejectJobTx, buildReleaseJobTx, buildRevokeLeafTx, buildSendTx, buildSwapTx, buildTokenizeTx, chatCompletion, chatCompletionStream, checkPositiveAmount, checkSuiAddress, classifyAction, classifyLabel, classifyTransaction, clearLimits, composeTx, dailySpentToday, deriveAllowedAddressesFromPtb, deserializeCetusRoute, displayHandle, executeTx, exportPrivateKey, extractAllUserLegs, extractTransferDetails, extractTxCommands, extractTxSender, fallbackLabel, fetchAllCoins, fetchService, findSwapRoute, formatAssetAmount, formatSui, formatUsd, fullHandle, generateKeypair, getAddress, getCoinMeta, getDecimals, getDecimalsForCoinType, getJob, getJobSpec, getLimits, getSponsoredSwapProviders, getSuiClient, getSuiGrpcClient, getSwapQuote, hasLimits, isAllowedAsset, isCetusRouteFresh, isInRegistry, jobActionsFor, keypairFromPrivateKey, listModels, listServices, loadKey, looksLikeSuiNs, mapMoveAbortCode, mapWalletError, mistToSui, normalizeAddressInput, normalizeAsset, normalizeCoinType, parseMppSuiChallenge, parseSuiRpcTx, payWithMpp, preflightCreateJob, preflightFail, preflightPay, preflightSend, preflightSwap, putJobSpec, queryBalance, queryHistory, queryTransaction, rawToStable, rawToUsdc, readLimitsFile, recordDailySpend, refineLendingLabel, resolveAddressToSuinsViaRpc, resolveSuinsViaRpc, resolveSymbol, resolveTokenType, saveBech32, saveKey, selectAndSplitCoin, selectSuiCoin, serializeCetusRoute, setLimits, simulateTransaction, stableToRaw, suiToMist, throwIfSimulationFailed, truncateAddress, usdcToRaw, validateAddress, validateAgentCoinParams, validateLabel, verifyCetusRouteCoinMatch, verifyJobForSeller, verifyReceipt, walletExists, writeLimitsFile };
|
|
4221
4222
|
//# sourceMappingURL=index.js.map
|
|
4222
4223
|
//# sourceMappingURL=index.js.map
|