alchemy 0.69.1 → 0.70.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/bin/alchemy.js +3883 -3906
- package/bin/alchemy.ts +2 -0
- package/bin/commands/telemetry.ts +33 -0
- package/bin/services/execute-alchemy.ts +7 -0
- package/bin/trpc.ts +4 -9
- package/lib/alchemy.d.ts +7 -3
- package/lib/alchemy.d.ts.map +1 -1
- package/lib/alchemy.js +3 -15
- package/lib/alchemy.js.map +1 -1
- package/lib/apply.js +24 -9
- package/lib/apply.js.map +1 -1
- package/lib/aws/utils.d.ts +2 -1
- package/lib/aws/utils.d.ts.map +1 -1
- package/lib/aws/utils.js.map +1 -1
- package/lib/clickhouse/api/client.gen.d.ts +13 -0
- package/lib/clickhouse/api/client.gen.d.ts.map +1 -0
- package/lib/clickhouse/api/client.gen.js +7 -0
- package/lib/clickhouse/api/client.gen.js.map +1 -0
- package/lib/clickhouse/api/sdk.gen.d.ts +322 -0
- package/lib/clickhouse/api/sdk.gen.d.ts.map +1 -0
- package/lib/clickhouse/api/sdk.gen.js +683 -0
- package/lib/clickhouse/api/sdk.gen.js.map +1 -0
- package/lib/clickhouse/api/types.gen.d.ts +5030 -0
- package/lib/clickhouse/api/types.gen.d.ts.map +1 -0
- package/lib/clickhouse/api/types.gen.js +2 -0
- package/lib/clickhouse/api/types.gen.js.map +1 -0
- package/lib/clickhouse/api-key.d.ts +29 -0
- package/lib/clickhouse/api-key.d.ts.map +1 -0
- package/lib/clickhouse/api-key.js +83 -0
- package/lib/clickhouse/api-key.js.map +1 -0
- package/lib/clickhouse/api.d.ts +36 -0
- package/lib/clickhouse/api.d.ts.map +1 -0
- package/lib/clickhouse/api.js +48 -0
- package/lib/clickhouse/api.js.map +1 -0
- package/lib/clickhouse/index.d.ts +4 -0
- package/lib/clickhouse/index.d.ts.map +1 -0
- package/lib/clickhouse/index.js +4 -0
- package/lib/clickhouse/index.js.map +1 -0
- package/lib/clickhouse/organization.d.ts +16 -0
- package/lib/clickhouse/organization.d.ts.map +1 -0
- package/lib/clickhouse/organization.js +21 -0
- package/lib/clickhouse/organization.js.map +1 -0
- package/lib/clickhouse/service.d.ts +275 -0
- package/lib/clickhouse/service.d.ts.map +1 -0
- package/lib/clickhouse/service.js +274 -0
- package/lib/clickhouse/service.js.map +1 -0
- package/lib/cloudflare/account-api-token.d.ts.map +1 -1
- package/lib/cloudflare/account-api-token.js +1 -1
- package/lib/cloudflare/account-api-token.js.map +1 -1
- package/lib/cloudflare/api.d.ts.map +1 -1
- package/lib/cloudflare/api.js +2 -0
- package/lib/cloudflare/api.js.map +1 -1
- package/lib/cloudflare/bun-spa/bun-spa.d.ts +13 -0
- package/lib/cloudflare/bun-spa/bun-spa.d.ts.map +1 -0
- package/lib/cloudflare/bun-spa/bun-spa.js +95 -0
- package/lib/cloudflare/bun-spa/bun-spa.js.map +1 -0
- package/lib/cloudflare/compatibility-date.gen.d.ts +1 -1
- package/lib/cloudflare/compatibility-date.gen.js +1 -1
- package/lib/cloudflare/container.d.ts +11 -1
- package/lib/cloudflare/container.d.ts.map +1 -1
- package/lib/cloudflare/container.js.map +1 -1
- package/lib/cloudflare/index.d.ts +1 -0
- package/lib/cloudflare/index.d.ts.map +1 -1
- package/lib/cloudflare/index.js +1 -0
- package/lib/cloudflare/index.js.map +1 -1
- package/lib/cloudflare/miniflare/build-worker-options.d.ts.map +1 -1
- package/lib/cloudflare/miniflare/build-worker-options.js +33 -6
- package/lib/cloudflare/miniflare/build-worker-options.js.map +1 -1
- package/lib/cloudflare/miniflare/miniflare-controller.d.ts.map +1 -1
- package/lib/cloudflare/miniflare/miniflare-controller.js +2 -0
- package/lib/cloudflare/miniflare/miniflare-controller.js.map +1 -1
- package/lib/cloudflare/miniflare/miniflare-worker-proxy.d.ts +1 -1
- package/lib/cloudflare/miniflare/miniflare-worker-proxy.d.ts.map +1 -1
- package/lib/cloudflare/miniflare/miniflare-worker-proxy.js +36 -49
- package/lib/cloudflare/miniflare/miniflare-worker-proxy.js.map +1 -1
- package/lib/cloudflare/permission-groups.d.ts +2 -3
- package/lib/cloudflare/permission-groups.d.ts.map +1 -1
- package/lib/cloudflare/permission-groups.js +10 -15
- package/lib/cloudflare/permission-groups.js.map +1 -1
- package/lib/cloudflare/redwood/redwood.d.ts +1 -1
- package/lib/cloudflare/redwood/redwood.js +1 -1
- package/lib/cloudflare/util/filter-env-bindings.d.ts +62 -0
- package/lib/cloudflare/util/filter-env-bindings.d.ts.map +1 -0
- package/lib/cloudflare/util/filter-env-bindings.js +81 -0
- package/lib/cloudflare/util/filter-env-bindings.js.map +1 -0
- package/lib/cloudflare/website.d.ts +2 -2
- package/lib/cloudflare/website.d.ts.map +1 -1
- package/lib/cloudflare/website.js +6 -18
- package/lib/cloudflare/website.js.map +1 -1
- package/lib/cloudflare/worker-metadata.d.ts +1 -0
- package/lib/cloudflare/worker-metadata.d.ts.map +1 -1
- package/lib/cloudflare/worker-metadata.js +1 -0
- package/lib/cloudflare/worker-metadata.js.map +1 -1
- package/lib/cloudflare/worker.d.ts +11 -1
- package/lib/cloudflare/worker.d.ts.map +1 -1
- package/lib/cloudflare/worker.js.map +1 -1
- package/lib/cloudflare/wrangler.json.d.ts +8 -0
- package/lib/cloudflare/wrangler.json.d.ts.map +1 -1
- package/lib/cloudflare/wrangler.json.js +3 -4
- package/lib/cloudflare/wrangler.json.js.map +1 -1
- package/lib/coinbase/client.d.ts +54 -0
- package/lib/coinbase/client.d.ts.map +1 -0
- package/lib/coinbase/client.js +89 -0
- package/lib/coinbase/client.js.map +1 -0
- package/lib/coinbase/evm-account.d.ts +118 -0
- package/lib/coinbase/evm-account.d.ts.map +1 -0
- package/lib/coinbase/evm-account.js +198 -0
- package/lib/coinbase/evm-account.js.map +1 -0
- package/lib/coinbase/evm-smart-account.d.ts +122 -0
- package/lib/coinbase/evm-smart-account.d.ts.map +1 -0
- package/lib/coinbase/evm-smart-account.js +213 -0
- package/lib/coinbase/evm-smart-account.js.map +1 -0
- package/lib/coinbase/faucet.d.ts +11 -0
- package/lib/coinbase/faucet.d.ts.map +1 -0
- package/lib/coinbase/faucet.js +146 -0
- package/lib/coinbase/faucet.js.map +1 -0
- package/lib/coinbase/index.d.ts +4 -0
- package/lib/coinbase/index.d.ts.map +1 -0
- package/lib/coinbase/index.js +4 -0
- package/lib/coinbase/index.js.map +1 -0
- package/lib/coinbase/types.d.ts +28 -0
- package/lib/coinbase/types.d.ts.map +1 -0
- package/lib/coinbase/types.js +4 -0
- package/lib/{util/telemetry → coinbase}/types.js.map +1 -1
- package/lib/coinbase/utils.d.ts +13 -0
- package/lib/coinbase/utils.d.ts.map +1 -0
- package/lib/coinbase/utils.js +17 -0
- package/lib/coinbase/utils.js.map +1 -0
- package/lib/neon/api/types.gen.d.ts +7 -2
- package/lib/neon/api/types.gen.d.ts.map +1 -1
- package/lib/planetscale/api/types.gen.d.ts +20 -4
- package/lib/planetscale/api/types.gen.d.ts.map +1 -1
- package/lib/planetscale/api.d.ts.map +1 -1
- package/lib/planetscale/api.js +1 -0
- package/lib/planetscale/api.js.map +1 -1
- package/lib/planetscale/password.d.ts.map +1 -1
- package/lib/planetscale/password.js +1 -13
- package/lib/planetscale/password.js.map +1 -1
- package/lib/resource.d.ts.map +1 -1
- package/lib/resource.js +7 -3
- package/lib/resource.js.map +1 -1
- package/lib/scope.d.ts +9 -9
- package/lib/scope.d.ts.map +1 -1
- package/lib/scope.js +18 -37
- package/lib/scope.js.map +1 -1
- package/lib/state/instrumented-state-store.d.ts +1 -3
- package/lib/state/instrumented-state-store.d.ts.map +1 -1
- package/lib/state/instrumented-state-store.js +19 -21
- package/lib/state/instrumented-state-store.js.map +1 -1
- package/lib/test/bun.d.ts.map +1 -1
- package/lib/test/bun.js +1 -2
- package/lib/test/bun.js.map +1 -1
- package/lib/test/vitest.d.ts.map +1 -1
- package/lib/test/vitest.js +1 -2
- package/lib/test/vitest.js.map +1 -1
- package/lib/util/diff.d.ts +5 -0
- package/lib/util/diff.d.ts.map +1 -0
- package/lib/util/diff.js +14 -0
- package/lib/util/diff.js.map +1 -0
- package/lib/util/idempotent-spawn.js +1 -1
- package/lib/util/idempotent-spawn.js.map +1 -1
- package/lib/util/telemetry.d.ts +53 -0
- package/lib/util/telemetry.d.ts.map +1 -0
- package/lib/util/telemetry.js +215 -0
- package/lib/util/telemetry.js.map +1 -0
- package/package.json +19 -1
- package/src/alchemy.ts +10 -20
- package/src/apply.ts +29 -12
- package/src/aws/utils.ts +2 -1
- package/src/clickhouse/api/client.gen.ts +28 -0
- package/src/clickhouse/api/sdk.gen.ts +1286 -0
- package/src/clickhouse/api/types.gen.ts +5898 -0
- package/src/clickhouse/api-key.ts +136 -0
- package/src/clickhouse/api.ts +84 -0
- package/src/clickhouse/index.ts +3 -0
- package/src/clickhouse/organization.ts +31 -0
- package/src/clickhouse/service.ts +668 -0
- package/src/cloudflare/account-api-token.ts +1 -4
- package/src/cloudflare/api.ts +2 -0
- package/src/cloudflare/bun-spa/bun-spa.ts +136 -0
- package/src/cloudflare/compatibility-date.gen.ts +1 -1
- package/src/cloudflare/container.ts +20 -1
- package/src/cloudflare/index.ts +1 -0
- package/src/cloudflare/miniflare/build-worker-options.ts +38 -8
- package/src/cloudflare/miniflare/miniflare-controller.ts +2 -0
- package/src/cloudflare/miniflare/miniflare-worker-proxy.ts +41 -58
- package/src/cloudflare/permission-groups.ts +21 -49
- package/src/cloudflare/redwood/redwood.ts +1 -1
- package/src/cloudflare/util/filter-env-bindings.ts +96 -0
- package/src/cloudflare/website.ts +11 -24
- package/src/cloudflare/worker-metadata.ts +2 -0
- package/src/cloudflare/worker.ts +12 -1
- package/src/cloudflare/wrangler.json.ts +12 -8
- package/src/coinbase/client.ts +146 -0
- package/src/coinbase/evm-account.ts +317 -0
- package/src/coinbase/evm-smart-account.ts +339 -0
- package/src/coinbase/faucet.ts +173 -0
- package/src/coinbase/index.ts +3 -0
- package/src/coinbase/types.ts +33 -0
- package/src/coinbase/utils.ts +19 -0
- package/src/neon/api/types.gen.ts +13 -1
- package/src/planetscale/api/types.gen.ts +22 -2
- package/src/planetscale/api.ts +1 -0
- package/src/planetscale/password.ts +1 -14
- package/src/resource.ts +11 -4
- package/src/scope.ts +29 -45
- package/src/state/instrumented-state-store.ts +27 -26
- package/src/test/bun.ts +1 -2
- package/src/test/vitest.ts +1 -2
- package/src/util/diff.ts +14 -0
- package/src/util/idempotent-spawn.ts +1 -1
- package/src/util/telemetry.ts +328 -0
- package/templates/tanstack-start/package.json +2 -2
- package/workers/tunnel-proxy.js +1 -1
- package/lib/util/telemetry/client.d.ts +0 -31
- package/lib/util/telemetry/client.d.ts.map +0 -1
- package/lib/util/telemetry/client.js +0 -121
- package/lib/util/telemetry/client.js.map +0 -1
- package/lib/util/telemetry/constants.d.ts +0 -5
- package/lib/util/telemetry/constants.d.ts.map +0 -1
- package/lib/util/telemetry/constants.js +0 -8
- package/lib/util/telemetry/constants.js.map +0 -1
- package/lib/util/telemetry/context.d.ts +0 -15
- package/lib/util/telemetry/context.d.ts.map +0 -1
- package/lib/util/telemetry/context.js +0 -128
- package/lib/util/telemetry/context.js.map +0 -1
- package/lib/util/telemetry/index.d.ts +0 -3
- package/lib/util/telemetry/index.d.ts.map +0 -1
- package/lib/util/telemetry/index.js +0 -3
- package/lib/util/telemetry/index.js.map +0 -1
- package/lib/util/telemetry/types.d.ts +0 -68
- package/lib/util/telemetry/types.d.ts.map +0 -1
- package/lib/util/telemetry/types.js +0 -1
- package/src/util/telemetry/client.ts +0 -156
- package/src/util/telemetry/constants.ts +0 -13
- package/src/util/telemetry/context.ts +0 -154
- package/src/util/telemetry/index.ts +0 -2
- package/src/util/telemetry/types.ts +0 -105
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
#!/usr/bin/env bun
|
|
2
|
+
/**
|
|
3
|
+
* Request testnet tokens from Coinbase faucet for accounts with faucet metadata
|
|
4
|
+
*
|
|
5
|
+
* Usage:
|
|
6
|
+
* bun node_modules/alchemy/src/coinbase/faucet.ts # Fund all accounts with faucet config
|
|
7
|
+
* bun node_modules/alchemy/src/coinbase/faucet.ts dev # Fund only accounts in dev scope
|
|
8
|
+
* bun node_modules/alchemy/src/coinbase/faucet.ts backend/dev # Fund specific scope
|
|
9
|
+
*/
|
|
10
|
+
export {};
|
|
11
|
+
//# sourceMappingURL=faucet.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"faucet.d.ts","sourceRoot":"","sources":["../../src/coinbase/faucet.ts"],"names":[],"mappings":";AACA;;;;;;;GAOG"}
|
|
@@ -0,0 +1,146 @@
|
|
|
1
|
+
#!/usr/bin/env bun
|
|
2
|
+
/**
|
|
3
|
+
* Request testnet tokens from Coinbase faucet for accounts with faucet metadata
|
|
4
|
+
*
|
|
5
|
+
* Usage:
|
|
6
|
+
* bun node_modules/alchemy/src/coinbase/faucet.ts # Fund all accounts with faucet config
|
|
7
|
+
* bun node_modules/alchemy/src/coinbase/faucet.ts dev # Fund only accounts in dev scope
|
|
8
|
+
* bun node_modules/alchemy/src/coinbase/faucet.ts backend/dev # Fund specific scope
|
|
9
|
+
*/
|
|
10
|
+
import { readFile, access } from "node:fs/promises";
|
|
11
|
+
import { join } from "node:path";
|
|
12
|
+
import { glob } from "glob";
|
|
13
|
+
import { createCdpClient } from "./client.js";
|
|
14
|
+
// Track funded combinations to avoid duplicates within this run
|
|
15
|
+
const funded = new Set();
|
|
16
|
+
// Get optional scope argument
|
|
17
|
+
const scope = process.argv[2];
|
|
18
|
+
// Initialize CDP client (uses CDP_* env vars automatically)
|
|
19
|
+
const cdp = await createCdpClient();
|
|
20
|
+
let stateFiles;
|
|
21
|
+
if (scope) {
|
|
22
|
+
// If scope provided, find matching directories
|
|
23
|
+
const scopePath = join(".alchemy", scope);
|
|
24
|
+
let scopeExists = false;
|
|
25
|
+
try {
|
|
26
|
+
await access(scopePath);
|
|
27
|
+
scopeExists = true;
|
|
28
|
+
}
|
|
29
|
+
catch {
|
|
30
|
+
scopeExists = false;
|
|
31
|
+
}
|
|
32
|
+
if (scopeExists) {
|
|
33
|
+
// Exact match found
|
|
34
|
+
console.log(`Using scope: ${scope}`);
|
|
35
|
+
stateFiles = await glob("*.json", {
|
|
36
|
+
cwd: scopePath,
|
|
37
|
+
absolute: true,
|
|
38
|
+
});
|
|
39
|
+
}
|
|
40
|
+
else {
|
|
41
|
+
// Try to find directories that end with the provided scope
|
|
42
|
+
// We need to find directories, so we'll look for JSON files and extract the directory paths
|
|
43
|
+
const allFiles = await glob(`**/${scope}/*.json`, {
|
|
44
|
+
cwd: ".alchemy",
|
|
45
|
+
});
|
|
46
|
+
// Extract unique directory paths
|
|
47
|
+
const possibleScopes = [
|
|
48
|
+
...new Set(allFiles.map((f) => f.replace(/\/[^/]+\.json$/, ""))),
|
|
49
|
+
];
|
|
50
|
+
if (possibleScopes.length === 0) {
|
|
51
|
+
console.error(`No scope found matching: ${scope}`);
|
|
52
|
+
process.exit(1);
|
|
53
|
+
}
|
|
54
|
+
else if (possibleScopes.length === 1) {
|
|
55
|
+
// Found exactly one match
|
|
56
|
+
const foundScope = possibleScopes[0];
|
|
57
|
+
console.log(`Using scope: ${foundScope}`);
|
|
58
|
+
stateFiles = await glob("*.json", {
|
|
59
|
+
cwd: join(".alchemy", foundScope),
|
|
60
|
+
absolute: true,
|
|
61
|
+
});
|
|
62
|
+
}
|
|
63
|
+
else {
|
|
64
|
+
// Multiple matches found - use all of them
|
|
65
|
+
console.log(`Found ${possibleScopes.length} scopes matching '${scope}':`);
|
|
66
|
+
for (const s of possibleScopes) {
|
|
67
|
+
console.log(` - ${s}`);
|
|
68
|
+
}
|
|
69
|
+
// Collect state files from all matching scopes
|
|
70
|
+
stateFiles = [];
|
|
71
|
+
for (const foundScope of possibleScopes) {
|
|
72
|
+
const files = await glob("*.json", {
|
|
73
|
+
cwd: join(".alchemy", foundScope),
|
|
74
|
+
absolute: true,
|
|
75
|
+
});
|
|
76
|
+
stateFiles.push(...files);
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
}
|
|
81
|
+
else {
|
|
82
|
+
// No scope provided, search all .alchemy subdirectories
|
|
83
|
+
console.log("Searching all scopes for accounts with faucet configuration...");
|
|
84
|
+
stateFiles = await glob("**/*.json", {
|
|
85
|
+
cwd: ".alchemy",
|
|
86
|
+
absolute: true,
|
|
87
|
+
});
|
|
88
|
+
}
|
|
89
|
+
const allStates = (await Promise.all(stateFiles.map(async (file) => {
|
|
90
|
+
try {
|
|
91
|
+
const content = await readFile(file, "utf-8");
|
|
92
|
+
return JSON.parse(content);
|
|
93
|
+
}
|
|
94
|
+
catch {
|
|
95
|
+
return null;
|
|
96
|
+
}
|
|
97
|
+
}))).filter(Boolean);
|
|
98
|
+
const accounts = allStates
|
|
99
|
+
.filter((state) => state?.kind?.startsWith("coinbase::evm") &&
|
|
100
|
+
state.output &&
|
|
101
|
+
state.output.faucet)
|
|
102
|
+
.map((state) => {
|
|
103
|
+
const output = state.output;
|
|
104
|
+
return {
|
|
105
|
+
address: output.address,
|
|
106
|
+
name: output.name,
|
|
107
|
+
faucet: output.faucet,
|
|
108
|
+
};
|
|
109
|
+
});
|
|
110
|
+
if (accounts.length === 0) {
|
|
111
|
+
console.log("No accounts with faucet configuration found");
|
|
112
|
+
process.exit(0);
|
|
113
|
+
}
|
|
114
|
+
console.log(`Found ${accounts.length} accounts with faucet configuration\n`);
|
|
115
|
+
for (const account of accounts) {
|
|
116
|
+
console.log(`Account: ${account.name} (${account.address})`);
|
|
117
|
+
for (const [network, tokens] of Object.entries(account.faucet)) {
|
|
118
|
+
for (const token of tokens) {
|
|
119
|
+
const key = `${account.address}-${network}-${token}`;
|
|
120
|
+
// Skip if already processed in this run
|
|
121
|
+
if (funded.has(key)) {
|
|
122
|
+
console.log(` ⏭️ Skipping ${token} on ${network} (already requested)`);
|
|
123
|
+
continue;
|
|
124
|
+
}
|
|
125
|
+
// Request tokens from faucet
|
|
126
|
+
try {
|
|
127
|
+
console.log(` 💧 Requesting ${token} on ${network}...`);
|
|
128
|
+
const response = await cdp.evm.requestFaucet({
|
|
129
|
+
address: account.address,
|
|
130
|
+
network: network,
|
|
131
|
+
token: token,
|
|
132
|
+
});
|
|
133
|
+
console.log(` ✅ Funded: ${response.transactionHash}`);
|
|
134
|
+
funded.add(key);
|
|
135
|
+
// Small delay to avoid rate limits
|
|
136
|
+
await new Promise((resolve) => setTimeout(resolve, 1000));
|
|
137
|
+
}
|
|
138
|
+
catch (error) {
|
|
139
|
+
console.log(` ❌ Error funding ${token} on ${network}: ${error.message}`);
|
|
140
|
+
}
|
|
141
|
+
}
|
|
142
|
+
}
|
|
143
|
+
console.log();
|
|
144
|
+
}
|
|
145
|
+
console.log("✨ Funding complete!");
|
|
146
|
+
//# sourceMappingURL=faucet.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"faucet.js","sourceRoot":"","sources":["../../src/coinbase/faucet.ts"],"names":[],"mappings":";AACA;;;;;;;GAOG;AAEH,OAAO,EAAE,QAAQ,EAAE,MAAM,EAAE,MAAM,kBAAkB,CAAC;AACpD,OAAO,EAAE,IAAI,EAAE,MAAM,WAAW,CAAC;AACjC,OAAO,EAAE,IAAI,EAAE,MAAM,MAAM,CAAC;AAC5B,OAAO,EAAE,eAAe,EAAE,MAAM,aAAa,CAAC;AAK9C,gEAAgE;AAChE,MAAM,MAAM,GAAG,IAAI,GAAG,EAAU,CAAC;AAEjC,8BAA8B;AAC9B,MAAM,KAAK,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;AAE9B,4DAA4D;AAC5D,MAAM,GAAG,GAAG,MAAM,eAAe,EAAE,CAAC;AAEpC,IAAI,UAAoB,CAAC;AAEzB,IAAI,KAAK,EAAE,CAAC;IACV,+CAA+C;IAC/C,MAAM,SAAS,GAAG,IAAI,CAAC,UAAU,EAAE,KAAK,CAAC,CAAC;IAE1C,IAAI,WAAW,GAAG,KAAK,CAAC;IACxB,IAAI,CAAC;QACH,MAA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AC;gBACH,OAAO,CAAC,GAAG,CAAC,mBAAmB,KAAK,OAAO,OAAO,KAAK,CAAC,CAAC;gBAEzD,MAAM,QAAQ,GAAG,MAAM,GAAG,CAAC,GAAG,CAAC,aAAa,CAAC;oBAC3C,OAAO,EAAE,OAAO,CAAC,OAAO;oBACxB,OAAO,EAAE,OAAwB;oBACjC,KAAK,EAAE,KAAoB;iBAC5B,CAAC,CAAC;gBAEH,OAAO,CAAC,GAAG,CAAC,eAAe,QAAQ,CAAC,eAAe,EAAE,CAAC,CAAC;gBACvD,MAAM,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC;gBAEhB,mCAAmC;gBACnC,MAAM,IAAI,OAAO,CAAC,CAAC,OAAO,EAAE,EAAE,CAAC,UAAU,CAAC,OAAO,EAAE,IAAI,CAAC,CAAC,CAAC;YAC5D,CAAC;YAAC,OAAO,KAAU,EAAE,CAAC;gBACpB,OAAO,CAAC,GAAG,CACT,qBAAqB,KAAK,OAAO,OAAO,KAAK,KAAK,CAAC,OAAO,EAAE,CAC7D,CAAC;YACJ,CAAC;QACH,CAAC;IACH,CAAC;IACD,OAAO,CAAC,GAAG,EAAE,CAAC;AAChB,CAAC;AAED,OAAO,CAAC,GAAG,CAAC,qBAAqB,CAAC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/coinbase/index.ts"],"names":[],"mappings":"AAAA,cAAc,YAAY,CAAC;AAC3B,cAAc,kBAAkB,CAAC;AACjC,cAAc,wBAAwB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/coinbase/index.ts"],"names":[],"mappings":"AAAA,cAAc,YAAY,CAAC;AAC3B,cAAc,kBAAkB,CAAC;AACjC,cAAc,wBAAwB,CAAC"}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Common types for Coinbase CDP resources
|
|
3
|
+
*/
|
|
4
|
+
/**
|
|
5
|
+
* Ethereum address format (20 bytes, 40 hex chars)
|
|
6
|
+
*/
|
|
7
|
+
export type Address = `0x${string}`;
|
|
8
|
+
/**
|
|
9
|
+
* Private key format (32 bytes, 64 hex chars)
|
|
10
|
+
*/
|
|
11
|
+
export type PrivateKey = `0x${string}`;
|
|
12
|
+
/**
|
|
13
|
+
* Transaction hash format (32 bytes, 64 hex chars)
|
|
14
|
+
*/
|
|
15
|
+
export type TransactionHash = `0x${string}`;
|
|
16
|
+
/**
|
|
17
|
+
* Supported testnet networks for faucet requests
|
|
18
|
+
*/
|
|
19
|
+
export type FaucetNetwork = "base-sepolia" | "ethereum-sepolia";
|
|
20
|
+
/**
|
|
21
|
+
* Supported tokens for faucet requests
|
|
22
|
+
*/
|
|
23
|
+
export type FaucetToken = "eth" | "usdc" | "eurc" | "cbbtc";
|
|
24
|
+
/**
|
|
25
|
+
* Faucet configuration for requesting testnet tokens
|
|
26
|
+
*/
|
|
27
|
+
export type FaucetConfig = Partial<Record<FaucetNetwork, FaucetToken[]>>;
|
|
28
|
+
//# sourceMappingURL=types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/coinbase/types.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH;;GAEG;AACH,MAAM,MAAM,OAAO,GAAG,KAAK,MAAM,EAAE,CAAC;AAEpC;;GAEG;AACH,MAAM,MAAM,UAAU,GAAG,KAAK,MAAM,EAAE,CAAC;AAEvC;;GAEG;AACH,MAAM,MAAM,eAAe,GAAG,KAAK,MAAM,EAAE,CAAC;AAE5C;;GAEG;AACH,MAAM,MAAM,aAAa,GAAG,cAAc,GAAG,kBAAkB,CAAC;AAEhE;;GAEG;AACH,MAAM,MAAM,WAAW,GAAG,KAAK,GAAG,MAAM,GAAG,MAAM,GAAG,OAAO,CAAC;AAE5D;;GAEG;AACH,MAAM,MAAM,YAAY,GAAG,OAAO,CAAC,MAAM,CAAC,aAAa,EAAE,WAAW,EAAE,CAAC,CAAC,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.js","sourceRoot":"","sources":["
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../src/coinbase/types.ts"],"names":[],"mappings":"AAAA;;GAEG"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Utility functions for Coinbase CDP resources
|
|
3
|
+
*/
|
|
4
|
+
/**
|
|
5
|
+
* Validates that a CDP account name follows the required format.
|
|
6
|
+
* CDP only allows letters, numbers, and hyphens in account names.
|
|
7
|
+
* Names cannot start or end with a hyphen.
|
|
8
|
+
*
|
|
9
|
+
* @param name - The account name to validate
|
|
10
|
+
* @throws Error if the name contains invalid characters or starts/ends with hyphen
|
|
11
|
+
*/
|
|
12
|
+
export declare function validateAccountName(name: string): void;
|
|
13
|
+
//# sourceMappingURL=utils.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../src/coinbase/utils.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH;;;;;;;GAOG;AACH,wBAAgB,mBAAmB,CAAC,IAAI,EAAE,MAAM,GAAG,IAAI,CAMtD"}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Utility functions for Coinbase CDP resources
|
|
3
|
+
*/
|
|
4
|
+
/**
|
|
5
|
+
* Validates that a CDP account name follows the required format.
|
|
6
|
+
* CDP only allows letters, numbers, and hyphens in account names.
|
|
7
|
+
* Names cannot start or end with a hyphen.
|
|
8
|
+
*
|
|
9
|
+
* @param name - The account name to validate
|
|
10
|
+
* @throws Error if the name contains invalid characters or starts/ends with hyphen
|
|
11
|
+
*/
|
|
12
|
+
export function validateAccountName(name) {
|
|
13
|
+
if (!/^[a-zA-Z0-9]([a-zA-Z0-9-]*[a-zA-Z0-9])?$/.test(name)) {
|
|
14
|
+
throw new Error(`Invalid account name '${name}'. CDP only allows letters, numbers, and hyphens. Names cannot start or end with a hyphen.`);
|
|
15
|
+
}
|
|
16
|
+
}
|
|
17
|
+
//# sourceMappingURL=utils.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"utils.js","sourceRoot":"","sources":["../../src/coinbase/utils.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH;;;;;;;GAOG;AACH,MAAM,UAAU,mBAAmB,CAAC,IAAY;IAC9C,IAAI,CAAC,0CAA0C,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,CAAC;QAC3D,MAAM,IAAI,KAAK,CACb,yBAAyB,IAAI,4FAA4F,CAC1H,CAAC;IACJ,CAAC;AACH,CAAC"}
|
|
@@ -1740,7 +1740,7 @@ export type BillingAccountState = "UNKNOWN" | "active" | "suspended" | "deactiva
|
|
|
1740
1740
|
* Notice that for users without billing account this will be "UNKNOWN"
|
|
1741
1741
|
*
|
|
1742
1742
|
*/
|
|
1743
|
-
export type BillingSubscriptionType = "UNKNOWN" | "direct_sales" | "aws_marketplace" | "free_v2" | "free_v3" | "launch" | "launch_v3" | "scale" | "scale_v3" | "business" | "vercel_pg_legacy";
|
|
1743
|
+
export type BillingSubscriptionType = "UNKNOWN" | "direct_sales" | "direct_sales_v3" | "aws_marketplace" | "free_v2" | "free_v3" | "launch" | "launch_v3" | "scale" | "scale_v3" | "business" | "vercel_pg_legacy";
|
|
1744
1744
|
/**
|
|
1745
1745
|
* Indicates whether and how an account makes payments.
|
|
1746
1746
|
*
|
|
@@ -2263,6 +2263,10 @@ export type NeonAuthCreateIntegrationRequest = {
|
|
|
2263
2263
|
*/
|
|
2264
2264
|
role_name?: string;
|
|
2265
2265
|
};
|
|
2266
|
+
export type EnableNeonAuthIntegrationRequest = {
|
|
2267
|
+
auth_provider: NeonAuthSupportedAuthProvider;
|
|
2268
|
+
database_name?: string;
|
|
2269
|
+
};
|
|
2266
2270
|
export type NeonAuthCreateIntegrationResponse = {
|
|
2267
2271
|
auth_provider: NeonAuthSupportedAuthProvider;
|
|
2268
2272
|
auth_provider_project_id: string;
|
|
@@ -2385,7 +2389,7 @@ export type EndpointOperations = EndpointResponse & OperationsResponse;
|
|
|
2385
2389
|
export type DatabaseOperations = DatabaseResponse & OperationsResponse;
|
|
2386
2390
|
export type RoleOperations = RoleResponse & OperationsResponse;
|
|
2387
2391
|
export type JwksCreationOperation = JwksResponse & OperationsResponse;
|
|
2388
|
-
export type SupportTicketSeverity = "low" | "normal" | "high" | "critical";
|
|
2392
|
+
export type SupportTicketSeverity = "low" | "normal" | "high" | "critical" | "urgent";
|
|
2389
2393
|
export type AnnotationData = {
|
|
2390
2394
|
object: AnnotationObjectData;
|
|
2391
2395
|
value: AnnotationValueData;
|
|
@@ -2454,6 +2458,7 @@ export type Snapshot = {
|
|
|
2454
2458
|
source_branch_id?: string;
|
|
2455
2459
|
created_at: string;
|
|
2456
2460
|
expires_at?: string;
|
|
2461
|
+
manual?: boolean;
|
|
2457
2462
|
};
|
|
2458
2463
|
export type SnapshotUpdateRequest = {
|
|
2459
2464
|
snapshot: {
|