@ziggs-ai/api-client 0.42.18 → 0.42.19

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/CHANGELOG.md CHANGED
@@ -2,6 +2,10 @@
2
2
 
3
3
  ## Unreleased
4
4
 
5
+ ## 0.42.19
6
+
7
+ - Taking a grant back uses `DELETE /grants/:grantId`.
8
+
5
9
  ## 0.42.18
6
10
 
7
11
  ## 0.42.17
@@ -156,7 +156,7 @@ export class ConnectionsClient {
156
156
  throw new Error("revokeGrant: connectionId is required");
157
157
  if (!grantId)
158
158
  throw new Error("revokeGrant: grantId is required");
159
- return this._request("DELETE", `/connections/${encodeURIComponent(connectionId)}/grants/${encodeURIComponent(grantId)}`, undefined);
159
+ return this._request("DELETE", `/grants/${encodeURIComponent(grantId)}`, undefined);
160
160
  }
161
161
  /**
162
162
  * agent-initiated MCP connection request: ask the principal to
@@ -137,7 +137,7 @@ export class ContextGrantsClient {
137
137
  };
138
138
  }
139
139
  async revokeGrant(grantId) {
140
- const res = await fetch(`${this.baseUrl}/context/grants/${encodeURIComponent(grantId)}`, {
140
+ const res = await fetch(`${this.baseUrl}/grants/${encodeURIComponent(grantId)}`, {
141
141
  method: 'DELETE',
142
142
  headers: buildOperatorHeaders(this.operatorKey, this.agentId, {
143
143
  'content-type': 'application/json',
@@ -66,7 +66,7 @@ export class PaymentsClient {
66
66
  return (await this._post('/payments/grants', { holderId, caveats }));
67
67
  }
68
68
  async revokeGrant(grantId) {
69
- return (await this._request('DELETE', `/payments/grants/${grantId}`, undefined));
69
+ return (await this._request('DELETE', `/grants/${grantId}`, undefined));
70
70
  }
71
71
  /**
72
72
  * Live wallet grants the acting agent holds, via the unified GET /grants
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ziggs-ai/api-client",
3
- "version": "0.42.18",
3
+ "version": "0.42.19",
4
4
  "description": "HTTP and WebSocket client for the Ziggs backend API",
5
5
  "homepage": "https://ziggsai.com/docs",
6
6
  "bugs": {