@databricks/sdk-agentkit 0.0.1 → 0.0.5

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/dist/package.js CHANGED
@@ -1,6 +1,6 @@
1
1
  //#region package.json
2
2
  var name = "@databricks/sdk-agentkit";
3
- var version = "0.0.1";
3
+ var version = "0.0.5";
4
4
 
5
5
  //#endregion
6
6
  export { name, version };
@@ -1,4 +1,4 @@
1
- import { AppendSessionItemsRequest, AppendSessionItemsResponse, ClearSessionItemsRequest, ClearSessionItemsResponse, CreateManagedMemoryEntryRequest, CreateManagedMemoryStoreRequest, CreateSessionRequest, CreateSessionStoreRequest, DeleteManagedMemoryEntryRequest, DeleteManagedMemoryStoreRequest, DeleteSessionRequest, DeleteSessionStoreRequest, ExtractMemoriesRequest, ExtractMemoriesResponse, ForkSessionRequest, ForkSessionResponse, GetManagedMemoryEntryRequest, GetManagedMemoryStoreRequest, GetSessionRequest, GetSessionStoreRequest, ListManagedMemoryEntriesRequest, ListManagedMemoryEntriesResponse, ListManagedMemoryStoresRequest, ListManagedMemoryStoresResponse, ListSessionItemsRequest, ListSessionItemsResponse, ListSessionStoresRequest, ListSessionStoresResponse, ListSessionsRequest, ListSessionsResponse, ManagedMemoryEntry, ManagedMemoryEntrySearchResult, ManagedMemoryStore, PopSessionItemRequest, PopSessionItemResponse, SearchManagedMemoryEntriesRequest, SearchManagedMemoryEntriesResponse, Session, SessionItem, SessionStore, UpdateManagedMemoryEntryRequest, UpdateManagedMemoryStoreRequest, UpdateSessionRequest, UpdateSessionStoreRequest } from "./model.js";
1
+ import { AppendSessionItemsRequest, AppendSessionItemsResponse, ClearSessionItemsRequest, ClearSessionItemsResponse, CreateManagedMemoryEntryRequest, CreateManagedMemoryStoreRequest, CreateSessionRequest, CreateSessionStoreRequest, DeleteManagedMemoryEntryRequest, DeleteManagedMemoryStoreRequest, DeleteSessionRequest, DeleteSessionStoreRequest, ExtractMemoriesRequest, ExtractMemoriesResponse, ForkSessionRequest, ForkSessionResponse, GetManagedMemoryEntryRequest, GetManagedMemoryStoreRequest, GetMemoryStorePermissionRequest, GetSessionRequest, GetSessionStorePermissionRequest, GetSessionStoreRequest, GrantMemoryStorePermissionRequest, GrantMemoryStorePermissionResponse, GrantSessionStorePermissionRequest, GrantSessionStorePermissionResponse, ListManagedMemoryEntriesRequest, ListManagedMemoryEntriesResponse, ListManagedMemoryStoresRequest, ListManagedMemoryStoresResponse, ListMemoryStorePermissionsRequest, ListMemoryStorePermissionsResponse, ListSessionItemsRequest, ListSessionItemsResponse, ListSessionStorePermissionsRequest, ListSessionStorePermissionsResponse, ListSessionStoresRequest, ListSessionStoresResponse, ListSessionsRequest, ListSessionsResponse, ManagedMemoryEntry, ManagedMemoryEntrySearchResult, ManagedMemoryStore, MemoryStorePermission, PopSessionItemRequest, PopSessionItemResponse, RevokeMemoryStorePermissionRequest, RevokeMemoryStorePermissionResponse, RevokeSessionStorePermissionRequest, RevokeSessionStorePermissionResponse, SearchManagedMemoryEntriesRequest, SearchManagedMemoryEntriesResponse, Session, SessionItem, SessionStore, SessionStorePermission, UpdateManagedMemoryEntryRequest, UpdateManagedMemoryStoreRequest, UpdateSessionRequest, UpdateSessionStoreRequest } from "./model.js";
2
2
  import { CallOptions } from "@databricks/sdk-options/call";
3
3
  import { ClientOptions } from "@databricks/sdk-options/client";
4
4
 
@@ -15,26 +15,26 @@ declare class AgentKitClient {
15
15
  /** Clears all items from a session. */
16
16
  clearSessionItems(req: ClearSessionItemsRequest, options?: CallOptions): Promise<ClearSessionItemsResponse>;
17
17
  /**
18
- * Creates a managed memory entry using exclusive-create semantics. Callers may choose the entry
18
+ * Creates a memory entry using exclusive-create semantics. Callers may choose the entry
19
19
  * ID; the service generates one when it is omitted. Returns `ALREADY_EXISTS` when an entry with
20
20
  * the same actor, session, and path already exists. Omitted `session_id` is its own uniqueness
21
21
  * key: two omitted-session entries with the same actor and path conflict, but an omitted-session
22
22
  * entry does not conflict with a session-scoped entry at the same actor and path.
23
23
  */
24
24
  createMemory(req: CreateManagedMemoryEntryRequest, options?: CallOptions): Promise<ManagedMemoryEntry>;
25
- /** Creates a managed memory store in the caller's workspace. */
25
+ /** Creates a memory store in the caller's workspace. */
26
26
  createMemoryStore(req: CreateManagedMemoryStoreRequest, options?: CallOptions): Promise<ManagedMemoryStore>;
27
27
  /** Creates a session within a session store. */
28
28
  createSession(req: CreateSessionRequest, options?: CallOptions): Promise<Session>;
29
29
  /** Creates a session store. */
30
30
  createSessionStore(req: CreateSessionStoreRequest, options?: CallOptions): Promise<SessionStore>;
31
31
  /**
32
- * Deletes a managed memory entry by resource name. Returns `NOT_FOUND` when the entry does not
32
+ * Deletes a memory entry by resource name. Returns `NOT_FOUND` when the entry does not
33
33
  * exist in the caller's workspace.
34
34
  */
35
35
  deleteMemory(req: DeleteManagedMemoryEntryRequest, options?: CallOptions): Promise<void>;
36
36
  /**
37
- * Deletes a managed memory store by resource name. Returns `NOT_FOUND` when the store does not
37
+ * Deletes a memory store by resource name. Returns `NOT_FOUND` when the store does not
38
38
  * exist in the caller's workspace.
39
39
  */
40
40
  deleteMemoryStore(req: DeleteManagedMemoryStoreRequest, options?: CallOptions): Promise<void>;
@@ -56,33 +56,47 @@ declare class AgentKitClient {
56
56
  /** Forks a session into an independent top-level copy. */
57
57
  forkSession(req: ForkSessionRequest, options?: CallOptions): Promise<ForkSessionResponse>;
58
58
  /**
59
- * Retrieves a managed memory entry by resource name. `view` controls whether the response
59
+ * Retrieves a memory entry by resource name. `view` controls whether the response
60
60
  * includes memory content. Returns `NOT_FOUND` when the entry does not exist in the caller's
61
61
  * workspace.
62
62
  */
63
63
  getMemory(req: GetManagedMemoryEntryRequest, options?: CallOptions): Promise<ManagedMemoryEntry>;
64
64
  /**
65
- * Retrieves a managed memory store by resource name. Returns `NOT_FOUND` when the store does not
65
+ * Retrieves a memory store by resource name. Returns `NOT_FOUND` when the store does not
66
66
  * exist in the caller's workspace.
67
67
  */
68
68
  getMemoryStore(req: GetManagedMemoryStoreRequest, options?: CallOptions): Promise<ManagedMemoryStore>;
69
+ /** Retrieves the current caller's effective memory store permission. Returns PERMISSION_LEVEL_UNSPECIFIED when the caller has no access. */
70
+ getMemoryStorePermission(req: GetMemoryStorePermissionRequest, options?: CallOptions): Promise<MemoryStorePermission>;
69
71
  /** Gets a session by resource name. */
70
72
  getSession(req: GetSessionRequest, options?: CallOptions): Promise<Session>;
71
73
  /** Gets a session store by resource name. */
72
74
  getSessionStore(req: GetSessionStoreRequest, options?: CallOptions): Promise<SessionStore>;
75
+ /** Retrieves the current caller's effective session store permission. Returns PERMISSION_LEVEL_UNSPECIFIED when the caller has no access. */
76
+ getSessionStorePermission(req: GetSessionStorePermissionRequest, options?: CallOptions): Promise<SessionStorePermission>;
77
+ /** Grants a READ or WRITE permission on a memory store to a principal. Only the owner or a workspace admin may grant permissions. */
78
+ grantMemoryStorePermission(req: GrantMemoryStorePermissionRequest, options?: CallOptions): Promise<GrantMemoryStorePermissionResponse>;
79
+ /** Grants a READ or WRITE permission on a session store to a principal. Only the owner or a workspace admin may grant permissions. */
80
+ grantSessionStorePermission(req: GrantSessionStorePermissionRequest, options?: CallOptions): Promise<GrantSessionStorePermissionResponse>;
73
81
  /**
74
- * Lists managed memory entries for one actor. An exact `path` filters entries across sessions,
82
+ * Lists memory entries for one actor. An exact `path` filters entries across sessions,
75
83
  * ignoring session metadata. Otherwise, `session_id` and `path_prefix` restrict the actor
76
84
  * partition. `view` controls whether each returned entry includes memory content.
77
85
  */
78
86
  listMemories(req: ListManagedMemoryEntriesRequest, options?: CallOptions): Promise<ListManagedMemoryEntriesResponse>;
79
87
  listMemoriesIter(req: ListManagedMemoryEntriesRequest, options?: CallOptions): AsyncGenerator<ManagedMemoryEntry>;
80
- /** Lists managed memory stores in the caller's workspace. */
88
+ /** Lists explicit memory store grants. Only the owner or a workspace admin may list permissions. */
89
+ listMemoryStorePermissions(req: ListMemoryStorePermissionsRequest, options?: CallOptions): Promise<ListMemoryStorePermissionsResponse>;
90
+ listMemoryStorePermissionsIter(req: ListMemoryStorePermissionsRequest, options?: CallOptions): AsyncGenerator<MemoryStorePermission>;
91
+ /** Lists memory stores in the caller's workspace. */
81
92
  listMemoryStores(req: ListManagedMemoryStoresRequest, options?: CallOptions): Promise<ListManagedMemoryStoresResponse>;
82
93
  listMemoryStoresIter(req: ListManagedMemoryStoresRequest, options?: CallOptions): AsyncGenerator<ManagedMemoryStore>;
83
94
  /** Lists items in a session. */
84
95
  listSessionItems(req: ListSessionItemsRequest, options?: CallOptions): Promise<ListSessionItemsResponse>;
85
96
  listSessionItemsIter(req: ListSessionItemsRequest, options?: CallOptions): AsyncGenerator<SessionItem>;
97
+ /** Lists explicit session store grants. Only the owner or a workspace admin may list permissions. */
98
+ listSessionStorePermissions(req: ListSessionStorePermissionsRequest, options?: CallOptions): Promise<ListSessionStorePermissionsResponse>;
99
+ listSessionStorePermissionsIter(req: ListSessionStorePermissionsRequest, options?: CallOptions): AsyncGenerator<SessionStorePermission>;
86
100
  /** Lists session stores. */
87
101
  listSessionStores(req: ListSessionStoresRequest, options?: CallOptions): Promise<ListSessionStoresResponse>;
88
102
  listSessionStoresIter(req: ListSessionStoresRequest, options?: CallOptions): AsyncGenerator<SessionStore>;
@@ -91,15 +105,19 @@ declare class AgentKitClient {
91
105
  listSessionsIter(req: ListSessionsRequest, options?: CallOptions): AsyncGenerator<Session>;
92
106
  /** Pops the newest item from a session. */
93
107
  popSessionItem(req: PopSessionItemRequest, options?: CallOptions): Promise<PopSessionItemResponse>;
108
+ /** Removes a principal's explicit READ and WRITE grants on a memory store. Only the owner or a workspace admin may revoke permissions. Ownership and inherited access are unaffected. */
109
+ revokeMemoryStorePermission(req: RevokeMemoryStorePermissionRequest, options?: CallOptions): Promise<RevokeMemoryStorePermissionResponse>;
110
+ /** Removes a principal's explicit READ and WRITE grants on a session store. Only the owner or a workspace admin may revoke permissions. Ownership and inherited access are unaffected. */
111
+ revokeSessionStorePermission(req: RevokeSessionStorePermissionRequest, options?: CallOptions): Promise<RevokeSessionStorePermissionResponse>;
94
112
  /**
95
- * Searches managed memory entries by text query for one actor. Returns matching entries and
113
+ * Searches memory entries by text query for one actor. Returns matching entries and
96
114
  * scores ranked by relevance; `view` controls whether each returned entry includes content.
97
115
  */
98
116
  searchMemories(req: SearchManagedMemoryEntriesRequest, options?: CallOptions): Promise<SearchManagedMemoryEntriesResponse>;
99
117
  searchMemoriesIter(req: SearchManagedMemoryEntriesRequest, options?: CallOptions): AsyncGenerator<ManagedMemoryEntrySearchResult>;
100
- /** Updates selected mutable fields on a managed memory entry. Identity fields are immutable. */
118
+ /** Updates selected mutable fields on a memory entry. Identity fields are immutable. */
101
119
  updateMemory(req: UpdateManagedMemoryEntryRequest, options?: CallOptions): Promise<ManagedMemoryEntry>;
102
- /** Updates a managed memory store's description and metadata. */
120
+ /** Updates a memory store's description and metadata. */
103
121
  updateMemoryStore(req: UpdateManagedMemoryStoreRequest, options?: CallOptions): Promise<ManagedMemoryStore>;
104
122
  /** Updates a session's mutable fields. */
105
123
  updateSession(req: UpdateSessionRequest, options?: CallOptions): Promise<Session>;
@@ -1 +1 @@
1
- {"version":3,"file":"client.d.ts","names":[],"sources":["../../src/v1/client.ts"],"mappings":";;;;;cAkGa,cAAA;EAAA,iBACM,OAAA;EAAA,iBACA,MAAA;EAAA,iBAIA,SAAA;EAAA,QAIT,MAAA;cAEI,OAAA,EAAS,aAAA;EAAA,QAUb,aAAA;EAQI;EAFN,kBAAA,CACJ,GAAA,EAAK,yBAAA,EACL,OAAA,GAAU,WAAA,GACT,OAAA,CAAQ,0BAAA;EAAR;EA2BG,iBAAA,CACJ,GAAA,EAAK,wBAAA,EACL,OAAA,GAAU,WAAA,GACT,OAAA,CAAQ,yBAAA;EADC;;;;;;;EAkCN,YAAA,CACJ,GAAA,EAAK,+BAAA,EACL,OAAA,GAAU,WAAA,GACT,OAAA,CAAQ,kBAAA;EA4CC;EAFN,iBAAA,CACJ,GAAA,EAAK,+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GAAU,WAAA,GACT,OAAA,CAAQ,mCAAA;EAxRO;EAyTZ,4BAAA,CACJ,GAAA,EAAK,mCAAA,EACL,OAAA,GAAU,WAAA,GACT,OAAA,CAAQ,oCAAA;EA5SJ;;;;EAgVD,cAAA,CACJ,GAAA,EAAK,iCAAA,EACL,OAAA,GAAU,WAAA,GACT,OAAA,CAAQ,kCAAA;EAgCJ,kBAAA,CACL,GAAA,EAAK,iCAAA,EACL,OAAA,GAAU,WAAA,GACT,cAAA,CAAe,8BAAA;EA5UA;EA2VZ,YAAA,CACJ,GAAA,EAAK,+BAAA,EACL,OAAA,GAAU,WAAA,GACT,OAAA,CAAQ,kBAAA;EA9UJ;EAwXD,iBAAA,CACJ,GAAA,EAAK,+BAAA,EACL,OAAA,GAAU,WAAA,GACT,OAAA,CAAQ,kBAAA;EAzXA;EAmaL,aAAA,CACJ,GAAA,EAAK,oBAAA,EACL,OAAA,GAAU,WAAA,GACT,OAAA,CAAQ,OAAA;EAhYJ;EAuaD,kBAAA,CACJ,GAAA,EAAK,yBAAA,EACL,OAAA,GAAU,WAAA,GACT,OAAA,CAAQ,YAAA;AAAA"}
package/dist/v1/client.js CHANGED
@@ -1,7 +1,7 @@
1
1
  import { resolveClientConfig } from "./transport.js";
2
2
  import { buildHttpRequest, executeCall, executeHttpCall, marshalRequest, parseResponse } from "./utils.js";
3
3
  import { name, version } from "../package.js";
4
- import { marshalAppendSessionItemsRequestSchema, marshalClearSessionItemsRequestSchema, marshalExtractMemoriesRequestSchema, marshalForkSessionRequestSchema, marshalManagedMemoryEntrySchema, marshalManagedMemoryStoreSchema, marshalPopSessionItemRequestSchema, marshalSearchManagedMemoryEntriesRequestSchema, marshalSessionSchema, marshalSessionStoreSchema, unmarshalAppendSessionItemsResponseSchema, unmarshalClearSessionItemsResponseSchema, unmarshalExtractMemoriesResponseSchema, unmarshalForkSessionResponseSchema, unmarshalListManagedMemoryEntriesResponseSchema, unmarshalListManagedMemoryStoresResponseSchema, unmarshalListSessionItemsResponseSchema, unmarshalListSessionStoresResponseSchema, unmarshalListSessionsResponseSchema, unmarshalManagedMemoryEntrySchema, unmarshalManagedMemoryStoreSchema, unmarshalPopSessionItemResponseSchema, unmarshalSearchManagedMemoryEntriesResponseSchema, unmarshalSessionSchema, unmarshalSessionStoreSchema } from "./model.js";
4
+ import { marshalAppendSessionItemsRequestSchema, marshalClearSessionItemsRequestSchema, marshalExtractMemoriesRequestSchema, marshalForkSessionRequestSchema, marshalGrantMemoryStorePermissionRequestSchema, marshalGrantSessionStorePermissionRequestSchema, marshalManagedMemoryEntrySchema, marshalManagedMemoryStoreSchema, marshalPopSessionItemRequestSchema, marshalRevokeMemoryStorePermissionRequestSchema, marshalRevokeSessionStorePermissionRequestSchema, marshalSearchManagedMemoryEntriesRequestSchema, marshalSessionSchema, marshalSessionStoreSchema, unmarshalAppendSessionItemsResponseSchema, unmarshalClearSessionItemsResponseSchema, unmarshalExtractMemoriesResponseSchema, unmarshalForkSessionResponseSchema, unmarshalGrantMemoryStorePermissionResponseSchema, unmarshalGrantSessionStorePermissionResponseSchema, unmarshalListManagedMemoryEntriesResponseSchema, unmarshalListManagedMemoryStoresResponseSchema, unmarshalListMemoryStorePermissionsResponseSchema, unmarshalListSessionItemsResponseSchema, unmarshalListSessionStorePermissionsResponseSchema, unmarshalListSessionStoresResponseSchema, unmarshalListSessionsResponseSchema, unmarshalManagedMemoryEntrySchema, unmarshalManagedMemoryStoreSchema, unmarshalMemoryStorePermissionSchema, unmarshalPopSessionItemResponseSchema, unmarshalRevokeMemoryStorePermissionResponseSchema, unmarshalRevokeSessionStorePermissionResponseSchema, unmarshalSearchManagedMemoryEntriesResponseSchema, unmarshalSessionSchema, unmarshalSessionStorePermissionSchema, unmarshalSessionStoreSchema } from "./model.js";
5
5
  import { VERSION } from "@databricks/sdk-auth";
6
6
  import { createDefault } from "@databricks/sdk-core/clientinfo";
7
7
  import { NoOpLogger } from "@databricks/sdk-core/logger";
@@ -72,7 +72,7 @@ var AgentKitClient = class {
72
72
  return resp;
73
73
  }
74
74
  /**
75
- * Creates a managed memory entry using exclusive-create semantics. Callers may choose the entry
75
+ * Creates a memory entry using exclusive-create semantics. Callers may choose the entry
76
76
  * ID; the service generates one when it is omitted. Returns `ALREADY_EXISTS` when an entry with
77
77
  * the same actor, session, and path already exists. Omitted `session_id` is its own uniqueness
78
78
  * key: two omitted-session entries with the same actor and path conflict, but an omitted-session
@@ -101,7 +101,7 @@ var AgentKitClient = class {
101
101
  if (resp === void 0) throw new Error("operation completed without a result.");
102
102
  return resp;
103
103
  }
104
- /** Creates a managed memory store in the caller's workspace. */
104
+ /** Creates a memory store in the caller's workspace. */
105
105
  async createMemoryStore(req, options) {
106
106
  const { host, workspaceId, httpClient } = await this.resolveConfig();
107
107
  const url = `${host}/api/2.0/agents/memory-stores`;
@@ -174,7 +174,7 @@ var AgentKitClient = class {
174
174
  return resp;
175
175
  }
176
176
  /**
177
- * Deletes a managed memory entry by resource name. Returns `NOT_FOUND` when the entry does not
177
+ * Deletes a memory entry by resource name. Returns `NOT_FOUND` when the entry does not
178
178
  * exist in the caller's workspace.
179
179
  */
180
180
  async deleteMemory(req, options) {
@@ -193,7 +193,7 @@ var AgentKitClient = class {
193
193
  await executeCall(call, options);
194
194
  }
195
195
  /**
196
- * Deletes a managed memory store by resource name. Returns `NOT_FOUND` when the store does not
196
+ * Deletes a memory store by resource name. Returns `NOT_FOUND` when the store does not
197
197
  * exist in the caller's workspace.
198
198
  */
199
199
  async deleteMemoryStore(req, options) {
@@ -293,7 +293,7 @@ var AgentKitClient = class {
293
293
  return resp;
294
294
  }
295
295
  /**
296
- * Retrieves a managed memory entry by resource name. `view` controls whether the response
296
+ * Retrieves a memory entry by resource name. `view` controls whether the response
297
297
  * includes memory content. Returns `NOT_FOUND` when the entry does not exist in the caller's
298
298
  * workspace.
299
299
  */
@@ -320,7 +320,7 @@ var AgentKitClient = class {
320
320
  return resp;
321
321
  }
322
322
  /**
323
- * Retrieves a managed memory store by resource name. Returns `NOT_FOUND` when the store does not
323
+ * Retrieves a memory store by resource name. Returns `NOT_FOUND` when the store does not
324
324
  * exist in the caller's workspace.
325
325
  */
326
326
  async getMemoryStore(req, options) {
@@ -341,6 +341,25 @@ var AgentKitClient = class {
341
341
  if (resp === void 0) throw new Error("operation completed without a result.");
342
342
  return resp;
343
343
  }
344
+ /** Retrieves the current caller's effective memory store permission. Returns PERMISSION_LEVEL_UNSPECIFIED when the caller has no access. */
345
+ async getMemoryStorePermission(req, options) {
346
+ const { host, workspaceId, httpClient } = await this.resolveConfig();
347
+ const url = `${host}/api/2.0/agents/${req.name ?? ""}/permissions/self`;
348
+ let resp;
349
+ const call = async (callSignal) => {
350
+ const headers = new Headers();
351
+ if (workspaceId !== void 0) headers.set("X-Databricks-Workspace-Id", workspaceId);
352
+ headers.set("User-Agent", this.userAgent);
353
+ resp = parseResponse(await executeHttpCall({
354
+ request: buildHttpRequest("GET", url, headers, callSignal),
355
+ httpClient,
356
+ logger: this.logger
357
+ }), unmarshalMemoryStorePermissionSchema);
358
+ };
359
+ await executeCall(call, options);
360
+ if (resp === void 0) throw new Error("operation completed without a result.");
361
+ return resp;
362
+ }
344
363
  /** Gets a session by resource name. */
345
364
  async getSession(req, options) {
346
365
  const { host, workspaceId, httpClient } = await this.resolveConfig();
@@ -379,8 +398,67 @@ var AgentKitClient = class {
379
398
  if (resp === void 0) throw new Error("operation completed without a result.");
380
399
  return resp;
381
400
  }
401
+ /** Retrieves the current caller's effective session store permission. Returns PERMISSION_LEVEL_UNSPECIFIED when the caller has no access. */
402
+ async getSessionStorePermission(req, options) {
403
+ const { host, workspaceId, httpClient } = await this.resolveConfig();
404
+ const url = `${host}/api/2.0/agents/${req.name ?? ""}/permissions/self`;
405
+ let resp;
406
+ const call = async (callSignal) => {
407
+ const headers = new Headers();
408
+ if (workspaceId !== void 0) headers.set("X-Databricks-Workspace-Id", workspaceId);
409
+ headers.set("User-Agent", this.userAgent);
410
+ resp = parseResponse(await executeHttpCall({
411
+ request: buildHttpRequest("GET", url, headers, callSignal),
412
+ httpClient,
413
+ logger: this.logger
414
+ }), unmarshalSessionStorePermissionSchema);
415
+ };
416
+ await executeCall(call, options);
417
+ if (resp === void 0) throw new Error("operation completed without a result.");
418
+ return resp;
419
+ }
420
+ /** Grants a READ or WRITE permission on a memory store to a principal. Only the owner or a workspace admin may grant permissions. */
421
+ async grantMemoryStorePermission(req, options) {
422
+ const { host, workspaceId, httpClient } = await this.resolveConfig();
423
+ const url = `${host}/api/2.0/agents/${req.name ?? ""}/permissions:grant`;
424
+ const body = marshalRequest(req, marshalGrantMemoryStorePermissionRequestSchema);
425
+ let resp;
426
+ const call = async (callSignal) => {
427
+ const headers = new Headers({ "Content-Type": "application/json" });
428
+ if (workspaceId !== void 0) headers.set("X-Databricks-Workspace-Id", workspaceId);
429
+ headers.set("User-Agent", this.userAgent);
430
+ resp = parseResponse(await executeHttpCall({
431
+ request: buildHttpRequest("POST", url, headers, callSignal, body),
432
+ httpClient,
433
+ logger: this.logger
434
+ }), unmarshalGrantMemoryStorePermissionResponseSchema);
435
+ };
436
+ await executeCall(call, options);
437
+ if (resp === void 0) throw new Error("operation completed without a result.");
438
+ return resp;
439
+ }
440
+ /** Grants a READ or WRITE permission on a session store to a principal. Only the owner or a workspace admin may grant permissions. */
441
+ async grantSessionStorePermission(req, options) {
442
+ const { host, workspaceId, httpClient } = await this.resolveConfig();
443
+ const url = `${host}/api/2.0/agents/${req.name ?? ""}/permissions:grant`;
444
+ const body = marshalRequest(req, marshalGrantSessionStorePermissionRequestSchema);
445
+ let resp;
446
+ const call = async (callSignal) => {
447
+ const headers = new Headers({ "Content-Type": "application/json" });
448
+ if (workspaceId !== void 0) headers.set("X-Databricks-Workspace-Id", workspaceId);
449
+ headers.set("User-Agent", this.userAgent);
450
+ resp = parseResponse(await executeHttpCall({
451
+ request: buildHttpRequest("POST", url, headers, callSignal, body),
452
+ httpClient,
453
+ logger: this.logger
454
+ }), unmarshalGrantSessionStorePermissionResponseSchema);
455
+ };
456
+ await executeCall(call, options);
457
+ if (resp === void 0) throw new Error("operation completed without a result.");
458
+ return resp;
459
+ }
382
460
  /**
383
- * Lists managed memory entries for one actor. An exact `path` filters entries across sessions,
461
+ * Lists memory entries for one actor. An exact `path` filters entries across sessions,
384
462
  * ignoring session metadata. Otherwise, `session_id` and `path_prefix` restrict the actor
385
463
  * partition. `view` controls whether each returned entry includes memory content.
386
464
  */
@@ -420,7 +498,40 @@ var AgentKitClient = class {
420
498
  pageReq.pageToken = resp.nextPageToken;
421
499
  }
422
500
  }
423
- /** Lists managed memory stores in the caller's workspace. */
501
+ /** Lists explicit memory store grants. Only the owner or a workspace admin may list permissions. */
502
+ async listMemoryStorePermissions(req, options) {
503
+ const { host, workspaceId, httpClient } = await this.resolveConfig();
504
+ const url = `${host}/api/2.0/agents/${req.parent ?? ""}/permissions`;
505
+ const params = new URLSearchParams();
506
+ if (req.pageSize !== void 0) params.append("page_size", String(req.pageSize));
507
+ if (req.pageToken !== void 0) params.append("page_token", req.pageToken);
508
+ const query = params.toString();
509
+ const fullUrl = query !== "" ? `${url}?${query}` : url;
510
+ let resp;
511
+ const call = async (callSignal) => {
512
+ const headers = new Headers();
513
+ if (workspaceId !== void 0) headers.set("X-Databricks-Workspace-Id", workspaceId);
514
+ headers.set("User-Agent", this.userAgent);
515
+ resp = parseResponse(await executeHttpCall({
516
+ request: buildHttpRequest("GET", fullUrl, headers, callSignal),
517
+ httpClient,
518
+ logger: this.logger
519
+ }), unmarshalListMemoryStorePermissionsResponseSchema);
520
+ };
521
+ await executeCall(call, options);
522
+ if (resp === void 0) throw new Error("operation completed without a result.");
523
+ return resp;
524
+ }
525
+ async *listMemoryStorePermissionsIter(req, options) {
526
+ const pageReq = { ...req };
527
+ for (;;) {
528
+ const resp = await this.listMemoryStorePermissions(pageReq, options);
529
+ for (const item of resp.memoryStorePermissions ?? []) yield item;
530
+ if (resp.nextPageToken === void 0 || resp.nextPageToken === "") return;
531
+ pageReq.pageToken = resp.nextPageToken;
532
+ }
533
+ }
534
+ /** Lists memory stores in the caller's workspace. */
424
535
  async listMemoryStores(req, options) {
425
536
  const { host, workspaceId, httpClient } = await this.resolveConfig();
426
537
  const url = `${host}/api/2.0/agents/memory-stores`;
@@ -487,6 +598,39 @@ var AgentKitClient = class {
487
598
  pageReq.pageToken = resp.nextPageToken;
488
599
  }
489
600
  }
601
+ /** Lists explicit session store grants. Only the owner or a workspace admin may list permissions. */
602
+ async listSessionStorePermissions(req, options) {
603
+ const { host, workspaceId, httpClient } = await this.resolveConfig();
604
+ const url = `${host}/api/2.0/agents/${req.parent ?? ""}/permissions`;
605
+ const params = new URLSearchParams();
606
+ if (req.pageSize !== void 0) params.append("page_size", String(req.pageSize));
607
+ if (req.pageToken !== void 0) params.append("page_token", req.pageToken);
608
+ const query = params.toString();
609
+ const fullUrl = query !== "" ? `${url}?${query}` : url;
610
+ let resp;
611
+ const call = async (callSignal) => {
612
+ const headers = new Headers();
613
+ if (workspaceId !== void 0) headers.set("X-Databricks-Workspace-Id", workspaceId);
614
+ headers.set("User-Agent", this.userAgent);
615
+ resp = parseResponse(await executeHttpCall({
616
+ request: buildHttpRequest("GET", fullUrl, headers, callSignal),
617
+ httpClient,
618
+ logger: this.logger
619
+ }), unmarshalListSessionStorePermissionsResponseSchema);
620
+ };
621
+ await executeCall(call, options);
622
+ if (resp === void 0) throw new Error("operation completed without a result.");
623
+ return resp;
624
+ }
625
+ async *listSessionStorePermissionsIter(req, options) {
626
+ const pageReq = { ...req };
627
+ for (;;) {
628
+ const resp = await this.listSessionStorePermissions(pageReq, options);
629
+ for (const item of resp.sessionStorePermissions ?? []) yield item;
630
+ if (resp.nextPageToken === void 0 || resp.nextPageToken === "") return;
631
+ pageReq.pageToken = resp.nextPageToken;
632
+ }
633
+ }
490
634
  /** Lists session stores. */
491
635
  async listSessionStores(req, options) {
492
636
  const { host, workspaceId, httpClient } = await this.resolveConfig();
@@ -575,8 +719,48 @@ var AgentKitClient = class {
575
719
  if (resp === void 0) throw new Error("operation completed without a result.");
576
720
  return resp;
577
721
  }
722
+ /** Removes a principal's explicit READ and WRITE grants on a memory store. Only the owner or a workspace admin may revoke permissions. Ownership and inherited access are unaffected. */
723
+ async revokeMemoryStorePermission(req, options) {
724
+ const { host, workspaceId, httpClient } = await this.resolveConfig();
725
+ const url = `${host}/api/2.0/agents/${req.name ?? ""}/permissions:revoke`;
726
+ const body = marshalRequest(req, marshalRevokeMemoryStorePermissionRequestSchema);
727
+ let resp;
728
+ const call = async (callSignal) => {
729
+ const headers = new Headers({ "Content-Type": "application/json" });
730
+ if (workspaceId !== void 0) headers.set("X-Databricks-Workspace-Id", workspaceId);
731
+ headers.set("User-Agent", this.userAgent);
732
+ resp = parseResponse(await executeHttpCall({
733
+ request: buildHttpRequest("POST", url, headers, callSignal, body),
734
+ httpClient,
735
+ logger: this.logger
736
+ }), unmarshalRevokeMemoryStorePermissionResponseSchema);
737
+ };
738
+ await executeCall(call, options);
739
+ if (resp === void 0) throw new Error("operation completed without a result.");
740
+ return resp;
741
+ }
742
+ /** Removes a principal's explicit READ and WRITE grants on a session store. Only the owner or a workspace admin may revoke permissions. Ownership and inherited access are unaffected. */
743
+ async revokeSessionStorePermission(req, options) {
744
+ const { host, workspaceId, httpClient } = await this.resolveConfig();
745
+ const url = `${host}/api/2.0/agents/${req.name ?? ""}/permissions:revoke`;
746
+ const body = marshalRequest(req, marshalRevokeSessionStorePermissionRequestSchema);
747
+ let resp;
748
+ const call = async (callSignal) => {
749
+ const headers = new Headers({ "Content-Type": "application/json" });
750
+ if (workspaceId !== void 0) headers.set("X-Databricks-Workspace-Id", workspaceId);
751
+ headers.set("User-Agent", this.userAgent);
752
+ resp = parseResponse(await executeHttpCall({
753
+ request: buildHttpRequest("POST", url, headers, callSignal, body),
754
+ httpClient,
755
+ logger: this.logger
756
+ }), unmarshalRevokeSessionStorePermissionResponseSchema);
757
+ };
758
+ await executeCall(call, options);
759
+ if (resp === void 0) throw new Error("operation completed without a result.");
760
+ return resp;
761
+ }
578
762
  /**
579
- * Searches managed memory entries by text query for one actor. Returns matching entries and
763
+ * Searches memory entries by text query for one actor. Returns matching entries and
580
764
  * scores ranked by relevance; `view` controls whether each returned entry includes content.
581
765
  */
582
766
  async searchMemories(req, options) {
@@ -607,7 +791,7 @@ var AgentKitClient = class {
607
791
  pageReq.pageToken = resp.nextPageToken;
608
792
  }
609
793
  }
610
- /** Updates selected mutable fields on a managed memory entry. Identity fields are immutable. */
794
+ /** Updates selected mutable fields on a memory entry. Identity fields are immutable. */
611
795
  async updateMemory(req, options) {
612
796
  const { host, workspaceId, httpClient } = await this.resolveConfig();
613
797
  const url = `${host}/api/2.0/agents/${req.managedMemoryEntry?.name ?? ""}`;
@@ -631,7 +815,7 @@ var AgentKitClient = class {
631
815
  if (resp === void 0) throw new Error("operation completed without a result.");
632
816
  return resp;
633
817
  }
634
- /** Updates a managed memory store's description and metadata. */
818
+ /** Updates a memory store's description and metadata. */
635
819
  async updateMemoryStore(req, options) {
636
820
  const { host, workspaceId, httpClient } = await this.resolveConfig();
637
821
  const url = `${host}/api/2.0/agents/${req.managedMemoryStore?.name ?? ""}`;