@ory/cline 0.13.8 → 0.13.9

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.
Files changed (2) hide show
  1. package/dist/handlers.js +3 -27
  2. package/package.json +2 -2
package/dist/handlers.js CHANGED
@@ -83,8 +83,9 @@ async function handleTaskStart(input, client, deps) {
83
83
  projectUrl: (0, argus_1.resolveConfig)().projectUrl,
84
84
  harness: "cline",
85
85
  });
86
- // 3. User → agent delegation tuple. Best-effort; never blocks.
87
- await writeDelegation(client);
86
+ // 3. User → agent delegation tuple. Best-effort; never blocks. Written at
87
+ // most once per install.
88
+ await (0, argus_1.writeUserDelegatesAgent)(client);
88
89
  if (!decision.proceed) {
89
90
  return {
90
91
  cancel: true,
@@ -125,31 +126,6 @@ async function handleTaskStart(input, client, deps) {
125
126
  });
126
127
  return {};
127
128
  }
128
- /**
129
- * Write the user → agent delegation tuple once both principal subjects are
130
- * populated. Idempotent (409s absorbed by the core). Failures are logged and
131
- * swallowed — delegation tuples are audit-trail only.
132
- */
133
- async function writeDelegation(client) {
134
- const userSubject = client.userPrincipal?.subject;
135
- const agentSubject = client.agentPrincipal?.subject;
136
- if (!userSubject || !agentSubject)
137
- return;
138
- const namespace = resolveNamespace();
139
- try {
140
- await client.createRelationship({
141
- namespace,
142
- object: `agent:${agentSubject}`,
143
- relation: "delegate",
144
- subjectId: `user:${userSubject}`,
145
- });
146
- }
147
- catch (err) {
148
- client.logger.warn("delegation.write_failed", {
149
- message: err?.message ?? String(err),
150
- });
151
- }
152
- }
153
129
  async function verifySessionToken(token, client) {
154
130
  try {
155
131
  const session = await client.verifySession(token);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ory/cline",
3
- "version": "0.13.8",
3
+ "version": "0.13.9",
4
4
  "description": "Ory plugin for Cline: scaffolding skills, a local Ory instance, and authentication, authorization, and audit for every tool call",
5
5
  "license": "Apache-2.0",
6
6
  "homepage": "https://ory.com",
@@ -67,7 +67,7 @@
67
67
  ],
68
68
  "dependencies": {
69
69
  "reo-census": "^1.2.8",
70
- "@ory/argus": "0.13.8"
70
+ "@ory/argus": "0.13.9"
71
71
  },
72
72
  "devDependencies": {
73
73
  "typescript": "^6.0.2",