aiprotocol-sbi 1.2.1 → 1.2.2

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.
@@ -3,6 +3,7 @@ export interface SbiConfig {
3
3
  apiBaseUrl: string;
4
4
  network: "base" | "base-sepolia";
5
5
  keystorePassword?: string;
6
+ image?: string;
6
7
  botId?: string;
7
8
  botName?: string;
8
9
  botCreatedAt?: string;
@@ -33,6 +33,7 @@ let EconomyLaunchCommand = EconomyLaunchCommand_1 = class EconomyLaunchCommand {
33
33
  .requiredOption("--name <name>", "Agent / economy name")
34
34
  .requiredOption("--ticker <ticker>", "Token ticker")
35
35
  .requiredOption("--description <description>", "Short agent description")
36
+ .requiredOption("--image <image>", "Agent image")
36
37
  .option("--json", "Output result as JSON")
37
38
  .action(async (opts) => {
38
39
  const cfg = this.config.requireWallet();
@@ -55,7 +56,8 @@ let EconomyLaunchCommand = EconomyLaunchCommand_1 = class EconomyLaunchCommand {
55
56
  }
56
57
  const name = this.security.sanitizeString(opts.name, 64);
57
58
  const ticker = tickerCheck.value;
58
- const description = opts.description
59
+ const description = opts.description;
60
+ const image = opts.image
59
61
  ? this.security.sanitizeString(opts.description, 512)
60
62
  : undefined;
61
63
  if (!opts.yes && !opts.json) {
@@ -63,6 +65,7 @@ let EconomyLaunchCommand = EconomyLaunchCommand_1 = class EconomyLaunchCommand {
63
65
  this.output.row("Name", name);
64
66
  this.output.row("Ticker", ticker);
65
67
  this.output.row("Network", cfg.network);
68
+ this.output.row("Image", image);
66
69
  this.output.row("Wallet", cfg.wallet_address);
67
70
  this.output.blank();
68
71
  }
@@ -81,12 +84,14 @@ let EconomyLaunchCommand = EconomyLaunchCommand_1 = class EconomyLaunchCommand {
81
84
  wallet_address: cfg.wallet_address,
82
85
  network: cfg.network,
83
86
  description,
87
+ image: image,
84
88
  });
85
89
  if (!result?.is_application) {
86
90
  this.output.blank();
87
91
  this.output.row("Status", this.output.statusBadge("BLOCKED"));
88
92
  this.output.row("Name", name);
89
93
  this.output.row("Ticker", ticker);
94
+ this.output.row("Image", image);
90
95
  this.output.divider();
91
96
  this.output.blank();
92
97
  this.output.warn("No funding application found for this bot.\n" +
@@ -104,6 +109,7 @@ let EconomyLaunchCommand = EconomyLaunchCommand_1 = class EconomyLaunchCommand {
104
109
  this.output.row("Status", this.output.statusBadge("BLOCKED"));
105
110
  this.output.row("Name", name);
106
111
  this.output.row("Ticker", ticker);
112
+ this.output.row("Image", image);
107
113
  this.output.divider();
108
114
  this.output.blank();
109
115
  this.output.warn("Launch blocked. Your funding application has not been verified yet.\n" +
@@ -112,7 +118,6 @@ let EconomyLaunchCommand = EconomyLaunchCommand_1 = class EconomyLaunchCommand {
112
118
  this.output.info(`Check application status with:\n ${nextCommand}`);
113
119
  process.exit(1);
114
120
  }
115
- console.log(result, "result");
116
121
  this.config.save({
117
122
  economyTicker: result?.sbi?.ticker ?? name,
118
123
  economyName: result?.sbi?.name ?? ticker,
@@ -124,6 +129,7 @@ let EconomyLaunchCommand = EconomyLaunchCommand_1 = class EconomyLaunchCommand {
124
129
  this.output.row("Status", this.output.statusBadge("PENDING"));
125
130
  this.output.row("Name", name);
126
131
  this.output.row("Ticker", ticker);
132
+ this.output.row("Image", image);
127
133
  this.output.divider();
128
134
  this.output.blank();
129
135
  this.output.info("Deployment in progress. Poll with:\n aiprotocol-sbi economy status --poll");
@@ -34,6 +34,7 @@ let SetupCommand = class SetupCommand {
34
34
  .option("--applicant-name <name>", "Required for GRANT")
35
35
  .option("--applicant-email <email>", "Required for GRANT")
36
36
  .option("--purpose <text>", "Required for GRANT")
37
+ .option("--links <text>", "Required for GRANT")
37
38
  .option("--json", "Output JSON")
38
39
  .option("--reset", "Clear config")
39
40
  .action(async (opts) => {
@@ -118,17 +119,19 @@ let SetupCommand = class SetupCommand {
118
119
  const requiredAmount = "500 ALI";
119
120
  if (!opts.json) {
120
121
  this.output.section("Funding Method: Self-Funded");
122
+ this.output.info("You need to send 500 ALI to launch an economy.");
123
+ this.output.info("Send payment to your bot's address:");
124
+ this.output.divider();
121
125
  this.output.row("Wallet Address", existingBot.wallet_address);
122
126
  this.output.row("Payment Token", token);
123
127
  this.output.row("Required Amount", requiredAmount);
124
128
  this.output.blank();
129
+ this.output.info("Transfer these funds using 'Transfer Script' to AIP");
125
130
  if (appStatus?.status === "SUCCESS") {
126
131
  this.output.success("✅ Payment confirmed! Your agent is funded.");
127
132
  this.output.info("aiprotocol-sbi economy launch");
128
133
  }
129
134
  else {
130
- this.output.warn("Payment not yet confirmed.");
131
- this.output.info(`Send ${requiredAmount} to the wallet above.`);
132
135
  this.output.info("Verify payment: aiprotocol-sbi payment verify");
133
136
  }
134
137
  this.output.blank();
@@ -159,8 +162,11 @@ let SetupCommand = class SetupCommand {
159
162
  return this.handleSelfFlow(botId, botName, wallet, network, opts);
160
163
  }
161
164
  async handleGrantFlow(botId, botName, wallet, network, opts) {
162
- if (!opts.applicantName || !opts.applicantEmail || !opts.purpose) {
163
- throw new Error("GRANT requires --applicant-name, --applicant-email, --purpose");
165
+ if (!opts.applicantName ||
166
+ !opts.applicantEmail ||
167
+ !opts.purpose ||
168
+ !!opts.links) {
169
+ throw new Error("GRANT requires --applicant-name, --applicant-email, --purpose --links");
164
170
  }
165
171
  this.output.section("AIP Grant Application");
166
172
  const result = await this.backend.submitGrantApplication({
@@ -197,12 +203,12 @@ let SetupCommand = class SetupCommand {
197
203
  type: "SELF",
198
204
  });
199
205
  this.output.warn("⚠️ You need to send 500 ALI to launch an economy.");
200
- this.output.warn("Send payment to the following address:");
206
+ this.output.warn("Send payment to your bot's address:");
201
207
  this.output.row("Wallet", wallet.address);
202
208
  this.output.row("Network", network);
203
209
  this.output.row("Required Amount", requiredAmount);
204
- this.output.info("After sending, verify payment.");
205
- this.output.info("Verify using: aiprotocol-sbi payment verify");
210
+ this.output.info("After sending, transfer these funds using 'Transfer Script' to AIP");
211
+ this.output.info("Verify payment using: aiprotocol-sbi payment verify");
206
212
  process.exit(0);
207
213
  }
208
214
  validateBotName(name) {