@suveren/gateway 0.19.5 → 0.20.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/content/integrations/crm.json +1 -1
- package/content/integrations/deploy-github.json +1 -1
- package/content/integrations/erp.json +1 -1
- package/content/integrations/mail.json +1 -1
- package/content/integrations/records.json +1 -1
- package/dist/control-plane/index.mjs +21 -13
- package/dist/mcp-server/{chunk-ZRRZFGRL.mjs → chunk-APIQIEUA.mjs} +39 -27
- package/dist/mcp-server/http.mjs +308 -97
- package/dist/mcp-server/report-verify-cli.mjs +1 -1
- package/dist/ui/assets/index-1gCMlbLl.js +116 -0
- package/dist/ui/index.html +1 -1
- package/node_modules/@hap/core/README.md +92 -29
- package/node_modules/@hap/core/dist/index.d.mts +614 -593
- package/node_modules/@hap/core/dist/index.d.ts +614 -593
- package/node_modules/@hap/core/dist/index.js +774 -749
- package/node_modules/@hap/core/dist/index.mjs +744 -724
- package/node_modules/@hap/core/package.json +1 -1
- package/node_modules/@hap/core/src/base64url.ts +39 -0
- package/node_modules/@hap/core/src/commitment-modes.ts +0 -21
- package/node_modules/@hap/core/src/errors.ts +76 -0
- package/node_modules/@hap/core/src/frame.ts +47 -178
- package/node_modules/@hap/core/src/gatekeeper.ts +219 -600
- package/node_modules/@hap/core/src/identity.ts +9 -12
- package/node_modules/@hap/core/src/index.ts +8 -4
- package/node_modules/@hap/core/src/mandate.ts +177 -166
- package/node_modules/@hap/core/src/owner-signature.ts +282 -0
- package/node_modules/@hap/core/src/profile.ts +234 -0
- package/node_modules/@hap/core/src/ticket.ts +148 -0
- package/node_modules/@hap/core/src/types.ts +191 -344
- package/node_modules/@hap/core/src/versions.ts +47 -0
- package/package.json +2 -2
- package/profiles/calendar/0.6.profile.json +191 -0
- package/profiles/charge/0.6.profile.json +211 -0
- package/profiles/customers/0.9.profile.json +182 -0
- package/profiles/delegation/0.3.profile.json +118 -0
- package/profiles/deploy/0.11.profile.json +177 -0
- package/profiles/email/0.8.profile.json +226 -0
- package/profiles/index.json +12 -1
- package/profiles/publish/0.6.profile.json +187 -0
- package/profiles/purchase/0.7.profile.json +235 -0
- package/profiles/records/0.6.profile.json +118 -0
- package/profiles/reporting/0.3.profile.json +98 -0
- package/profiles/sales/0.4.profile.json +291 -0
- package/dist/ui/assets/index-Du68zJhH.js +0 -116
- package/node_modules/@hap/core/src/attestation.ts +0 -173
- package/node_modules/@hap/core/src/receipt.ts +0 -74
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Version negotiation — protocol.md → *Version negotiation (v0.7)*.
|
|
3
|
+
*
|
|
4
|
+
* "Gatekeepers and Authority Servers MUST reject unknown or untrusted
|
|
5
|
+
* versions" is a safety rule, not a transition plan; this module is the
|
|
6
|
+
* transition plan. A mandate request carries `supported_versions`; the AS
|
|
7
|
+
* issues at the highest version both sides support, or refuses with
|
|
8
|
+
* `VERSION_UNSUPPORTED` where there is none. A request without the field is
|
|
9
|
+
* read as `["0.6"]` (rule 1) — but this package issues and verifies `0.7`
|
|
10
|
+
* only (CLAUDE.md "Decided by the owner": no backward verify path), so that
|
|
11
|
+
* default exists to make the refusal message honest, not to accept the
|
|
12
|
+
* mandate.
|
|
13
|
+
*/
|
|
14
|
+
import { HapError } from './errors';
|
|
15
|
+
|
|
16
|
+
/** The protocol version this package issues and verifies. */
|
|
17
|
+
export const PROTOCOL_VERSION = '0.7';
|
|
18
|
+
|
|
19
|
+
/** The protocol versions this package can verify and enforce. */
|
|
20
|
+
export const SUPPORTED_VERSIONS: readonly string[] = ['0.7'];
|
|
21
|
+
|
|
22
|
+
/**
|
|
23
|
+
* The highest version both the requester and this implementation support.
|
|
24
|
+
*
|
|
25
|
+
* @param requested `supported_versions` from the mandate request. Absent →
|
|
26
|
+
* read as `["0.6"]` (protocol.md rule 1) — which, against this package's
|
|
27
|
+
* `SUPPORTED_VERSIONS`, has no overlap and refuses honestly rather than
|
|
28
|
+
* silently assuming `0.7`.
|
|
29
|
+
* @throws HapError `VERSION_UNSUPPORTED` when no version is common to both.
|
|
30
|
+
*/
|
|
31
|
+
export function negotiateVersion(
|
|
32
|
+
requested: readonly string[] | undefined,
|
|
33
|
+
supported: readonly string[] = SUPPORTED_VERSIONS,
|
|
34
|
+
): string {
|
|
35
|
+
const requestedVersions = requested ?? ['0.6'];
|
|
36
|
+
// Highest-first so a requester offering several supported versions gets the
|
|
37
|
+
// newest one both sides agree on, not merely the first common element.
|
|
38
|
+
const common = supported.filter((v) => requestedVersions.includes(v)).sort().reverse();
|
|
39
|
+
if (common.length === 0) {
|
|
40
|
+
throw new HapError(
|
|
41
|
+
'VERSION_UNSUPPORTED',
|
|
42
|
+
`no protocol version in [${requestedVersions.join(', ')}] is supported by this implementation ` +
|
|
43
|
+
`(supports [${supported.join(', ')}])`,
|
|
44
|
+
);
|
|
45
|
+
}
|
|
46
|
+
return common[0];
|
|
47
|
+
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@suveren/gateway",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.20.0",
|
|
4
4
|
"description": "Suveren gateway — local agent gateway built in compliance with the Human Agency Protocol (HAP). Runs the UI, control plane, and MCP server in one Node process.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "server.js",
|
|
@@ -24,7 +24,7 @@
|
|
|
24
24
|
"node": ">=22"
|
|
25
25
|
},
|
|
26
26
|
"dependencies": {
|
|
27
|
-
"@hap/core": "npm:@humanagencyp/hap-core@^0.
|
|
27
|
+
"@hap/core": "npm:@humanagencyp/hap-core@^0.12.0",
|
|
28
28
|
"@hpke/core": "^1.9.0",
|
|
29
29
|
"express": "^4.22.3",
|
|
30
30
|
"http-proxy-middleware": "^3.0.7",
|
|
@@ -0,0 +1,191 @@
|
|
|
1
|
+
{
|
|
2
|
+
"id": "github.com/humanagencyprotocol/hap-profiles/calendar@0.6",
|
|
3
|
+
"name": "Calendar",
|
|
4
|
+
"version": "0.6",
|
|
5
|
+
"description": "Calendar authority — governs calendar access: reading, drafting, and booking events",
|
|
6
|
+
"whatsNew": "Protocol v0.7 wording: the scope schema replaces the context schema, and the required gate is the Mandate Owner. Limits and scope are unchanged.",
|
|
7
|
+
"boundsSchema": {
|
|
8
|
+
"actionTypes": [
|
|
9
|
+
"booking",
|
|
10
|
+
"delete"
|
|
11
|
+
],
|
|
12
|
+
"keyOrder": [
|
|
13
|
+
"profile",
|
|
14
|
+
"booking_daily_max",
|
|
15
|
+
"booking_duration_max",
|
|
16
|
+
"lookahead_days_max"
|
|
17
|
+
],
|
|
18
|
+
"fields": {
|
|
19
|
+
"profile": {
|
|
20
|
+
"type": "string",
|
|
21
|
+
"required": true
|
|
22
|
+
},
|
|
23
|
+
"booking_daily_max": {
|
|
24
|
+
"type": "number",
|
|
25
|
+
"required": true,
|
|
26
|
+
"displayName": "Daily booking limit",
|
|
27
|
+
"description": "Maximum new events booked per day",
|
|
28
|
+
"unit": "count",
|
|
29
|
+
"boundType": {
|
|
30
|
+
"kind": "cumulative_count",
|
|
31
|
+
"window": "daily"
|
|
32
|
+
},
|
|
33
|
+
"appliesTo": [
|
|
34
|
+
"booking"
|
|
35
|
+
]
|
|
36
|
+
},
|
|
37
|
+
"booking_duration_max": {
|
|
38
|
+
"type": "number",
|
|
39
|
+
"required": true,
|
|
40
|
+
"displayName": "Max event duration",
|
|
41
|
+
"description": "Maximum duration of a single event",
|
|
42
|
+
"unit": "minutes",
|
|
43
|
+
"boundType": {
|
|
44
|
+
"kind": "per_transaction",
|
|
45
|
+
"of": "duration"
|
|
46
|
+
}
|
|
47
|
+
},
|
|
48
|
+
"lookahead_days_max": {
|
|
49
|
+
"type": "number",
|
|
50
|
+
"required": true,
|
|
51
|
+
"displayName": "Max lookahead",
|
|
52
|
+
"description": "Maximum number of days into the future an event can be booked",
|
|
53
|
+
"unit": "days",
|
|
54
|
+
"boundType": {
|
|
55
|
+
"kind": "per_transaction",
|
|
56
|
+
"of": "lookahead"
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
},
|
|
61
|
+
"scopeSchema": {
|
|
62
|
+
"keyOrder": [
|
|
63
|
+
"allowed_calendars",
|
|
64
|
+
"allowed_attendees",
|
|
65
|
+
"allowed_domains"
|
|
66
|
+
],
|
|
67
|
+
"fields": {
|
|
68
|
+
"allowed_calendars": {
|
|
69
|
+
"type": "string",
|
|
70
|
+
"required": false,
|
|
71
|
+
"displayName": "Allowed calendars",
|
|
72
|
+
"description": "Comma-separated list of calendar names the agent may access",
|
|
73
|
+
"constraint": {
|
|
74
|
+
"type": "string",
|
|
75
|
+
"enforceable": [
|
|
76
|
+
"subset"
|
|
77
|
+
]
|
|
78
|
+
}
|
|
79
|
+
},
|
|
80
|
+
"allowed_attendees": {
|
|
81
|
+
"type": "string",
|
|
82
|
+
"required": false,
|
|
83
|
+
"displayName": "Allowed attendees",
|
|
84
|
+
"format": "email",
|
|
85
|
+
"description": "Comma-separated list of allowed attendee email addresses",
|
|
86
|
+
"constraint": {
|
|
87
|
+
"type": "string",
|
|
88
|
+
"enforceable": [
|
|
89
|
+
"subset"
|
|
90
|
+
]
|
|
91
|
+
}
|
|
92
|
+
},
|
|
93
|
+
"allowed_domains": {
|
|
94
|
+
"type": "string",
|
|
95
|
+
"required": false,
|
|
96
|
+
"displayName": "Allowed domains",
|
|
97
|
+
"format": "domain",
|
|
98
|
+
"description": "Comma-separated list of allowed attendee domains (e.g. acme.com,partner.org)",
|
|
99
|
+
"constraint": {
|
|
100
|
+
"type": "string",
|
|
101
|
+
"enforceable": [
|
|
102
|
+
"subset"
|
|
103
|
+
]
|
|
104
|
+
}
|
|
105
|
+
}
|
|
106
|
+
}
|
|
107
|
+
},
|
|
108
|
+
"executionContextSchema": {
|
|
109
|
+
"fields": {
|
|
110
|
+
"duration": {
|
|
111
|
+
"source": "declared",
|
|
112
|
+
"description": "Duration of the event in minutes",
|
|
113
|
+
"required": true,
|
|
114
|
+
"constraint": {
|
|
115
|
+
"type": "number",
|
|
116
|
+
"enforceable": [
|
|
117
|
+
"max"
|
|
118
|
+
]
|
|
119
|
+
}
|
|
120
|
+
},
|
|
121
|
+
"lookahead": {
|
|
122
|
+
"source": "declared",
|
|
123
|
+
"description": "Days from now the event is scheduled",
|
|
124
|
+
"required": true,
|
|
125
|
+
"constraint": {
|
|
126
|
+
"type": "number",
|
|
127
|
+
"enforceable": [
|
|
128
|
+
"max"
|
|
129
|
+
]
|
|
130
|
+
}
|
|
131
|
+
},
|
|
132
|
+
"allowed_calendars": {
|
|
133
|
+
"source": "declared",
|
|
134
|
+
"description": "Calendar being used (checked against authorized calendars)",
|
|
135
|
+
"required": false,
|
|
136
|
+
"constraint": {
|
|
137
|
+
"type": "string",
|
|
138
|
+
"enforceable": [
|
|
139
|
+
"subset"
|
|
140
|
+
]
|
|
141
|
+
}
|
|
142
|
+
},
|
|
143
|
+
"allowed_attendees": {
|
|
144
|
+
"source": "declared",
|
|
145
|
+
"description": "Attendee addresses from this event (checked against authorized attendees)",
|
|
146
|
+
"required": false,
|
|
147
|
+
"constraint": {
|
|
148
|
+
"type": "string",
|
|
149
|
+
"enforceable": [
|
|
150
|
+
"subset"
|
|
151
|
+
]
|
|
152
|
+
}
|
|
153
|
+
},
|
|
154
|
+
"allowed_domains": {
|
|
155
|
+
"source": "declared",
|
|
156
|
+
"description": "Unique attendee domains from this event (checked against authorized domains)",
|
|
157
|
+
"required": false,
|
|
158
|
+
"constraint": {
|
|
159
|
+
"type": "string",
|
|
160
|
+
"enforceable": [
|
|
161
|
+
"subset"
|
|
162
|
+
]
|
|
163
|
+
}
|
|
164
|
+
},
|
|
165
|
+
"booking_count_daily": {
|
|
166
|
+
"source": "cumulative",
|
|
167
|
+
"cumulativeField": "_count",
|
|
168
|
+
"window": "daily",
|
|
169
|
+
"description": "Running daily booking count (resolved from execution log)",
|
|
170
|
+
"required": true,
|
|
171
|
+
"constraint": {
|
|
172
|
+
"type": "number",
|
|
173
|
+
"enforceable": [
|
|
174
|
+
"max"
|
|
175
|
+
]
|
|
176
|
+
}
|
|
177
|
+
}
|
|
178
|
+
}
|
|
179
|
+
},
|
|
180
|
+
"requiredGates": [
|
|
181
|
+
"bounds",
|
|
182
|
+
"intent",
|
|
183
|
+
"commitment",
|
|
184
|
+
"mandate_owner"
|
|
185
|
+
],
|
|
186
|
+
"ttl": {
|
|
187
|
+
"default": 86400,
|
|
188
|
+
"max": 31536000
|
|
189
|
+
},
|
|
190
|
+
"retention_minimum": 7776000
|
|
191
|
+
}
|
|
@@ -0,0 +1,211 @@
|
|
|
1
|
+
{
|
|
2
|
+
"id": "github.com/humanagencyprotocol/hap-profiles/charge@0.6",
|
|
3
|
+
"name": "Charge",
|
|
4
|
+
"version": "0.6",
|
|
5
|
+
"description": "Charge authority — governs charging customers: payments, refunds, subscriptions",
|
|
6
|
+
"whatsNew": "Protocol v0.7 wording: the scope schema replaces the context schema, and the required gate is the Mandate Owner. Limits and scope are unchanged.",
|
|
7
|
+
"boundsSchema": {
|
|
8
|
+
"actionTypes": [
|
|
9
|
+
"charge",
|
|
10
|
+
"subscribe",
|
|
11
|
+
"unclassified"
|
|
12
|
+
],
|
|
13
|
+
"keyOrder": [
|
|
14
|
+
"profile",
|
|
15
|
+
"amount_max",
|
|
16
|
+
"amount_daily_max",
|
|
17
|
+
"amount_monthly_max",
|
|
18
|
+
"transaction_count_daily_max"
|
|
19
|
+
],
|
|
20
|
+
"fields": {
|
|
21
|
+
"profile": {
|
|
22
|
+
"type": "string",
|
|
23
|
+
"required": true
|
|
24
|
+
},
|
|
25
|
+
"amount_max": {
|
|
26
|
+
"type": "number",
|
|
27
|
+
"required": true,
|
|
28
|
+
"displayName": "Max per transaction",
|
|
29
|
+
"description": "Maximum monetary amount per transaction in currency units",
|
|
30
|
+
"unit": "currency:EUR",
|
|
31
|
+
"boundType": {
|
|
32
|
+
"kind": "per_transaction",
|
|
33
|
+
"of": "amount"
|
|
34
|
+
}
|
|
35
|
+
},
|
|
36
|
+
"amount_daily_max": {
|
|
37
|
+
"type": "number",
|
|
38
|
+
"required": true,
|
|
39
|
+
"displayName": "Daily charge limit",
|
|
40
|
+
"description": "Maximum cumulative charges per day in currency units",
|
|
41
|
+
"unit": "currency:EUR",
|
|
42
|
+
"boundType": {
|
|
43
|
+
"kind": "cumulative_sum",
|
|
44
|
+
"of": "amount",
|
|
45
|
+
"window": "daily"
|
|
46
|
+
}
|
|
47
|
+
},
|
|
48
|
+
"amount_monthly_max": {
|
|
49
|
+
"type": "number",
|
|
50
|
+
"required": true,
|
|
51
|
+
"displayName": "Monthly charge limit",
|
|
52
|
+
"description": "Maximum cumulative charges per month in currency units",
|
|
53
|
+
"unit": "currency:EUR",
|
|
54
|
+
"boundType": {
|
|
55
|
+
"kind": "cumulative_sum",
|
|
56
|
+
"of": "amount",
|
|
57
|
+
"window": "monthly"
|
|
58
|
+
}
|
|
59
|
+
},
|
|
60
|
+
"transaction_count_daily_max": {
|
|
61
|
+
"type": "number",
|
|
62
|
+
"required": true,
|
|
63
|
+
"displayName": "Daily transaction limit",
|
|
64
|
+
"description": "Maximum number of transactions per day",
|
|
65
|
+
"unit": "count",
|
|
66
|
+
"boundType": {
|
|
67
|
+
"kind": "cumulative_count",
|
|
68
|
+
"window": "daily"
|
|
69
|
+
},
|
|
70
|
+
"appliesTo": [
|
|
71
|
+
"charge",
|
|
72
|
+
"subscribe",
|
|
73
|
+
"unclassified"
|
|
74
|
+
]
|
|
75
|
+
}
|
|
76
|
+
}
|
|
77
|
+
},
|
|
78
|
+
"scopeSchema": {
|
|
79
|
+
"keyOrder": [
|
|
80
|
+
"currency",
|
|
81
|
+
"action_type"
|
|
82
|
+
],
|
|
83
|
+
"fields": {
|
|
84
|
+
"currency": {
|
|
85
|
+
"type": "string",
|
|
86
|
+
"required": true,
|
|
87
|
+
"displayName": "Currency",
|
|
88
|
+
"description": "Permitted currency code",
|
|
89
|
+
"constraint": {
|
|
90
|
+
"type": "string",
|
|
91
|
+
"enforceable": [
|
|
92
|
+
"enum"
|
|
93
|
+
]
|
|
94
|
+
},
|
|
95
|
+
"enum": [
|
|
96
|
+
"USD",
|
|
97
|
+
"EUR",
|
|
98
|
+
"GBP",
|
|
99
|
+
"CHF",
|
|
100
|
+
"JPY",
|
|
101
|
+
"CAD",
|
|
102
|
+
"AUD"
|
|
103
|
+
]
|
|
104
|
+
},
|
|
105
|
+
"action_type": {
|
|
106
|
+
"type": "string",
|
|
107
|
+
"required": true,
|
|
108
|
+
"displayName": "Action type",
|
|
109
|
+
"description": "Authorized financial operation",
|
|
110
|
+
"constraint": {
|
|
111
|
+
"type": "string",
|
|
112
|
+
"enforceable": [
|
|
113
|
+
"enum"
|
|
114
|
+
]
|
|
115
|
+
},
|
|
116
|
+
"enum": [
|
|
117
|
+
"charge",
|
|
118
|
+
"refund",
|
|
119
|
+
"subscribe"
|
|
120
|
+
]
|
|
121
|
+
}
|
|
122
|
+
}
|
|
123
|
+
},
|
|
124
|
+
"executionContextSchema": {
|
|
125
|
+
"fields": {
|
|
126
|
+
"action_type": {
|
|
127
|
+
"source": "declared",
|
|
128
|
+
"description": "Financial operation being performed",
|
|
129
|
+
"required": true,
|
|
130
|
+
"constraint": {
|
|
131
|
+
"type": "string",
|
|
132
|
+
"enforceable": [
|
|
133
|
+
"enum"
|
|
134
|
+
]
|
|
135
|
+
}
|
|
136
|
+
},
|
|
137
|
+
"amount": {
|
|
138
|
+
"source": "declared",
|
|
139
|
+
"description": "Monetary amount in currency units",
|
|
140
|
+
"required": true,
|
|
141
|
+
"constraint": {
|
|
142
|
+
"type": "number",
|
|
143
|
+
"enforceable": [
|
|
144
|
+
"max"
|
|
145
|
+
]
|
|
146
|
+
}
|
|
147
|
+
},
|
|
148
|
+
"currency": {
|
|
149
|
+
"source": "declared",
|
|
150
|
+
"description": "Currency code",
|
|
151
|
+
"required": true,
|
|
152
|
+
"constraint": {
|
|
153
|
+
"type": "string",
|
|
154
|
+
"enforceable": [
|
|
155
|
+
"enum"
|
|
156
|
+
]
|
|
157
|
+
}
|
|
158
|
+
},
|
|
159
|
+
"amount_daily": {
|
|
160
|
+
"source": "cumulative",
|
|
161
|
+
"cumulativeField": "amount",
|
|
162
|
+
"window": "daily",
|
|
163
|
+
"description": "Running daily charge total (resolved from execution log)",
|
|
164
|
+
"required": true,
|
|
165
|
+
"constraint": {
|
|
166
|
+
"type": "number",
|
|
167
|
+
"enforceable": [
|
|
168
|
+
"max"
|
|
169
|
+
]
|
|
170
|
+
}
|
|
171
|
+
},
|
|
172
|
+
"amount_monthly": {
|
|
173
|
+
"source": "cumulative",
|
|
174
|
+
"cumulativeField": "amount",
|
|
175
|
+
"window": "monthly",
|
|
176
|
+
"description": "Running monthly charge total (resolved from execution log)",
|
|
177
|
+
"required": true,
|
|
178
|
+
"constraint": {
|
|
179
|
+
"type": "number",
|
|
180
|
+
"enforceable": [
|
|
181
|
+
"max"
|
|
182
|
+
]
|
|
183
|
+
}
|
|
184
|
+
},
|
|
185
|
+
"transaction_count_daily": {
|
|
186
|
+
"source": "cumulative",
|
|
187
|
+
"cumulativeField": "_count",
|
|
188
|
+
"window": "daily",
|
|
189
|
+
"description": "Running daily transaction count (resolved from execution log)",
|
|
190
|
+
"required": true,
|
|
191
|
+
"constraint": {
|
|
192
|
+
"type": "number",
|
|
193
|
+
"enforceable": [
|
|
194
|
+
"max"
|
|
195
|
+
]
|
|
196
|
+
}
|
|
197
|
+
}
|
|
198
|
+
}
|
|
199
|
+
},
|
|
200
|
+
"requiredGates": [
|
|
201
|
+
"bounds",
|
|
202
|
+
"intent",
|
|
203
|
+
"commitment",
|
|
204
|
+
"mandate_owner"
|
|
205
|
+
],
|
|
206
|
+
"ttl": {
|
|
207
|
+
"default": 86400,
|
|
208
|
+
"max": 2592000
|
|
209
|
+
},
|
|
210
|
+
"retention_minimum": 7776000
|
|
211
|
+
}
|
|
@@ -0,0 +1,182 @@
|
|
|
1
|
+
{
|
|
2
|
+
"id": "github.com/humanagencyprotocol/hap-profiles/customers@0.9",
|
|
3
|
+
"name": "Customer Management",
|
|
4
|
+
"version": "0.9",
|
|
5
|
+
"description": "Customer authority — governs CRM operations: contacts, activities, deals, tasks",
|
|
6
|
+
"whatsNew": "Protocol v0.7 wording: the scope schema replaces the context schema, and the required gate is the Mandate Owner. Limits and scope are unchanged.",
|
|
7
|
+
"boundsSchema": {
|
|
8
|
+
"actionTypes": [
|
|
9
|
+
"delete",
|
|
10
|
+
"write",
|
|
11
|
+
"setup"
|
|
12
|
+
],
|
|
13
|
+
"keyOrder": [
|
|
14
|
+
"profile",
|
|
15
|
+
"read_access",
|
|
16
|
+
"export_access",
|
|
17
|
+
"write_daily_max",
|
|
18
|
+
"delete_daily_max",
|
|
19
|
+
"setup_daily_max"
|
|
20
|
+
],
|
|
21
|
+
"fields": {
|
|
22
|
+
"profile": {
|
|
23
|
+
"type": "string",
|
|
24
|
+
"required": true
|
|
25
|
+
},
|
|
26
|
+
"read_access": {
|
|
27
|
+
"type": "string",
|
|
28
|
+
"required": true,
|
|
29
|
+
"displayName": "Read access",
|
|
30
|
+
"description": "Allow the agent to browse contacts, timelines, pipeline and tasks. Bulk export is governed separately by Export access.",
|
|
31
|
+
"boundType": {
|
|
32
|
+
"kind": "enum",
|
|
33
|
+
"values": [
|
|
34
|
+
"unlimited",
|
|
35
|
+
"none"
|
|
36
|
+
]
|
|
37
|
+
},
|
|
38
|
+
"toolsDescription": "find_contacts, get_timeline, get_pipeline, list_tasks",
|
|
39
|
+
"default": "unlimited"
|
|
40
|
+
},
|
|
41
|
+
"export_access": {
|
|
42
|
+
"type": "string",
|
|
43
|
+
"required": true,
|
|
44
|
+
"displayName": "Export access",
|
|
45
|
+
"description": "Allow the agent to export the ENTIRE CRM in one call. Separate from read access because the risk is different in kind: reading one contact and extracting the whole customer database are not the same decision.",
|
|
46
|
+
"boundType": {
|
|
47
|
+
"kind": "enum",
|
|
48
|
+
"values": [
|
|
49
|
+
"allowed",
|
|
50
|
+
"none"
|
|
51
|
+
]
|
|
52
|
+
},
|
|
53
|
+
"toolsDescription": "export_crm",
|
|
54
|
+
"default": "none"
|
|
55
|
+
},
|
|
56
|
+
"write_daily_max": {
|
|
57
|
+
"type": "number",
|
|
58
|
+
"required": true,
|
|
59
|
+
"displayName": "Daily write limit",
|
|
60
|
+
"description": "Maximum CRM write operations per day (creates, updates)",
|
|
61
|
+
"unit": "count",
|
|
62
|
+
"boundType": {
|
|
63
|
+
"kind": "cumulative_count",
|
|
64
|
+
"window": "daily"
|
|
65
|
+
},
|
|
66
|
+
"appliesTo": [
|
|
67
|
+
"write"
|
|
68
|
+
]
|
|
69
|
+
},
|
|
70
|
+
"delete_daily_max": {
|
|
71
|
+
"type": "number",
|
|
72
|
+
"required": true,
|
|
73
|
+
"displayName": "Daily delete limit",
|
|
74
|
+
"description": "Maximum CRM delete operations per day",
|
|
75
|
+
"unit": "count",
|
|
76
|
+
"boundType": {
|
|
77
|
+
"kind": "cumulative_count",
|
|
78
|
+
"window": "daily"
|
|
79
|
+
},
|
|
80
|
+
"appliesTo": [
|
|
81
|
+
"delete"
|
|
82
|
+
]
|
|
83
|
+
},
|
|
84
|
+
"setup_daily_max": {
|
|
85
|
+
"type": "number",
|
|
86
|
+
"required": true,
|
|
87
|
+
"displayName": "Test-data loads per day",
|
|
88
|
+
"description": "How many times per day the simulated system may be loaded with a simulation package (load_simulation). Only works while the connector runs in simulation mode, and only into an empty system — a load cannot edit or replace existing test data. 0 = not allowed. Grant it only in a separate setup mandate, never in the mandate the AI uses for its work.",
|
|
89
|
+
"unit": "count",
|
|
90
|
+
"boundType": {
|
|
91
|
+
"kind": "cumulative_count",
|
|
92
|
+
"window": "daily"
|
|
93
|
+
},
|
|
94
|
+
"appliesTo": [
|
|
95
|
+
"setup"
|
|
96
|
+
],
|
|
97
|
+
"default": 0
|
|
98
|
+
}
|
|
99
|
+
}
|
|
100
|
+
},
|
|
101
|
+
"scopeSchema": {
|
|
102
|
+
"keyOrder": [
|
|
103
|
+
"contact_type"
|
|
104
|
+
],
|
|
105
|
+
"fields": {
|
|
106
|
+
"contact_type": {
|
|
107
|
+
"type": "string",
|
|
108
|
+
"required": true,
|
|
109
|
+
"displayName": "Contact types the agent may create or modify",
|
|
110
|
+
"description": "Contact types the agent may create, update or delete. Does NOT restrict reading — reads are governed by read_access.",
|
|
111
|
+
"enum": [
|
|
112
|
+
"customer",
|
|
113
|
+
"lead",
|
|
114
|
+
"partner",
|
|
115
|
+
"vendor"
|
|
116
|
+
],
|
|
117
|
+
"constraint": {
|
|
118
|
+
"type": "string",
|
|
119
|
+
"enforceable": [
|
|
120
|
+
"subset"
|
|
121
|
+
]
|
|
122
|
+
}
|
|
123
|
+
}
|
|
124
|
+
}
|
|
125
|
+
},
|
|
126
|
+
"executionContextSchema": {
|
|
127
|
+
"fields": {
|
|
128
|
+
"contact_type": {
|
|
129
|
+
"source": "declared",
|
|
130
|
+
"description": "Contact type being accessed",
|
|
131
|
+
"required": true,
|
|
132
|
+
"constraint": {
|
|
133
|
+
"type": "string",
|
|
134
|
+
"enforceable": [
|
|
135
|
+
"subset"
|
|
136
|
+
]
|
|
137
|
+
}
|
|
138
|
+
},
|
|
139
|
+
"write_count_daily": {
|
|
140
|
+
"source": "cumulative",
|
|
141
|
+
"cumulativeField": "_count",
|
|
142
|
+
"window": "daily",
|
|
143
|
+
"description": "Running daily write operation count",
|
|
144
|
+
"required": true,
|
|
145
|
+
"constraint": {
|
|
146
|
+
"type": "number",
|
|
147
|
+
"enforceable": [
|
|
148
|
+
"max"
|
|
149
|
+
]
|
|
150
|
+
}
|
|
151
|
+
},
|
|
152
|
+
"setup_count_daily": {
|
|
153
|
+
"source": "cumulative",
|
|
154
|
+
"cumulativeField": "_count",
|
|
155
|
+
"window": "daily",
|
|
156
|
+
"description": "Running daily count of test-data loads",
|
|
157
|
+
"required": true,
|
|
158
|
+
"constraint": {
|
|
159
|
+
"type": "number",
|
|
160
|
+
"enforceable": [
|
|
161
|
+
"max"
|
|
162
|
+
]
|
|
163
|
+
}
|
|
164
|
+
}
|
|
165
|
+
}
|
|
166
|
+
},
|
|
167
|
+
"requiredGates": [
|
|
168
|
+
"bounds",
|
|
169
|
+
"intent",
|
|
170
|
+
"commitment",
|
|
171
|
+
"mandate_owner"
|
|
172
|
+
],
|
|
173
|
+
"ttl": {
|
|
174
|
+
"default": 86400,
|
|
175
|
+
"max": 31536000
|
|
176
|
+
},
|
|
177
|
+
"retention_minimum": 7776000,
|
|
178
|
+
"content_binding": {
|
|
179
|
+
"version": "1",
|
|
180
|
+
"kind": "jcs"
|
|
181
|
+
}
|
|
182
|
+
}
|