@1db/cli 0.3.0 → 0.3.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.
@@ -102,13 +102,17 @@ export const configCommands = {
102
102
  async forwarding({ positional, flags }) {
103
103
  const [action = "list", id] = positional;
104
104
  if (action === "list") {
105
- const { rules } = await api("/v1/agent/forwarding");
105
+ const { rules, warnings = [] } = await api("/v1/agent/forwarding");
106
106
  if (flags.json) return json(rules);
107
- if (rules.length === 0) return print("No forwarding rules.");
108
- return table(
109
- rules.map((r) => ({ ...r, on: r.enabled ? "yes" : "no", auth: r.hasAuthToken ? r.authType : "none" })),
110
- ["id", "name", "endpoint", "on", "auth"],
111
- );
107
+ if (rules.length === 0) print("No forwarding rules.");
108
+ else {
109
+ table(
110
+ rules.map((r) => ({ ...r, on: r.enabled ? "yes" : "no", auth: r.hasAuthToken ? r.authType : "none" })),
111
+ ["id", "name", "endpoint", "on", "auth"],
112
+ );
113
+ }
114
+ for (const warning of warnings) print(`! ${warning}`);
115
+ return;
112
116
  }
113
117
  let result;
114
118
  if (action === "add") {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@1db/cli",
3
- "version": "0.3.0",
3
+ "version": "0.3.1",
4
4
  "description": "Connect websites to 1DB from your terminal or an AI agent: onboard a domain, get its lead keys, send and list leads.",
5
5
  "type": "module",
6
6
  "bin": {