claude-flow 3.15.0 → 3.16.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/package.json +1 -1
- package/v3/@claude-flow/cli/dist/src/business-pods/bbs-budget-tracker.d.ts +139 -0
- package/v3/@claude-flow/cli/dist/src/business-pods/bbs-budget-tracker.js +358 -0
- package/v3/@claude-flow/cli/dist/src/business-pods/domain-affinity-policy.d.ts +47 -0
- package/v3/@claude-flow/cli/dist/src/business-pods/domain-affinity-policy.js +65 -0
- package/v3/@claude-flow/cli/dist/src/business-pods/pod-schema.d.ts +96 -0
- package/v3/@claude-flow/cli/dist/src/business-pods/pod-schema.js +225 -0
- package/v3/@claude-flow/cli/dist/src/mcp-client.js +16 -0
- package/v3/@claude-flow/cli/dist/src/mcp-tools/agentbbs-tools.d.ts +28 -0
- package/v3/@claude-flow/cli/dist/src/mcp-tools/agentbbs-tools.js +394 -0
- package/v3/@claude-flow/cli/dist/src/mcp-tools/business-pod-tools.d.ts +20 -0
- package/v3/@claude-flow/cli/dist/src/mcp-tools/business-pod-tools.js +169 -0
- package/v3/@claude-flow/cli/dist/src/mcp-tools/http-fetch-tools.d.ts +55 -0
- package/v3/@claude-flow/cli/dist/src/mcp-tools/http-fetch-tools.js +329 -0
- package/v3/@claude-flow/cli/dist/src/mcp-tools/index.d.ts +3 -0
- package/v3/@claude-flow/cli/dist/src/mcp-tools/index.js +6 -0
- package/v3/@claude-flow/cli/package.json +2 -1
|
@@ -0,0 +1,96 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Pod template schema validator (ADR-164 §3.3 + ADR-164.1 §3.2).
|
|
3
|
+
*
|
|
4
|
+
* Defines the `PodTemplate` type that every business-pod JSON file under
|
|
5
|
+
* `plugins/ruflo-business-pods/templates/` MUST conform to, and a hand-rolled
|
|
6
|
+
* validator that throws structured errors on invalid templates. No external
|
|
7
|
+
* deps (no AJV, no zod) — the schema is small enough to validate by hand and
|
|
8
|
+
* doing so keeps the cli's optional-dep surface unchanged.
|
|
9
|
+
*
|
|
10
|
+
* @module @claude-flow/cli/business-pods/pod-schema
|
|
11
|
+
*/
|
|
12
|
+
export type PiiPolicy = 'soc2' | 'gdpr' | 'hipaa' | 'permissive';
|
|
13
|
+
export interface PodAgent {
|
|
14
|
+
/** Role label inside the pod, e.g. "lead-gen-agent". */
|
|
15
|
+
role: string;
|
|
16
|
+
/** Must resolve to a known ruflo agent type (researcher / coder / ...). */
|
|
17
|
+
agentType: string;
|
|
18
|
+
/** Human-readable description of what the agent does in this pod. */
|
|
19
|
+
description: string;
|
|
20
|
+
/** Routing hint — true = prefer local stdio execution. */
|
|
21
|
+
preferLocal: boolean;
|
|
22
|
+
}
|
|
23
|
+
export interface PodBench {
|
|
24
|
+
/** Bench identifier, e.g. "sales-pipeline-bench". */
|
|
25
|
+
name: string;
|
|
26
|
+
/** What the bench measures. */
|
|
27
|
+
description: string;
|
|
28
|
+
/** Acceptance criteria — non-empty list of human-readable bullets. */
|
|
29
|
+
successCriteria: string[];
|
|
30
|
+
/** Cadence between bench evaluations (hours, ≥1). */
|
|
31
|
+
scheduleHours: number;
|
|
32
|
+
}
|
|
33
|
+
export interface PodAuditReadView {
|
|
34
|
+
/** Event types surfaced to the business-owner read view. */
|
|
35
|
+
includedEventTypes: string[];
|
|
36
|
+
/** Retention window for the read view (days, ≥1). */
|
|
37
|
+
retentionDays: number;
|
|
38
|
+
}
|
|
39
|
+
export interface PodTemplate {
|
|
40
|
+
/** Canonical pod name (matches BBS roomId). */
|
|
41
|
+
name: string;
|
|
42
|
+
/** Display name for the cockpit. */
|
|
43
|
+
displayName: string;
|
|
44
|
+
/** BBS room this pod serves, e.g. "sales". */
|
|
45
|
+
roomId: string;
|
|
46
|
+
/** Ordered list of pod agent compositions. */
|
|
47
|
+
agents: PodAgent[];
|
|
48
|
+
/** Allow-list of MCP tools the pod's agents may invoke. */
|
|
49
|
+
allowedMcpTools: string[];
|
|
50
|
+
/** Bench definition for periodic Darwin /loop scoring. */
|
|
51
|
+
bench: PodBench;
|
|
52
|
+
/** PII compliance mode applied to every envelope in/out of this room. */
|
|
53
|
+
piiPolicy: PiiPolicy;
|
|
54
|
+
/** Monthly USD hard cap (0 = unlimited; not recommended). */
|
|
55
|
+
budgetUsdMonthly: number;
|
|
56
|
+
/** Estimated USD per pod tick — drives reservation amount. */
|
|
57
|
+
budgetUsdPerRun: number;
|
|
58
|
+
/** If true, @metaharness/router routes to local first. */
|
|
59
|
+
preferLocalExecution: boolean;
|
|
60
|
+
/** POSIX cron expression for the perpetual /loop scheduler. */
|
|
61
|
+
cronSchedule: string;
|
|
62
|
+
/** Compliance audit-log projection. */
|
|
63
|
+
auditReadView: PodAuditReadView;
|
|
64
|
+
/**
|
|
65
|
+
* Reservation expiry for the atomic budget tracker — ADR-164.1 §3.2.
|
|
66
|
+
* Bounded to [5000, 300000] ms (5 s – 5 min). Default 60_000 if omitted.
|
|
67
|
+
*/
|
|
68
|
+
reservationExpiryMs?: number;
|
|
69
|
+
}
|
|
70
|
+
/**
|
|
71
|
+
* Structured validation error — carries the JSON pointer that caused it so
|
|
72
|
+
* callers can render a precise message.
|
|
73
|
+
*/
|
|
74
|
+
export declare class PodTemplateValidationError extends Error {
|
|
75
|
+
path: string;
|
|
76
|
+
constructor(message: string, path: string);
|
|
77
|
+
}
|
|
78
|
+
/**
|
|
79
|
+
* Validate `json` and return a typed `PodTemplate`. Throws
|
|
80
|
+
* `PodTemplateValidationError` with a JSON-pointer-style path on failure.
|
|
81
|
+
*
|
|
82
|
+
* Used by:
|
|
83
|
+
* - `business_pod_validate` MCP tool — returns the error verbatim
|
|
84
|
+
* - `pod-tick.mjs` — pre-flight check before any pod execution
|
|
85
|
+
* - any external schema-loader that wants typed templates
|
|
86
|
+
*/
|
|
87
|
+
export declare function validatePodTemplate(json: unknown): PodTemplate;
|
|
88
|
+
/**
|
|
89
|
+
* Known ruflo agent types — kept in sync with src/commands/agent.ts AGENT_TYPES.
|
|
90
|
+
* The list is duplicated here intentionally so pod-tick.mjs can run without
|
|
91
|
+
* importing the entire commands module.
|
|
92
|
+
*
|
|
93
|
+
* If a new agent type is added to AGENT_TYPES, mirror it here.
|
|
94
|
+
*/
|
|
95
|
+
export declare const KNOWN_AGENT_TYPES: readonly ["coder", "researcher", "tester", "reviewer", "architect", "system-architect", "coordinator", "analyst", "optimizer", "security-architect", "security-auditor", "memory-specialist", "swarm-specialist", "performance-engineer", "core-architect", "test-architect", "planner", "task-orchestrator", "perf-analyzer", "backend-dev", "api-docs", "cicd-engineer", "code-analyzer", "database-specialist", "base-template-generator"];
|
|
96
|
+
//# sourceMappingURL=pod-schema.d.ts.map
|
|
@@ -0,0 +1,225 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Pod template schema validator (ADR-164 §3.3 + ADR-164.1 §3.2).
|
|
3
|
+
*
|
|
4
|
+
* Defines the `PodTemplate` type that every business-pod JSON file under
|
|
5
|
+
* `plugins/ruflo-business-pods/templates/` MUST conform to, and a hand-rolled
|
|
6
|
+
* validator that throws structured errors on invalid templates. No external
|
|
7
|
+
* deps (no AJV, no zod) — the schema is small enough to validate by hand and
|
|
8
|
+
* doing so keeps the cli's optional-dep surface unchanged.
|
|
9
|
+
*
|
|
10
|
+
* @module @claude-flow/cli/business-pods/pod-schema
|
|
11
|
+
*/
|
|
12
|
+
/**
|
|
13
|
+
* Structured validation error — carries the JSON pointer that caused it so
|
|
14
|
+
* callers can render a precise message.
|
|
15
|
+
*/
|
|
16
|
+
export class PodTemplateValidationError extends Error {
|
|
17
|
+
path;
|
|
18
|
+
constructor(message, path) {
|
|
19
|
+
super(`pod-template at ${path}: ${message}`);
|
|
20
|
+
this.path = path;
|
|
21
|
+
this.name = 'PodTemplateValidationError';
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
const PII_POLICIES = ['soc2', 'gdpr', 'hipaa', 'permissive'];
|
|
25
|
+
function isObject(v) {
|
|
26
|
+
return typeof v === 'object' && v !== null && !Array.isArray(v);
|
|
27
|
+
}
|
|
28
|
+
function requireString(parent, key, path) {
|
|
29
|
+
const v = parent[key];
|
|
30
|
+
if (typeof v !== 'string' || v.length === 0) {
|
|
31
|
+
throw new PodTemplateValidationError(`field "${key}" must be a non-empty string`, path);
|
|
32
|
+
}
|
|
33
|
+
return v;
|
|
34
|
+
}
|
|
35
|
+
function requireNumber(parent, key, path) {
|
|
36
|
+
const v = parent[key];
|
|
37
|
+
if (typeof v !== 'number' || !Number.isFinite(v)) {
|
|
38
|
+
throw new PodTemplateValidationError(`field "${key}" must be a finite number`, path);
|
|
39
|
+
}
|
|
40
|
+
return v;
|
|
41
|
+
}
|
|
42
|
+
function requireBoolean(parent, key, path) {
|
|
43
|
+
const v = parent[key];
|
|
44
|
+
if (typeof v !== 'boolean') {
|
|
45
|
+
throw new PodTemplateValidationError(`field "${key}" must be a boolean`, path);
|
|
46
|
+
}
|
|
47
|
+
return v;
|
|
48
|
+
}
|
|
49
|
+
function requireArray(parent, key, path, itemValidator) {
|
|
50
|
+
const v = parent[key];
|
|
51
|
+
if (!Array.isArray(v)) {
|
|
52
|
+
throw new PodTemplateValidationError(`field "${key}" must be an array`, path);
|
|
53
|
+
}
|
|
54
|
+
return v.map((item, idx) => itemValidator(item, `${path}/${key}[${idx}]`));
|
|
55
|
+
}
|
|
56
|
+
function validatePodAgent(item, path) {
|
|
57
|
+
if (!isObject(item))
|
|
58
|
+
throw new PodTemplateValidationError('agent must be an object', path);
|
|
59
|
+
return {
|
|
60
|
+
role: requireString(item, 'role', path),
|
|
61
|
+
agentType: requireString(item, 'agentType', path),
|
|
62
|
+
description: requireString(item, 'description', path),
|
|
63
|
+
preferLocal: requireBoolean(item, 'preferLocal', path),
|
|
64
|
+
};
|
|
65
|
+
}
|
|
66
|
+
function validatePodBench(item, path) {
|
|
67
|
+
if (!isObject(item))
|
|
68
|
+
throw new PodTemplateValidationError('bench must be an object', path);
|
|
69
|
+
const name = requireString(item, 'name', path);
|
|
70
|
+
const description = requireString(item, 'description', path);
|
|
71
|
+
const successCriteria = requireArray(item, 'successCriteria', path, (s, sp) => {
|
|
72
|
+
if (typeof s !== 'string' || s.length === 0) {
|
|
73
|
+
throw new PodTemplateValidationError('successCriteria entries must be non-empty strings', sp);
|
|
74
|
+
}
|
|
75
|
+
return s;
|
|
76
|
+
});
|
|
77
|
+
if (successCriteria.length === 0) {
|
|
78
|
+
throw new PodTemplateValidationError('bench.successCriteria must have ≥1 entry', path);
|
|
79
|
+
}
|
|
80
|
+
const scheduleHours = requireNumber(item, 'scheduleHours', path);
|
|
81
|
+
if (scheduleHours < 1) {
|
|
82
|
+
throw new PodTemplateValidationError('bench.scheduleHours must be ≥1', path);
|
|
83
|
+
}
|
|
84
|
+
return { name, description, successCriteria, scheduleHours };
|
|
85
|
+
}
|
|
86
|
+
function validateAuditReadView(item, path) {
|
|
87
|
+
if (!isObject(item)) {
|
|
88
|
+
throw new PodTemplateValidationError('auditReadView must be an object', path);
|
|
89
|
+
}
|
|
90
|
+
const includedEventTypes = requireArray(item, 'includedEventTypes', path, (s, sp) => {
|
|
91
|
+
if (typeof s !== 'string' || s.length === 0) {
|
|
92
|
+
throw new PodTemplateValidationError('includedEventTypes entries must be non-empty strings', sp);
|
|
93
|
+
}
|
|
94
|
+
return s;
|
|
95
|
+
});
|
|
96
|
+
const retentionDays = requireNumber(item, 'retentionDays', path);
|
|
97
|
+
if (retentionDays < 1) {
|
|
98
|
+
throw new PodTemplateValidationError('auditReadView.retentionDays must be ≥1', path);
|
|
99
|
+
}
|
|
100
|
+
return { includedEventTypes, retentionDays };
|
|
101
|
+
}
|
|
102
|
+
// POSIX cron — five or six space-separated fields. Permissive on field
|
|
103
|
+
// contents (digits, *, -, /, ,) — actual cron evaluation happens at schedule
|
|
104
|
+
// time. We only catch obviously malformed values here.
|
|
105
|
+
const CRON_RE = /^([\d*/,\-]+\s+){4,5}[\d*/,\-]+$/;
|
|
106
|
+
/**
|
|
107
|
+
* Validate `json` and return a typed `PodTemplate`. Throws
|
|
108
|
+
* `PodTemplateValidationError` with a JSON-pointer-style path on failure.
|
|
109
|
+
*
|
|
110
|
+
* Used by:
|
|
111
|
+
* - `business_pod_validate` MCP tool — returns the error verbatim
|
|
112
|
+
* - `pod-tick.mjs` — pre-flight check before any pod execution
|
|
113
|
+
* - any external schema-loader that wants typed templates
|
|
114
|
+
*/
|
|
115
|
+
export function validatePodTemplate(json) {
|
|
116
|
+
if (!isObject(json)) {
|
|
117
|
+
throw new PodTemplateValidationError('pod-template must be a JSON object', '/');
|
|
118
|
+
}
|
|
119
|
+
const name = requireString(json, 'name', '/');
|
|
120
|
+
if (!/^[a-z][a-z0-9-]*$/.test(name)) {
|
|
121
|
+
throw new PodTemplateValidationError('name must be lowercase-kebab (e.g. "sales")', '/');
|
|
122
|
+
}
|
|
123
|
+
const displayName = requireString(json, 'displayName', '/');
|
|
124
|
+
const roomId = requireString(json, 'roomId', '/');
|
|
125
|
+
if (!/^[A-Za-z0-9_.\-:/@#]+$/.test(roomId)) {
|
|
126
|
+
throw new PodTemplateValidationError('roomId may only contain [A-Za-z0-9_.\\-:/@#]', '/');
|
|
127
|
+
}
|
|
128
|
+
const agents = requireArray(json, 'agents', '/', validatePodAgent);
|
|
129
|
+
if (agents.length === 0) {
|
|
130
|
+
throw new PodTemplateValidationError('agents must have ≥1 entry', '/');
|
|
131
|
+
}
|
|
132
|
+
const allowedMcpTools = requireArray(json, 'allowedMcpTools', '/', (t, tp) => {
|
|
133
|
+
if (typeof t !== 'string' || t.length === 0) {
|
|
134
|
+
throw new PodTemplateValidationError('allowedMcpTools entries must be non-empty strings', tp);
|
|
135
|
+
}
|
|
136
|
+
return t;
|
|
137
|
+
});
|
|
138
|
+
if (allowedMcpTools.length === 0) {
|
|
139
|
+
throw new PodTemplateValidationError('allowedMcpTools must have ≥1 entry', '/');
|
|
140
|
+
}
|
|
141
|
+
const bench = validatePodBench(json.bench, '/bench');
|
|
142
|
+
const piiPolicy = requireString(json, 'piiPolicy', '/');
|
|
143
|
+
if (!PII_POLICIES.includes(piiPolicy)) {
|
|
144
|
+
throw new PodTemplateValidationError(`piiPolicy must be one of: ${PII_POLICIES.join(', ')}`, '/');
|
|
145
|
+
}
|
|
146
|
+
const budgetUsdMonthly = requireNumber(json, 'budgetUsdMonthly', '/');
|
|
147
|
+
if (budgetUsdMonthly < 0) {
|
|
148
|
+
throw new PodTemplateValidationError('budgetUsdMonthly must be ≥0', '/');
|
|
149
|
+
}
|
|
150
|
+
const budgetUsdPerRun = requireNumber(json, 'budgetUsdPerRun', '/');
|
|
151
|
+
if (budgetUsdPerRun < 0) {
|
|
152
|
+
throw new PodTemplateValidationError('budgetUsdPerRun must be ≥0', '/');
|
|
153
|
+
}
|
|
154
|
+
if (budgetUsdMonthly > 0 && budgetUsdPerRun > budgetUsdMonthly) {
|
|
155
|
+
throw new PodTemplateValidationError('budgetUsdPerRun must not exceed budgetUsdMonthly', '/');
|
|
156
|
+
}
|
|
157
|
+
const preferLocalExecution = requireBoolean(json, 'preferLocalExecution', '/');
|
|
158
|
+
const cronSchedule = requireString(json, 'cronSchedule', '/');
|
|
159
|
+
if (!CRON_RE.test(cronSchedule)) {
|
|
160
|
+
throw new PodTemplateValidationError('cronSchedule must be a POSIX cron expression (5 or 6 fields)', '/');
|
|
161
|
+
}
|
|
162
|
+
const auditReadView = validateAuditReadView(json.auditReadView, '/auditReadView');
|
|
163
|
+
let reservationExpiryMs;
|
|
164
|
+
if (json.reservationExpiryMs !== undefined) {
|
|
165
|
+
const v = requireNumber(json, 'reservationExpiryMs', '/');
|
|
166
|
+
// ADR-164.1 §3.2 — bounded to [5_000, 300_000] ms.
|
|
167
|
+
if (v < 5_000 || v > 300_000) {
|
|
168
|
+
throw new PodTemplateValidationError('reservationExpiryMs must be within [5000, 300000] ms (ADR-164.1 §3.2)', '/');
|
|
169
|
+
}
|
|
170
|
+
reservationExpiryMs = v;
|
|
171
|
+
}
|
|
172
|
+
return {
|
|
173
|
+
name,
|
|
174
|
+
displayName,
|
|
175
|
+
roomId,
|
|
176
|
+
agents,
|
|
177
|
+
allowedMcpTools,
|
|
178
|
+
bench,
|
|
179
|
+
piiPolicy: piiPolicy,
|
|
180
|
+
budgetUsdMonthly,
|
|
181
|
+
budgetUsdPerRun,
|
|
182
|
+
preferLocalExecution,
|
|
183
|
+
cronSchedule,
|
|
184
|
+
auditReadView,
|
|
185
|
+
reservationExpiryMs,
|
|
186
|
+
};
|
|
187
|
+
}
|
|
188
|
+
/**
|
|
189
|
+
* Known ruflo agent types — kept in sync with src/commands/agent.ts AGENT_TYPES.
|
|
190
|
+
* The list is duplicated here intentionally so pod-tick.mjs can run without
|
|
191
|
+
* importing the entire commands module.
|
|
192
|
+
*
|
|
193
|
+
* If a new agent type is added to AGENT_TYPES, mirror it here.
|
|
194
|
+
*/
|
|
195
|
+
export const KNOWN_AGENT_TYPES = [
|
|
196
|
+
'coder',
|
|
197
|
+
'researcher',
|
|
198
|
+
'tester',
|
|
199
|
+
'reviewer',
|
|
200
|
+
'architect',
|
|
201
|
+
'system-architect',
|
|
202
|
+
'coordinator',
|
|
203
|
+
'analyst',
|
|
204
|
+
'optimizer',
|
|
205
|
+
'security-architect',
|
|
206
|
+
'security-auditor',
|
|
207
|
+
'memory-specialist',
|
|
208
|
+
'swarm-specialist',
|
|
209
|
+
'performance-engineer',
|
|
210
|
+
'core-architect',
|
|
211
|
+
'test-architect',
|
|
212
|
+
'planner',
|
|
213
|
+
'task-orchestrator',
|
|
214
|
+
'perf-analyzer',
|
|
215
|
+
'backend-dev',
|
|
216
|
+
'api-docs',
|
|
217
|
+
'cicd-engineer',
|
|
218
|
+
'code-analyzer',
|
|
219
|
+
'database-specialist',
|
|
220
|
+
// ADR-164 Phase 3 — added for the marketing/hr pods (content drafting +
|
|
221
|
+
// onboarding-template generation). Mirror this addition in the JS copy
|
|
222
|
+
// inside plugins/ruflo-business-pods/scripts/pod-tick.mjs.
|
|
223
|
+
'base-template-generator',
|
|
224
|
+
];
|
|
225
|
+
//# sourceMappingURL=pod-schema.js.map
|
|
@@ -50,6 +50,15 @@ import { metaharnessTools } from './mcp-tools/metaharness-tools.js';
|
|
|
50
50
|
// agenticow@~0.2.3 — Copy-On-Write memory branching tools (162-byte branches);
|
|
51
51
|
// optional runtime dep, every handler returns `{degraded: true}` when missing.
|
|
52
52
|
import { agenticowTools } from './mcp-tools/agenticow-tools.js';
|
|
53
|
+
// ADR-164 — AgentBBS federated business-domain BBS rooms (Phase 1).
|
|
54
|
+
// Optional runtime dep, every handler returns `{degraded: true}` when missing.
|
|
55
|
+
import { agentbbsTools } from './mcp-tools/agentbbs-tools.js';
|
|
56
|
+
// ADR-164 Phase 2 — Business-pod template validation (pure local, no optional deps).
|
|
57
|
+
import { businessPodTools } from './mcp-tools/business-pod-tools.js';
|
|
58
|
+
// ADR-164 Phase 4 §5.1.8 — http_fetch MCP tool (secure-by-default HTTP probe
|
|
59
|
+
// for ops-pod synthetic-endpoint benches). Default-rejects private addresses
|
|
60
|
+
// + auth headers; opt-in via CLAUDE_FLOW_HTTP_FETCH_ALLOW_PRIVATE / _AUTH=1.
|
|
61
|
+
import { httpFetchTools } from './mcp-tools/http-fetch-tools.js';
|
|
53
62
|
// #1916: coverage-aware routing tools — defined in ruvector/coverage-tools.ts
|
|
54
63
|
// but were never registered, so the `ruflo hooks coverage-*` CLI subcommands
|
|
55
64
|
// failed with `Tool not found: hooks_coverage-route`.
|
|
@@ -132,6 +141,13 @@ registerTools([
|
|
|
132
141
|
...metaharnessTools,
|
|
133
142
|
// agenticow@~0.2.3 — COW memory branching (4 tools, graceful-degraded when missing)
|
|
134
143
|
...agenticowTools,
|
|
144
|
+
// ADR-164 — AgentBBS federated business-domain BBS rooms (4 tools, Phase 1, graceful-degraded)
|
|
145
|
+
...agentbbsTools,
|
|
146
|
+
// ADR-164 Phase 2 + Phase 3 — business_pod_validate + business_pod_route_backend
|
|
147
|
+
// (2 tools, no optional dep — schema validator + §3.4 domain-affinity router)
|
|
148
|
+
...businessPodTools,
|
|
149
|
+
// ADR-164 Phase 4 §5.1.8 — http_fetch (1 tool, secure-by-default HTTP probe)
|
|
150
|
+
...httpFetchTools,
|
|
135
151
|
]);
|
|
136
152
|
/**
|
|
137
153
|
* MCP Client Error
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* AgentBBS MCP Tools — Federated business-domain BBS room surface (ADR-164 Phase 1).
|
|
3
|
+
*
|
|
4
|
+
* Exposes the `agentbbs@~0.1.0` (a sibling BBS-style federation peer by the same
|
|
5
|
+
* author as ruflo) as MCP tools so ruflo agents can register business rooms
|
|
6
|
+
* (#sales, #finance, #marketing, ...), publish/watch typed envelopes, and
|
|
7
|
+
* mint single-use human-join tokens for SSH/web cockpit access.
|
|
8
|
+
*
|
|
9
|
+
* Motivation:
|
|
10
|
+
* ADR-164 wires the "business autopilot" cockpit on top of the existing
|
|
11
|
+
* ruflo federation primitives (FederationEnvelope, PII pipeline, budget
|
|
12
|
+
* circuit breaker). The 4 tools here are the ruflo-side handles into the
|
|
13
|
+
* agentbbs Rust workspace (`crates/agentbbs-federation/` and
|
|
14
|
+
* `crates/agentbbs-mcp/`) that already implement Ed25519-signed envelopes
|
|
15
|
+
* and an MCP transport. Phase 1 ships the surface; Phases 2-5 wire deeper.
|
|
16
|
+
*
|
|
17
|
+
* Architectural constraint (mirrors metaharness-tools.ts / agenticow-tools.ts):
|
|
18
|
+
* - `agentbbs` lives in `optionalDependencies` — must NOT be a hard runtime dep
|
|
19
|
+
* - When the package is missing, every tool returns
|
|
20
|
+
* `{success: true, degraded: true, reason: 'agentbbs-not-found'}`
|
|
21
|
+
* so callers see one contract regardless of install state
|
|
22
|
+
* - Phase 1: polling-based watch (streaming subscriptions are Phase 4)
|
|
23
|
+
*
|
|
24
|
+
* @module @claude-flow/cli/mcp-tools/agentbbs
|
|
25
|
+
*/
|
|
26
|
+
import type { MCPTool } from './types.js';
|
|
27
|
+
export declare const agentbbsTools: MCPTool[];
|
|
28
|
+
//# sourceMappingURL=agentbbs-tools.d.ts.map
|