@suigar/mcp 0.1.0 → 0.1.1
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/CHANGELOG.md +19 -0
- package/dist/bin.cjs +1 -1
- package/dist/bin.mjs +1 -1
- package/dist/index.cjs +43 -50
- package/dist/index.d.cts +818 -8
- package/dist/index.d.mts +818 -8
- package/dist/index.mjs +1 -8
- package/{node_modules/@suigar/sui-rpc-pool/dist/index.cjs → dist/server-BD-123-u.mjs} +2084 -671
- package/{node_modules/@suigar/sui-rpc-pool/dist/index.mjs → dist/server-Cmo8UaHE.cjs} +2341 -645
- package/dist/server.cjs +3 -432
- package/dist/server.mjs +1 -430
- package/package.json +75 -61
- package/dist/client.cjs +0 -46
- package/dist/client.d.cts +0 -17
- package/dist/client.d.mts +0 -17
- package/dist/client.mjs +0 -43
- package/dist/coin.cjs +0 -86
- package/dist/coin.d.cts +0 -35
- package/dist/coin.d.mts +0 -35
- package/dist/coin.mjs +0 -86
- package/dist/config.cjs +0 -183
- package/dist/config.d.cts +0 -15
- package/dist/config.d.mts +0 -15
- package/dist/config.mjs +0 -174
- package/dist/mcp-support.cjs +0 -62
- package/dist/mcp-support.d.cts +0 -16
- package/dist/mcp-support.d.mts +0 -16
- package/dist/mcp-support.mjs +0 -60
- package/dist/metadata.cjs +0 -51
- package/dist/metadata.d.cts +0 -52
- package/dist/metadata.d.mts +0 -52
- package/dist/metadata.mjs +0 -47
- package/dist/tools.cjs +0 -617
- package/dist/tools.d.cts +0 -158
- package/dist/tools.d.mts +0 -158
- package/dist/tools.mjs +0 -608
- package/dist/transactions.cjs +0 -294
- package/dist/transactions.d.cts +0 -40
- package/dist/transactions.d.mts +0 -40
- package/dist/transactions.mjs +0 -286
- package/dist/types.d.cts +0 -111
- package/dist/types.d.mts +0 -111
- package/node_modules/@suigar/currency-registry/dist/index.cjs +0 -121
- package/node_modules/@suigar/currency-registry/dist/index.d.cts +0 -50
- package/node_modules/@suigar/currency-registry/dist/index.d.mts +0 -50
- package/node_modules/@suigar/currency-registry/dist/index.mjs +0 -110
- package/node_modules/@suigar/currency-registry/package.json +0 -31
- package/node_modules/@suigar/game-registry/dist/index.cjs +0 -310
- package/node_modules/@suigar/game-registry/dist/index.d.cts +0 -65
- package/node_modules/@suigar/game-registry/dist/index.d.mts +0 -65
- package/node_modules/@suigar/game-registry/dist/index.mjs +0 -292
- package/node_modules/@suigar/game-registry/package.json +0 -31
- package/node_modules/@suigar/sui-rpc-pool/dist/index.d.cts +0 -465
- package/node_modules/@suigar/sui-rpc-pool/dist/index.d.mts +0 -465
- package/node_modules/@suigar/sui-rpc-pool/package.json +0 -31
package/dist/index.d.cts
CHANGED
|
@@ -1,10 +1,820 @@
|
|
|
1
|
-
import { GameMcpSupport, McpExecutionSurface, SUPPORTED_MCP_TOOL_NAMES, SuigarMcpToolName, buildMcpSupportCatalog, getMcpSupportForGame } from "./mcp-support.cjs";
|
|
2
|
-
import { BetCoinSource, BetMetadataInput, BetMetadataInputValue, BetMetadataPrimitive, BuilderMode, CasinoBetGameId, CoinReadClient, CoinSide, ConfigInspection, ReadOnlyPlan, SharedBuildOptions, SuigarConfig, SuigarConfigInput, SuigarNetwork, SupportedGameId, TransactionSummary } from "./types.cjs";
|
|
3
|
-
import { assertRequiredConfig, buildGraphqlUrl, buildProviderUrl, getRequiredConfigKeysForGame, inspectResolvedConfig, parseApiUrl, resolveGamePackageId, resolveGameSettingsId, resolvePythPriceInfoId, resolveSuigarConfig } from "./config.cjs";
|
|
4
|
-
import { getCurrencyInfo, getGameMetadata, listConfiguredCurrencies, listSupportedGames, readConfigMetadata } from "./metadata.cjs";
|
|
5
|
-
import { resolveBetCoin } from "./coin.cjs";
|
|
6
|
-
import { createReadOnlyClientBundle, dryRunTransaction, sanitizeForJson, serializeTransactionToBase64 } from "./client.cjs";
|
|
7
|
-
import { buildCoinflipTransaction, buildLimboTransaction, buildPlinkoTransaction, buildPvpCoinflipCancelTransaction, buildPvpCoinflipCreateTransaction, buildPvpCoinflipJoinTransaction, buildRangeTransaction, buildWheelTransaction, summarizeTransaction } from "./transactions.cjs";
|
|
8
|
-
import { buildCoinflipTransactionTool, buildLimboTransactionTool, buildPlinkoTransactionTool, buildPvpCoinflipCancelTransactionTool, buildPvpCoinflipCreateTransactionTool, buildPvpCoinflipJoinTransactionTool, buildRangeTransactionTool, buildWheelTransactionTool, readConfigTool, readGameMetadataTool } from "./tools.cjs";
|
|
9
1
|
import { createSuigarMcpServer, startSuigarMcpServer } from "./server.cjs";
|
|
2
|
+
import { SuiGraphQLClient } from "@mysten/sui/graphql";
|
|
3
|
+
import { SuiGrpcClient } from "@mysten/sui/grpc";
|
|
4
|
+
import { Transaction } from "@mysten/sui/transactions";
|
|
5
|
+
|
|
6
|
+
//#region ../currency-registry/dist/index.d.mts
|
|
7
|
+
//#region src/index.d.ts
|
|
8
|
+
type CurrencyFamilyId = 'sui' | 'usdc';
|
|
9
|
+
type ConfiguredCurrencyId = 'sui' | 'usdc';
|
|
10
|
+
type ConfiguredCurrencyEntry = {
|
|
11
|
+
id: ConfiguredCurrencyId;
|
|
12
|
+
familyId: CurrencyFamilyId;
|
|
13
|
+
symbol: string;
|
|
14
|
+
name: string;
|
|
15
|
+
type: string;
|
|
16
|
+
normalizedType: string;
|
|
17
|
+
decimals: number;
|
|
18
|
+
};
|
|
19
|
+
//#endregion
|
|
20
|
+
//#region ../game-registry/dist/index.d.mts
|
|
21
|
+
//#region src/index.d.ts
|
|
22
|
+
type GameId = 'coinflip' | 'pvp-coinflip' | 'lootbox' | 'slots' | 'limbo' | 'plinko' | 'wheel' | 'range' | 'soccer';
|
|
23
|
+
type GameModule = 'coinflip' | 'pvp_coinflip' | 'lootbox' | 'slots' | 'limbo' | 'plinko' | 'wheel' | 'range' | 'soccer';
|
|
24
|
+
type GameStatus = 'active' | 'disabled' | 'hidden';
|
|
25
|
+
type OnchainGameSettingsId = 'coinflip' | 'pvp-coinflip' | 'range' | 'limbo' | 'wheel' | 'plinko' | 'soccer' | 'rps';
|
|
26
|
+
interface GameDefinition {
|
|
27
|
+
id: GameId;
|
|
28
|
+
name: string;
|
|
29
|
+
module: GameModule;
|
|
30
|
+
eventTypeName: string;
|
|
31
|
+
description?: string;
|
|
32
|
+
aliases: string[];
|
|
33
|
+
tags?: string[];
|
|
34
|
+
status?: GameStatus;
|
|
35
|
+
updatedAt?: string;
|
|
36
|
+
}
|
|
37
|
+
interface OnchainGameSettingsDefinition {
|
|
38
|
+
id: OnchainGameSettingsId;
|
|
39
|
+
moduleName: string;
|
|
40
|
+
keyName: string;
|
|
41
|
+
settingsStructName: string;
|
|
42
|
+
parametersStructName: string;
|
|
43
|
+
}
|
|
44
|
+
//#endregion
|
|
45
|
+
//#region ../sui-rpc-pool/dist/index.d.mts
|
|
46
|
+
//#region src/index.d.ts
|
|
47
|
+
type NetworkName = 'mainnet' | 'testnet' | 'devnet' | 'localnet' | (string & {});
|
|
48
|
+
type SuiNetwork = NetworkName;
|
|
49
|
+
type ResilientGrpcPoolOptions = {
|
|
50
|
+
network?: string;
|
|
51
|
+
providerUrl?: string;
|
|
52
|
+
extraPublicEndpoints?: string[];
|
|
53
|
+
defaultPublicEndpoints?: string[];
|
|
54
|
+
requestTimeoutMs?: number;
|
|
55
|
+
maxAttempts?: number;
|
|
56
|
+
cooldownMs?: number;
|
|
57
|
+
maxCooldownMs?: number;
|
|
58
|
+
failureThreshold?: number;
|
|
59
|
+
retryBackoffMs?: number;
|
|
60
|
+
maxRetryRounds?: number;
|
|
61
|
+
debug?: boolean;
|
|
62
|
+
};
|
|
63
|
+
type ResilientGrpcCallOptions<T = unknown> = {
|
|
64
|
+
isDeterministicError?: (error: unknown) => boolean;
|
|
65
|
+
resolveDeterministicError?: (error: unknown) => T | undefined;
|
|
66
|
+
};
|
|
67
|
+
type SuiObjectDataOptions = {
|
|
68
|
+
showType?: boolean;
|
|
69
|
+
showOwner?: boolean;
|
|
70
|
+
showPreviousTransaction?: boolean;
|
|
71
|
+
showStorageRebate?: boolean;
|
|
72
|
+
showContent?: boolean;
|
|
73
|
+
showDisplay?: boolean;
|
|
74
|
+
showBcs?: boolean;
|
|
75
|
+
};
|
|
76
|
+
type SuiParsedData = {
|
|
77
|
+
dataType?: string;
|
|
78
|
+
type?: string;
|
|
79
|
+
fields?: Record<string, unknown>;
|
|
80
|
+
hasPublicTransfer?: boolean;
|
|
81
|
+
} & Record<string, unknown>;
|
|
82
|
+
type ObjectOwner = {
|
|
83
|
+
AddressOwner: string;
|
|
84
|
+
} | {
|
|
85
|
+
ObjectOwner: string;
|
|
86
|
+
} | {
|
|
87
|
+
Shared: {
|
|
88
|
+
initial_shared_version?: string;
|
|
89
|
+
} | Record<string, unknown>;
|
|
90
|
+
} | {
|
|
91
|
+
Immutable: true;
|
|
92
|
+
} | {
|
|
93
|
+
ConsensusAddressOwner: {
|
|
94
|
+
owner?: string;
|
|
95
|
+
startVersion?: string;
|
|
96
|
+
};
|
|
97
|
+
} | Record<string, unknown>;
|
|
98
|
+
type SuiObjectData = {
|
|
99
|
+
objectId?: string;
|
|
100
|
+
version?: string;
|
|
101
|
+
digest?: string;
|
|
102
|
+
type?: string;
|
|
103
|
+
owner?: ObjectOwner;
|
|
104
|
+
previousTransaction?: string;
|
|
105
|
+
storageRebate?: string;
|
|
106
|
+
content?: SuiParsedData | null;
|
|
107
|
+
bcs?: {
|
|
108
|
+
bcsBytes: string;
|
|
109
|
+
};
|
|
110
|
+
};
|
|
111
|
+
type SuiObjectResponse = {
|
|
112
|
+
data: SuiObjectData | null;
|
|
113
|
+
error?: Record<string, unknown>;
|
|
114
|
+
};
|
|
115
|
+
type GetObjectParams = {
|
|
116
|
+
id: string;
|
|
117
|
+
options?: SuiObjectDataOptions | null;
|
|
118
|
+
};
|
|
119
|
+
type MultiGetObjectsParams = {
|
|
120
|
+
ids: string[];
|
|
121
|
+
options?: SuiObjectDataOptions | null;
|
|
122
|
+
};
|
|
123
|
+
type GetOwnedObjectsParams = {
|
|
124
|
+
owner: string;
|
|
125
|
+
filter?: {
|
|
126
|
+
StructType: string;
|
|
127
|
+
} | {
|
|
128
|
+
MoveModule: {
|
|
129
|
+
package: string;
|
|
130
|
+
module: string;
|
|
131
|
+
};
|
|
132
|
+
} | {
|
|
133
|
+
MatchAll: unknown[];
|
|
134
|
+
} | {
|
|
135
|
+
MatchAny: unknown[];
|
|
136
|
+
} | {
|
|
137
|
+
MatchNone: unknown[];
|
|
138
|
+
} | Record<string, unknown> | null;
|
|
139
|
+
options?: SuiObjectDataOptions | null;
|
|
140
|
+
cursor?: string | null;
|
|
141
|
+
limit?: number | null;
|
|
142
|
+
};
|
|
143
|
+
type PaginatedObjectsResponse = {
|
|
144
|
+
data: SuiObjectResponse[];
|
|
145
|
+
hasNextPage: boolean;
|
|
146
|
+
nextCursor: string | null;
|
|
147
|
+
};
|
|
148
|
+
type GetCoinsParams = {
|
|
149
|
+
owner: string;
|
|
150
|
+
coinType?: string | null;
|
|
151
|
+
cursor?: string | null;
|
|
152
|
+
limit?: number | null;
|
|
153
|
+
};
|
|
154
|
+
type PaginatedCoins = {
|
|
155
|
+
data: Array<{
|
|
156
|
+
coinObjectId: string;
|
|
157
|
+
version: string;
|
|
158
|
+
digest: string;
|
|
159
|
+
coinType: string;
|
|
160
|
+
balance: string;
|
|
161
|
+
previousTransaction: string;
|
|
162
|
+
}>;
|
|
163
|
+
hasNextPage: boolean;
|
|
164
|
+
nextCursor: string | null;
|
|
165
|
+
};
|
|
166
|
+
type GetBalanceParams = {
|
|
167
|
+
owner: string;
|
|
168
|
+
coinType?: string | null;
|
|
169
|
+
};
|
|
170
|
+
type CoinBalance = {
|
|
171
|
+
coinType: string;
|
|
172
|
+
totalBalance: string;
|
|
173
|
+
coinObjectCount: number;
|
|
174
|
+
lockedBalance: Record<string, string>;
|
|
175
|
+
};
|
|
176
|
+
type GetAllBalancesParams = {
|
|
177
|
+
owner: string;
|
|
178
|
+
};
|
|
179
|
+
type DynamicFieldInfo = {
|
|
180
|
+
name: {
|
|
181
|
+
type?: string;
|
|
182
|
+
value?: unknown;
|
|
183
|
+
bcsName?: string;
|
|
184
|
+
} & Record<string, unknown>;
|
|
185
|
+
bcsEncoding: 'base64';
|
|
186
|
+
bcsName: string;
|
|
187
|
+
type: 'DynamicField' | 'DynamicObject';
|
|
188
|
+
objectType: string;
|
|
189
|
+
objectId: string;
|
|
190
|
+
version: string;
|
|
191
|
+
digest: string;
|
|
192
|
+
};
|
|
193
|
+
type DynamicFieldPage = {
|
|
194
|
+
data: DynamicFieldInfo[];
|
|
195
|
+
hasNextPage: boolean;
|
|
196
|
+
nextCursor: string | null;
|
|
197
|
+
};
|
|
198
|
+
type GetDynamicFieldsParams = {
|
|
199
|
+
parentId: string;
|
|
200
|
+
cursor?: string | null;
|
|
201
|
+
limit?: number | null;
|
|
202
|
+
};
|
|
203
|
+
type GetDynamicFieldObjectParams = {
|
|
204
|
+
parentId: string;
|
|
205
|
+
name: {
|
|
206
|
+
type?: string;
|
|
207
|
+
value?: unknown;
|
|
208
|
+
bcsName?: string;
|
|
209
|
+
} & Record<string, unknown>;
|
|
210
|
+
};
|
|
211
|
+
type PaginatedStrings = {
|
|
212
|
+
data: string[];
|
|
213
|
+
hasNextPage: boolean;
|
|
214
|
+
nextCursor: string | null;
|
|
215
|
+
};
|
|
216
|
+
type ResolveNameServiceNamesParams = {
|
|
217
|
+
address: string;
|
|
218
|
+
limit?: number | null;
|
|
219
|
+
};
|
|
220
|
+
type ResolveNameServiceAddressParams = {
|
|
221
|
+
name: string;
|
|
222
|
+
};
|
|
223
|
+
type EventId = {
|
|
224
|
+
txDigest: string;
|
|
225
|
+
eventSeq: string;
|
|
226
|
+
cursor?: string;
|
|
227
|
+
};
|
|
228
|
+
type SuiEvent = {
|
|
229
|
+
id: EventId;
|
|
230
|
+
type: string;
|
|
231
|
+
packageId?: string;
|
|
232
|
+
transactionModule?: string;
|
|
233
|
+
sender?: string;
|
|
234
|
+
parsedJson?: Record<string, unknown> | null;
|
|
235
|
+
bcs?: string;
|
|
236
|
+
timestampMs?: string | null;
|
|
237
|
+
};
|
|
238
|
+
type SuiEventFilter = {
|
|
239
|
+
MoveEventType: string;
|
|
240
|
+
} | {
|
|
241
|
+
MoveEventModule: {
|
|
242
|
+
package: string;
|
|
243
|
+
module: string;
|
|
244
|
+
};
|
|
245
|
+
} | {
|
|
246
|
+
Sender: string;
|
|
247
|
+
};
|
|
248
|
+
type QueryEventsParams = {
|
|
249
|
+
query: SuiEventFilter;
|
|
250
|
+
cursor?: EventId | null;
|
|
251
|
+
limit?: number | null;
|
|
252
|
+
order?: 'ascending' | 'descending';
|
|
253
|
+
};
|
|
254
|
+
type PaginatedEvents = {
|
|
255
|
+
data: SuiEvent[];
|
|
256
|
+
hasNextPage: boolean;
|
|
257
|
+
nextCursor: EventId | null;
|
|
258
|
+
};
|
|
259
|
+
type SuiObjectChangeCreated = {
|
|
260
|
+
type: 'created';
|
|
261
|
+
sender?: string;
|
|
262
|
+
owner?: ObjectOwner;
|
|
263
|
+
objectType?: string;
|
|
264
|
+
objectId: string;
|
|
265
|
+
version?: string;
|
|
266
|
+
digest?: string;
|
|
267
|
+
};
|
|
268
|
+
type SuiObjectChange = SuiObjectChangeCreated | {
|
|
269
|
+
type: 'mutated' | 'deleted' | 'transferred' | 'published' | 'wrapped';
|
|
270
|
+
sender?: string;
|
|
271
|
+
owner?: ObjectOwner;
|
|
272
|
+
objectType?: string;
|
|
273
|
+
objectId: string;
|
|
274
|
+
version?: string;
|
|
275
|
+
digest?: string;
|
|
276
|
+
};
|
|
277
|
+
type SuiTransactionBlockResponse = {
|
|
278
|
+
digest: string;
|
|
279
|
+
transaction?: {
|
|
280
|
+
data?: Record<string, unknown>;
|
|
281
|
+
};
|
|
282
|
+
effects?: {
|
|
283
|
+
status: {
|
|
284
|
+
status: 'success' | 'failure';
|
|
285
|
+
error?: string;
|
|
286
|
+
};
|
|
287
|
+
transactionDigest?: string;
|
|
288
|
+
gasUsed?: Record<string, unknown>;
|
|
289
|
+
created?: Array<{
|
|
290
|
+
owner?: ObjectOwner;
|
|
291
|
+
reference?: {
|
|
292
|
+
objectId: string;
|
|
293
|
+
version?: string;
|
|
294
|
+
digest?: string;
|
|
295
|
+
};
|
|
296
|
+
}>;
|
|
297
|
+
mutated?: Array<{
|
|
298
|
+
owner?: ObjectOwner;
|
|
299
|
+
reference?: {
|
|
300
|
+
objectId: string;
|
|
301
|
+
version?: string;
|
|
302
|
+
digest?: string;
|
|
303
|
+
};
|
|
304
|
+
}>;
|
|
305
|
+
};
|
|
306
|
+
events?: SuiEvent[];
|
|
307
|
+
balanceChanges?: Array<{
|
|
308
|
+
owner: ObjectOwner | null;
|
|
309
|
+
coinType: string;
|
|
310
|
+
amount: string;
|
|
311
|
+
}>;
|
|
312
|
+
objectChanges?: SuiObjectChange[];
|
|
313
|
+
timestampMs?: string | null;
|
|
314
|
+
};
|
|
315
|
+
type QueryTransactionBlocksParams = {
|
|
316
|
+
filter?: {
|
|
317
|
+
FromAddress?: string;
|
|
318
|
+
ToAddress?: string;
|
|
319
|
+
} | null;
|
|
320
|
+
options?: {
|
|
321
|
+
showInput?: boolean;
|
|
322
|
+
showEffects?: boolean;
|
|
323
|
+
showEvents?: boolean;
|
|
324
|
+
showBalanceChanges?: boolean;
|
|
325
|
+
showObjectChanges?: boolean;
|
|
326
|
+
} | null;
|
|
327
|
+
cursor?: string | null;
|
|
328
|
+
limit?: number | null;
|
|
329
|
+
order?: 'ascending' | 'descending';
|
|
330
|
+
};
|
|
331
|
+
type PaginatedTransactionResponse = {
|
|
332
|
+
data: SuiTransactionBlockResponse[];
|
|
333
|
+
hasNextPage: boolean;
|
|
334
|
+
nextCursor: string | null;
|
|
335
|
+
};
|
|
336
|
+
type WaitForTransactionParams = {
|
|
337
|
+
digest?: string;
|
|
338
|
+
result?: unknown;
|
|
339
|
+
options?: {
|
|
340
|
+
showEffects?: boolean;
|
|
341
|
+
showEvents?: boolean;
|
|
342
|
+
showBalanceChanges?: boolean;
|
|
343
|
+
showObjectChanges?: boolean;
|
|
344
|
+
showInput?: boolean;
|
|
345
|
+
} | null;
|
|
346
|
+
timeout?: number;
|
|
347
|
+
};
|
|
348
|
+
type SuiCompatClient = {
|
|
349
|
+
getObject(params: GetObjectParams): Promise<SuiObjectResponse>;
|
|
350
|
+
multiGetObjects(params: MultiGetObjectsParams): Promise<SuiObjectResponse[]>;
|
|
351
|
+
getOwnedObjects(params: GetOwnedObjectsParams): Promise<PaginatedObjectsResponse>;
|
|
352
|
+
getCoins(params: GetCoinsParams): Promise<PaginatedCoins>;
|
|
353
|
+
getBalance(params: GetBalanceParams): Promise<CoinBalance>;
|
|
354
|
+
getAllBalances(params: GetAllBalancesParams): Promise<CoinBalance[]>;
|
|
355
|
+
getDynamicFields(params: GetDynamicFieldsParams): Promise<DynamicFieldPage>;
|
|
356
|
+
getDynamicFieldObject(params: GetDynamicFieldObjectParams): Promise<SuiObjectResponse>;
|
|
357
|
+
resolveNameServiceNames(params: ResolveNameServiceNamesParams): Promise<PaginatedStrings>;
|
|
358
|
+
resolveNameServiceAddress(params: ResolveNameServiceAddressParams): Promise<string | null>;
|
|
359
|
+
getReferenceGasPrice(): Promise<bigint>;
|
|
360
|
+
queryEvents(params: QueryEventsParams): Promise<PaginatedEvents>;
|
|
361
|
+
queryTransactionBlocks(params: QueryTransactionBlocksParams): Promise<PaginatedTransactionResponse>;
|
|
362
|
+
waitForTransaction(params: WaitForTransactionParams): Promise<SuiTransactionBlockResponse>;
|
|
363
|
+
};
|
|
364
|
+
type BuildSuiCompatClientOptions = {
|
|
365
|
+
network: SuiNetwork;
|
|
366
|
+
defaultCoinType?: string;
|
|
367
|
+
graphqlUrl?: string;
|
|
368
|
+
graphqlClient?: SuiGraphQLClient;
|
|
369
|
+
grpcPool?: ResilientGrpcPool;
|
|
370
|
+
resolveGrpcClient?: (endpointUrl: string) => SuiGrpcClient;
|
|
371
|
+
providerGrpcUrl?: string;
|
|
372
|
+
};
|
|
373
|
+
declare class ResilientGrpcPool {
|
|
374
|
+
private readonly network;
|
|
375
|
+
private readonly providerUrl;
|
|
376
|
+
private readonly endpoints;
|
|
377
|
+
private readonly maxAttempts;
|
|
378
|
+
private readonly failureThreshold;
|
|
379
|
+
private readonly cooldownMs;
|
|
380
|
+
private readonly maxCooldownMs;
|
|
381
|
+
private readonly requestTimeoutMs;
|
|
382
|
+
private readonly retryBackoffMs;
|
|
383
|
+
private readonly maxRetryRounds;
|
|
384
|
+
private readonly debug;
|
|
385
|
+
constructor(options: ResilientGrpcPoolOptions);
|
|
386
|
+
getProviderUrl(): string;
|
|
387
|
+
call<T>(method: string, invoke: (endpointUrl: string) => Promise<T>, options?: ResilientGrpcCallOptions<T>): Promise<T>;
|
|
388
|
+
private pickAttemptOrder;
|
|
389
|
+
private endpointScore;
|
|
390
|
+
private invoke;
|
|
391
|
+
private markSuccess;
|
|
392
|
+
private markFailure;
|
|
393
|
+
}
|
|
394
|
+
type ResilientSuiClientRuntimeOptions = ResilientGrpcPoolOptions;
|
|
395
|
+
type ResilientSuiCompatClientOptions = Omit<BuildSuiCompatClientOptions, 'network' | 'grpcPool' | 'providerGrpcUrl' | 'resolveGrpcClient'> & {
|
|
396
|
+
rawClient?: SuiGrpcClient;
|
|
397
|
+
};
|
|
398
|
+
declare class ResilientSuiClientRuntime {
|
|
399
|
+
readonly network: SuiNetwork;
|
|
400
|
+
readonly grpcPool: ResilientGrpcPool;
|
|
401
|
+
private readonly grpcClientByUrl;
|
|
402
|
+
constructor(options: ResilientSuiClientRuntimeOptions);
|
|
403
|
+
getProviderUrl(): string;
|
|
404
|
+
getGrpcClient(endpointUrl?: string): SuiGrpcClient;
|
|
405
|
+
createCompatClient(options?: ResilientSuiCompatClientOptions): SuiCompatClient;
|
|
406
|
+
}
|
|
407
|
+
//#endregion
|
|
408
|
+
//#region src/mcp-support.d.ts
|
|
409
|
+
type SuigarMcpToolName = 'read_config' | 'read_game_metadata' | 'build_coinflip_transaction' | 'build_limbo_transaction' | 'build_plinko_transaction' | 'build_wheel_transaction' | 'build_range_transaction' | 'build_pvp_coinflip_create_transaction' | 'build_pvp_coinflip_join_transaction' | 'build_pvp_coinflip_cancel_transaction';
|
|
410
|
+
type McpExecutionSurface = 'onchain' | 'backend';
|
|
411
|
+
type GameMcpSupport = {
|
|
412
|
+
executionSurface: McpExecutionSurface;
|
|
413
|
+
toolSupported: boolean;
|
|
414
|
+
primaryToolName: SuigarMcpToolName | null;
|
|
415
|
+
};
|
|
416
|
+
declare const SUPPORTED_MCP_TOOL_NAMES: SuigarMcpToolName[];
|
|
417
|
+
declare const getMcpSupportForGame: (gameId: string) => GameMcpSupport;
|
|
418
|
+
declare const buildMcpSupportCatalog: () => Readonly<{
|
|
419
|
+
serverName: "suigar";
|
|
420
|
+
supportedToolNames: SuigarMcpToolName[];
|
|
421
|
+
}>;
|
|
422
|
+
//#endregion
|
|
423
|
+
//#region src/types.d.ts
|
|
424
|
+
type SuigarNetwork = 'mainnet' | 'testnet' | 'devnet' | 'localnet' | (string & {});
|
|
425
|
+
type BetMetadataPrimitive = string | number | boolean | bigint;
|
|
426
|
+
type BetMetadataInputValue = BetMetadataPrimitive | Uint8Array | number[];
|
|
427
|
+
type BetMetadataInput = Record<string, BetMetadataInputValue>;
|
|
428
|
+
type CoinSide = 'heads' | 'tails';
|
|
429
|
+
type BuilderMode = 'build' | 'dry-run' | 'read-only';
|
|
430
|
+
type CasinoBetGameId = 'coinflip' | 'limbo' | 'plinko' | 'wheel' | 'range';
|
|
431
|
+
type SupportedGameId = CasinoBetGameId | 'pvp-coinflip';
|
|
432
|
+
type SuigarConfig = {
|
|
433
|
+
network: SuigarNetwork;
|
|
434
|
+
providerUrl: string;
|
|
435
|
+
graphqlUrl: string;
|
|
436
|
+
siteUrl: string;
|
|
437
|
+
suigarPackageId: string;
|
|
438
|
+
coinflipPackageId: string;
|
|
439
|
+
pvpCoinflipPackageId: string;
|
|
440
|
+
plinkoPackageId: string;
|
|
441
|
+
limboPackageId: string;
|
|
442
|
+
rangePackageId: string;
|
|
443
|
+
wheelPackageId: string;
|
|
444
|
+
sweethouseId: string;
|
|
445
|
+
suiCoinType: string;
|
|
446
|
+
usdcCoinType: string;
|
|
447
|
+
suiPythPriceInfoObjectId: string;
|
|
448
|
+
usdcPythPriceInfoObjectId: string;
|
|
449
|
+
coinflipSettingsId: string;
|
|
450
|
+
pvpCoinflipSettingsId: string;
|
|
451
|
+
plinkoSettingsId: string;
|
|
452
|
+
limboSettingsId: string;
|
|
453
|
+
rangeSettingsId: string;
|
|
454
|
+
wheelSettingsId: string;
|
|
455
|
+
pvpCoinflipRegistryId: string;
|
|
456
|
+
};
|
|
457
|
+
type SuigarConfigInput = Partial<SuigarConfig> & {
|
|
458
|
+
network?: SuigarNetwork;
|
|
459
|
+
providerUrl?: string;
|
|
460
|
+
graphqlUrl?: string;
|
|
461
|
+
config?: Partial<SuigarConfig>;
|
|
462
|
+
};
|
|
463
|
+
type ConfigInspection = {
|
|
464
|
+
config: SuigarConfig;
|
|
465
|
+
configuredCurrencies: ConfiguredCurrencyEntry[];
|
|
466
|
+
availableGames: Array<GameDefinition & {
|
|
467
|
+
mcpSupport: GameMcpSupport;
|
|
468
|
+
}>;
|
|
469
|
+
missingValues: Array<keyof SuigarConfig>;
|
|
470
|
+
mcp: {
|
|
471
|
+
serverName: string;
|
|
472
|
+
supportedToolNames: SuigarMcpToolName[];
|
|
473
|
+
};
|
|
474
|
+
};
|
|
475
|
+
type CoinReadClient = Pick<SuiCompatClient, 'getCoins' | 'getReferenceGasPrice'>;
|
|
476
|
+
type BetCoinSource = {
|
|
477
|
+
kind: 'gas';
|
|
478
|
+
split?: boolean;
|
|
479
|
+
} | {
|
|
480
|
+
kind: 'object-ids';
|
|
481
|
+
objectIds: string[];
|
|
482
|
+
split?: boolean;
|
|
483
|
+
};
|
|
484
|
+
type SharedBuildOptions = {
|
|
485
|
+
config?: SuigarConfigInput;
|
|
486
|
+
client?: CoinReadClient;
|
|
487
|
+
owner: string;
|
|
488
|
+
coinType: string;
|
|
489
|
+
stake: number | bigint;
|
|
490
|
+
cashStake?: number | bigint;
|
|
491
|
+
betCount?: number | bigint;
|
|
492
|
+
metadata?: BetMetadataInput;
|
|
493
|
+
partner?: string;
|
|
494
|
+
gasBudget?: number | bigint;
|
|
495
|
+
coinSource?: BetCoinSource;
|
|
496
|
+
sender?: string;
|
|
497
|
+
allowGasCoinShortcut?: boolean;
|
|
498
|
+
};
|
|
499
|
+
type TransactionSummary = {
|
|
500
|
+
sender: string | null;
|
|
501
|
+
gasBudget: string | null;
|
|
502
|
+
gasPrice: string | null;
|
|
503
|
+
commandCount: number;
|
|
504
|
+
commands: Array<{
|
|
505
|
+
kind: string;
|
|
506
|
+
target?: string;
|
|
507
|
+
typeArguments?: string[];
|
|
508
|
+
}>;
|
|
509
|
+
inputs: number;
|
|
510
|
+
objectInputs: string[];
|
|
511
|
+
game?: SupportedGameId;
|
|
512
|
+
coinType?: string;
|
|
513
|
+
stake?: string;
|
|
514
|
+
};
|
|
515
|
+
type ReadOnlyPlan = {
|
|
516
|
+
mode: 'read-only';
|
|
517
|
+
network: SuigarNetwork;
|
|
518
|
+
game: SupportedGameId;
|
|
519
|
+
config: ConfigInspection;
|
|
520
|
+
plan: {
|
|
521
|
+
target: string | null;
|
|
522
|
+
typeArguments: string[];
|
|
523
|
+
requiredConfigKeys: Array<keyof SuigarConfig>;
|
|
524
|
+
notes: string[];
|
|
525
|
+
};
|
|
526
|
+
};
|
|
527
|
+
//#endregion
|
|
528
|
+
//#region src/config.d.ts
|
|
529
|
+
declare const resolveSuigarConfig: (input?: SuigarConfigInput) => SuigarConfig;
|
|
530
|
+
declare const getRequiredConfigKeysForGame: (game: SupportedGameId) => Array<keyof SuigarConfig>;
|
|
531
|
+
declare const inspectResolvedConfig: (input?: SuigarConfigInput) => ConfigInspection;
|
|
532
|
+
declare const resolvePythPriceInfoId: (coinType: string, configInput?: SuigarConfigInput) => string;
|
|
533
|
+
declare const resolveGamePackageId: (game: SupportedGameId, configInput?: SuigarConfigInput) => string | null;
|
|
534
|
+
declare const resolveGameSettingsId: (game: CasinoBetGameId | "pvp-coinflip", configInput?: SuigarConfigInput) => string | null;
|
|
535
|
+
declare const assertRequiredConfig: (game: SupportedGameId, configInput?: SuigarConfigInput) => SuigarConfig;
|
|
536
|
+
declare const buildProviderUrl: (network: string) => "https://fullnode.mainnet.sui.io:443" | "https://fullnode.devnet.sui.io:443" | "http://127.0.0.1:9000" | "https://fullnode.testnet.sui.io:443";
|
|
537
|
+
declare const buildGraphqlUrl: (network: string) => string;
|
|
538
|
+
declare const parseApiUrl: (value: string | undefined) => string;
|
|
539
|
+
//#endregion
|
|
540
|
+
//#region src/metadata.d.ts
|
|
541
|
+
declare const listSupportedGames: ({
|
|
542
|
+
activeOnly
|
|
543
|
+
}?: {
|
|
544
|
+
activeOnly?: boolean;
|
|
545
|
+
}) => {
|
|
546
|
+
mcpSupport: GameMcpSupport;
|
|
547
|
+
id: GameId;
|
|
548
|
+
name: string;
|
|
549
|
+
module: GameModule;
|
|
550
|
+
eventTypeName: string;
|
|
551
|
+
description?: string;
|
|
552
|
+
aliases: string[];
|
|
553
|
+
tags?: string[];
|
|
554
|
+
status?: GameStatus;
|
|
555
|
+
updatedAt?: string;
|
|
556
|
+
}[];
|
|
557
|
+
declare const getGameMetadata: (game: string, configInput?: SuigarConfigInput) => {
|
|
558
|
+
mcpSupport: GameMcpSupport;
|
|
559
|
+
packageId: string | null;
|
|
560
|
+
settingsId: string | null;
|
|
561
|
+
onchainSettings: {
|
|
562
|
+
definition: OnchainGameSettingsDefinition;
|
|
563
|
+
objectType: string;
|
|
564
|
+
parametersTypePrefix: string;
|
|
565
|
+
} | null;
|
|
566
|
+
id: GameId;
|
|
567
|
+
name: string;
|
|
568
|
+
module: GameModule;
|
|
569
|
+
eventTypeName: string;
|
|
570
|
+
description?: string;
|
|
571
|
+
aliases: string[];
|
|
572
|
+
tags?: string[];
|
|
573
|
+
status?: GameStatus;
|
|
574
|
+
updatedAt?: string;
|
|
575
|
+
};
|
|
576
|
+
declare const listConfiguredCurrencies: (configInput?: SuigarConfigInput) => ConfiguredCurrencyEntry[];
|
|
577
|
+
declare const getCurrencyInfo: (coinType: string, configInput?: SuigarConfigInput) => {
|
|
578
|
+
coinType: string;
|
|
579
|
+
configuredCurrencies: ConfiguredCurrencyEntry[];
|
|
580
|
+
metadata: {
|
|
581
|
+
symbol: string;
|
|
582
|
+
name: string;
|
|
583
|
+
decimals: number;
|
|
584
|
+
};
|
|
585
|
+
};
|
|
586
|
+
declare const readConfigMetadata: (configInput?: SuigarConfigInput) => ConfigInspection;
|
|
587
|
+
//#endregion
|
|
588
|
+
//#region src/coin.d.ts
|
|
589
|
+
declare const resolveBetCoin: ({
|
|
590
|
+
tx,
|
|
591
|
+
coinType,
|
|
592
|
+
amount,
|
|
593
|
+
suiCoinType: _suiCoinType,
|
|
594
|
+
coinSource,
|
|
595
|
+
client,
|
|
596
|
+
owner,
|
|
597
|
+
allowGasCoinShortcut
|
|
598
|
+
}: {
|
|
599
|
+
tx: Transaction;
|
|
600
|
+
coinType: string;
|
|
601
|
+
amount: number | bigint;
|
|
602
|
+
suiCoinType?: string;
|
|
603
|
+
coinSource?: BetCoinSource;
|
|
604
|
+
client?: CoinReadClient;
|
|
605
|
+
owner?: string;
|
|
606
|
+
allowGasCoinShortcut?: boolean;
|
|
607
|
+
}) => Promise<{
|
|
608
|
+
NestedResult: [number, number];
|
|
609
|
+
$kind: "NestedResult";
|
|
610
|
+
} | import("@mysten/sui/transactions").TransactionResult | {
|
|
611
|
+
$kind: "Input";
|
|
612
|
+
Input: number;
|
|
613
|
+
type?: "object";
|
|
614
|
+
} | {
|
|
615
|
+
$kind: "GasCoin";
|
|
616
|
+
GasCoin: true;
|
|
617
|
+
}>;
|
|
618
|
+
//#endregion
|
|
619
|
+
//#region src/client.d.ts
|
|
620
|
+
declare const createReadOnlyClientBundle: (configInput?: SuigarConfigInput) => {
|
|
621
|
+
config: SuigarConfig;
|
|
622
|
+
runtime: ResilientSuiClientRuntime;
|
|
623
|
+
client: SuiCompatClient;
|
|
624
|
+
rawClient: SuiGrpcClient;
|
|
625
|
+
};
|
|
626
|
+
declare const serializeTransactionToBase64: (transaction: Transaction, client: SuiGrpcClient) => Promise<string>;
|
|
627
|
+
declare const sanitizeForJson: (value: unknown) => unknown;
|
|
628
|
+
declare const dryRunTransaction: (transaction: Transaction, configInput?: SuigarConfigInput) => Promise<unknown>;
|
|
629
|
+
//#endregion
|
|
630
|
+
//#region src/transactions.d.ts
|
|
631
|
+
declare const buildCoinflipTransaction: (args: SharedBuildOptions & {
|
|
632
|
+
side: CoinSide;
|
|
633
|
+
}) => Promise<Transaction>;
|
|
634
|
+
declare const buildLimboTransaction: (args: SharedBuildOptions & {
|
|
635
|
+
targetMultiplier: number;
|
|
636
|
+
}) => Promise<Transaction>;
|
|
637
|
+
declare const buildPlinkoTransaction: (args: SharedBuildOptions & {
|
|
638
|
+
configId: number;
|
|
639
|
+
}) => Promise<Transaction>;
|
|
640
|
+
declare const buildWheelTransaction: (args: SharedBuildOptions & {
|
|
641
|
+
configId: number;
|
|
642
|
+
}) => Promise<Transaction>;
|
|
643
|
+
declare const buildRangeTransaction: (args: SharedBuildOptions & {
|
|
644
|
+
leftPoint: number;
|
|
645
|
+
rightPoint: number;
|
|
646
|
+
outOfRange?: boolean;
|
|
647
|
+
scale?: number;
|
|
648
|
+
}) => Promise<Transaction>;
|
|
649
|
+
declare const buildPvpCoinflipCreateTransaction: (args: SharedBuildOptions & {
|
|
650
|
+
creatorSide: CoinSide;
|
|
651
|
+
isPrivate?: boolean;
|
|
652
|
+
}) => Promise<Transaction>;
|
|
653
|
+
declare const buildPvpCoinflipJoinTransaction: (args: SharedBuildOptions & {
|
|
654
|
+
gameId: string;
|
|
655
|
+
}) => Promise<Transaction>;
|
|
656
|
+
declare const buildPvpCoinflipCancelTransaction: (args: Pick<SharedBuildOptions, "config" | "owner" | "sender" | "gasBudget"> & {
|
|
657
|
+
gameId: string;
|
|
658
|
+
coinType: string;
|
|
659
|
+
}) => Transaction;
|
|
660
|
+
declare const summarizeTransaction: (transaction: Transaction, context?: {
|
|
661
|
+
game?: SupportedGameId;
|
|
662
|
+
coinType?: string;
|
|
663
|
+
stake?: bigint | number;
|
|
664
|
+
}) => TransactionSummary;
|
|
665
|
+
//#endregion
|
|
666
|
+
//#region src/tools.d.ts
|
|
667
|
+
declare const readConfigTool: (input?: unknown) => Promise<ConfigInspection>;
|
|
668
|
+
declare const readGameMetadataTool: (input?: unknown) => Promise<{
|
|
669
|
+
config: ConfigInspection;
|
|
670
|
+
game: {
|
|
671
|
+
mcpSupport: GameMcpSupport;
|
|
672
|
+
packageId: string | null;
|
|
673
|
+
settingsId: string | null;
|
|
674
|
+
onchainSettings: {
|
|
675
|
+
definition: OnchainGameSettingsDefinition;
|
|
676
|
+
objectType: string;
|
|
677
|
+
parametersTypePrefix: string;
|
|
678
|
+
} | null;
|
|
679
|
+
id: GameId;
|
|
680
|
+
name: string;
|
|
681
|
+
module: GameModule;
|
|
682
|
+
eventTypeName: string;
|
|
683
|
+
description?: string;
|
|
684
|
+
aliases: string[];
|
|
685
|
+
tags?: string[];
|
|
686
|
+
status?: GameStatus;
|
|
687
|
+
updatedAt?: string;
|
|
688
|
+
} | null;
|
|
689
|
+
currency: {
|
|
690
|
+
coinType: string;
|
|
691
|
+
configuredCurrencies: ConfiguredCurrencyEntry[];
|
|
692
|
+
metadata: {
|
|
693
|
+
symbol: string;
|
|
694
|
+
name: string;
|
|
695
|
+
decimals: number;
|
|
696
|
+
};
|
|
697
|
+
} | null;
|
|
698
|
+
}>;
|
|
699
|
+
declare const buildCoinflipTransactionTool: (input?: unknown) => Promise<ReadOnlyPlan | {
|
|
700
|
+
mode: "dry-run";
|
|
701
|
+
network: SuigarNetwork;
|
|
702
|
+
config: ConfigInspection;
|
|
703
|
+
summary: TransactionSummary;
|
|
704
|
+
dryRun: unknown;
|
|
705
|
+
transactionBytesBase64?: undefined;
|
|
706
|
+
} | {
|
|
707
|
+
mode: "build" | "read-only";
|
|
708
|
+
network: SuigarNetwork;
|
|
709
|
+
config: ConfigInspection;
|
|
710
|
+
summary: TransactionSummary;
|
|
711
|
+
transactionBytesBase64: string;
|
|
712
|
+
dryRun?: undefined;
|
|
713
|
+
}>;
|
|
714
|
+
declare const buildLimboTransactionTool: (input?: unknown) => Promise<ReadOnlyPlan | {
|
|
715
|
+
mode: "dry-run";
|
|
716
|
+
network: SuigarNetwork;
|
|
717
|
+
config: ConfigInspection;
|
|
718
|
+
summary: TransactionSummary;
|
|
719
|
+
dryRun: unknown;
|
|
720
|
+
transactionBytesBase64?: undefined;
|
|
721
|
+
} | {
|
|
722
|
+
mode: "build" | "read-only";
|
|
723
|
+
network: SuigarNetwork;
|
|
724
|
+
config: ConfigInspection;
|
|
725
|
+
summary: TransactionSummary;
|
|
726
|
+
transactionBytesBase64: string;
|
|
727
|
+
dryRun?: undefined;
|
|
728
|
+
}>;
|
|
729
|
+
declare const buildPlinkoTransactionTool: (input?: unknown) => Promise<ReadOnlyPlan | {
|
|
730
|
+
mode: "dry-run";
|
|
731
|
+
network: SuigarNetwork;
|
|
732
|
+
config: ConfigInspection;
|
|
733
|
+
summary: TransactionSummary;
|
|
734
|
+
dryRun: unknown;
|
|
735
|
+
transactionBytesBase64?: undefined;
|
|
736
|
+
} | {
|
|
737
|
+
mode: "build" | "read-only";
|
|
738
|
+
network: SuigarNetwork;
|
|
739
|
+
config: ConfigInspection;
|
|
740
|
+
summary: TransactionSummary;
|
|
741
|
+
transactionBytesBase64: string;
|
|
742
|
+
dryRun?: undefined;
|
|
743
|
+
}>;
|
|
744
|
+
declare const buildWheelTransactionTool: (input?: unknown) => Promise<ReadOnlyPlan | {
|
|
745
|
+
mode: "dry-run";
|
|
746
|
+
network: SuigarNetwork;
|
|
747
|
+
config: ConfigInspection;
|
|
748
|
+
summary: TransactionSummary;
|
|
749
|
+
dryRun: unknown;
|
|
750
|
+
transactionBytesBase64?: undefined;
|
|
751
|
+
} | {
|
|
752
|
+
mode: "build" | "read-only";
|
|
753
|
+
network: SuigarNetwork;
|
|
754
|
+
config: ConfigInspection;
|
|
755
|
+
summary: TransactionSummary;
|
|
756
|
+
transactionBytesBase64: string;
|
|
757
|
+
dryRun?: undefined;
|
|
758
|
+
}>;
|
|
759
|
+
declare const buildRangeTransactionTool: (input?: unknown) => Promise<ReadOnlyPlan | {
|
|
760
|
+
mode: "dry-run";
|
|
761
|
+
network: SuigarNetwork;
|
|
762
|
+
config: ConfigInspection;
|
|
763
|
+
summary: TransactionSummary;
|
|
764
|
+
dryRun: unknown;
|
|
765
|
+
transactionBytesBase64?: undefined;
|
|
766
|
+
} | {
|
|
767
|
+
mode: "build" | "read-only";
|
|
768
|
+
network: SuigarNetwork;
|
|
769
|
+
config: ConfigInspection;
|
|
770
|
+
summary: TransactionSummary;
|
|
771
|
+
transactionBytesBase64: string;
|
|
772
|
+
dryRun?: undefined;
|
|
773
|
+
}>;
|
|
774
|
+
declare const buildPvpCoinflipCreateTransactionTool: (input?: unknown) => Promise<ReadOnlyPlan | {
|
|
775
|
+
mode: "dry-run";
|
|
776
|
+
network: SuigarNetwork;
|
|
777
|
+
config: ConfigInspection;
|
|
778
|
+
summary: TransactionSummary;
|
|
779
|
+
dryRun: unknown;
|
|
780
|
+
transactionBytesBase64?: undefined;
|
|
781
|
+
} | {
|
|
782
|
+
mode: "build" | "read-only";
|
|
783
|
+
network: SuigarNetwork;
|
|
784
|
+
config: ConfigInspection;
|
|
785
|
+
summary: TransactionSummary;
|
|
786
|
+
transactionBytesBase64: string;
|
|
787
|
+
dryRun?: undefined;
|
|
788
|
+
}>;
|
|
789
|
+
declare const buildPvpCoinflipJoinTransactionTool: (input?: unknown) => Promise<ReadOnlyPlan | {
|
|
790
|
+
mode: "dry-run";
|
|
791
|
+
network: SuigarNetwork;
|
|
792
|
+
config: ConfigInspection;
|
|
793
|
+
summary: TransactionSummary;
|
|
794
|
+
dryRun: unknown;
|
|
795
|
+
transactionBytesBase64?: undefined;
|
|
796
|
+
} | {
|
|
797
|
+
mode: "build" | "read-only";
|
|
798
|
+
network: SuigarNetwork;
|
|
799
|
+
config: ConfigInspection;
|
|
800
|
+
summary: TransactionSummary;
|
|
801
|
+
transactionBytesBase64: string;
|
|
802
|
+
dryRun?: undefined;
|
|
803
|
+
}>;
|
|
804
|
+
declare const buildPvpCoinflipCancelTransactionTool: (input?: unknown) => Promise<ReadOnlyPlan | {
|
|
805
|
+
mode: "dry-run";
|
|
806
|
+
network: SuigarNetwork;
|
|
807
|
+
config: ConfigInspection;
|
|
808
|
+
summary: TransactionSummary;
|
|
809
|
+
dryRun: unknown;
|
|
810
|
+
transactionBytesBase64?: undefined;
|
|
811
|
+
} | {
|
|
812
|
+
mode: "build" | "read-only";
|
|
813
|
+
network: SuigarNetwork;
|
|
814
|
+
config: ConfigInspection;
|
|
815
|
+
summary: TransactionSummary;
|
|
816
|
+
transactionBytesBase64: string;
|
|
817
|
+
dryRun?: undefined;
|
|
818
|
+
}>;
|
|
819
|
+
//#endregion
|
|
10
820
|
export { BetCoinSource, BetMetadataInput, BetMetadataInputValue, BetMetadataPrimitive, BuilderMode, CasinoBetGameId, CoinReadClient, CoinSide, ConfigInspection, GameMcpSupport, McpExecutionSurface, ReadOnlyPlan, SUPPORTED_MCP_TOOL_NAMES, SharedBuildOptions, SuigarConfig, SuigarConfigInput, SuigarMcpToolName, SuigarNetwork, SupportedGameId, TransactionSummary, assertRequiredConfig, buildCoinflipTransaction, buildCoinflipTransactionTool, buildGraphqlUrl, buildLimboTransaction, buildLimboTransactionTool, buildMcpSupportCatalog, buildPlinkoTransaction, buildPlinkoTransactionTool, buildProviderUrl, buildPvpCoinflipCancelTransaction, buildPvpCoinflipCancelTransactionTool, buildPvpCoinflipCreateTransaction, buildPvpCoinflipCreateTransactionTool, buildPvpCoinflipJoinTransaction, buildPvpCoinflipJoinTransactionTool, buildRangeTransaction, buildRangeTransactionTool, buildWheelTransaction, buildWheelTransactionTool, createReadOnlyClientBundle, createSuigarMcpServer, dryRunTransaction, getCurrencyInfo, getGameMetadata, getMcpSupportForGame, getRequiredConfigKeysForGame, inspectResolvedConfig, listConfiguredCurrencies, listSupportedGames, parseApiUrl, readConfigMetadata, readConfigTool, readGameMetadataTool, resolveBetCoin, resolveGamePackageId, resolveGameSettingsId, resolvePythPriceInfoId, resolveSuigarConfig, sanitizeForJson, serializeTransactionToBase64, startSuigarMcpServer, summarizeTransaction };
|