@bankr/cli 0.1.0-beta.9 → 0.1.3

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.
Files changed (64) hide show
  1. package/README.md +18 -0
  2. package/dist/cli.js +200 -3
  3. package/dist/commands/balances.d.ts +5 -0
  4. package/dist/commands/balances.js +113 -0
  5. package/dist/commands/fees.d.ts +18 -0
  6. package/dist/commands/fees.js +793 -0
  7. package/dist/commands/launch.d.ts +13 -0
  8. package/dist/commands/launch.js +174 -0
  9. package/dist/commands/llm.d.ts +11 -0
  10. package/dist/commands/llm.js +463 -22
  11. package/dist/commands/login.d.ts +3 -0
  12. package/dist/commands/login.js +94 -4
  13. package/dist/commands/profile.d.ts +26 -0
  14. package/dist/commands/profile.js +183 -0
  15. package/dist/commands/prompt.js +5 -0
  16. package/dist/commands/sign.js +3 -0
  17. package/dist/commands/sounds.d.ts +12 -0
  18. package/dist/commands/sounds.js +262 -0
  19. package/dist/commands/submit.js +14 -4
  20. package/dist/index.d.ts +2 -2
  21. package/dist/index.js +1 -1
  22. package/dist/lib/api.d.ts +213 -0
  23. package/dist/lib/api.js +177 -3
  24. package/dist/lib/cesp/engine.d.ts +13 -0
  25. package/dist/lib/cesp/engine.js +132 -0
  26. package/dist/lib/cesp/player.d.ts +6 -0
  27. package/dist/lib/cesp/player.js +50 -0
  28. package/dist/lib/cesp/types.d.ts +38 -0
  29. package/dist/lib/cesp/types.js +2 -0
  30. package/dist/lib/config.d.ts +4 -0
  31. package/dist/lib/config.js +1 -0
  32. package/package.json +4 -2
  33. package/dist/cli.d.ts.map +0 -1
  34. package/dist/cli.js.map +0 -1
  35. package/dist/commands/cancel.d.ts.map +0 -1
  36. package/dist/commands/cancel.js.map +0 -1
  37. package/dist/commands/capabilities.d.ts.map +0 -1
  38. package/dist/commands/capabilities.js.map +0 -1
  39. package/dist/commands/config.d.ts.map +0 -1
  40. package/dist/commands/config.js.map +0 -1
  41. package/dist/commands/llm.d.ts.map +0 -1
  42. package/dist/commands/llm.js.map +0 -1
  43. package/dist/commands/login.d.ts.map +0 -1
  44. package/dist/commands/login.js.map +0 -1
  45. package/dist/commands/logout.d.ts.map +0 -1
  46. package/dist/commands/logout.js.map +0 -1
  47. package/dist/commands/prompt.d.ts.map +0 -1
  48. package/dist/commands/prompt.js.map +0 -1
  49. package/dist/commands/sign.d.ts.map +0 -1
  50. package/dist/commands/sign.js.map +0 -1
  51. package/dist/commands/status.d.ts.map +0 -1
  52. package/dist/commands/status.js.map +0 -1
  53. package/dist/commands/submit.d.ts.map +0 -1
  54. package/dist/commands/submit.js.map +0 -1
  55. package/dist/commands/whoami.d.ts.map +0 -1
  56. package/dist/commands/whoami.js.map +0 -1
  57. package/dist/index.d.ts.map +0 -1
  58. package/dist/index.js.map +0 -1
  59. package/dist/lib/api.d.ts.map +0 -1
  60. package/dist/lib/api.js.map +0 -1
  61. package/dist/lib/config.d.ts.map +0 -1
  62. package/dist/lib/config.js.map +0 -1
  63. package/dist/lib/output.d.ts.map +0 -1
  64. package/dist/lib/output.js.map +0 -1
@@ -0,0 +1,262 @@
1
+ import { existsSync, mkdirSync } from "node:fs";
2
+ import { join } from "node:path";
3
+ import { execFile } from "node:child_process";
4
+ import { promisify } from "node:util";
5
+ import { tmpdir } from "node:os";
6
+ import { readConfig, writeConfig } from "../lib/config.js";
7
+ import { DEFAULT_SOUND_CONFIG, emitCESP, getPacksDir, listInstalledPacks, } from "../lib/cesp/engine.js";
8
+ import * as output from "../lib/output.js";
9
+ const execFileAsync = promisify(execFile);
10
+ const REGISTRY_URL = "https://peonping.github.io/registry/index.json";
11
+ function getSoundConfig() {
12
+ return readConfig().sound ?? { ...DEFAULT_SOUND_CONFIG };
13
+ }
14
+ function saveSoundConfig(sound) {
15
+ const config = readConfig();
16
+ config.sound = sound;
17
+ writeConfig(config);
18
+ }
19
+ export async function soundsStatusCommand() {
20
+ const sound = getSoundConfig();
21
+ output.brandBold(" Sound Configuration");
22
+ console.log();
23
+ output.keyValue("Enabled", sound.enabled ? "yes" : "no");
24
+ output.keyValue("Muted", sound.muted ? "yes" : "no");
25
+ output.keyValue("Volume", `${Math.round(sound.volume * 100)}%`);
26
+ output.keyValue("Active Pack", sound.activePack ?? "(none)");
27
+ if (sound.disabledCategories?.length) {
28
+ output.keyValue("Disabled Categories", sound.disabledCategories.join(", "));
29
+ }
30
+ console.log();
31
+ const packs = listInstalledPacks();
32
+ if (packs.length === 0) {
33
+ output.dim(` No sound packs installed. Add packs to ${getPacksDir()}`);
34
+ }
35
+ else {
36
+ output.dim(` ${packs.length} pack(s) installed. Run: bankr sounds list`);
37
+ }
38
+ }
39
+ export async function soundsEnableCommand() {
40
+ const sound = getSoundConfig();
41
+ sound.enabled = true;
42
+ saveSoundConfig(sound);
43
+ output.success("Sounds enabled");
44
+ }
45
+ export async function soundsDisableCommand() {
46
+ const sound = getSoundConfig();
47
+ sound.enabled = false;
48
+ saveSoundConfig(sound);
49
+ output.success("Sounds disabled");
50
+ }
51
+ export async function soundsListCommand() {
52
+ const packs = listInstalledPacks();
53
+ const sound = getSoundConfig();
54
+ if (packs.length === 0) {
55
+ output.dim("No sound packs installed.");
56
+ output.dim(`Install packs to ${getPacksDir()}`);
57
+ return;
58
+ }
59
+ output.brandBold(" Installed Sound Packs");
60
+ console.log();
61
+ for (const pack of packs) {
62
+ const active = pack.name === sound.activePack ? " (active)" : "";
63
+ const cats = Object.keys(pack.manifest.categories).length;
64
+ const totalSounds = Object.values(pack.manifest.categories).reduce((sum, c) => sum + (c.sounds?.length ?? 0), 0);
65
+ console.log(` ${output.fmt.brand(pack.name)}${active ? output.fmt.brand(active) : ""}`);
66
+ output.dim(` ${cats} categories, ${totalSounds} sounds`);
67
+ }
68
+ }
69
+ export async function soundsUseCommand(packName) {
70
+ const packs = listInstalledPacks();
71
+ const match = packs.find((p) => p.name === packName);
72
+ if (!match) {
73
+ output.error(`Pack "${packName}" not found. Run: bankr sounds list`);
74
+ process.exit(1);
75
+ }
76
+ const sound = getSoundConfig();
77
+ sound.activePack = packName;
78
+ saveSoundConfig(sound);
79
+ output.success(`Active sound pack: ${match.manifest.display_name ?? packName}`);
80
+ }
81
+ export async function soundsVolumeCommand(level) {
82
+ const sound = getSoundConfig();
83
+ if (!level) {
84
+ output.label("Volume", `${Math.round(sound.volume * 100)}%`);
85
+ return;
86
+ }
87
+ const vol = parseFloat(level);
88
+ if (isNaN(vol) || vol < 0 || vol > 1) {
89
+ output.error("Volume must be a number between 0.0 and 1.0");
90
+ process.exit(1);
91
+ }
92
+ sound.volume = vol;
93
+ saveSoundConfig(sound);
94
+ output.success(`Volume set to ${Math.round(vol * 100)}%`);
95
+ }
96
+ export async function soundsMuteCommand() {
97
+ const sound = getSoundConfig();
98
+ sound.muted = true;
99
+ saveSoundConfig(sound);
100
+ output.success("Sounds muted");
101
+ }
102
+ export async function soundsUnmuteCommand() {
103
+ const sound = getSoundConfig();
104
+ sound.muted = false;
105
+ saveSoundConfig(sound);
106
+ output.success("Sounds unmuted");
107
+ }
108
+ export async function soundsTestCommand(category) {
109
+ const sound = getSoundConfig();
110
+ if (!sound.activePack) {
111
+ output.error("No active sound pack. Run: bankr sounds use <pack>");
112
+ process.exit(1);
113
+ }
114
+ const cat = category ?? "task.complete";
115
+ output.dim(`Playing "${cat}" from ${sound.activePack}...`);
116
+ // Temporarily force enabled + unmuted for the test
117
+ const prev = { enabled: sound.enabled, muted: sound.muted };
118
+ sound.enabled = true;
119
+ sound.muted = false;
120
+ saveSoundConfig(sound);
121
+ emitCESP(cat);
122
+ // Restore previous state
123
+ sound.enabled = prev.enabled;
124
+ sound.muted = prev.muted;
125
+ saveSoundConfig(sound);
126
+ }
127
+ // -- Registry helpers --
128
+ async function fetchRegistry() {
129
+ const res = await fetch(REGISTRY_URL);
130
+ if (!res.ok) {
131
+ throw new Error(`Failed to fetch registry: ${res.status} ${res.statusText}`);
132
+ }
133
+ const body = (await res.json());
134
+ return Array.isArray(body) ? body : body.packs;
135
+ }
136
+ function formatSize(bytes) {
137
+ if (bytes < 1024)
138
+ return `${bytes}B`;
139
+ if (bytes < 1024 * 1024)
140
+ return `${(bytes / 1024).toFixed(0)}KB`;
141
+ return `${(bytes / (1024 * 1024)).toFixed(1)}MB`;
142
+ }
143
+ // -- Install command --
144
+ export async function soundsInstallCommand(packName) {
145
+ const packsDir = getPacksDir();
146
+ const destDir = join(packsDir, packName);
147
+ // Check if already installed
148
+ if (existsSync(join(destDir, "openpeon.json"))) {
149
+ output.warn(`Pack "${packName}" is already installed at ${destDir}`);
150
+ return;
151
+ }
152
+ const spin = output.spinner(`Looking up "${packName}" in CESP registry...`);
153
+ let entry;
154
+ try {
155
+ const registry = await fetchRegistry();
156
+ const match = registry.find((e) => e.name.toLowerCase() === packName.toLowerCase());
157
+ if (!match) {
158
+ spin.fail(`Pack "${packName}" not found in registry`);
159
+ output.dim("Run: bankr sounds search <query> to browse available packs");
160
+ process.exit(1);
161
+ }
162
+ entry = match;
163
+ spin.succeed(`Found ${entry.display_name} (${entry.sound_count} sounds, ${formatSize(entry.total_size_bytes)})`);
164
+ }
165
+ catch (err) {
166
+ spin.fail("Failed to fetch registry");
167
+ output.error(err.message);
168
+ process.exit(1);
169
+ }
170
+ // Download and extract
171
+ const tarballUrl = `https://github.com/${entry.source_repo}/archive/refs/tags/${entry.source_ref}.tar.gz`;
172
+ const spin2 = output.spinner("Downloading and extracting...");
173
+ try {
174
+ const tmpDir = join(tmpdir(), `bankr-sound-${Date.now()}`);
175
+ mkdirSync(tmpDir, { recursive: true });
176
+ mkdirSync(packsDir, { recursive: true });
177
+ // Download tarball with curl and extract with tar
178
+ await execFileAsync("curl", ["-fsSL", "-o", join(tmpDir, "pack.tar.gz"), tarballUrl], { timeout: 30000 });
179
+ await execFileAsync("tar", ["xzf", join(tmpDir, "pack.tar.gz"), "-C", tmpDir], { timeout: 15000 });
180
+ // Find the extracted directory (name is <repo>-<ref>/<source_path>)
181
+ // The tarball extracts to <repo-name>-<tag>/ (e.g. og-packs-v1.0.0/)
182
+ const repoName = entry.source_repo.split("/")[1];
183
+ const refClean = entry.source_ref.replace(/^v/, "");
184
+ const extractedBase = join(tmpDir, `${repoName}-${refClean}`);
185
+ const sourcePath = join(extractedBase, entry.source_path);
186
+ if (!existsSync(join(sourcePath, "openpeon.json"))) {
187
+ // Try alternative naming (some tarballs keep the v prefix)
188
+ const altBase = join(tmpDir, `${repoName}-${entry.source_ref}`);
189
+ const altSource = join(altBase, entry.source_path);
190
+ if (!existsSync(join(altSource, "openpeon.json"))) {
191
+ spin2.fail("Pack manifest (openpeon.json) not found in archive");
192
+ process.exit(1);
193
+ }
194
+ // Copy from alt path
195
+ await execFileAsync("cp", ["-r", altSource, destDir]);
196
+ }
197
+ else {
198
+ await execFileAsync("cp", ["-r", sourcePath, destDir]);
199
+ }
200
+ // Cleanup temp dir
201
+ await execFileAsync("rm", ["-rf", tmpDir]).catch(() => { });
202
+ // Verify install
203
+ if (!existsSync(join(destDir, "openpeon.json"))) {
204
+ spin2.fail("Install failed: manifest not found after extraction");
205
+ process.exit(1);
206
+ }
207
+ spin2.succeed(`Installed "${entry.display_name}" to ${destDir}`);
208
+ // Auto-set as active pack if it's the first one
209
+ const sound = getSoundConfig();
210
+ if (!sound.activePack) {
211
+ sound.activePack = packName;
212
+ saveSoundConfig(sound);
213
+ output.dim(`Set as active pack. Run: bankr sounds enable`);
214
+ }
215
+ else {
216
+ output.dim(`Activate with: bankr sounds use ${packName}`);
217
+ }
218
+ }
219
+ catch (err) {
220
+ spin2.fail("Install failed");
221
+ output.error(err.message);
222
+ process.exit(1);
223
+ }
224
+ }
225
+ // -- Search command --
226
+ export async function soundsSearchCommand(query) {
227
+ const spin = output.spinner("Fetching CESP registry...");
228
+ let registry;
229
+ try {
230
+ registry = await fetchRegistry();
231
+ spin.stop();
232
+ }
233
+ catch (err) {
234
+ spin.fail("Failed to fetch registry");
235
+ output.error(err.message);
236
+ process.exit(1);
237
+ }
238
+ // Filter by query if provided
239
+ let results = registry;
240
+ if (query) {
241
+ const q = query.toLowerCase();
242
+ results = registry.filter((e) => e.name.toLowerCase().includes(q) ||
243
+ e.display_name.toLowerCase().includes(q) ||
244
+ (e.description?.toLowerCase().includes(q) ?? false));
245
+ }
246
+ if (results.length === 0) {
247
+ output.dim(query ? `No packs matching "${query}"` : "No packs in registry");
248
+ return;
249
+ }
250
+ // Check which are already installed
251
+ const installed = new Set(listInstalledPacks().map((p) => p.name));
252
+ output.brandBold(` ${results.length} sound pack(s) available`);
253
+ console.log();
254
+ for (const entry of results) {
255
+ const tag = installed.has(entry.name) ? " (installed)" : "";
256
+ console.log(` ${output.fmt.brand(entry.name)}${tag ? output.fmt.dim(tag) : ""} ${entry.display_name}`);
257
+ output.dim(` ${entry.sound_count} sounds, ${formatSize(entry.total_size_bytes)}, ${entry.categories.length} categories`);
258
+ }
259
+ console.log();
260
+ output.dim(" Install with: bankr sounds install <name>");
261
+ }
262
+ //# sourceMappingURL=sounds.js.map
@@ -1,13 +1,16 @@
1
1
  import { submit } from "../lib/api.js";
2
+ import { emitCESP } from "../lib/cesp/engine.js";
2
3
  import * as output from "../lib/output.js";
3
4
  function displayResult(result) {
4
5
  if (!result.success) {
6
+ emitCESP("task.error");
5
7
  output.error(result.error || "Submission failed");
6
8
  if (result.transactionHash) {
7
9
  output.keyValue("Transaction Hash", result.transactionHash);
8
10
  }
9
11
  process.exit(1);
10
12
  }
13
+ emitCESP("task.complete");
11
14
  output.success("Transaction submitted");
12
15
  console.log();
13
16
  output.keyValue("Transaction Hash", result.transactionHash || "");
@@ -60,7 +63,9 @@ export async function submitCommand(opts) {
60
63
  waitForConfirmation: !opts.noWait,
61
64
  };
62
65
  // Execute submission with spinner
63
- const spinner = output.spinner(opts.noWait ? "Submitting transaction..." : "Submitting and waiting for confirmation...");
66
+ const spinner = output.spinner(opts.noWait
67
+ ? "Submitting transaction..."
68
+ : "Submitting and waiting for confirmation...");
64
69
  try {
65
70
  const result = await submit(request);
66
71
  spinner.stop();
@@ -82,7 +87,9 @@ export async function submitJsonCommand(json, opts) {
82
87
  output.error("Invalid JSON. Expected: {to, chainId, value?, data?}");
83
88
  process.exit(1);
84
89
  }
85
- if (!transaction || typeof transaction !== "object" || Array.isArray(transaction)) {
90
+ if (!transaction ||
91
+ typeof transaction !== "object" ||
92
+ Array.isArray(transaction)) {
86
93
  output.error("Invalid JSON. Expected object: {to, chainId, value?, data?}");
87
94
  process.exit(1);
88
95
  }
@@ -99,7 +106,8 @@ export async function submitJsonCommand(json, opts) {
99
106
  output.error("Transaction 'chainId' must be a number");
100
107
  process.exit(1);
101
108
  }
102
- if (transaction.nonce !== undefined && (typeof transaction.nonce !== "number" || isNaN(transaction.nonce))) {
109
+ if (transaction.nonce !== undefined &&
110
+ (typeof transaction.nonce !== "number" || isNaN(transaction.nonce))) {
103
111
  output.error("Transaction 'nonce' must be a number");
104
112
  process.exit(1);
105
113
  }
@@ -109,7 +117,9 @@ export async function submitJsonCommand(json, opts) {
109
117
  waitForConfirmation: !opts.noWait,
110
118
  };
111
119
  // Execute submission with spinner
112
- const spinner = output.spinner(opts.noWait ? "Submitting transaction..." : "Submitting and waiting for confirmation...");
120
+ const spinner = output.spinner(opts.noWait
121
+ ? "Submitting transaction..."
122
+ : "Submitting and waiting for confirmation...");
113
123
  try {
114
124
  const result = await submit(request);
115
125
  spinner.stop();
package/dist/index.d.ts CHANGED
@@ -1,5 +1,5 @@
1
1
  export { clearConfig, DEFAULT_API_URL, getApiKey, getApiUrl, readConfig, setConfigPath, writeConfig, } from "./lib/config.js";
2
2
  export type { BankrConfig } from "./lib/config.js";
3
- export { cancelJob, getJobStatus, getUserInfo, pollJob, submitPrompt, validateApiKey, } from "./lib/api.js";
4
- export type { JobStatusResponse, PromptResponse, UserInfoResponse, } from "./lib/api.js";
3
+ export { cancelJob, getBalances, getJobStatus, getUserInfo, pollJob, submitPrompt, validateApiKey, } from "./lib/api.js";
4
+ export type { BalancesResponse, ChainBalanceInfo, JobStatusResponse, PromptResponse, TokenBalanceInfo, UserInfoResponse, } from "./lib/api.js";
5
5
  //# sourceMappingURL=index.d.ts.map
package/dist/index.js CHANGED
@@ -1,3 +1,3 @@
1
1
  export { clearConfig, DEFAULT_API_URL, getApiKey, getApiUrl, readConfig, setConfigPath, writeConfig, } from "./lib/config.js";
2
- export { cancelJob, getJobStatus, getUserInfo, pollJob, submitPrompt, validateApiKey, } from "./lib/api.js";
2
+ export { cancelJob, getBalances, getJobStatus, getUserInfo, pollJob, submitPrompt, validateApiKey, } from "./lib/api.js";
3
3
  //# sourceMappingURL=index.js.map
package/dist/lib/api.d.ts CHANGED
@@ -48,6 +48,34 @@ export declare function getJobStatus(jobId: string): Promise<JobStatusResponse>;
48
48
  export declare function cancelJob(jobId: string): Promise<JobStatusResponse>;
49
49
  export declare function validateApiKey(): Promise<boolean>;
50
50
  export declare function getUserInfo(): Promise<UserInfoResponse>;
51
+ export interface TokenBalanceInfo {
52
+ network: string;
53
+ token: {
54
+ balance: number;
55
+ balanceUSD: number;
56
+ baseToken: {
57
+ name: string;
58
+ address: string;
59
+ symbol: string;
60
+ price: number;
61
+ imgUrl: string;
62
+ decimals: number;
63
+ };
64
+ };
65
+ }
66
+ export interface ChainBalanceInfo {
67
+ nativeBalance: string;
68
+ nativeUsd: string;
69
+ tokenBalances: TokenBalanceInfo[];
70
+ total: string;
71
+ }
72
+ export interface BalancesResponse {
73
+ success: boolean;
74
+ evmAddress: string;
75
+ solAddress?: string;
76
+ balances: Record<string, ChainBalanceInfo>;
77
+ }
78
+ export declare function getBalances(chains?: string[]): Promise<BalancesResponse>;
51
79
  export declare function pollJob(jobId: string, opts?: {
52
80
  interval?: number;
53
81
  maxAttempts?: number;
@@ -112,4 +140,189 @@ export interface SubmitResponse {
112
140
  error?: string;
113
141
  }
114
142
  export declare function submit(request: SubmitRequest): Promise<SubmitResponse>;
143
+ export type FeeRecipientType = "wallet" | "x" | "farcaster" | "ens";
144
+ export interface DeployTokenRequest {
145
+ tokenName: string;
146
+ tokenSymbol?: string;
147
+ image?: string;
148
+ description?: string;
149
+ tweetUrl?: string;
150
+ websiteUrl?: string;
151
+ feeRecipient?: {
152
+ type: FeeRecipientType;
153
+ value: string;
154
+ };
155
+ simulateOnly?: boolean;
156
+ }
157
+ export interface DeployTokenResponse {
158
+ success: boolean;
159
+ tokenAddress: string;
160
+ poolId: string;
161
+ txHash?: string;
162
+ activityId: string;
163
+ chain: string;
164
+ simulated?: boolean;
165
+ feeDistribution: Record<string, {
166
+ address: string;
167
+ bps: number;
168
+ }>;
169
+ error?: string;
170
+ }
171
+ export declare function deployToken(request: DeployTokenRequest): Promise<DeployTokenResponse>;
172
+ export interface CreatorFeesTokenResult {
173
+ tokenAddress: string;
174
+ name: string;
175
+ symbol: string;
176
+ poolId: string;
177
+ initializer?: string;
178
+ share: string;
179
+ token0Label: string;
180
+ token1Label: string;
181
+ claimable: {
182
+ token0: string;
183
+ token1: string;
184
+ };
185
+ claimed: {
186
+ token0: string;
187
+ token1: string;
188
+ count: number;
189
+ };
190
+ source?: "doppler" | "clanker";
191
+ }
192
+ export interface CreatorFeesResponse {
193
+ address: string;
194
+ chain: "base";
195
+ days: number;
196
+ tokens: CreatorFeesTokenResult[];
197
+ dailyEarnings: Array<{
198
+ date: string;
199
+ weth: string;
200
+ }>;
201
+ totals: {
202
+ claimableWeth: string;
203
+ claimedWeth: string;
204
+ claimCount: number;
205
+ };
206
+ }
207
+ export interface BeneficiaryFeesResponse {
208
+ address: string;
209
+ chain: "base";
210
+ totalLaunches: number;
211
+ poolsWithShares: number;
212
+ tokens: CreatorFeesTokenResult[];
213
+ }
214
+ export interface DopplerClaimTxResponse {
215
+ to: string;
216
+ data: string;
217
+ chainId: number;
218
+ description: string;
219
+ }
220
+ /**
221
+ * Fetch creator fee data for a wallet address. Unauthenticated — calls
222
+ * the public endpoint directly.
223
+ */
224
+ export declare function getCreatorFees(address: string, days?: number): Promise<CreatorFeesResponse>;
225
+ /**
226
+ * Fetch fee data for a wallet address as ANY beneficiary role (creator,
227
+ * protocol, platform, etc.). Processes ALL launches server-side in one
228
+ * request (mirrors the internal claim-doppler-fees script).
229
+ * Unauthenticated — calls the public endpoint.
230
+ */
231
+ export declare function getBeneficiaryFees(address: string): Promise<BeneficiaryFeesResponse>;
232
+ export interface StreamProgress {
233
+ phase: string;
234
+ scanned: number;
235
+ total: number;
236
+ found?: number;
237
+ }
238
+ /**
239
+ * Fetch beneficiary fees with NDJSON streaming. The server sends progress
240
+ * lines during processing and a final result line. The onProgress callback
241
+ * is invoked for each progress update so the caller can update a spinner.
242
+ */
243
+ export declare function getBeneficiaryFeesStreaming(address: string, onProgress: (progress: StreamProgress) => void): Promise<BeneficiaryFeesResponse>;
244
+ /**
245
+ * Fetch creator fee data for a specific token address. Unauthenticated —
246
+ * looks up the token's creator beneficiary and returns their fee data.
247
+ */
248
+ export declare function getTokenCreatorFees(tokenAddress: string, days?: number): Promise<CreatorFeesResponse>;
249
+ /**
250
+ * Build a Doppler fee claim transaction. Requires authentication.
251
+ * The returned transaction data should be submitted via `submit()`.
252
+ */
253
+ export declare function buildDopplerClaimTx(tokenAddress: string): Promise<DopplerClaimTxResponse>;
254
+ export interface BuildClaimTx {
255
+ tokenAddress: string;
256
+ tokenName: string;
257
+ tokenSymbol: string;
258
+ to: string;
259
+ data: string;
260
+ chainId: number;
261
+ gasEstimate: string;
262
+ maxFeePerGas: string;
263
+ maxPriorityFeePerGas: string;
264
+ description: string;
265
+ }
266
+ export interface BuildClaimResponse {
267
+ transactions: BuildClaimTx[];
268
+ errors?: Array<{
269
+ tokenAddress: string;
270
+ error: string;
271
+ }>;
272
+ }
273
+ /**
274
+ * Build unsigned claim transactions for the given beneficiary and tokens.
275
+ * Unauthenticated -- calls the public endpoint. The CLI signs and
276
+ * broadcasts locally.
277
+ */
278
+ export interface AgentProfileResponse {
279
+ id: string;
280
+ slug: string;
281
+ projectName: string;
282
+ description?: string;
283
+ profileImageUrl?: string;
284
+ tokenAddress?: string;
285
+ tokenChainId?: string;
286
+ tokenSymbol?: string;
287
+ tokenName?: string;
288
+ marketCapUsd?: number;
289
+ weeklyRevenueWeth?: string;
290
+ twitterUsername?: string;
291
+ website?: string;
292
+ teamMembers: Array<{
293
+ name: string;
294
+ role?: string;
295
+ links: Array<{
296
+ type: string;
297
+ url: string;
298
+ }>;
299
+ }>;
300
+ products: Array<{
301
+ name: string;
302
+ description?: string;
303
+ url?: string;
304
+ }>;
305
+ revenueSources: Array<{
306
+ name: string;
307
+ description?: string;
308
+ }>;
309
+ projectUpdates: Array<{
310
+ title: string;
311
+ content: string;
312
+ createdAt: string;
313
+ }>;
314
+ approved: boolean;
315
+ createdAt: string;
316
+ }
317
+ export declare function getOwnProfile(): Promise<AgentProfileResponse>;
318
+ export declare function createProfile(data: Record<string, unknown>): Promise<AgentProfileResponse>;
319
+ export declare function updateProfile(data: Record<string, unknown>): Promise<AgentProfileResponse>;
320
+ export declare function deleteProfile(): Promise<{
321
+ success: boolean;
322
+ }>;
323
+ export declare function addProjectUpdate(data: {
324
+ title: string;
325
+ content: string;
326
+ }): Promise<AgentProfileResponse>;
327
+ export declare function buildPublicClaimTxs(beneficiaryAddress: string, tokenAddresses: string[]): Promise<BuildClaimResponse>;
115
328
  //# sourceMappingURL=api.d.ts.map