oneie 3.8.3 → 4.0.0
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/LICENSE +86 -0
- package/README.md +63 -952
- package/dist/package.json +38 -0
- package/dist/src/agent.d.ts +2 -0
- package/dist/src/agent.js +888 -0
- package/dist/src/args.d.ts +9 -0
- package/dist/src/args.js +61 -0
- package/dist/src/auth.d.ts +6 -0
- package/dist/src/auth.js +122 -0
- package/dist/src/broadcast.d.ts +6 -0
- package/dist/src/broadcast.js +150 -0
- package/dist/src/catalog.d.ts +2 -0
- package/dist/src/catalog.js +78 -0
- package/dist/src/chat.d.ts +2 -0
- package/dist/src/chat.js +92 -0
- package/dist/src/client.d.ts +5 -0
- package/dist/src/client.js +151 -0
- package/dist/src/compiler.d.ts +36 -0
- package/dist/src/compiler.js +314 -0
- package/dist/src/config.d.ts +24 -0
- package/dist/src/config.js +70 -0
- package/dist/src/connect.d.ts +2 -0
- package/dist/src/connect.js +64 -0
- package/dist/src/coordinate.d.ts +3 -0
- package/dist/src/coordinate.js +58 -0
- package/dist/src/create.d.ts +2 -0
- package/dist/src/create.js +106 -0
- package/dist/src/deploy.d.ts +2 -0
- package/dist/src/deploy.js +19 -0
- package/dist/src/dev.d.ts +2 -0
- package/dist/src/dev.js +75 -0
- package/dist/src/device-flow.d.ts +57 -0
- package/dist/src/device-flow.js +173 -0
- package/dist/src/doctor.d.ts +26 -0
- package/dist/src/doctor.js +91 -0
- package/dist/src/env.d.ts +3 -0
- package/dist/src/env.js +37 -0
- package/dist/src/eval.d.ts +2 -0
- package/dist/src/eval.js +42 -0
- package/dist/src/fn.d.ts +2 -0
- package/dist/src/fn.js +73 -0
- package/dist/src/group.d.ts +2 -0
- package/dist/src/group.js +115 -0
- package/dist/src/index.d.ts +2 -0
- package/dist/src/index.js +101 -0
- package/dist/src/init.d.ts +11 -0
- package/dist/src/init.js +121 -0
- package/dist/src/lib/agent-env.d.ts +5 -0
- package/dist/src/lib/agent-env.js +25 -0
- package/dist/src/lib/api-path.d.ts +1 -0
- package/dist/src/lib/api-path.js +9 -0
- package/dist/src/lib/client.d.ts +16 -0
- package/dist/src/lib/client.js +57 -0
- package/dist/src/links.d.ts +5 -0
- package/dist/src/links.js +44 -0
- package/dist/src/onboard.d.ts +16 -0
- package/dist/src/onboard.js +146 -0
- package/dist/src/plugin.d.ts +2 -0
- package/dist/src/plugin.js +184 -0
- package/dist/src/push.d.ts +2 -0
- package/dist/src/push.js +114 -0
- package/dist/src/render.d.ts +20 -0
- package/dist/src/render.js +32 -0
- package/dist/src/setup.d.ts +6 -0
- package/dist/src/setup.js +118 -0
- package/dist/src/ship.d.ts +2 -0
- package/dist/src/ship.js +18 -0
- package/dist/src/skill-parser.d.ts +14 -0
- package/dist/src/skill-parser.js +113 -0
- package/dist/src/skill.d.ts +2 -0
- package/dist/src/skill.js +377 -0
- package/dist/src/slug.d.ts +2 -0
- package/dist/src/slug.js +6 -0
- package/dist/src/social.d.ts +2 -0
- package/dist/src/social.js +87 -0
- package/dist/src/staff.d.ts +2 -0
- package/dist/src/staff.js +93 -0
- package/dist/src/status.d.ts +2 -0
- package/dist/src/status.js +38 -0
- package/dist/src/substrate.d.ts +2 -0
- package/dist/src/substrate.js +243 -0
- package/dist/src/templates.d.ts +1 -0
- package/dist/src/templates.js +205 -0
- package/dist/src/trade.d.ts +2 -0
- package/dist/src/trade.js +95 -0
- package/dist/src/trail.d.ts +2 -0
- package/dist/src/trail.js +41 -0
- package/dist/src/validate.d.ts +13 -0
- package/dist/src/validate.js +35 -0
- package/dist/src/wallet.d.ts +9 -0
- package/dist/src/wallet.js +209 -0
- package/package.json +26 -54
- package/LICENSE.md +0 -89
- package/dist/admin/build.d.ts +0 -15
- package/dist/admin/build.d.ts.map +0 -1
- package/dist/admin/build.js +0 -295
- package/dist/admin/build.js.map +0 -1
- package/dist/admin/index.d.ts +0 -24
- package/dist/admin/index.d.ts.map +0 -1
- package/dist/admin/index.js +0 -98
- package/dist/admin/index.js.map +0 -1
- package/dist/admin/list.d.ts +0 -14
- package/dist/admin/list.d.ts.map +0 -1
- package/dist/admin/list.js +0 -90
- package/dist/admin/list.js.map +0 -1
- package/dist/admin/manifest.d.ts +0 -86
- package/dist/admin/manifest.d.ts.map +0 -1
- package/dist/admin/manifest.js +0 -183
- package/dist/admin/manifest.js.map +0 -1
- package/dist/admin/monorepo.d.ts +0 -25
- package/dist/admin/monorepo.d.ts.map +0 -1
- package/dist/admin/monorepo.js +0 -59
- package/dist/admin/monorepo.js.map +0 -1
- package/dist/admin/release.d.ts +0 -17
- package/dist/admin/release.d.ts.map +0 -1
- package/dist/admin/release.js +0 -144
- package/dist/admin/release.js.map +0 -1
- package/dist/admin/sync.d.ts +0 -14
- package/dist/admin/sync.d.ts.map +0 -1
- package/dist/admin/sync.js +0 -104
- package/dist/admin/sync.js.map +0 -1
- package/dist/admin/validate.d.ts +0 -15
- package/dist/admin/validate.d.ts.map +0 -1
- package/dist/admin/validate.js +0 -169
- package/dist/admin/validate.js.map +0 -1
- package/dist/banner.d.ts +0 -2
- package/dist/banner.d.ts.map +0 -1
- package/dist/banner.js +0 -15
- package/dist/banner.js.map +0 -1
- package/dist/clone-docs.d.ts +0 -17
- package/dist/clone-docs.d.ts.map +0 -1
- package/dist/clone-docs.js +0 -62
- package/dist/clone-docs.js.map +0 -1
- package/dist/clone-web.d.ts +0 -12
- package/dist/clone-web.d.ts.map +0 -1
- package/dist/clone-web.js +0 -50
- package/dist/clone-web.js.map +0 -1
- package/dist/commands/agent.d.ts +0 -20
- package/dist/commands/agent.d.ts.map +0 -1
- package/dist/commands/agent.js +0 -315
- package/dist/commands/agent.js.map +0 -1
- package/dist/commands/ask.d.ts +0 -4
- package/dist/commands/ask.d.ts.map +0 -1
- package/dist/commands/ask.js +0 -8
- package/dist/commands/ask.js.map +0 -1
- package/dist/commands/bounty.d.ts +0 -4
- package/dist/commands/bounty.d.ts.map +0 -1
- package/dist/commands/bounty.js +0 -24
- package/dist/commands/bounty.js.map +0 -1
- package/dist/commands/buy.d.ts +0 -19
- package/dist/commands/buy.d.ts.map +0 -1
- package/dist/commands/buy.js +0 -63
- package/dist/commands/buy.js.map +0 -1
- package/dist/commands/capabilities.d.ts +0 -4
- package/dist/commands/capabilities.d.ts.map +0 -1
- package/dist/commands/capabilities.js +0 -18
- package/dist/commands/capabilities.js.map +0 -1
- package/dist/commands/claw.d.ts +0 -4
- package/dist/commands/claw.d.ts.map +0 -1
- package/dist/commands/claw.js +0 -14
- package/dist/commands/claw.js.map +0 -1
- package/dist/commands/commend.d.ts +0 -4
- package/dist/commands/commend.d.ts.map +0 -1
- package/dist/commands/commend.js +0 -13
- package/dist/commands/commend.js.map +0 -1
- package/dist/commands/completion.d.ts +0 -4
- package/dist/commands/completion.d.ts.map +0 -1
- package/dist/commands/completion.js +0 -49
- package/dist/commands/completion.js.map +0 -1
- package/dist/commands/config.d.ts +0 -4
- package/dist/commands/config.d.ts.map +0 -1
- package/dist/commands/config.js +0 -78
- package/dist/commands/config.js.map +0 -1
- package/dist/commands/deploy.d.ts +0 -4
- package/dist/commands/deploy.d.ts.map +0 -1
- package/dist/commands/deploy.js +0 -45
- package/dist/commands/deploy.js.map +0 -1
- package/dist/commands/doctor.d.ts +0 -4
- package/dist/commands/doctor.d.ts.map +0 -1
- package/dist/commands/doctor.js +0 -72
- package/dist/commands/doctor.js.map +0 -1
- package/dist/commands/domain.d.ts +0 -4
- package/dist/commands/domain.d.ts.map +0 -1
- package/dist/commands/domain.js +0 -19
- package/dist/commands/domain.js.map +0 -1
- package/dist/commands/export.d.ts +0 -4
- package/dist/commands/export.d.ts.map +0 -1
- package/dist/commands/export.js +0 -15
- package/dist/commands/export.js.map +0 -1
- package/dist/commands/fade.d.ts +0 -4
- package/dist/commands/fade.d.ts.map +0 -1
- package/dist/commands/fade.js +0 -15
- package/dist/commands/fade.js.map +0 -1
- package/dist/commands/flag.d.ts +0 -4
- package/dist/commands/flag.d.ts.map +0 -1
- package/dist/commands/flag.js +0 -13
- package/dist/commands/flag.js.map +0 -1
- package/dist/commands/forget.d.ts +0 -4
- package/dist/commands/forget.d.ts.map +0 -1
- package/dist/commands/forget.js +0 -16
- package/dist/commands/forget.js.map +0 -1
- package/dist/commands/frontier.d.ts +0 -4
- package/dist/commands/frontier.d.ts.map +0 -1
- package/dist/commands/frontier.js +0 -11
- package/dist/commands/frontier.js.map +0 -1
- package/dist/commands/group.d.ts +0 -3
- package/dist/commands/group.d.ts.map +0 -1
- package/dist/commands/group.js +0 -123
- package/dist/commands/group.js.map +0 -1
- package/dist/commands/health.d.ts +0 -4
- package/dist/commands/health.d.ts.map +0 -1
- package/dist/commands/health.js +0 -11
- package/dist/commands/health.js.map +0 -1
- package/dist/commands/highways.d.ts +0 -4
- package/dist/commands/highways.d.ts.map +0 -1
- package/dist/commands/highways.js +0 -14
- package/dist/commands/highways.js.map +0 -1
- package/dist/commands/hire.d.ts +0 -4
- package/dist/commands/hire.d.ts.map +0 -1
- package/dist/commands/hire.js +0 -16
- package/dist/commands/hire.js.map +0 -1
- package/dist/commands/init.d.ts +0 -17
- package/dist/commands/init.d.ts.map +0 -1
- package/dist/commands/init.js +0 -308
- package/dist/commands/init.js.map +0 -1
- package/dist/commands/invite.d.ts +0 -4
- package/dist/commands/invite.d.ts.map +0 -1
- package/dist/commands/invite.js +0 -37
- package/dist/commands/invite.js.map +0 -1
- package/dist/commands/know.d.ts +0 -4
- package/dist/commands/know.d.ts.map +0 -1
- package/dist/commands/know.js +0 -8
- package/dist/commands/know.js.map +0 -1
- package/dist/commands/launch.d.ts +0 -4
- package/dist/commands/launch.d.ts.map +0 -1
- package/dist/commands/launch.js +0 -16
- package/dist/commands/launch.js.map +0 -1
- package/dist/commands/mark.d.ts +0 -4
- package/dist/commands/mark.d.ts.map +0 -1
- package/dist/commands/mark.js +0 -15
- package/dist/commands/mark.js.map +0 -1
- package/dist/commands/pay.d.ts +0 -4
- package/dist/commands/pay.d.ts.map +0 -1
- package/dist/commands/pay.js +0 -21
- package/dist/commands/pay.js.map +0 -1
- package/dist/commands/pipe.d.ts +0 -4
- package/dist/commands/pipe.d.ts.map +0 -1
- package/dist/commands/pipe.js +0 -35
- package/dist/commands/pipe.js.map +0 -1
- package/dist/commands/publish.d.ts +0 -4
- package/dist/commands/publish.d.ts.map +0 -1
- package/dist/commands/publish.js +0 -23
- package/dist/commands/publish.js.map +0 -1
- package/dist/commands/recall.d.ts +0 -4
- package/dist/commands/recall.d.ts.map +0 -1
- package/dist/commands/recall.js +0 -12
- package/dist/commands/recall.js.map +0 -1
- package/dist/commands/repl.d.ts +0 -4
- package/dist/commands/repl.d.ts.map +0 -1
- package/dist/commands/repl.js +0 -56
- package/dist/commands/repl.js.map +0 -1
- package/dist/commands/reveal.d.ts +0 -4
- package/dist/commands/reveal.d.ts.map +0 -1
- package/dist/commands/reveal.js +0 -11
- package/dist/commands/reveal.js.map +0 -1
- package/dist/commands/revenue.d.ts +0 -4
- package/dist/commands/revenue.d.ts.map +0 -1
- package/dist/commands/revenue.js +0 -11
- package/dist/commands/revenue.js.map +0 -1
- package/dist/commands/select.d.ts +0 -4
- package/dist/commands/select.d.ts.map +0 -1
- package/dist/commands/select.js +0 -19
- package/dist/commands/select.js.map +0 -1
- package/dist/commands/sell.d.ts +0 -15
- package/dist/commands/sell.d.ts.map +0 -1
- package/dist/commands/sell.js +0 -49
- package/dist/commands/sell.js.map +0 -1
- package/dist/commands/signal.d.ts +0 -4
- package/dist/commands/signal.d.ts.map +0 -1
- package/dist/commands/signal.js +0 -8
- package/dist/commands/signal.js.map +0 -1
- package/dist/commands/stats.d.ts +0 -4
- package/dist/commands/stats.d.ts.map +0 -1
- package/dist/commands/stats.js +0 -11
- package/dist/commands/stats.js.map +0 -1
- package/dist/commands/status.d.ts +0 -4
- package/dist/commands/status.d.ts.map +0 -1
- package/dist/commands/status.js +0 -18
- package/dist/commands/status.js.map +0 -1
- package/dist/commands/subscribe.d.ts +0 -14
- package/dist/commands/subscribe.d.ts.map +0 -1
- package/dist/commands/subscribe.js +0 -33
- package/dist/commands/subscribe.js.map +0 -1
- package/dist/commands/sync.d.ts +0 -4
- package/dist/commands/sync.d.ts.map +0 -1
- package/dist/commands/sync.js +0 -20
- package/dist/commands/sync.js.map +0 -1
- package/dist/commands/tail.d.ts +0 -4
- package/dist/commands/tail.d.ts.map +0 -1
- package/dist/commands/tail.js +0 -51
- package/dist/commands/tail.js.map +0 -1
- package/dist/commands/warn.d.ts +0 -4
- package/dist/commands/warn.d.ts.map +0 -1
- package/dist/commands/warn.js +0 -15
- package/dist/commands/warn.js.map +0 -1
- package/dist/copy-claude-config.d.ts +0 -2
- package/dist/copy-claude-config.d.ts.map +0 -1
- package/dist/copy-claude-config.js +0 -32
- package/dist/copy-claude-config.js.map +0 -1
- package/dist/create-org-profile.d.ts +0 -10
- package/dist/create-org-profile.d.ts.map +0 -1
- package/dist/create-org-profile.js +0 -136
- package/dist/create-org-profile.js.map +0 -1
- package/dist/create-user-profile.d.ts +0 -9
- package/dist/create-user-profile.d.ts.map +0 -1
- package/dist/create-user-profile.js +0 -115
- package/dist/create-user-profile.js.map +0 -1
- package/dist/index.d.ts +0 -3
- package/dist/index.d.ts.map +0 -1
- package/dist/index.js +0 -375
- package/dist/index.js.map +0 -1
- package/dist/lib/agent-detection.d.ts +0 -19
- package/dist/lib/agent-detection.d.ts.map +0 -1
- package/dist/lib/agent-detection.js +0 -87
- package/dist/lib/agent-detection.js.map +0 -1
- package/dist/lib/args.d.ts +0 -11
- package/dist/lib/args.d.ts.map +0 -1
- package/dist/lib/args.js +0 -57
- package/dist/lib/args.js.map +0 -1
- package/dist/lib/config.d.ts +0 -12
- package/dist/lib/config.d.ts.map +0 -1
- package/dist/lib/config.js +0 -38
- package/dist/lib/config.js.map +0 -1
- package/dist/lib/detect.d.ts +0 -45
- package/dist/lib/detect.d.ts.map +0 -1
- package/dist/lib/detect.js +0 -221
- package/dist/lib/detect.js.map +0 -1
- package/dist/lib/http.d.ts +0 -9
- package/dist/lib/http.d.ts.map +0 -1
- package/dist/lib/http.js +0 -25
- package/dist/lib/http.js.map +0 -1
- package/dist/lib/output.d.ts +0 -5
- package/dist/lib/output.d.ts.map +0 -1
- package/dist/lib/output.js +0 -32
- package/dist/lib/output.js.map +0 -1
- package/dist/lib/sdk.d.ts +0 -10
- package/dist/lib/sdk.d.ts.map +0 -1
- package/dist/lib/sdk.js +0 -22
- package/dist/lib/sdk.js.map +0 -1
- package/dist/lib/telemetry.d.ts +0 -4
- package/dist/lib/telemetry.d.ts.map +0 -1
- package/dist/lib/telemetry.js +0 -61
- package/dist/lib/telemetry.js.map +0 -1
- package/dist/sync-agents.d.ts +0 -5
- package/dist/sync-agents.d.ts.map +0 -1
- package/dist/sync-agents.js +0 -28
- package/dist/sync-agents.js.map +0 -1
- package/dist/sync-ontology.d.ts +0 -4
- package/dist/sync-ontology.d.ts.map +0 -1
- package/dist/sync-ontology.js +0 -40
- package/dist/sync-ontology.js.map +0 -1
- package/dist/utils/file-resolver.d.ts +0 -83
- package/dist/utils/file-resolver.d.ts.map +0 -1
- package/dist/utils/file-resolver.js +0 -194
- package/dist/utils/file-resolver.js.map +0 -1
- package/dist/utils/installation-setup.d.ts +0 -88
- package/dist/utils/installation-setup.d.ts.map +0 -1
- package/dist/utils/installation-setup.js +0 -409
- package/dist/utils/installation-setup.js.map +0 -1
- package/dist/utils/launch-claude.d.ts +0 -7
- package/dist/utils/launch-claude.d.ts.map +0 -1
- package/dist/utils/launch-claude.js +0 -86
- package/dist/utils/launch-claude.js.map +0 -1
- package/dist/utils/validation.d.ts +0 -48
- package/dist/utils/validation.d.ts.map +0 -1
- package/dist/utils/validation.js +0 -73
- package/dist/utils/validation.js.map +0 -1
|
@@ -0,0 +1,95 @@
|
|
|
1
|
+
import { askPath } from './lib/api-path.js';
|
|
2
|
+
const DEFAULT_API = process.env.ONEIE_BASE_URL ?? process.env.ONE_API_URL ?? 'https://api.one.ie';
|
|
3
|
+
function apiKey() {
|
|
4
|
+
return process.env.ONEIE_API_KEY ?? process.env.ONE_API_KEY ?? '';
|
|
5
|
+
}
|
|
6
|
+
function base(opts) {
|
|
7
|
+
return (opts.api ?? DEFAULT_API).replace(/\/$/, '');
|
|
8
|
+
}
|
|
9
|
+
function authHeaders() {
|
|
10
|
+
const h = { 'Content-Type': 'application/json' };
|
|
11
|
+
const k = apiKey();
|
|
12
|
+
if (k)
|
|
13
|
+
h['Authorization'] = `Bearer ${k}`;
|
|
14
|
+
return h;
|
|
15
|
+
}
|
|
16
|
+
async function ask(b, receiver, data) {
|
|
17
|
+
const res = await fetch(askPath(b, receiver), {
|
|
18
|
+
method: 'POST',
|
|
19
|
+
headers: authHeaders(),
|
|
20
|
+
body: JSON.stringify({ data }),
|
|
21
|
+
});
|
|
22
|
+
if (!res.ok) {
|
|
23
|
+
process.stderr.write(`${receiver} → ${res.status}\n`);
|
|
24
|
+
process.exit(1);
|
|
25
|
+
}
|
|
26
|
+
return res.json();
|
|
27
|
+
}
|
|
28
|
+
export function tradeCommands(program) {
|
|
29
|
+
program
|
|
30
|
+
.command('market')
|
|
31
|
+
.description('Discover agents and skills on the market')
|
|
32
|
+
.option('--query <text>', 'Search for agents or skills by keyword')
|
|
33
|
+
.option('--api <url>', 'API base URL', DEFAULT_API)
|
|
34
|
+
.option('--json', 'Output raw JSON')
|
|
35
|
+
.action(async (opts) => {
|
|
36
|
+
const b = base(opts);
|
|
37
|
+
const data = opts.query
|
|
38
|
+
? await ask(b, 'actors:find', { search: opts.query, type: 'agent' })
|
|
39
|
+
: await ask(b, 'market:list', {});
|
|
40
|
+
process.stdout.write(JSON.stringify(data, null, 2) + '\n');
|
|
41
|
+
});
|
|
42
|
+
program
|
|
43
|
+
.command('hire <skillId>')
|
|
44
|
+
.description('Hire an agent for a skill (use --dry-run to simulate)')
|
|
45
|
+
.option('--dry-run', 'Simulate — no settlement, no cost')
|
|
46
|
+
.option('--api <url>', 'API base URL', DEFAULT_API)
|
|
47
|
+
.option('--provider <uid>', 'Preferred provider UID')
|
|
48
|
+
.option('--budget <n>', 'Credit budget', '0')
|
|
49
|
+
.action(async (skillId, opts) => {
|
|
50
|
+
const payload = { skillId };
|
|
51
|
+
if (opts.provider)
|
|
52
|
+
payload.provider = opts.provider;
|
|
53
|
+
if (opts.budget)
|
|
54
|
+
payload.budget = Number(opts.budget);
|
|
55
|
+
if (opts.dryRun)
|
|
56
|
+
payload.simulate = true;
|
|
57
|
+
const data = await ask(base(opts), 'market:hire', payload);
|
|
58
|
+
if (opts.dryRun)
|
|
59
|
+
process.stdout.write('[dry-run] market:hire simulated — nothing settled\n');
|
|
60
|
+
process.stdout.write(JSON.stringify(data, null, 2) + '\n');
|
|
61
|
+
});
|
|
62
|
+
program
|
|
63
|
+
.command('bounty <skillId>')
|
|
64
|
+
.description('Post a bounty for a skill (use --dry-run to simulate)')
|
|
65
|
+
.option('--dry-run', 'Simulate — no settlement, no cost')
|
|
66
|
+
.option('--api <url>', 'API base URL', DEFAULT_API)
|
|
67
|
+
.option('--price <n>', 'Bounty price in credits', '0')
|
|
68
|
+
.action(async (skillId, opts) => {
|
|
69
|
+
const payload = { skillId, price: Number(opts.price) };
|
|
70
|
+
if (opts.dryRun)
|
|
71
|
+
payload.simulate = true;
|
|
72
|
+
const data = await ask(base(opts), 'market:bounty', payload);
|
|
73
|
+
if (opts.dryRun)
|
|
74
|
+
process.stdout.write('[dry-run] market:bounty simulated — nothing settled\n');
|
|
75
|
+
process.stdout.write(JSON.stringify(data, null, 2) + '\n');
|
|
76
|
+
});
|
|
77
|
+
program
|
|
78
|
+
.command('earn')
|
|
79
|
+
.description('Show credit earned summary (pay:weight)')
|
|
80
|
+
.option('--api <url>', 'API base URL', DEFAULT_API)
|
|
81
|
+
.option('--json', 'Output raw JSON')
|
|
82
|
+
.action(async (opts) => {
|
|
83
|
+
const data = await ask(base(opts), 'pay:weight', {});
|
|
84
|
+
process.stdout.write(JSON.stringify(data, null, 2) + '\n');
|
|
85
|
+
});
|
|
86
|
+
program
|
|
87
|
+
.command('usage')
|
|
88
|
+
.description('Show credit usage dashboard')
|
|
89
|
+
.option('--api <url>', 'API base URL', DEFAULT_API)
|
|
90
|
+
.option('--json', 'Output raw JSON')
|
|
91
|
+
.action(async (opts) => {
|
|
92
|
+
const data = await ask(base(opts), 'dashboard:usage', {});
|
|
93
|
+
process.stdout.write(JSON.stringify(data, null, 2) + '\n');
|
|
94
|
+
});
|
|
95
|
+
}
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import { Command } from 'commander';
|
|
2
|
+
import { authHeaders, jsonMode, resolveBase } from './lib/client.js';
|
|
3
|
+
const DEFAULT_API = resolveBase({}, 'https://one.ie');
|
|
4
|
+
export function trailCmd() {
|
|
5
|
+
const cmd = new Command('trail')
|
|
6
|
+
.description('read trail confidence for a tag combination — ranked next tasks from KV')
|
|
7
|
+
.argument('<tags>', 'comma-separated tags, e.g. fn:engineering,builds,deploy')
|
|
8
|
+
.option('--workspace <ws>', 'workspace slug', 'global')
|
|
9
|
+
.option('--limit <n>', 'max results', '10')
|
|
10
|
+
.option('--api <url>', 'api base url', DEFAULT_API)
|
|
11
|
+
.action(async (tags, opts) => {
|
|
12
|
+
const base = resolveBase(opts, 'https://one.ie');
|
|
13
|
+
const sorted = tags.split(',').map((t) => t.trim()).filter(Boolean).sort().join(',');
|
|
14
|
+
const params = new URLSearchParams({ tags: sorted, workspace: opts.workspace, limit: opts.limit });
|
|
15
|
+
const res = await fetch(`${base}/api/export/trail?${params}`, {
|
|
16
|
+
headers: authHeaders(),
|
|
17
|
+
});
|
|
18
|
+
if (!res.ok) {
|
|
19
|
+
const body = await res.text().catch(() => '');
|
|
20
|
+
process.stderr.write(`trail: ${res.status}\n${body}\n`);
|
|
21
|
+
process.exit(1);
|
|
22
|
+
}
|
|
23
|
+
const data = (await res.json());
|
|
24
|
+
if (jsonMode(cmd)) {
|
|
25
|
+
process.stdout.write(JSON.stringify(data, null, 2) + '\n');
|
|
26
|
+
return;
|
|
27
|
+
}
|
|
28
|
+
process.stdout.write(`fingerprint: ${data.fingerprint}\n`);
|
|
29
|
+
process.stdout.write(`confidence: ${(data.confidence * 100).toFixed(1)}%\n\n`);
|
|
30
|
+
if (!data.tasks.length) {
|
|
31
|
+
process.stdout.write('no trail data for these tags — run some /do cycles with matching tags\n');
|
|
32
|
+
return;
|
|
33
|
+
}
|
|
34
|
+
for (const t of data.tasks) {
|
|
35
|
+
const pct = (t.confidence * 100).toFixed(0).padStart(3);
|
|
36
|
+
const score = t.score.toFixed(2).padStart(6);
|
|
37
|
+
process.stdout.write(` ${pct}% score=${score} ${t.slug}\n`);
|
|
38
|
+
}
|
|
39
|
+
});
|
|
40
|
+
return cmd;
|
|
41
|
+
}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
export interface ClientShape {
|
|
2
|
+
slug?: string;
|
|
3
|
+
name?: string;
|
|
4
|
+
markup_pct?: number | null;
|
|
5
|
+
monthly_cap?: number | null;
|
|
6
|
+
credits?: number | null;
|
|
7
|
+
}
|
|
8
|
+
export declare function validateClient(c: ClientShape): string[];
|
|
9
|
+
export declare function frontmatter(md: string): Record<string, string>;
|
|
10
|
+
export declare function validateAgent(md: string): {
|
|
11
|
+
name: string;
|
|
12
|
+
errors: string[];
|
|
13
|
+
};
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
export function validateClient(c) {
|
|
2
|
+
const errs = [];
|
|
3
|
+
if (!c.slug)
|
|
4
|
+
errs.push('client: slug required');
|
|
5
|
+
if (!c.name)
|
|
6
|
+
errs.push('client: name required');
|
|
7
|
+
if (c.markup_pct != null && (c.markup_pct < 0 || c.markup_pct > 100))
|
|
8
|
+
errs.push('client: markup_pct must be 0–100');
|
|
9
|
+
if (c.monthly_cap != null && c.monthly_cap < 0)
|
|
10
|
+
errs.push('client: monthly_cap must be ≥ 0');
|
|
11
|
+
if (c.credits != null && c.credits < 0)
|
|
12
|
+
errs.push('client: credits must be ≥ 0');
|
|
13
|
+
return errs;
|
|
14
|
+
}
|
|
15
|
+
export function frontmatter(md) {
|
|
16
|
+
const m = md.match(/^---\n([\s\S]*?)\n---/);
|
|
17
|
+
if (!m)
|
|
18
|
+
return {};
|
|
19
|
+
const out = {};
|
|
20
|
+
for (const line of m[1].split('\n')) {
|
|
21
|
+
const kv = line.match(/^([A-Za-z_][\w-]*)\s*:\s*(.*)$/);
|
|
22
|
+
if (kv)
|
|
23
|
+
out[kv[1]] = kv[2].trim();
|
|
24
|
+
}
|
|
25
|
+
return out;
|
|
26
|
+
}
|
|
27
|
+
export function validateAgent(md) {
|
|
28
|
+
const fm = frontmatter(md);
|
|
29
|
+
const errors = [];
|
|
30
|
+
if (!fm.name)
|
|
31
|
+
errors.push('agent: frontmatter `name` required');
|
|
32
|
+
if (!fm.description)
|
|
33
|
+
errors.push('agent: frontmatter `description` required');
|
|
34
|
+
return { name: fm.name ?? '', errors };
|
|
35
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { Command } from 'commander';
|
|
2
|
+
import { askPath } from './lib/api-path.js';
|
|
3
|
+
export { askPath };
|
|
4
|
+
export declare function faucetOk(results: Array<{
|
|
5
|
+
success: boolean;
|
|
6
|
+
}>): boolean;
|
|
7
|
+
export declare function okWrap(result: Record<string, unknown>): Record<string, unknown>;
|
|
8
|
+
export declare function walletCmd(): Command;
|
|
9
|
+
export declare function writeKeysFile(filePath: string, contents: string, accepted: boolean): void;
|
|
@@ -0,0 +1,209 @@
|
|
|
1
|
+
import { Command } from 'commander';
|
|
2
|
+
import { mergeEnv } from './env.js';
|
|
3
|
+
import { writeFileSync, chmodSync, readFileSync } from 'node:fs';
|
|
4
|
+
import { generateWallet, recoverWallet } from '@oneie/sdk/wallet';
|
|
5
|
+
import { askPath } from './lib/api-path.js';
|
|
6
|
+
const DEFAULT_API = process.env.ONEIE_BASE_URL ?? process.env.ONE_API_URL ?? 'https://api.one.ie';
|
|
7
|
+
// Re-exported for existing callers/tests — canonical implementation now lives
|
|
8
|
+
// in ./lib/api-path.ts so trade.ts/client.ts/coordinate.ts/catalog.ts can share
|
|
9
|
+
// it instead of each hardcoding /api/ask/<receiver> against DEFAULT_API.
|
|
10
|
+
export { askPath };
|
|
11
|
+
// The ask envelope nests the resolver's return under `result`, not at the top
|
|
12
|
+
// level: { outcome:'result'|'timeout'|'dissolved'|'failure', result, signalId,
|
|
13
|
+
// receiver }. Unwrap it here so callers work with the plain wallet:* shape.
|
|
14
|
+
async function ask(base, key, receiver, data) {
|
|
15
|
+
const res = await fetch(askPath(base, receiver), {
|
|
16
|
+
method: 'POST',
|
|
17
|
+
headers: { 'Content-Type': 'application/json', ...(key ? { Authorization: `Bearer ${key}` } : {}) },
|
|
18
|
+
body: JSON.stringify({ data }),
|
|
19
|
+
});
|
|
20
|
+
if (!res.ok) {
|
|
21
|
+
const body = await res.text().catch(() => '');
|
|
22
|
+
throw new Error(`${receiver} → ${res.status}\n${body}`);
|
|
23
|
+
}
|
|
24
|
+
const envelope = (await res.json());
|
|
25
|
+
if (envelope.outcome && envelope.outcome !== 'result') {
|
|
26
|
+
throw new Error(`${receiver} → ${envelope.outcome}`);
|
|
27
|
+
}
|
|
28
|
+
return envelope.result ?? envelope;
|
|
29
|
+
}
|
|
30
|
+
const DEFAULT_PAY = process.env.ONEIE_PAY_URL ?? 'https://pay.one.ie';
|
|
31
|
+
// pay.one.ie is a separate service from the gateway/one.ie ask surface above —
|
|
32
|
+
// its own protocol envelope, POST <payUrl>/ { protocol, data } → { success, data,
|
|
33
|
+
// error? }. faucet_request is public (no credential), matching the threat model:
|
|
34
|
+
// funding ≠ ownership, anyone can fund any address (wallet-plan.md).
|
|
35
|
+
async function payProtocol(payUrl, protocol, data) {
|
|
36
|
+
const res = await fetch(`${payUrl.replace(/\/$/, '')}/`, {
|
|
37
|
+
method: 'POST',
|
|
38
|
+
headers: { 'Content-Type': 'application/json' },
|
|
39
|
+
body: JSON.stringify({ protocol, data }),
|
|
40
|
+
});
|
|
41
|
+
const body = (await res.json().catch(() => ({})));
|
|
42
|
+
if (!res.ok || !body.success) {
|
|
43
|
+
throw new Error(`${protocol} → ${body.error?.message ?? body.error?.code ?? res.status}`);
|
|
44
|
+
}
|
|
45
|
+
return body.data ?? {};
|
|
46
|
+
}
|
|
47
|
+
function resolveAuth(opts) {
|
|
48
|
+
const env = mergeEnv(process.cwd());
|
|
49
|
+
const key = opts.key ?? env.ONEIE_API_KEY ?? env.ONE_API_KEY ?? '';
|
|
50
|
+
return { base: opts.api.replace(/\/$/, ''), key };
|
|
51
|
+
}
|
|
52
|
+
function resolveWorkspace(explicit) {
|
|
53
|
+
const env = mergeEnv(process.cwd());
|
|
54
|
+
const workspace = explicit ?? env.AGENCY_SLUG;
|
|
55
|
+
if (!workspace) {
|
|
56
|
+
process.stderr.write('--workspace required (or set AGENCY_SLUG)\n');
|
|
57
|
+
process.exit(1);
|
|
58
|
+
}
|
|
59
|
+
return workspace;
|
|
60
|
+
}
|
|
61
|
+
// A chain with no auto-fund path (ETH/USDC/BTC) legitimately returns success:false
|
|
62
|
+
// with a manualUrls fallback — that's documented, expected behavior (wallet-plan.md:
|
|
63
|
+
// "SUI/SOL auto-fund; ETH/USDC/BTC return a manual URL"), never a call failure.
|
|
64
|
+
// `ok` here means "the request was answered" (payProtocol already throws on a real
|
|
65
|
+
// failure) — per-chain funded/manual status lives in `results`, read that, not `ok`.
|
|
66
|
+
export function faucetOk(results) {
|
|
67
|
+
return results.length > 0;
|
|
68
|
+
}
|
|
69
|
+
// wallet:get/create/transactions return bare data or { error } — no `ok` field
|
|
70
|
+
// of their own. wallet:send already returns { ok, ... }. Normalize both to the
|
|
71
|
+
// { ok, ... } shape out() expects without ever overwriting a real error/false
|
|
72
|
+
// with a hardcoded ok:true.
|
|
73
|
+
export function okWrap(result) {
|
|
74
|
+
if ('ok' in result)
|
|
75
|
+
return result;
|
|
76
|
+
if ('error' in result)
|
|
77
|
+
return { ok: false, ...result };
|
|
78
|
+
return { ok: true, ...result };
|
|
79
|
+
}
|
|
80
|
+
export function walletCmd() {
|
|
81
|
+
const cmd = new Command('wallet').description('Read balances, provision a wallet row, fund from testnet, send crypto — wallet:* receivers + pay.one.ie');
|
|
82
|
+
cmd.command('get')
|
|
83
|
+
.description('Credits, spend ceiling, wallet rows, live chain balances, delegated wallets')
|
|
84
|
+
.option('--workspace <slug>', 'Workspace (defaults to AGENCY_SLUG)')
|
|
85
|
+
.option('--actor <id>', 'Actor within the workspace (defaults to workspace)')
|
|
86
|
+
.option('--api <url>', 'API base URL', DEFAULT_API)
|
|
87
|
+
.option('--key <key>', 'API key (overrides ONEIE_API_KEY env)')
|
|
88
|
+
.action(async (opts) => {
|
|
89
|
+
const { base, key } = resolveAuth(opts);
|
|
90
|
+
const workspace = resolveWorkspace(opts.workspace);
|
|
91
|
+
const result = await ask(base, key, 'wallet:get', { workspace, actor: opts.actor });
|
|
92
|
+
out(cmd, okWrap(result));
|
|
93
|
+
});
|
|
94
|
+
cmd.command('create')
|
|
95
|
+
.description('Provision a wallet row for an actor (idempotent)')
|
|
96
|
+
.option('--workspace <slug>', 'Workspace (defaults to AGENCY_SLUG)')
|
|
97
|
+
.option('--actor <id>', 'Actor to provision (defaults to workspace)')
|
|
98
|
+
.option('--kind <kind>', 'human | agent', 'human')
|
|
99
|
+
.option('--api <url>', 'API base URL', DEFAULT_API)
|
|
100
|
+
.option('--key <key>', 'API key (overrides ONEIE_API_KEY env)')
|
|
101
|
+
.action(async (opts) => {
|
|
102
|
+
const { base, key } = resolveAuth(opts);
|
|
103
|
+
const workspace = resolveWorkspace(opts.workspace);
|
|
104
|
+
const result = await ask(base, key, 'wallet:create', { workspace, actor: opts.actor, kind: opts.kind });
|
|
105
|
+
out(cmd, okWrap(result));
|
|
106
|
+
});
|
|
107
|
+
cmd.command('transactions')
|
|
108
|
+
.description('Unified transaction feed across every settlement rail')
|
|
109
|
+
.option('--workspace <slug>', 'Workspace (defaults to AGENCY_SLUG)')
|
|
110
|
+
.option('--limit <n>', 'Max rows (default 100, max 500)', '100')
|
|
111
|
+
.option('--api <url>', 'API base URL', DEFAULT_API)
|
|
112
|
+
.option('--key <key>', 'API key (overrides ONEIE_API_KEY env)')
|
|
113
|
+
.action(async (opts) => {
|
|
114
|
+
const { base, key } = resolveAuth(opts);
|
|
115
|
+
const workspace = resolveWorkspace(opts.workspace);
|
|
116
|
+
const result = await ask(base, key, 'wallet:transactions', { workspace, limit: Number(opts.limit) });
|
|
117
|
+
out(cmd, okWrap(result));
|
|
118
|
+
});
|
|
119
|
+
cmd.command('faucet <address>')
|
|
120
|
+
.description('Fund an address from a testnet tap — Sui and Solana auto-fund; ETH/USDC/BTC return a manual faucet URL')
|
|
121
|
+
.requiredOption('--chain <chain>', 'sui | sol | eth | usdc | btc | all')
|
|
122
|
+
.option('--network <network>', 'testnet | devnet (Sui only)')
|
|
123
|
+
.option('--pay-url <url>', 'pay.one.ie base URL', DEFAULT_PAY)
|
|
124
|
+
.action(async (address, opts) => {
|
|
125
|
+
const data = await payProtocol(opts.payUrl, 'faucet_request', { chain: opts.chain, address, network: opts.network });
|
|
126
|
+
const results = (data.results ?? []);
|
|
127
|
+
out(cmd, { ok: faucetOk(results), results, manualFaucets: data.manualFaucets });
|
|
128
|
+
});
|
|
129
|
+
cmd.command('send <to>')
|
|
130
|
+
.description('Send crypto via pay.one.ie payment links, incl. Bitcoin — sign the transfer yourself first, pass the tx hash')
|
|
131
|
+
.requiredOption('--chain <chain>', 'SUI | EVM | SOL | BTC | BASE | ARB | OPT')
|
|
132
|
+
.requiredOption('--amount <n>', 'Amount to send')
|
|
133
|
+
.requiredOption('--payment-tx <hash>', 'The transaction hash from signing & broadcasting client-side — this command never signs')
|
|
134
|
+
.option('--workspace <slug>', 'Source workspace (defaults to AGENCY_SLUG)')
|
|
135
|
+
.option('--unit <unit>', 'usd | token', 'usd')
|
|
136
|
+
.option('--currency <currency>', 'NATIVE | USDC', 'NATIVE')
|
|
137
|
+
.option('--user-address <address>', 'Sender address (defaults to --to)')
|
|
138
|
+
.option('--memo <text>', 'Payment memo')
|
|
139
|
+
.option('--api <url>', 'API base URL', DEFAULT_API)
|
|
140
|
+
.option('--key <key>', 'API key (overrides ONEIE_API_KEY env)')
|
|
141
|
+
.action(async (to, opts) => {
|
|
142
|
+
const { base, key } = resolveAuth(opts);
|
|
143
|
+
const workspace = resolveWorkspace(opts.workspace);
|
|
144
|
+
const result = await ask(base, key, 'wallet:send', {
|
|
145
|
+
workspace, to, chain: opts.chain, amount: Number(opts.amount), paymentTx: opts.paymentTx,
|
|
146
|
+
unit: opts.unit, currency: opts.currency, userAddress: opts.userAddress, memo: opts.memo,
|
|
147
|
+
});
|
|
148
|
+
out(cmd, okWrap(result));
|
|
149
|
+
});
|
|
150
|
+
cmd.command('keygen')
|
|
151
|
+
.description('Generate or recover a self-hosted wallet locally — 4 chains (Sui/EVM/Sol/BTC), fully offline, never touches the network or a server. Prints once by default; use --out for scripted bulk provisioning')
|
|
152
|
+
.option('--recover', 'Recover from a 24-word BIP-39 mnemonic (ONE_WALLET_MNEMONIC env or stdin) instead of generating a fresh one')
|
|
153
|
+
.option('--out <file>', 'Write the mnemonic + keys to a file at mode 0600 instead of printing once')
|
|
154
|
+
.option('--yes-i-accept-plaintext-file', 'Required with --out — acknowledge that unencrypted key material will be written to disk')
|
|
155
|
+
.action(async (opts) => {
|
|
156
|
+
const wallet = opts.recover ? await recoverWallet(readMnemonic()) : await generateWallet();
|
|
157
|
+
const addresses = Object.fromEntries(wallet.keys.map((k) => [k.chain, k.address]));
|
|
158
|
+
if (opts.out) {
|
|
159
|
+
const contents = JSON.stringify({ mnemonic: wallet.mnemonic, keys: wallet.keys }, null, 2) + '\n';
|
|
160
|
+
writeKeysFile(opts.out, contents, Boolean(opts.yesIAcceptPlaintextFile));
|
|
161
|
+
out(cmd, { ok: true, out: opts.out, chains: wallet.keys.map((k) => k.chain), addresses });
|
|
162
|
+
}
|
|
163
|
+
else {
|
|
164
|
+
out(cmd, { ok: true, mnemonic: wallet.mnemonic, addresses, keys: wallet.keys });
|
|
165
|
+
}
|
|
166
|
+
});
|
|
167
|
+
return cmd;
|
|
168
|
+
}
|
|
169
|
+
// Read the recovery mnemonic for `keygen --recover`: ONE_WALLET_MNEMONIC env first
|
|
170
|
+
// (scriptable), else stdin (fd 0). Never a CLI arg — keeps the phrase out of the
|
|
171
|
+
// process table / shell history.
|
|
172
|
+
function readMnemonic() {
|
|
173
|
+
const fromEnv = process.env.ONE_WALLET_MNEMONIC?.trim();
|
|
174
|
+
if (fromEnv)
|
|
175
|
+
return fromEnv;
|
|
176
|
+
try {
|
|
177
|
+
return readFileSync(0, 'utf8').trim();
|
|
178
|
+
}
|
|
179
|
+
catch {
|
|
180
|
+
throw new Error('--recover needs a mnemonic — set ONE_WALLET_MNEMONIC or pipe the phrase on stdin');
|
|
181
|
+
}
|
|
182
|
+
}
|
|
183
|
+
// Write key material to a plaintext file at mode 0600, and ONLY when the operator
|
|
184
|
+
// explicitly accepted the risk. chmod after write in case umask stripped bits at
|
|
185
|
+
// create time. Exported for the demo gate.
|
|
186
|
+
export function writeKeysFile(filePath, contents, accepted) {
|
|
187
|
+
if (!accepted) {
|
|
188
|
+
throw new Error('refusing to write plaintext key material to disk — pass --yes-i-accept-plaintext-file to override');
|
|
189
|
+
}
|
|
190
|
+
writeFileSync(filePath, contents, { mode: 0o600 });
|
|
191
|
+
chmodSync(filePath, 0o600);
|
|
192
|
+
}
|
|
193
|
+
function out(cmd, data) {
|
|
194
|
+
const isJson = cmd.parent?.opts().json;
|
|
195
|
+
if (isJson) {
|
|
196
|
+
process.stdout.write(JSON.stringify(data) + '\n');
|
|
197
|
+
}
|
|
198
|
+
else if (data.ok) {
|
|
199
|
+
const pairs = Object.entries(data)
|
|
200
|
+
.filter(([k]) => k !== 'ok')
|
|
201
|
+
.map(([k, v]) => `${k}=${JSON.stringify(v)}`)
|
|
202
|
+
.join(' ');
|
|
203
|
+
console.log('✓', pairs);
|
|
204
|
+
}
|
|
205
|
+
else {
|
|
206
|
+
const detail = data.error ?? data.errors ?? data.issues ?? data;
|
|
207
|
+
console.error('✗', typeof detail === 'string' ? detail : JSON.stringify(detail));
|
|
208
|
+
}
|
|
209
|
+
}
|
package/package.json
CHANGED
|
@@ -1,66 +1,38 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "oneie",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "4.0.0",
|
|
4
|
+
"description": "ONE agent CLI",
|
|
4
5
|
"type": "module",
|
|
5
|
-
"description": "Build apps, websites, and AI agents in English. Zero-interaction setup for AI agents (Claude Code, Cursor, Windsurf). Download to your computer, run in the cloud, deploy to the edge. Open source and free forever.",
|
|
6
6
|
"bin": {
|
|
7
|
-
"oneie": "
|
|
8
|
-
"one": "
|
|
7
|
+
"oneie": "dist/src/index.js",
|
|
8
|
+
"one": "dist/src/index.js"
|
|
9
9
|
},
|
|
10
|
-
"
|
|
11
|
-
"
|
|
12
|
-
"
|
|
13
|
-
"prepublishOnly": "npm run build"
|
|
14
|
-
},
|
|
15
|
-
"keywords": [
|
|
16
|
-
"one",
|
|
17
|
-
"ontology",
|
|
18
|
-
"cli",
|
|
19
|
-
"bootstrap",
|
|
20
|
-
"6-dimension",
|
|
21
|
-
"ai-agents",
|
|
22
|
-
"cascade",
|
|
23
|
-
"astro",
|
|
24
|
-
"react",
|
|
25
|
-
"convex",
|
|
26
|
-
"website-builder",
|
|
27
|
-
"no-code",
|
|
28
|
-
"low-code",
|
|
29
|
-
"claude",
|
|
30
|
-
"ai"
|
|
10
|
+
"files": [
|
|
11
|
+
"dist",
|
|
12
|
+
"README.md"
|
|
31
13
|
],
|
|
32
|
-
"
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
"
|
|
36
|
-
"
|
|
37
|
-
"
|
|
38
|
-
},
|
|
39
|
-
"homepage": "https://one.ie",
|
|
40
|
-
"bugs": {
|
|
41
|
-
"url": "https://github.com/one-ie/envelopes/issues"
|
|
42
|
-
},
|
|
43
|
-
"engines": {
|
|
44
|
-
"node": ">=22.16.0"
|
|
14
|
+
"scripts": {
|
|
15
|
+
"build": "tsc && cp package.json dist/ && chmod +x dist/src/index.js",
|
|
16
|
+
"dev": "tsx src/index.ts",
|
|
17
|
+
"typecheck": "tsc --noEmit",
|
|
18
|
+
"test": "vitest run",
|
|
19
|
+
"prepublishOnly": "bun run build"
|
|
45
20
|
},
|
|
46
21
|
"dependencies": {
|
|
47
|
-
"
|
|
48
|
-
"
|
|
49
|
-
"fs-extra": "^11.2.0",
|
|
50
|
-
"glob": "^10.3.10",
|
|
51
|
-
"ora": "^8.0.1",
|
|
52
|
-
"prompts": "^2.4.2",
|
|
53
|
-
"yaml": "^2.3.4"
|
|
22
|
+
"commander": "^12.0.0",
|
|
23
|
+
"@oneie/sdk": "^0.14.6"
|
|
54
24
|
},
|
|
55
25
|
"devDependencies": {
|
|
56
|
-
"@
|
|
57
|
-
"@types/node": "^
|
|
58
|
-
"
|
|
59
|
-
"typescript": "^5.
|
|
26
|
+
"@oneie/evals": "workspace:*",
|
|
27
|
+
"@types/node": "^25.6.0",
|
|
28
|
+
"tsx": "^4.0.0",
|
|
29
|
+
"typescript": "^5.4.0",
|
|
30
|
+
"vitest": "^4.1.6"
|
|
60
31
|
},
|
|
61
|
-
"
|
|
62
|
-
|
|
63
|
-
"
|
|
64
|
-
"
|
|
65
|
-
|
|
32
|
+
"license": "SEE LICENSE IN LICENSE",
|
|
33
|
+
"repository": {
|
|
34
|
+
"type": "git",
|
|
35
|
+
"url": "git+https://github.com/one-ie/packages.git",
|
|
36
|
+
"directory": "cli"
|
|
37
|
+
}
|
|
66
38
|
}
|
package/LICENSE.md
DELETED
|
@@ -1,89 +0,0 @@
|
|
|
1
|
-
# ONE License (Version 1.0)
|
|
2
|
-
|
|
3
|
-
## Maximum Freedom, Zero Restrictions
|
|
4
|
-
|
|
5
|
-
This license empowers you with complete commercial freedom to use, reuse, modify, sell and resell the software, AI and data, at any price you wish.
|
|
6
|
-
|
|
7
|
-
No usage limits. No royalty fees. Just pure, unrestricted ability to innovate and profit from the software.
|
|
8
|
-
|
|
9
|
-
You are free to run ONE locally, on your own servers, in the cloud and at the edge.
|
|
10
|
-
|
|
11
|
-
## You Receive:
|
|
12
|
-
|
|
13
|
-
### Unlimited Rights
|
|
14
|
-
|
|
15
|
-
You have unrestricted rights to use, modify, license, sublicense, distribute, sell, resell and monetize the Software without restrictions.
|
|
16
|
-
|
|
17
|
-
### Permitted Actions
|
|
18
|
-
|
|
19
|
-
Including, but not limited to:
|
|
20
|
-
|
|
21
|
-
- Commercial use and integration into any systems
|
|
22
|
-
- Creation and sale of derivative works
|
|
23
|
-
- Providing software as a service
|
|
24
|
-
- AI training and content generation
|
|
25
|
-
- Patenting innovations based on the Software
|
|
26
|
-
- Open source applications and integrations
|
|
27
|
-
|
|
28
|
-
### License Compatibility
|
|
29
|
-
|
|
30
|
-
This license is compatible with all major open-source licenses, including:
|
|
31
|
-
|
|
32
|
-
- MIT License
|
|
33
|
-
- Apache License
|
|
34
|
-
- GNU General Public License (GPL)
|
|
35
|
-
- BSD Licenses
|
|
36
|
-
- Mozilla Public License
|
|
37
|
-
|
|
38
|
-
### Perpetual Rights
|
|
39
|
-
|
|
40
|
-
These rights are granted in perpetuity and are irrevocable, provided the brand requirements are maintained.
|
|
41
|
-
|
|
42
|
-
## Intellectual Property
|
|
43
|
-
|
|
44
|
-
- We retain ownership of the original data.
|
|
45
|
-
- You own any modifications you make.
|
|
46
|
-
- You never have to share your code or data.
|
|
47
|
-
|
|
48
|
-
## Liability and Warranty
|
|
49
|
-
|
|
50
|
-
The data and code is provided "AS IS". We bear no liability for its use.
|
|
51
|
-
|
|
52
|
-
## Brand Requirements
|
|
53
|
-
|
|
54
|
-
The only obligation is:
|
|
55
|
-
|
|
56
|
-
- Don't remove ONE brand, logo and link to https://one.ie/.
|
|
57
|
-
|
|
58
|
-
## Termination
|
|
59
|
-
|
|
60
|
-
This license terminates if you remove or hide our brand.
|
|
61
|
-
|
|
62
|
-
## Dispute Resolution
|
|
63
|
-
|
|
64
|
-
- Resolved through good faith negotiation
|
|
65
|
-
- Mediation if needed
|
|
66
|
-
- Binding arbitration as last resort
|
|
67
|
-
|
|
68
|
-
## Education
|
|
69
|
-
|
|
70
|
-
Learn how to build AI Agents at https://one.ie/learn
|
|
71
|
-
|
|
72
|
-
## Agents
|
|
73
|
-
|
|
74
|
-
Connect to https://one.ie/llms.txt
|
|
75
|
-
|
|
76
|
-
---
|
|
77
|
-
|
|
78
|
-
This license is designed to maximize freedom to innovate and profit from free software, open source without restrictions. There is no copyleft requirement to share any code making it suitable for enterprise use.
|
|
79
|
-
|
|
80
|
-
## Enterprise Solutions
|
|
81
|
-
|
|
82
|
-
Building something big? We're here to help:
|
|
83
|
-
|
|
84
|
-
- **Free**: Use all features with minimal branding - compliant with your enterprise
|
|
85
|
-
- **Custom**: White-label solutions for your needs
|
|
86
|
-
- **Enterprise**: Full support and deployment assistance
|
|
87
|
-
- **Training**: Help getting your team started
|
|
88
|
-
|
|
89
|
-
Contact agent@one.ie to share your needs.
|
package/dist/admin/build.d.ts
DELETED
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Build Command
|
|
3
|
-
*
|
|
4
|
-
* Builds packages from the manifest by copying files to apps/ and packages/.
|
|
5
|
-
*
|
|
6
|
-
* Usage:
|
|
7
|
-
* npx oneie admin build <package> # Build specific package
|
|
8
|
-
* npx oneie admin build --all # Build all packages
|
|
9
|
-
*/
|
|
10
|
-
import type { AdminOptions } from "./index.js";
|
|
11
|
-
/**
|
|
12
|
-
* Run the build command
|
|
13
|
-
*/
|
|
14
|
-
export declare function runBuild(args: string[], options: AdminOptions): Promise<void>;
|
|
15
|
-
//# sourceMappingURL=build.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"build.d.ts","sourceRoot":"","sources":["../../src/admin/build.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAeH,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,YAAY,CAAC;AAE/C;;GAEG;AACH,wBAAsB,QAAQ,CAC5B,IAAI,EAAE,MAAM,EAAE,EACd,OAAO,EAAE,YAAY,GACpB,OAAO,CAAC,IAAI,CAAC,CAsBf"}
|