@0xmonaco/types 1.0.3 → 1.0.14
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/faucet/index.d.ts +20 -4
- package/dist/wire/schema.d.ts +25 -2
- package/package.json +2 -2
package/dist/faucet/index.d.ts
CHANGED
|
@@ -29,6 +29,15 @@ export interface FailedMint {
|
|
|
29
29
|
/** Error message describing why the mint failed */
|
|
30
30
|
error: string;
|
|
31
31
|
}
|
|
32
|
+
/** Parameters for a faucet mint request. */
|
|
33
|
+
export interface MintTokensParams {
|
|
34
|
+
/**
|
|
35
|
+
* Cloudflare Turnstile token proving the request came from a real client.
|
|
36
|
+
* Required when the gateway has captcha enforcement enabled; ignored
|
|
37
|
+
* otherwise.
|
|
38
|
+
*/
|
|
39
|
+
turnstileToken?: string;
|
|
40
|
+
}
|
|
32
41
|
/** Result of a faucet mint request. */
|
|
33
42
|
export interface MintTokensResponse {
|
|
34
43
|
/** Tokens that were successfully minted */
|
|
@@ -45,10 +54,17 @@ export interface FaucetAPI extends BaseAPI {
|
|
|
45
54
|
/**
|
|
46
55
|
* Mints the full set of testnet tokens to the authenticated user.
|
|
47
56
|
*
|
|
48
|
-
* Testnet-only and rate-limited; see the module note.
|
|
49
|
-
*
|
|
57
|
+
* Testnet-only and rate-limited; see the module note. The call is
|
|
58
|
+
* synchronous and resolves only when every faucet transaction confirmed
|
|
59
|
+
* on-chain (HTTP 200). Failures reject with meaningful status codes:
|
|
60
|
+
* 429 when the daily quota is exhausted, 502 when transactions failed or
|
|
61
|
+
* were only partially confirmed on-chain (the error details carry the
|
|
62
|
+
* minted/failed breakdown; delivered legs still consume the quota), and
|
|
63
|
+
* 503 when the faucet is unavailable (nothing credited, safe to retry).
|
|
50
64
|
*
|
|
51
|
-
* @
|
|
65
|
+
* @param params - Optional parameters (Turnstile captcha token when the
|
|
66
|
+
* gateway requires one)
|
|
67
|
+
* @returns Promise resolving to the minted tokens and remaining quota
|
|
52
68
|
*/
|
|
53
|
-
mint(): Promise<MintTokensResponse>;
|
|
69
|
+
mint(params?: MintTokensParams): Promise<MintTokensResponse>;
|
|
54
70
|
}
|
package/dist/wire/schema.d.ts
CHANGED
|
@@ -671,7 +671,8 @@ export interface paths {
|
|
|
671
671
|
* @description Mint all testnet tokens.
|
|
672
672
|
*
|
|
673
673
|
* Mint all available testnet tokens to the authenticated user's address.
|
|
674
|
-
* Rate limited per 24 hours.
|
|
674
|
+
* Rate limited per 24 hours. The request is synchronous: it returns 200
|
|
675
|
+
* only once every faucet transaction is confirmed on-chain.
|
|
675
676
|
*/
|
|
676
677
|
post: operations["mint_tokens"];
|
|
677
678
|
delete?: never;
|
|
@@ -4707,6 +4708,10 @@ export interface components {
|
|
|
4707
4708
|
maxSlippageBps?: number | null;
|
|
4708
4709
|
executionPriceRange?: components["schemas"]["ExecutionPriceRange"];
|
|
4709
4710
|
};
|
|
4711
|
+
MintTokensRequest: {
|
|
4712
|
+
/** @description Cloudflare Turnstile token; required when faucet captcha enforcement is enabled */
|
|
4713
|
+
turnstileToken?: string | null;
|
|
4714
|
+
};
|
|
4710
4715
|
MintTokensResponse: {
|
|
4711
4716
|
minted?: components["schemas"]["MintedToken"][] | null;
|
|
4712
4717
|
failed?: components["schemas"]["FailedMint"][] | null;
|
|
@@ -7509,7 +7514,11 @@ export interface operations {
|
|
|
7509
7514
|
path?: never;
|
|
7510
7515
|
cookie?: never;
|
|
7511
7516
|
};
|
|
7512
|
-
requestBody?:
|
|
7517
|
+
requestBody?: {
|
|
7518
|
+
content: {
|
|
7519
|
+
"application/json": components["schemas"]["MintTokensRequest"];
|
|
7520
|
+
};
|
|
7521
|
+
};
|
|
7513
7522
|
responses: {
|
|
7514
7523
|
/** @description OK */
|
|
7515
7524
|
200: {
|
|
@@ -7548,6 +7557,20 @@ export interface operations {
|
|
|
7548
7557
|
};
|
|
7549
7558
|
content?: never;
|
|
7550
7559
|
};
|
|
7560
|
+
/** @description Faucet transactions failed or were only partially confirmed on-chain; the error details carry the minted/failed breakdown. Do not blindly retry: delivered legs consume the daily quota */
|
|
7561
|
+
502: {
|
|
7562
|
+
headers: {
|
|
7563
|
+
[name: string]: unknown;
|
|
7564
|
+
};
|
|
7565
|
+
content?: never;
|
|
7566
|
+
};
|
|
7567
|
+
/** @description Faucet unavailable (not configured, resolver down, or reply timed out); nothing is known to have been credited, safe to retry */
|
|
7568
|
+
503: {
|
|
7569
|
+
headers: {
|
|
7570
|
+
[name: string]: unknown;
|
|
7571
|
+
};
|
|
7572
|
+
content?: never;
|
|
7573
|
+
};
|
|
7551
7574
|
};
|
|
7552
7575
|
};
|
|
7553
7576
|
simulate_fees: {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@0xmonaco/types",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.14",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -20,7 +20,7 @@
|
|
|
20
20
|
"lint": "biome lint ."
|
|
21
21
|
},
|
|
22
22
|
"dependencies": {
|
|
23
|
-
"@0xmonaco/contracts": "1.0.
|
|
23
|
+
"@0xmonaco/contracts": "1.0.14",
|
|
24
24
|
"zod": "^4.1.12"
|
|
25
25
|
},
|
|
26
26
|
"peerDependencies": {
|