@inkeep/agents-api 0.0.0-dev-20260123205017 → 0.0.0-dev-20260123211824

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 (41) hide show
  1. package/dist/.well-known/workflow/v1/manifest.debug.json +17 -17
  2. package/dist/.well-known/workflow/v1/step.cjs +942 -24
  3. package/dist/createApp.d.ts +2 -2
  4. package/dist/domains/evals/workflow/routes.d.ts +2 -2
  5. package/dist/domains/manage/index.js +0 -2
  6. package/dist/domains/manage/routes/agent.js +5 -2
  7. package/dist/domains/manage/routes/agentFull.js +5 -2
  8. package/dist/domains/manage/routes/agentToolRelations.js +5 -2
  9. package/dist/domains/manage/routes/apiKeys.js +1 -2
  10. package/dist/domains/manage/routes/cliAuth.js +2 -2
  11. package/dist/domains/manage/routes/credentials.js +1 -2
  12. package/dist/domains/manage/routes/dataComponents.js +1 -2
  13. package/dist/domains/manage/routes/evals/evaluationResults.d.ts +2 -2
  14. package/dist/domains/manage/routes/externalAgents.js +1 -2
  15. package/dist/domains/manage/routes/index.d.ts +2 -2
  16. package/dist/domains/manage/routes/index.js +4 -0
  17. package/dist/domains/manage/routes/mcp.d.ts +2 -2
  18. package/dist/domains/manage/routes/playgroundToken.js +0 -1
  19. package/dist/domains/manage/routes/projectFull.js +28 -6
  20. package/dist/domains/manage/routes/projectMembers.js +16 -35
  21. package/dist/domains/manage/routes/projectPermissions.js +17 -10
  22. package/dist/domains/manage/routes/projects.js +4 -5
  23. package/dist/domains/manage/routes/signoz.d.ts +2 -2
  24. package/dist/domains/manage/routes/userOrganizations.js +2 -2
  25. package/dist/domains/manage/routes/userProjectMemberships.d.ts +9 -0
  26. package/dist/domains/manage/routes/userProjectMemberships.js +45 -0
  27. package/dist/env.d.ts +2 -2
  28. package/dist/factory.d.ts +9 -9
  29. package/dist/index.d.ts +8 -8
  30. package/dist/initialization.js +2 -2
  31. package/dist/middleware/evalsAuth.d.ts +2 -2
  32. package/dist/middleware/projectAccess.d.ts +3 -10
  33. package/dist/middleware/projectAccess.js +1 -17
  34. package/dist/middleware/requirePermission.d.ts +2 -2
  35. package/dist/middleware/runAuth.d.ts +4 -4
  36. package/dist/middleware/sessionAuth.d.ts +3 -3
  37. package/dist/middleware/tenantAccess.d.ts +2 -2
  38. package/dist/middleware/tenantAccess.js +4 -4
  39. package/dist/middleware/tracing.d.ts +3 -3
  40. package/dist/types/app.d.ts +2 -0
  41. package/package.json +3 -3
@@ -66455,7 +66455,7 @@ var require_pg_pool = __commonJS({
66455
66455
  throw new Error("Release called on client which has already been released to the pool.");
66456
66456
  }
66457
66457
  __name(throwOnDoubleRelease, "throwOnDoubleRelease");
66458
- function promisify4(Promise2, callback) {
66458
+ function promisify5(Promise2, callback) {
66459
66459
  if (callback) {
66460
66460
  return {
66461
66461
  callback,
@@ -66479,7 +66479,7 @@ var require_pg_pool = __commonJS({
66479
66479
  result
66480
66480
  };
66481
66481
  }
66482
- __name(promisify4, "promisify");
66482
+ __name(promisify5, "promisify");
66483
66483
  function makeIdleListener(pool2, client) {
66484
66484
  return /* @__PURE__ */ __name(function idleListener(err2) {
66485
66485
  err2.client = client;
@@ -66597,7 +66597,7 @@ var require_pg_pool = __commonJS({
66597
66597
  const err2 = new Error("Cannot use a pool after calling end on the pool");
66598
66598
  return cb ? cb(err2) : this.Promise.reject(err2);
66599
66599
  }
66600
- const response = promisify4(this.Promise, cb);
66600
+ const response = promisify5(this.Promise, cb);
66601
66601
  const result = response.result;
66602
66602
  if (this._isFull() || this._idle.length) {
66603
66603
  if (this._idle.length) {
@@ -66751,7 +66751,7 @@ var require_pg_pool = __commonJS({
66751
66751
  }
66752
66752
  query(text3, values, cb) {
66753
66753
  if (typeof text3 === "function") {
66754
- const response2 = promisify4(this.Promise, text3);
66754
+ const response2 = promisify5(this.Promise, text3);
66755
66755
  setImmediate(function() {
66756
66756
  return response2.callback(new Error("Passing a function as the first parameter to pool.query is not supported"));
66757
66757
  });
@@ -66761,7 +66761,7 @@ var require_pg_pool = __commonJS({
66761
66761
  cb = values;
66762
66762
  values = void 0;
66763
66763
  }
66764
- const response = promisify4(this.Promise, cb);
66764
+ const response = promisify5(this.Promise, cb);
66765
66765
  cb = response.callback;
66766
66766
  this.connect((err2, client) => {
66767
66767
  if (err2) {
@@ -66806,7 +66806,7 @@ var require_pg_pool = __commonJS({
66806
66806
  return cb ? cb(err2) : this.Promise.reject(err2);
66807
66807
  }
66808
66808
  this.ending = true;
66809
- const promised = promisify4(this.Promise, cb);
66809
+ const promised = promisify5(this.Promise, cb);
66810
66810
  this._endCallback = promised.callback;
66811
66811
  this._pulseQueue();
66812
66812
  return promised.result;
@@ -91427,7 +91427,7 @@ var require_mock_interceptor = __commonJS({
91427
91427
  var require_mock_client = __commonJS({
91428
91428
  "../node_modules/.pnpm/undici@6.22.0/node_modules/undici/lib/mock/mock-client.js"(exports2, module2) {
91429
91429
  "use strict";
91430
- var { promisify: promisify4 } = require("node:util");
91430
+ var { promisify: promisify5 } = require("node:util");
91431
91431
  var Client10 = require_client4();
91432
91432
  var { buildMockDispatch } = require_mock_utils();
91433
91433
  var { kDispatches, kMockAgent, kClose, kOriginalClose, kOrigin, kOriginalDispatch, kConnected } = require_mock_symbols();
@@ -91462,7 +91462,7 @@ var require_mock_client = __commonJS({
91462
91462
  return new MockInterceptor(opts, this[kDispatches]);
91463
91463
  }
91464
91464
  async [kClose]() {
91465
- await promisify4(this[kOriginalClose])();
91465
+ await promisify5(this[kOriginalClose])();
91466
91466
  this[kConnected] = 0;
91467
91467
  this[kMockAgent][Symbols.kClients].delete(this[kOrigin]);
91468
91468
  }
@@ -91475,7 +91475,7 @@ var require_mock_client = __commonJS({
91475
91475
  var require_mock_pool = __commonJS({
91476
91476
  "../node_modules/.pnpm/undici@6.22.0/node_modules/undici/lib/mock/mock-pool.js"(exports2, module2) {
91477
91477
  "use strict";
91478
- var { promisify: promisify4 } = require("node:util");
91478
+ var { promisify: promisify5 } = require("node:util");
91479
91479
  var Pool3 = require_pool2();
91480
91480
  var { buildMockDispatch } = require_mock_utils();
91481
91481
  var { kDispatches, kMockAgent, kClose, kOriginalClose, kOrigin, kOriginalDispatch, kConnected } = require_mock_symbols();
@@ -91510,7 +91510,7 @@ var require_mock_pool = __commonJS({
91510
91510
  return new MockInterceptor(opts, this[kDispatches]);
91511
91511
  }
91512
91512
  async [kClose]() {
91513
- await promisify4(this[kOriginalClose])();
91513
+ await promisify5(this[kOriginalClose])();
91514
91514
  this[kConnected] = 0;
91515
91515
  this[kMockAgent][Symbols.kClients].delete(this[kOrigin]);
91516
91516
  }
@@ -135260,6 +135260,156 @@ var Timestamp$Type = class extends import_runtime231.MessageType {
135260
135260
  };
135261
135261
  var Timestamp = new Timestamp$Type();
135262
135262
 
135263
+ // ../node_modules/.pnpm/@authzed+authzed-node@1.6.1/node_modules/@authzed/authzed-node/dist/src/v1.js
135264
+ var v1_exports = {};
135265
+ __export(v1_exports, {
135266
+ AlgebraicSubjectSet: () => AlgebraicSubjectSet,
135267
+ AlgebraicSubjectSet_Operation: () => AlgebraicSubjectSet_Operation,
135268
+ BreakingSchemaChange: () => BreakingSchemaChange,
135269
+ BulkCheckPermissionPair: () => BulkCheckPermissionPair,
135270
+ BulkCheckPermissionRequest: () => BulkCheckPermissionRequest,
135271
+ BulkCheckPermissionRequestItem: () => BulkCheckPermissionRequestItem,
135272
+ BulkCheckPermissionResponse: () => BulkCheckPermissionResponse,
135273
+ BulkCheckPermissionResponseItem: () => BulkCheckPermissionResponseItem,
135274
+ BulkExportRelationshipsRequest: () => BulkExportRelationshipsRequest,
135275
+ BulkExportRelationshipsResponse: () => BulkExportRelationshipsResponse,
135276
+ BulkImportRelationshipsRequest: () => BulkImportRelationshipsRequest,
135277
+ BulkImportRelationshipsResponse: () => BulkImportRelationshipsResponse,
135278
+ CheckBulkPermissionsPair: () => CheckBulkPermissionsPair,
135279
+ CheckBulkPermissionsRequest: () => CheckBulkPermissionsRequest,
135280
+ CheckBulkPermissionsRequestItem: () => CheckBulkPermissionsRequestItem,
135281
+ CheckBulkPermissionsResponse: () => CheckBulkPermissionsResponse,
135282
+ CheckBulkPermissionsResponseItem: () => CheckBulkPermissionsResponseItem,
135283
+ CheckPermissionRequest: () => CheckPermissionRequest,
135284
+ CheckPermissionResponse: () => CheckPermissionResponse,
135285
+ CheckPermissionResponse_Permissionship: () => CheckPermissionResponse_Permissionship,
135286
+ ClientSecurity: () => ClientSecurity,
135287
+ ComputablePermissionsRequest: () => ComputablePermissionsRequest,
135288
+ ComputablePermissionsResponse: () => ComputablePermissionsResponse,
135289
+ Consistency: () => Consistency,
135290
+ ContextualizedCaveat: () => ContextualizedCaveat,
135291
+ Cursor: () => Cursor,
135292
+ DeleteRelationshipsRequest: () => DeleteRelationshipsRequest,
135293
+ DeleteRelationshipsResponse: () => DeleteRelationshipsResponse,
135294
+ DeleteRelationshipsResponse_DeletionProgress: () => DeleteRelationshipsResponse_DeletionProgress,
135295
+ DependentRelationsRequest: () => DependentRelationsRequest,
135296
+ DependentRelationsResponse: () => DependentRelationsResponse,
135297
+ DiffSchemaRequest: () => DiffSchemaRequest,
135298
+ DiffSchemaResponse: () => DiffSchemaResponse,
135299
+ DirectSubjectSet: () => DirectSubjectSet,
135300
+ ErrorReason: () => ErrorReason,
135301
+ ExpCaveat: () => ExpCaveat,
135302
+ ExpCaveatParameter: () => ExpCaveatParameter,
135303
+ ExpCaveatParameterTypeChange: () => ExpCaveatParameterTypeChange,
135304
+ ExpDefinition: () => ExpDefinition,
135305
+ ExpPermission: () => ExpPermission,
135306
+ ExpRelation: () => ExpRelation,
135307
+ ExpRelationReference: () => ExpRelationReference,
135308
+ ExpRelationSubjectTypeChange: () => ExpRelationSubjectTypeChange,
135309
+ ExpSchemaDiff: () => ExpSchemaDiff,
135310
+ ExpSchemaFilter: () => ExpSchemaFilter,
135311
+ ExpTypeReference: () => ExpTypeReference,
135312
+ ExpandPermissionTreeRequest: () => ExpandPermissionTreeRequest,
135313
+ ExpandPermissionTreeResponse: () => ExpandPermissionTreeResponse,
135314
+ ExperimentalComputablePermissionsRequest: () => ExperimentalComputablePermissionsRequest,
135315
+ ExperimentalComputablePermissionsResponse: () => ExperimentalComputablePermissionsResponse,
135316
+ ExperimentalCountRelationshipsRequest: () => ExperimentalCountRelationshipsRequest,
135317
+ ExperimentalCountRelationshipsResponse: () => ExperimentalCountRelationshipsResponse,
135318
+ ExperimentalDependentRelationsRequest: () => ExperimentalDependentRelationsRequest,
135319
+ ExperimentalDependentRelationsResponse: () => ExperimentalDependentRelationsResponse,
135320
+ ExperimentalDiffSchemaRequest: () => ExperimentalDiffSchemaRequest,
135321
+ ExperimentalDiffSchemaResponse: () => ExperimentalDiffSchemaResponse,
135322
+ ExperimentalReflectSchemaRequest: () => ExperimentalReflectSchemaRequest,
135323
+ ExperimentalReflectSchemaResponse: () => ExperimentalReflectSchemaResponse,
135324
+ ExperimentalRegisterRelationshipCounterRequest: () => ExperimentalRegisterRelationshipCounterRequest,
135325
+ ExperimentalRegisterRelationshipCounterResponse: () => ExperimentalRegisterRelationshipCounterResponse,
135326
+ ExperimentalService: () => ExperimentalService,
135327
+ ExperimentalServiceClient: () => ExperimentalServiceClient,
135328
+ ExperimentalUnregisterRelationshipCounterRequest: () => ExperimentalUnregisterRelationshipCounterRequest,
135329
+ ExperimentalUnregisterRelationshipCounterResponse: () => ExperimentalUnregisterRelationshipCounterResponse,
135330
+ ExportBulkRelationshipsRequest: () => ExportBulkRelationshipsRequest,
135331
+ ExportBulkRelationshipsResponse: () => ExportBulkRelationshipsResponse,
135332
+ ImportBulkRelationshipsRequest: () => ImportBulkRelationshipsRequest,
135333
+ ImportBulkRelationshipsResponse: () => ImportBulkRelationshipsResponse,
135334
+ LookupPermissionSetsRequest: () => LookupPermissionSetsRequest,
135335
+ LookupPermissionSetsRequired: () => LookupPermissionSetsRequired,
135336
+ LookupPermissionSetsResponse: () => LookupPermissionSetsResponse,
135337
+ LookupPermissionship: () => LookupPermissionship,
135338
+ LookupResourcesRequest: () => LookupResourcesRequest,
135339
+ LookupResourcesResponse: () => LookupResourcesResponse,
135340
+ LookupSubjectsRequest: () => LookupSubjectsRequest,
135341
+ LookupSubjectsRequest_WildcardOption: () => LookupSubjectsRequest_WildcardOption,
135342
+ LookupSubjectsResponse: () => LookupSubjectsResponse,
135343
+ MaterializeCursor: () => Cursor2,
135344
+ MemberReference: () => MemberReference,
135345
+ NewClient: () => NewClient,
135346
+ NewClientWithChannelCredentials: () => NewClientWithChannelCredentials,
135347
+ NewClientWithCustomCert: () => NewClientWithCustomCert,
135348
+ ObjectReference: () => ObjectReference,
135349
+ PartialCaveatInfo: () => PartialCaveatInfo,
135350
+ PbNullValue: () => NullValue,
135351
+ PbStruct: () => Struct,
135352
+ PermissionChange: () => PermissionChange,
135353
+ PermissionChange_Permissionship: () => PermissionChange_Permissionship,
135354
+ PermissionRelationshipTree: () => PermissionRelationshipTree,
135355
+ PermissionSetChange: () => PermissionSetChange,
135356
+ PermissionSetChange_SetOperation: () => PermissionSetChange_SetOperation,
135357
+ PermissionsService: () => PermissionsService,
135358
+ PermissionsServiceClient: () => PermissionsServiceClient,
135359
+ Precondition: () => Precondition,
135360
+ Precondition_Operation: () => Precondition_Operation,
135361
+ ReadCounterValue: () => ReadCounterValue,
135362
+ ReadRelationshipsRequest: () => ReadRelationshipsRequest,
135363
+ ReadRelationshipsResponse: () => ReadRelationshipsResponse,
135364
+ ReadSchemaRequest: () => ReadSchemaRequest,
135365
+ ReadSchemaResponse: () => ReadSchemaResponse,
135366
+ ReflectSchemaRequest: () => ReflectSchemaRequest,
135367
+ ReflectSchemaResponse: () => ReflectSchemaResponse,
135368
+ ReflectionCaveat: () => ReflectionCaveat,
135369
+ ReflectionCaveatParameter: () => ReflectionCaveatParameter,
135370
+ ReflectionCaveatParameterTypeChange: () => ReflectionCaveatParameterTypeChange,
135371
+ ReflectionDefinition: () => ReflectionDefinition,
135372
+ ReflectionPermission: () => ReflectionPermission,
135373
+ ReflectionRelation: () => ReflectionRelation,
135374
+ ReflectionRelationReference: () => ReflectionRelationReference,
135375
+ ReflectionRelationSubjectTypeChange: () => ReflectionRelationSubjectTypeChange,
135376
+ ReflectionSchemaDiff: () => ReflectionSchemaDiff,
135377
+ ReflectionSchemaFilter: () => ReflectionSchemaFilter,
135378
+ ReflectionTypeReference: () => ReflectionTypeReference,
135379
+ Relationship: () => Relationship,
135380
+ RelationshipFilter: () => RelationshipFilter,
135381
+ RelationshipUpdate: () => RelationshipUpdate,
135382
+ RelationshipUpdate_Operation: () => RelationshipUpdate_Operation,
135383
+ ResolvedSubject: () => ResolvedSubject,
135384
+ SchemaService: () => SchemaService,
135385
+ SchemaServiceClient: () => SchemaServiceClient,
135386
+ SetReference: () => SetReference,
135387
+ SubjectFilter: () => SubjectFilter,
135388
+ SubjectFilter_RelationFilter: () => SubjectFilter_RelationFilter,
135389
+ SubjectReference: () => SubjectReference,
135390
+ WatchKind: () => WatchKind,
135391
+ WatchPermissionSetsRequest: () => WatchPermissionSetsRequest,
135392
+ WatchPermissionSetsResponse: () => WatchPermissionSetsResponse,
135393
+ WatchPermissionSetsServiceClient: () => WatchPermissionSetsServiceClient,
135394
+ WatchPermissionsRequest: () => WatchPermissionsRequest,
135395
+ WatchPermissionsResponse: () => WatchPermissionsResponse,
135396
+ WatchPermissionsService: () => WatchPermissionsService,
135397
+ WatchPermissionsServiceClient: () => WatchPermissionsServiceClient,
135398
+ WatchRequest: () => WatchRequest,
135399
+ WatchResponse: () => WatchResponse,
135400
+ WatchService: () => WatchService,
135401
+ WatchServiceClient: () => WatchServiceClient,
135402
+ WatchedPermission: () => WatchedPermission,
135403
+ WriteRelationshipsRequest: () => WriteRelationshipsRequest,
135404
+ WriteRelationshipsResponse: () => WriteRelationshipsResponse,
135405
+ WriteSchemaRequest: () => WriteSchemaRequest,
135406
+ WriteSchemaResponse: () => WriteSchemaResponse,
135407
+ ZedToken: () => ZedToken,
135408
+ createStructFromObject: () => createStructFromObject,
135409
+ default: () => v1_default
135410
+ });
135411
+ var import_util3 = require("util");
135412
+
135263
135413
  // ../node_modules/.pnpm/@authzed+authzed-node@1.6.1/node_modules/@authzed/authzed-node/dist/src/authzedapi/authzed/api/v1/experimental_service.js
135264
135414
  var import_runtime_rpc2 = __toESM(require_commonjs2(), 1);
135265
135415
  var import_runtime266 = __toESM(require_commonjs(), 1);
@@ -135275,11 +135425,11 @@ var import_runtime235 = __toESM(require_commonjs(), 1);
135275
135425
  var import_runtime236 = __toESM(require_commonjs(), 1);
135276
135426
  var import_runtime237 = __toESM(require_commonjs(), 1);
135277
135427
  var RelationshipUpdate_Operation;
135278
- (function(RelationshipUpdate_Operation2) {
135279
- RelationshipUpdate_Operation2[RelationshipUpdate_Operation2["UNSPECIFIED"] = 0] = "UNSPECIFIED";
135280
- RelationshipUpdate_Operation2[RelationshipUpdate_Operation2["CREATE"] = 1] = "CREATE";
135281
- RelationshipUpdate_Operation2[RelationshipUpdate_Operation2["TOUCH"] = 2] = "TOUCH";
135282
- RelationshipUpdate_Operation2[RelationshipUpdate_Operation2["DELETE"] = 3] = "DELETE";
135428
+ (function(RelationshipUpdate_Operation3) {
135429
+ RelationshipUpdate_Operation3[RelationshipUpdate_Operation3["UNSPECIFIED"] = 0] = "UNSPECIFIED";
135430
+ RelationshipUpdate_Operation3[RelationshipUpdate_Operation3["CREATE"] = 1] = "CREATE";
135431
+ RelationshipUpdate_Operation3[RelationshipUpdate_Operation3["TOUCH"] = 2] = "TOUCH";
135432
+ RelationshipUpdate_Operation3[RelationshipUpdate_Operation3["DELETE"] = 3] = "DELETE";
135283
135433
  })(RelationshipUpdate_Operation || (RelationshipUpdate_Operation = {}));
135284
135434
  var AlgebraicSubjectSet_Operation;
135285
135435
  (function(AlgebraicSubjectSet_Operation2) {
@@ -136995,11 +137145,11 @@ var DeleteRelationshipsResponse_DeletionProgress;
136995
137145
  DeleteRelationshipsResponse_DeletionProgress2[DeleteRelationshipsResponse_DeletionProgress2["PARTIAL"] = 2] = "PARTIAL";
136996
137146
  })(DeleteRelationshipsResponse_DeletionProgress || (DeleteRelationshipsResponse_DeletionProgress = {}));
136997
137147
  var CheckPermissionResponse_Permissionship;
136998
- (function(CheckPermissionResponse_Permissionship2) {
136999
- CheckPermissionResponse_Permissionship2[CheckPermissionResponse_Permissionship2["UNSPECIFIED"] = 0] = "UNSPECIFIED";
137000
- CheckPermissionResponse_Permissionship2[CheckPermissionResponse_Permissionship2["NO_PERMISSION"] = 1] = "NO_PERMISSION";
137001
- CheckPermissionResponse_Permissionship2[CheckPermissionResponse_Permissionship2["HAS_PERMISSION"] = 2] = "HAS_PERMISSION";
137002
- CheckPermissionResponse_Permissionship2[CheckPermissionResponse_Permissionship2["CONDITIONAL_PERMISSION"] = 3] = "CONDITIONAL_PERMISSION";
137148
+ (function(CheckPermissionResponse_Permissionship3) {
137149
+ CheckPermissionResponse_Permissionship3[CheckPermissionResponse_Permissionship3["UNSPECIFIED"] = 0] = "UNSPECIFIED";
137150
+ CheckPermissionResponse_Permissionship3[CheckPermissionResponse_Permissionship3["NO_PERMISSION"] = 1] = "NO_PERMISSION";
137151
+ CheckPermissionResponse_Permissionship3[CheckPermissionResponse_Permissionship3["HAS_PERMISSION"] = 2] = "HAS_PERMISSION";
137152
+ CheckPermissionResponse_Permissionship3[CheckPermissionResponse_Permissionship3["CONDITIONAL_PERMISSION"] = 3] = "CONDITIONAL_PERMISSION";
137003
137153
  })(CheckPermissionResponse_Permissionship || (CheckPermissionResponse_Permissionship = {}));
137004
137154
  var LookupSubjectsRequest_WildcardOption;
137005
137155
  (function(LookupSubjectsRequest_WildcardOption2) {
@@ -143409,9 +143559,237 @@ var ExperimentalService = new import_runtime_rpc2.ServiceType("authzed.api.v1.Ex
143409
143559
 
143410
143560
  // ../node_modules/.pnpm/@authzed+authzed-node@1.6.1/node_modules/@authzed/authzed-node/dist/src/authzedapi/authzed/api/v1/experimental_service.grpc-client.js
143411
143561
  var grpc = __toESM(require_src3(), 1);
143562
+ var ExperimentalServiceClient = class extends grpc.Client {
143563
+ static {
143564
+ __name(this, "ExperimentalServiceClient");
143565
+ }
143566
+ _binaryOptions;
143567
+ constructor(address, credentials2, options = {}, binaryOptions = {}) {
143568
+ super(address, credentials2, options);
143569
+ this._binaryOptions = binaryOptions;
143570
+ }
143571
+ /**
143572
+ * DEPRECATED: Promoted to ImportBulkRelationships in the stable API.
143573
+ *
143574
+ * @deprecated
143575
+ * @generated from protobuf rpc: BulkImportRelationships(stream authzed.api.v1.BulkImportRelationshipsRequest) returns (authzed.api.v1.BulkImportRelationshipsResponse);
143576
+ */
143577
+ bulkImportRelationships(metadata2, options, callback) {
143578
+ const method = ExperimentalService.methods[0];
143579
+ return this.makeClientStreamRequest(`/${ExperimentalService.typeName}/${method.name}`, (value) => Buffer.from(method.I.toBinary(value, this._binaryOptions)), (value) => method.O.fromBinary(value, this._binaryOptions), metadata2, options, callback);
143580
+ }
143581
+ /**
143582
+ * DEPRECATED: Promoted to ExportBulkRelationships in the stable API.
143583
+ *
143584
+ * @deprecated
143585
+ * @generated from protobuf rpc: BulkExportRelationships(authzed.api.v1.BulkExportRelationshipsRequest) returns (stream authzed.api.v1.BulkExportRelationshipsResponse);
143586
+ */
143587
+ bulkExportRelationships(input, metadata2, options) {
143588
+ const method = ExperimentalService.methods[1];
143589
+ return this.makeServerStreamRequest(`/${ExperimentalService.typeName}/${method.name}`, (value) => Buffer.from(method.I.toBinary(value, this._binaryOptions)), (value) => method.O.fromBinary(value, this._binaryOptions), input, metadata2, options);
143590
+ }
143591
+ /**
143592
+ * DEPRECATED: Promoted to CheckBulkPermission in the stable API.
143593
+ *
143594
+ * @deprecated
143595
+ * @generated from protobuf rpc: BulkCheckPermission(authzed.api.v1.BulkCheckPermissionRequest) returns (authzed.api.v1.BulkCheckPermissionResponse);
143596
+ */
143597
+ bulkCheckPermission(input, metadata2, options, callback) {
143598
+ const method = ExperimentalService.methods[2];
143599
+ return this.makeUnaryRequest(`/${ExperimentalService.typeName}/${method.name}`, (value) => Buffer.from(method.I.toBinary(value, this._binaryOptions)), (value) => method.O.fromBinary(value, this._binaryOptions), input, metadata2, options, callback);
143600
+ }
143601
+ /**
143602
+ * DEPRECATED: Promoted to ReflectSchema in the stable API.
143603
+ *
143604
+ * @deprecated
143605
+ * @generated from protobuf rpc: ExperimentalReflectSchema(authzed.api.v1.ExperimentalReflectSchemaRequest) returns (authzed.api.v1.ExperimentalReflectSchemaResponse);
143606
+ */
143607
+ experimentalReflectSchema(input, metadata2, options, callback) {
143608
+ const method = ExperimentalService.methods[3];
143609
+ return this.makeUnaryRequest(`/${ExperimentalService.typeName}/${method.name}`, (value) => Buffer.from(method.I.toBinary(value, this._binaryOptions)), (value) => method.O.fromBinary(value, this._binaryOptions), input, metadata2, options, callback);
143610
+ }
143611
+ /**
143612
+ * DEPRECATED: Promoted to ComputablePermissions in the stable API.
143613
+ *
143614
+ * @deprecated
143615
+ * @generated from protobuf rpc: ExperimentalComputablePermissions(authzed.api.v1.ExperimentalComputablePermissionsRequest) returns (authzed.api.v1.ExperimentalComputablePermissionsResponse);
143616
+ */
143617
+ experimentalComputablePermissions(input, metadata2, options, callback) {
143618
+ const method = ExperimentalService.methods[4];
143619
+ return this.makeUnaryRequest(`/${ExperimentalService.typeName}/${method.name}`, (value) => Buffer.from(method.I.toBinary(value, this._binaryOptions)), (value) => method.O.fromBinary(value, this._binaryOptions), input, metadata2, options, callback);
143620
+ }
143621
+ /**
143622
+ * DEPRECATED: Promoted to DependentRelations in the stable API.
143623
+ *
143624
+ * @deprecated
143625
+ * @generated from protobuf rpc: ExperimentalDependentRelations(authzed.api.v1.ExperimentalDependentRelationsRequest) returns (authzed.api.v1.ExperimentalDependentRelationsResponse);
143626
+ */
143627
+ experimentalDependentRelations(input, metadata2, options, callback) {
143628
+ const method = ExperimentalService.methods[5];
143629
+ return this.makeUnaryRequest(`/${ExperimentalService.typeName}/${method.name}`, (value) => Buffer.from(method.I.toBinary(value, this._binaryOptions)), (value) => method.O.fromBinary(value, this._binaryOptions), input, metadata2, options, callback);
143630
+ }
143631
+ /**
143632
+ * DEPRECATED: Promoted to DiffSchema in the stable API.
143633
+ *
143634
+ * @deprecated
143635
+ * @generated from protobuf rpc: ExperimentalDiffSchema(authzed.api.v1.ExperimentalDiffSchemaRequest) returns (authzed.api.v1.ExperimentalDiffSchemaResponse);
143636
+ */
143637
+ experimentalDiffSchema(input, metadata2, options, callback) {
143638
+ const method = ExperimentalService.methods[6];
143639
+ return this.makeUnaryRequest(`/${ExperimentalService.typeName}/${method.name}`, (value) => Buffer.from(method.I.toBinary(value, this._binaryOptions)), (value) => method.O.fromBinary(value, this._binaryOptions), input, metadata2, options, callback);
143640
+ }
143641
+ /**
143642
+ * EXPERIMENTAL: RegisterRelationshipCounter registers a new filter for counting relationships. A filter must be registered before
143643
+ * a count can be requested.
143644
+ *
143645
+ * @generated from protobuf rpc: ExperimentalRegisterRelationshipCounter(authzed.api.v1.ExperimentalRegisterRelationshipCounterRequest) returns (authzed.api.v1.ExperimentalRegisterRelationshipCounterResponse);
143646
+ */
143647
+ experimentalRegisterRelationshipCounter(input, metadata2, options, callback) {
143648
+ const method = ExperimentalService.methods[7];
143649
+ return this.makeUnaryRequest(`/${ExperimentalService.typeName}/${method.name}`, (value) => Buffer.from(method.I.toBinary(value, this._binaryOptions)), (value) => method.O.fromBinary(value, this._binaryOptions), input, metadata2, options, callback);
143650
+ }
143651
+ /**
143652
+ * EXPERIMENTAL: CountRelationships returns the count of relationships for *pre-registered* filter.
143653
+ *
143654
+ * @generated from protobuf rpc: ExperimentalCountRelationships(authzed.api.v1.ExperimentalCountRelationshipsRequest) returns (authzed.api.v1.ExperimentalCountRelationshipsResponse);
143655
+ */
143656
+ experimentalCountRelationships(input, metadata2, options, callback) {
143657
+ const method = ExperimentalService.methods[8];
143658
+ return this.makeUnaryRequest(`/${ExperimentalService.typeName}/${method.name}`, (value) => Buffer.from(method.I.toBinary(value, this._binaryOptions)), (value) => method.O.fromBinary(value, this._binaryOptions), input, metadata2, options, callback);
143659
+ }
143660
+ /**
143661
+ * EXPERIMENTAL: UnregisterRelationshipCounter unregisters an existing filter for counting relationships.
143662
+ *
143663
+ * @generated from protobuf rpc: ExperimentalUnregisterRelationshipCounter(authzed.api.v1.ExperimentalUnregisterRelationshipCounterRequest) returns (authzed.api.v1.ExperimentalUnregisterRelationshipCounterResponse);
143664
+ */
143665
+ experimentalUnregisterRelationshipCounter(input, metadata2, options, callback) {
143666
+ const method = ExperimentalService.methods[9];
143667
+ return this.makeUnaryRequest(`/${ExperimentalService.typeName}/${method.name}`, (value) => Buffer.from(method.I.toBinary(value, this._binaryOptions)), (value) => method.O.fromBinary(value, this._binaryOptions), input, metadata2, options, callback);
143668
+ }
143669
+ };
143412
143670
 
143413
143671
  // ../node_modules/.pnpm/@authzed+authzed-node@1.6.1/node_modules/@authzed/authzed-node/dist/src/authzedapi/authzed/api/v1/permission_service.grpc-client.js
143414
143672
  var grpc2 = __toESM(require_src3(), 1);
143673
+ var PermissionsServiceClient = class extends grpc2.Client {
143674
+ static {
143675
+ __name(this, "PermissionsServiceClient");
143676
+ }
143677
+ _binaryOptions;
143678
+ constructor(address, credentials2, options = {}, binaryOptions = {}) {
143679
+ super(address, credentials2, options);
143680
+ this._binaryOptions = binaryOptions;
143681
+ }
143682
+ /**
143683
+ * ReadRelationships reads a set of the relationships matching one or more
143684
+ * filters.
143685
+ *
143686
+ * @generated from protobuf rpc: ReadRelationships(authzed.api.v1.ReadRelationshipsRequest) returns (stream authzed.api.v1.ReadRelationshipsResponse);
143687
+ */
143688
+ readRelationships(input, metadata2, options) {
143689
+ const method = PermissionsService.methods[0];
143690
+ return this.makeServerStreamRequest(`/${PermissionsService.typeName}/${method.name}`, (value) => Buffer.from(method.I.toBinary(value, this._binaryOptions)), (value) => method.O.fromBinary(value, this._binaryOptions), input, metadata2, options);
143691
+ }
143692
+ /**
143693
+ * WriteRelationships atomically writes and/or deletes a set of specified
143694
+ * relationships. An optional set of preconditions can be provided that must
143695
+ * be satisfied for the operation to commit.
143696
+ *
143697
+ * @generated from protobuf rpc: WriteRelationships(authzed.api.v1.WriteRelationshipsRequest) returns (authzed.api.v1.WriteRelationshipsResponse);
143698
+ */
143699
+ writeRelationships(input, metadata2, options, callback) {
143700
+ const method = PermissionsService.methods[1];
143701
+ return this.makeUnaryRequest(`/${PermissionsService.typeName}/${method.name}`, (value) => Buffer.from(method.I.toBinary(value, this._binaryOptions)), (value) => method.O.fromBinary(value, this._binaryOptions), input, metadata2, options, callback);
143702
+ }
143703
+ /**
143704
+ * DeleteRelationships atomically bulk deletes all relationships matching the
143705
+ * provided filter. If no relationships match, none will be deleted and the
143706
+ * operation will succeed. An optional set of preconditions can be provided that must
143707
+ * be satisfied for the operation to commit.
143708
+ *
143709
+ * @generated from protobuf rpc: DeleteRelationships(authzed.api.v1.DeleteRelationshipsRequest) returns (authzed.api.v1.DeleteRelationshipsResponse);
143710
+ */
143711
+ deleteRelationships(input, metadata2, options, callback) {
143712
+ const method = PermissionsService.methods[2];
143713
+ return this.makeUnaryRequest(`/${PermissionsService.typeName}/${method.name}`, (value) => Buffer.from(method.I.toBinary(value, this._binaryOptions)), (value) => method.O.fromBinary(value, this._binaryOptions), input, metadata2, options, callback);
143714
+ }
143715
+ /**
143716
+ * CheckPermission determines for a given resource whether a subject computes
143717
+ * to having a permission or is a direct member of a particular relation.
143718
+ *
143719
+ * @generated from protobuf rpc: CheckPermission(authzed.api.v1.CheckPermissionRequest) returns (authzed.api.v1.CheckPermissionResponse);
143720
+ */
143721
+ checkPermission(input, metadata2, options, callback) {
143722
+ const method = PermissionsService.methods[3];
143723
+ return this.makeUnaryRequest(`/${PermissionsService.typeName}/${method.name}`, (value) => Buffer.from(method.I.toBinary(value, this._binaryOptions)), (value) => method.O.fromBinary(value, this._binaryOptions), input, metadata2, options, callback);
143724
+ }
143725
+ /**
143726
+ * CheckBulkPermissions evaluates the given list of permission checks
143727
+ * and returns the list of results.
143728
+ *
143729
+ * @generated from protobuf rpc: CheckBulkPermissions(authzed.api.v1.CheckBulkPermissionsRequest) returns (authzed.api.v1.CheckBulkPermissionsResponse);
143730
+ */
143731
+ checkBulkPermissions(input, metadata2, options, callback) {
143732
+ const method = PermissionsService.methods[4];
143733
+ return this.makeUnaryRequest(`/${PermissionsService.typeName}/${method.name}`, (value) => Buffer.from(method.I.toBinary(value, this._binaryOptions)), (value) => method.O.fromBinary(value, this._binaryOptions), input, metadata2, options, callback);
143734
+ }
143735
+ /**
143736
+ * ExpandPermissionTree reveals the graph structure for a resource's
143737
+ * permission or relation. This RPC does not recurse infinitely deep and may
143738
+ * require multiple calls to fully unnest a deeply nested graph.
143739
+ *
143740
+ * @generated from protobuf rpc: ExpandPermissionTree(authzed.api.v1.ExpandPermissionTreeRequest) returns (authzed.api.v1.ExpandPermissionTreeResponse);
143741
+ */
143742
+ expandPermissionTree(input, metadata2, options, callback) {
143743
+ const method = PermissionsService.methods[5];
143744
+ return this.makeUnaryRequest(`/${PermissionsService.typeName}/${method.name}`, (value) => Buffer.from(method.I.toBinary(value, this._binaryOptions)), (value) => method.O.fromBinary(value, this._binaryOptions), input, metadata2, options, callback);
143745
+ }
143746
+ /**
143747
+ * LookupResources returns all the resources of a given type that a subject
143748
+ * can access whether via a computed permission or relation membership.
143749
+ *
143750
+ * @generated from protobuf rpc: LookupResources(authzed.api.v1.LookupResourcesRequest) returns (stream authzed.api.v1.LookupResourcesResponse);
143751
+ */
143752
+ lookupResources(input, metadata2, options) {
143753
+ const method = PermissionsService.methods[6];
143754
+ return this.makeServerStreamRequest(`/${PermissionsService.typeName}/${method.name}`, (value) => Buffer.from(method.I.toBinary(value, this._binaryOptions)), (value) => method.O.fromBinary(value, this._binaryOptions), input, metadata2, options);
143755
+ }
143756
+ /**
143757
+ * LookupSubjects returns all the subjects of a given type that
143758
+ * have access whether via a computed permission or relation membership.
143759
+ *
143760
+ * @generated from protobuf rpc: LookupSubjects(authzed.api.v1.LookupSubjectsRequest) returns (stream authzed.api.v1.LookupSubjectsResponse);
143761
+ */
143762
+ lookupSubjects(input, metadata2, options) {
143763
+ const method = PermissionsService.methods[7];
143764
+ return this.makeServerStreamRequest(`/${PermissionsService.typeName}/${method.name}`, (value) => Buffer.from(method.I.toBinary(value, this._binaryOptions)), (value) => method.O.fromBinary(value, this._binaryOptions), input, metadata2, options);
143765
+ }
143766
+ /**
143767
+ * ImportBulkRelationships is a faster path to writing a large number of
143768
+ * relationships at once. It is both batched and streaming. For maximum
143769
+ * performance, the caller should attempt to write relationships in as close
143770
+ * to relationship sort order as possible: (resource.object_type,
143771
+ * resource.object_id, relation, subject.object.object_type,
143772
+ * subject.object.object_id, subject.optional_relation). All relationships
143773
+ * written are done so under a single transaction.
143774
+ *
143775
+ * @generated from protobuf rpc: ImportBulkRelationships(stream authzed.api.v1.ImportBulkRelationshipsRequest) returns (authzed.api.v1.ImportBulkRelationshipsResponse);
143776
+ */
143777
+ importBulkRelationships(metadata2, options, callback) {
143778
+ const method = PermissionsService.methods[8];
143779
+ return this.makeClientStreamRequest(`/${PermissionsService.typeName}/${method.name}`, (value) => Buffer.from(method.I.toBinary(value, this._binaryOptions)), (value) => method.O.fromBinary(value, this._binaryOptions), metadata2, options, callback);
143780
+ }
143781
+ /**
143782
+ * ExportBulkRelationships is the fastest path available to exporting
143783
+ * relationships from the server. It is resumable, and will return results
143784
+ * in an order determined by the server.
143785
+ *
143786
+ * @generated from protobuf rpc: ExportBulkRelationships(authzed.api.v1.ExportBulkRelationshipsRequest) returns (stream authzed.api.v1.ExportBulkRelationshipsResponse);
143787
+ */
143788
+ exportBulkRelationships(input, metadata2, options) {
143789
+ const method = PermissionsService.methods[9];
143790
+ return this.makeServerStreamRequest(`/${PermissionsService.typeName}/${method.name}`, (value) => Buffer.from(method.I.toBinary(value, this._binaryOptions)), (value) => method.O.fromBinary(value, this._binaryOptions), input, metadata2, options);
143791
+ }
143792
+ };
143415
143793
 
143416
143794
  // ../node_modules/.pnpm/@authzed+authzed-node@1.6.1/node_modules/@authzed/authzed-node/dist/src/authzedapi/authzed/api/v1/schema_service.js
143417
143795
  var import_runtime_rpc3 = __toESM(require_commonjs2(), 1);
@@ -145462,6 +145840,81 @@ var SchemaService = new import_runtime_rpc3.ServiceType("authzed.api.v1.SchemaSe
145462
145840
 
145463
145841
  // ../node_modules/.pnpm/@authzed+authzed-node@1.6.1/node_modules/@authzed/authzed-node/dist/src/authzedapi/authzed/api/v1/schema_service.grpc-client.js
145464
145842
  var grpc3 = __toESM(require_src3(), 1);
145843
+ var SchemaServiceClient = class extends grpc3.Client {
145844
+ static {
145845
+ __name(this, "SchemaServiceClient");
145846
+ }
145847
+ _binaryOptions;
145848
+ constructor(address, credentials2, options = {}, binaryOptions = {}) {
145849
+ super(address, credentials2, options);
145850
+ this._binaryOptions = binaryOptions;
145851
+ }
145852
+ /**
145853
+ * Read returns the current Object Definitions for a Permissions System.
145854
+ *
145855
+ * Errors include:
145856
+ * - INVALID_ARGUMENT: a provided value has failed to semantically validate
145857
+ * - NOT_FOUND: no schema has been defined
145858
+ *
145859
+ * @generated from protobuf rpc: ReadSchema(authzed.api.v1.ReadSchemaRequest) returns (authzed.api.v1.ReadSchemaResponse);
145860
+ */
145861
+ readSchema(input, metadata2, options, callback) {
145862
+ const method = SchemaService.methods[0];
145863
+ return this.makeUnaryRequest(`/${SchemaService.typeName}/${method.name}`, (value) => Buffer.from(method.I.toBinary(value, this._binaryOptions)), (value) => method.O.fromBinary(value, this._binaryOptions), input, metadata2, options, callback);
145864
+ }
145865
+ /**
145866
+ * Write overwrites the current Object Definitions for a Permissions System.
145867
+ *
145868
+ * @generated from protobuf rpc: WriteSchema(authzed.api.v1.WriteSchemaRequest) returns (authzed.api.v1.WriteSchemaResponse);
145869
+ */
145870
+ writeSchema(input, metadata2, options, callback) {
145871
+ const method = SchemaService.methods[1];
145872
+ return this.makeUnaryRequest(`/${SchemaService.typeName}/${method.name}`, (value) => Buffer.from(method.I.toBinary(value, this._binaryOptions)), (value) => method.O.fromBinary(value, this._binaryOptions), input, metadata2, options, callback);
145873
+ }
145874
+ /**
145875
+ * ReflectSchema reflects the current schema stored in SpiceDB, returning a structural
145876
+ * form of the schema for use by client tooling.
145877
+ *
145878
+ * @generated from protobuf rpc: ReflectSchema(authzed.api.v1.ReflectSchemaRequest) returns (authzed.api.v1.ReflectSchemaResponse);
145879
+ */
145880
+ reflectSchema(input, metadata2, options, callback) {
145881
+ const method = SchemaService.methods[2];
145882
+ return this.makeUnaryRequest(`/${SchemaService.typeName}/${method.name}`, (value) => Buffer.from(method.I.toBinary(value, this._binaryOptions)), (value) => method.O.fromBinary(value, this._binaryOptions), input, metadata2, options, callback);
145883
+ }
145884
+ /**
145885
+ * ComputablePermissions returns the set of permissions that compute based off a relation
145886
+ * in the current schema. For example, if the schema has a relation `viewer` and a permission
145887
+ * `view` defined as `permission view = viewer + editor`, then the
145888
+ * computable permissions for the relation `viewer` will include `view`.
145889
+ *
145890
+ * @generated from protobuf rpc: ComputablePermissions(authzed.api.v1.ComputablePermissionsRequest) returns (authzed.api.v1.ComputablePermissionsResponse);
145891
+ */
145892
+ computablePermissions(input, metadata2, options, callback) {
145893
+ const method = SchemaService.methods[3];
145894
+ return this.makeUnaryRequest(`/${SchemaService.typeName}/${method.name}`, (value) => Buffer.from(method.I.toBinary(value, this._binaryOptions)), (value) => method.O.fromBinary(value, this._binaryOptions), input, metadata2, options, callback);
145895
+ }
145896
+ /**
145897
+ * DependentRelations returns the set of relations and permissions that used
145898
+ * to compute a permission, recursively, in the current schema. It is the
145899
+ * inverse of the ComputablePermissions API.
145900
+ *
145901
+ * @generated from protobuf rpc: DependentRelations(authzed.api.v1.DependentRelationsRequest) returns (authzed.api.v1.DependentRelationsResponse);
145902
+ */
145903
+ dependentRelations(input, metadata2, options, callback) {
145904
+ const method = SchemaService.methods[4];
145905
+ return this.makeUnaryRequest(`/${SchemaService.typeName}/${method.name}`, (value) => Buffer.from(method.I.toBinary(value, this._binaryOptions)), (value) => method.O.fromBinary(value, this._binaryOptions), input, metadata2, options, callback);
145906
+ }
145907
+ /**
145908
+ * DiffSchema returns the difference between the specified schema and the current
145909
+ * schema stored in SpiceDB.
145910
+ *
145911
+ * @generated from protobuf rpc: DiffSchema(authzed.api.v1.DiffSchemaRequest) returns (authzed.api.v1.DiffSchemaResponse);
145912
+ */
145913
+ diffSchema(input, metadata2, options, callback) {
145914
+ const method = SchemaService.methods[5];
145915
+ return this.makeUnaryRequest(`/${SchemaService.typeName}/${method.name}`, (value) => Buffer.from(method.I.toBinary(value, this._binaryOptions)), (value) => method.O.fromBinary(value, this._binaryOptions), input, metadata2, options, callback);
145916
+ }
145917
+ };
145465
145918
 
145466
145919
  // ../node_modules/.pnpm/@authzed+authzed-node@1.6.1/node_modules/@authzed/authzed-node/dist/src/authzedapi/authzed/api/v1/watch_service.js
145467
145920
  var import_runtime_rpc4 = __toESM(require_commonjs2(), 1);
@@ -145734,6 +146187,26 @@ var WatchService = new import_runtime_rpc4.ServiceType("authzed.api.v1.WatchServ
145734
146187
 
145735
146188
  // ../node_modules/.pnpm/@authzed+authzed-node@1.6.1/node_modules/@authzed/authzed-node/dist/src/authzedapi/authzed/api/v1/watch_service.grpc-client.js
145736
146189
  var grpc4 = __toESM(require_src3(), 1);
146190
+ var WatchServiceClient = class extends grpc4.Client {
146191
+ static {
146192
+ __name(this, "WatchServiceClient");
146193
+ }
146194
+ _binaryOptions;
146195
+ constructor(address, credentials2, options = {}, binaryOptions = {}) {
146196
+ super(address, credentials2, options);
146197
+ this._binaryOptions = binaryOptions;
146198
+ }
146199
+ /**
146200
+ * Watch returns a stream of events that occurred in the datastore in ascending timestamp order.
146201
+ * The events can be relationship updates, schema updates, or checkpoints.
146202
+ *
146203
+ * @generated from protobuf rpc: Watch(authzed.api.v1.WatchRequest) returns (stream authzed.api.v1.WatchResponse);
146204
+ */
146205
+ watch(input, metadata2, options) {
146206
+ const method = WatchService.methods[0];
146207
+ return this.makeServerStreamRequest(`/${WatchService.typeName}/${method.name}`, (value) => Buffer.from(method.I.toBinary(value, this._binaryOptions)), (value) => method.O.fromBinary(value, this._binaryOptions), input, metadata2, options);
146208
+ }
146209
+ };
145737
146210
 
145738
146211
  // ../node_modules/.pnpm/@authzed+authzed-node@1.6.1/node_modules/@authzed/authzed-node/dist/src/authzedapi/authzed/api/materialize/v0/watchpermissions.js
145739
146212
  var import_runtime_rpc5 = __toESM(require_commonjs2(), 1);
@@ -146088,6 +146561,39 @@ var WatchPermissionsService = new import_runtime_rpc5.ServiceType("authzed.api.m
146088
146561
 
146089
146562
  // ../node_modules/.pnpm/@authzed+authzed-node@1.6.1/node_modules/@authzed/authzed-node/dist/src/authzedapi/authzed/api/materialize/v0/watchpermissions.grpc-client.js
146090
146563
  var grpc5 = __toESM(require_src3(), 1);
146564
+ var WatchPermissionsServiceClient = class extends grpc5.Client {
146565
+ static {
146566
+ __name(this, "WatchPermissionsServiceClient");
146567
+ }
146568
+ _binaryOptions;
146569
+ constructor(address, credentials2, options = {}, binaryOptions = {}) {
146570
+ super(address, credentials2, options);
146571
+ this._binaryOptions = binaryOptions;
146572
+ }
146573
+ /**
146574
+ * WatchPermissions returns a stream of PermissionChange events for the given permissions.
146575
+ *
146576
+ * WatchPermissions is a long-running RPC, and will stream events until the client
146577
+ * closes the connection or the server terminates the stream. The consumer is responsible of
146578
+ * keeping track of the last seen revision and resuming the stream from that point in the event
146579
+ * of disconnection or client-side restarts.
146580
+ *
146581
+ * The API does not offer a sharding mechanism and thus there should only be one consumer per target system.
146582
+ * Implementing an active-active HA consumer setup over the same target system will require coordinating which
146583
+ * revisions have been consumed in order to prevent transitioning to an inconsistent state.
146584
+ *
146585
+ * Usage of WatchPermissions requires to be explicitly enabled on the service, including the permissions to be
146586
+ * watched. It requires more resources and is less performant than WatchPermissionsSets. It's usage
146587
+ * is only recommended when performing the set intersections of WatchPermissionSets in the client side is not viable
146588
+ * or there is a strict application requirement to use consume the computed permissions.
146589
+ *
146590
+ * @generated from protobuf rpc: WatchPermissions(authzed.api.materialize.v0.WatchPermissionsRequest) returns (stream authzed.api.materialize.v0.WatchPermissionsResponse);
146591
+ */
146592
+ watchPermissions(input, metadata2, options) {
146593
+ const method = WatchPermissionsService.methods[0];
146594
+ return this.makeServerStreamRequest(`/${WatchPermissionsService.typeName}/${method.name}`, (value) => Buffer.from(method.I.toBinary(value, this._binaryOptions)), (value) => method.O.fromBinary(value, this._binaryOptions), input, metadata2, options);
146595
+ }
146596
+ };
146091
146597
 
146092
146598
  // ../node_modules/.pnpm/@authzed+authzed-node@1.6.1/node_modules/@authzed/authzed-node/dist/src/authzedapi/authzed/api/materialize/v0/watchpermissionsets.js
146093
146599
  var import_runtime_rpc6 = __toESM(require_commonjs2(), 1);
@@ -147057,9 +147563,164 @@ var WatchPermissionSetsService = new import_runtime_rpc6.ServiceType("authzed.ap
147057
147563
 
147058
147564
  // ../node_modules/.pnpm/@authzed+authzed-node@1.6.1/node_modules/@authzed/authzed-node/dist/src/authzedapi/authzed/api/materialize/v0/watchpermissionsets.grpc-client.js
147059
147565
  var grpc6 = __toESM(require_src3(), 1);
147566
+ var WatchPermissionSetsServiceClient = class extends grpc6.Client {
147567
+ static {
147568
+ __name(this, "WatchPermissionSetsServiceClient");
147569
+ }
147570
+ _binaryOptions;
147571
+ constructor(address, credentials2, options = {}, binaryOptions = {}) {
147572
+ super(address, credentials2, options);
147573
+ this._binaryOptions = binaryOptions;
147574
+ }
147575
+ /**
147576
+ * WatchPermissionSets returns a stream of changes to the sets which can be used to compute the watched permissions.
147577
+ *
147578
+ * WatchPermissionSets lets consumers achieve the same thing as WatchPermissions, but trades off a simpler usage model with
147579
+ * significantly lower computational requirements. Unlike WatchPermissions, this method returns changes to the sets of permissions,
147580
+ * rather than the individual permissions. Permission sets are a normalized form of the computed permissions, which
147581
+ * means that the consumer must perform an extra computation over this representation to obtain the final computed
147582
+ * permissions, typically by intersecting the provided sets.
147583
+ *
147584
+ * For example, this would look like a JOIN between the
147585
+ * materialize permission sets table in a target relation database, the table with the resources to authorize access
147586
+ * to, and the table with the subject (e.g. a user).
147587
+ *
147588
+ * In exchange, the number of changes issued by WatchPermissionSets will be several orders of magnitude less than those
147589
+ * emitted by WatchPermissions, which has several implications:
147590
+ * - significantly less resources to compute the sets
147591
+ * - significantly less messages to stream over the network
147592
+ * - significantly less events to ingest on the consumer side
147593
+ * - less ingestion lag from the origin SpiceDB mutation
147594
+ *
147595
+ * The type of scenarios WatchPermissionSets is particularly well suited is when a single change
147596
+ * in the origin SpiceDB can yield millions of changes. For example, in the GitHub authorization model, assigning a role
147597
+ * to a top-level team of an organization with hundreds of thousands of employees can lead to an explosion of
147598
+ * permission change events that would require a lot of computational resources to process, both on Materialize and
147599
+ * the consumer side.
147600
+ *
147601
+ * WatchPermissionSets is thus recommended for any larger scale use case where the fan-out in permission changes that
147602
+ * emerges from a specific schema and data shape is too large to handle effectively.
147603
+ *
147604
+ * The API does not offer a sharding mechanism and thus there should only be one consumer per target system.
147605
+ * Implementing an active-active HA consumer setup over the same target system will require coordinating which
147606
+ * revisions have been consumed in order to prevent transitioning to an inconsistent state.
147607
+ *
147608
+ * @generated from protobuf rpc: WatchPermissionSets(authzed.api.materialize.v0.WatchPermissionSetsRequest) returns (stream authzed.api.materialize.v0.WatchPermissionSetsResponse);
147609
+ */
147610
+ watchPermissionSets(input, metadata2, options) {
147611
+ const method = WatchPermissionSetsService.methods[0];
147612
+ return this.makeServerStreamRequest(`/${WatchPermissionSetsService.typeName}/${method.name}`, (value) => Buffer.from(method.I.toBinary(value, this._binaryOptions)), (value) => method.O.fromBinary(value, this._binaryOptions), input, metadata2, options);
147613
+ }
147614
+ /**
147615
+ * LookupPermissionSets returns the current state of the permission sets which can be used to derive the computed permissions.
147616
+ * It's typically used to backfill the state of the permission sets in the consumer side.
147617
+ *
147618
+ * It's a cursored API and the consumer is responsible to keep track of the cursor and use it on each subsequent call.
147619
+ * Each stream will return <N> permission sets defined by the specified request limit. The server will keep streaming until
147620
+ * the sets per stream is hit, or the current state of the sets is reached,
147621
+ * whatever happens first, and then close the stream. The server will indicate there are no more changes to stream
147622
+ * through the `completed_members` in the cursor.
147623
+ *
147624
+ * There may be many elements to stream, and so the consumer should be prepared to resume the stream from the last
147625
+ * cursor received. Once completed, the consumer may start streaming permission set changes using WatchPermissionSets
147626
+ * and the revision token from the last LookupPermissionSets response.
147627
+ *
147628
+ * @generated from protobuf rpc: LookupPermissionSets(authzed.api.materialize.v0.LookupPermissionSetsRequest) returns (stream authzed.api.materialize.v0.LookupPermissionSetsResponse);
147629
+ */
147630
+ lookupPermissionSets(input, metadata2, options) {
147631
+ const method = WatchPermissionSetsService.methods[1];
147632
+ return this.makeServerStreamRequest(`/${WatchPermissionSetsService.typeName}/${method.name}`, (value) => Buffer.from(method.I.toBinary(value, this._binaryOptions)), (value) => method.O.fromBinary(value, this._binaryOptions), input, metadata2, options);
147633
+ }
147634
+ /**
147635
+ * DownloadPermissionSets returns URLs to download permission sets data as Avro files.
147636
+ * This provides an alternative to LookupPermissionSets for customers who need to download
147637
+ * large datasets efficiently. The returned URLs point to compressed Avro files containing
147638
+ * the permission sets data in a normalized format.
147639
+ *
147640
+ * @generated from protobuf rpc: DownloadPermissionSets(authzed.api.materialize.v0.DownloadPermissionSetsRequest) returns (authzed.api.materialize.v0.DownloadPermissionSetsResponse);
147641
+ */
147642
+ downloadPermissionSets(input, metadata2, options, callback) {
147643
+ const method = WatchPermissionSetsService.methods[2];
147644
+ return this.makeUnaryRequest(`/${WatchPermissionSetsService.typeName}/${method.name}`, (value) => Buffer.from(method.I.toBinary(value, this._binaryOptions)), (value) => method.O.fromBinary(value, this._binaryOptions), input, metadata2, options, callback);
147645
+ }
147646
+ };
147060
147647
 
147061
147648
  // ../node_modules/.pnpm/@authzed+authzed-node@1.6.1/node_modules/@authzed/authzed-node/dist/src/util.js
147062
147649
  var grpc7 = __toESM(require_src3(), 1);
147650
+ var ComposedChannelCredentials = class _ComposedChannelCredentials extends grpc7.ChannelCredentials {
147651
+ static {
147652
+ __name(this, "ComposedChannelCredentials");
147653
+ }
147654
+ channelCredentials;
147655
+ callCreds;
147656
+ constructor(channelCredentials, callCreds) {
147657
+ super();
147658
+ this.channelCredentials = channelCredentials;
147659
+ this.callCreds = callCreds;
147660
+ }
147661
+ compose(callCredentials) {
147662
+ const combinedCallCredentials = this.callCreds.compose(callCredentials);
147663
+ return new _ComposedChannelCredentials(this.channelCredentials, combinedCallCredentials);
147664
+ }
147665
+ _isSecure() {
147666
+ return false;
147667
+ }
147668
+ // NOTE: this is copied from the InsecureChannelCredentialsImpl class
147669
+ _createSecureConnector(channelTarget, options, callCredentials) {
147670
+ return {
147671
+ connect: /* @__PURE__ */ __name(async (socket) => {
147672
+ return {
147673
+ socket,
147674
+ secure: false
147675
+ };
147676
+ }, "connect"),
147677
+ waitForReady: /* @__PURE__ */ __name(async () => {
147678
+ }, "waitForReady"),
147679
+ getCallCredentials: /* @__PURE__ */ __name(() => callCredentials || this.callCreds, "getCallCredentials"),
147680
+ destroy: /* @__PURE__ */ __name(() => {
147681
+ }, "destroy")
147682
+ };
147683
+ }
147684
+ _equals(other) {
147685
+ if (this === other) {
147686
+ return true;
147687
+ }
147688
+ if (other instanceof _ComposedChannelCredentials) {
147689
+ return this.channelCredentials._equals(other.channelCredentials) && this.callCreds._equals(other.callCreds);
147690
+ } else {
147691
+ return false;
147692
+ }
147693
+ }
147694
+ };
147695
+ var KnownInsecureChannelCredentialsImpl = class _KnownInsecureChannelCredentialsImpl extends grpc7.ChannelCredentials {
147696
+ static {
147697
+ __name(this, "KnownInsecureChannelCredentialsImpl");
147698
+ }
147699
+ compose(callCredentials) {
147700
+ return new ComposedChannelCredentials(this, callCredentials);
147701
+ }
147702
+ _isSecure() {
147703
+ return false;
147704
+ }
147705
+ _equals(other) {
147706
+ return other instanceof _KnownInsecureChannelCredentialsImpl;
147707
+ }
147708
+ _createSecureConnector(channelTarget, options, callCredentials) {
147709
+ return {
147710
+ connect: /* @__PURE__ */ __name(async (socket) => {
147711
+ return {
147712
+ socket,
147713
+ secure: false
147714
+ };
147715
+ }, "connect"),
147716
+ waitForReady: /* @__PURE__ */ __name(async () => {
147717
+ }, "waitForReady"),
147718
+ getCallCredentials: /* @__PURE__ */ __name(() => callCredentials, "getCallCredentials"),
147719
+ destroy: /* @__PURE__ */ __name(() => {
147720
+ }, "destroy")
147721
+ };
147722
+ }
147723
+ };
147063
147724
  var ClientSecurity;
147064
147725
  (function(ClientSecurity2) {
147065
147726
  ClientSecurity2[ClientSecurity2["SECURE"] = 0] = "SECURE";
@@ -147076,6 +147737,61 @@ var PreconnectServices;
147076
147737
  PreconnectServices2[PreconnectServices2["WATCH_PERMISSIONS_SERVICE"] = 9] = "WATCH_PERMISSIONS_SERVICE";
147077
147738
  PreconnectServices2[PreconnectServices2["WATCH_PERMISSIONSETS_SERVICE"] = 10] = "WATCH_PERMISSIONSETS_SERVICE";
147078
147739
  })(PreconnectServices || (PreconnectServices = {}));
147740
+ function createClientCreds(endpoint, token, security = ClientSecurity.SECURE) {
147741
+ const metadata2 = new grpc7.Metadata();
147742
+ metadata2.set("authorization", "Bearer " + token);
147743
+ const creds = [];
147744
+ if (security === ClientSecurity.SECURE || security === ClientSecurity.INSECURE_PLAINTEXT_CREDENTIALS || security === ClientSecurity.INSECURE_LOCALHOST_ALLOWED && endpoint.startsWith("localhost:")) {
147745
+ creds.push(grpc7.credentials.createFromMetadataGenerator((_3, callback) => {
147746
+ callback(null, metadata2);
147747
+ }));
147748
+ }
147749
+ return grpc7.credentials.combineChannelCredentials(security === ClientSecurity.SECURE ? grpc7.credentials.createSsl() : new KnownInsecureChannelCredentialsImpl(), ...creds);
147750
+ }
147751
+ __name(createClientCreds, "createClientCreds");
147752
+ function createClientCredsWithCustomCert(token, certificate) {
147753
+ const metadata2 = new grpc7.Metadata();
147754
+ metadata2.set("authorization", "Bearer " + token);
147755
+ const creds = [];
147756
+ creds.push(grpc7.credentials.createFromMetadataGenerator((_3, callback) => {
147757
+ callback(null, metadata2);
147758
+ }));
147759
+ return grpc7.credentials.combineChannelCredentials(grpc7.credentials.createSsl(certificate), ...creds);
147760
+ }
147761
+ __name(createClientCredsWithCustomCert, "createClientCredsWithCustomCert");
147762
+ function promisifyStream(fn2, bind2) {
147763
+ return (req) => {
147764
+ return new Promise((resolve4, reject) => {
147765
+ const results = [];
147766
+ const stream4 = fn2.bind(bind2)(req);
147767
+ stream4.on("data", function(response) {
147768
+ results.push(response);
147769
+ });
147770
+ stream4.on("error", function(e) {
147771
+ return reject(e);
147772
+ });
147773
+ stream4.on("end", function() {
147774
+ return resolve4(results);
147775
+ });
147776
+ stream4.on("status", function(status2) {
147777
+ if (status2.code !== grpc7.status.OK) {
147778
+ return reject(status2);
147779
+ }
147780
+ });
147781
+ });
147782
+ };
147783
+ }
147784
+ __name(promisifyStream, "promisifyStream");
147785
+ function deadlineInterceptor(timeoutInMS) {
147786
+ return (options, nextCall) => {
147787
+ if (!options.deadline) {
147788
+ options.deadline = Date.now() + (timeoutInMS ? timeoutInMS : 6e4);
147789
+ }
147790
+ return new grpc7.InterceptingCall(nextCall(options));
147791
+ };
147792
+ }
147793
+ __name(deadlineInterceptor, "deadlineInterceptor");
147794
+ var authzedEndpoint = "grpc.authzed.com:443";
147079
147795
 
147080
147796
  // ../node_modules/.pnpm/@authzed+authzed-node@1.6.1/node_modules/@authzed/authzed-node/dist/src/authzedapi/authzed/api/v1/error_reason.js
147081
147797
  var ErrorReason;
@@ -147114,6 +147830,208 @@ var ErrorReason;
147114
147830
 
147115
147831
  // ../node_modules/.pnpm/@authzed+authzed-node@1.6.1/node_modules/@authzed/authzed-node/dist/src/v1.js
147116
147832
  var DEFAULT_DEADLINE_MS = 30 * 1e3;
147833
+ var ZedClient = class _ZedClient {
147834
+ static {
147835
+ __name(this, "ZedClient");
147836
+ }
147837
+ endpoint;
147838
+ creds;
147839
+ acl;
147840
+ ns;
147841
+ watch;
147842
+ experimental;
147843
+ watchPermissions;
147844
+ watchPermissionSets;
147845
+ options;
147846
+ constructor(endpoint, creds, preconnect, options) {
147847
+ this.endpoint = endpoint;
147848
+ this.creds = creds;
147849
+ this.options = {
147850
+ ...options ?? {},
147851
+ interceptors: [
147852
+ ...options?.interceptors ?? [],
147853
+ // We put this interceptor last because it checks if the deadline is already
147854
+ // set and, if so, does not overwrite it.
147855
+ deadlineInterceptor(DEFAULT_DEADLINE_MS)
147856
+ ]
147857
+ };
147858
+ if (preconnect & PreconnectServices.PERMISSIONS_SERVICE) {
147859
+ this.acl = new PermissionsServiceClient(this.endpoint, this.creds, options);
147860
+ }
147861
+ if (preconnect & PreconnectServices.SCHEMA_SERVICE) {
147862
+ this.ns = new SchemaServiceClient(this.endpoint, this.creds, options);
147863
+ }
147864
+ if (preconnect & PreconnectServices.WATCH_SERVICE) {
147865
+ this.watch = new WatchServiceClient(this.endpoint, this.creds, options);
147866
+ }
147867
+ if (preconnect & PreconnectServices.WATCH_PERMISSIONS_SERVICE) {
147868
+ this.watchPermissions = new WatchPermissionsServiceClient(this.endpoint, this.creds, options);
147869
+ }
147870
+ if (preconnect & PreconnectServices.WATCH_PERMISSIONSETS_SERVICE) {
147871
+ this.watchPermissionSets = new WatchPermissionSetsServiceClient(this.endpoint, this.creds, options);
147872
+ }
147873
+ if (preconnect & PreconnectServices.EXPERIMENTAL_SERVICE) {
147874
+ this.experimental = new ExperimentalServiceClient(this.endpoint, this.creds, options);
147875
+ }
147876
+ }
147877
+ static create(endpoint, creds, preconnect, options) {
147878
+ return new Proxy({}, new _ZedClient(endpoint, creds, preconnect, options));
147879
+ }
147880
+ close = /* @__PURE__ */ __name(() => {
147881
+ [
147882
+ this.acl,
147883
+ this.ns,
147884
+ this.watch,
147885
+ this.experimental,
147886
+ this.watchPermissions,
147887
+ this.watchPermissionSets
147888
+ ].forEach((client) => client?.close());
147889
+ }, "close");
147890
+ get(_target, name18) {
147891
+ if (name18 === "close") {
147892
+ return this.close;
147893
+ }
147894
+ if (typeof name18 === "symbol") {
147895
+ if (this.acl === void 0) {
147896
+ this.acl = new PermissionsServiceClient(this.endpoint, this.creds, this.options);
147897
+ }
147898
+ return this.acl[name18];
147899
+ }
147900
+ if (name18 in PermissionsServiceClient.prototype) {
147901
+ if (this.acl === void 0) {
147902
+ this.acl = new PermissionsServiceClient(this.endpoint, this.creds, this.options);
147903
+ }
147904
+ return this.acl[name18];
147905
+ }
147906
+ if (name18 in SchemaServiceClient.prototype) {
147907
+ if (this.ns === void 0) {
147908
+ this.ns = new SchemaServiceClient(this.endpoint, this.creds, this.options);
147909
+ }
147910
+ return this.ns[name18];
147911
+ }
147912
+ if (name18 in WatchServiceClient.prototype) {
147913
+ if (this.watch === void 0) {
147914
+ this.watch = new WatchServiceClient(this.endpoint, this.creds, this.options);
147915
+ }
147916
+ return this.watch[name18];
147917
+ }
147918
+ if (name18 in WatchPermissionsServiceClient.prototype) {
147919
+ if (this.watchPermissions === void 0) {
147920
+ this.watchPermissions = new WatchPermissionsServiceClient(this.endpoint, this.creds, this.options);
147921
+ }
147922
+ return this.watchPermissions[name18];
147923
+ }
147924
+ if (name18 in WatchPermissionSetsServiceClient.prototype) {
147925
+ if (this.watchPermissionSets === void 0) {
147926
+ this.watchPermissionSets = new WatchPermissionSetsServiceClient(this.endpoint, this.creds, this.options);
147927
+ }
147928
+ return this.watchPermissionSets[name18];
147929
+ }
147930
+ if (name18 in ExperimentalServiceClient.prototype) {
147931
+ if (this.experimental === void 0) {
147932
+ this.experimental = new ExperimentalServiceClient(this.endpoint, this.creds, this.options);
147933
+ }
147934
+ return this.experimental[name18];
147935
+ }
147936
+ return void 0;
147937
+ }
147938
+ };
147939
+ var ZedPromiseClient = class _ZedPromiseClient {
147940
+ static {
147941
+ __name(this, "ZedPromiseClient");
147942
+ }
147943
+ client;
147944
+ promiseCache = {};
147945
+ streamMethods = /* @__PURE__ */ new Set([
147946
+ "readRelationships",
147947
+ "lookupResources",
147948
+ "lookupSubjects",
147949
+ "bulkExportRelationships",
147950
+ "exportBulkRelationships",
147951
+ "watchPermissions",
147952
+ "watchPermissionSets"
147953
+ ]);
147954
+ writableStreamMethods = /* @__PURE__ */ new Set([
147955
+ "bulkImportRelationships",
147956
+ "importBulkRelationships"
147957
+ ]);
147958
+ constructor(client) {
147959
+ this.client = client;
147960
+ }
147961
+ static create(client) {
147962
+ return new Proxy({}, new _ZedPromiseClient(client));
147963
+ }
147964
+ get(_target, name18) {
147965
+ if (!(name18 in this.promiseCache)) {
147966
+ const clientMethod = this.client[name18];
147967
+ if (clientMethod !== void 0) {
147968
+ if (this.streamMethods.has(name18)) {
147969
+ this.promiseCache[name18] = promisifyStream(clientMethod, this.client);
147970
+ } else if (this.writableStreamMethods.has(name18)) {
147971
+ this.promiseCache[name18] = clientMethod.bind(this.client);
147972
+ } else if (typeof clientMethod === "function") {
147973
+ this.promiseCache[name18] = (0, import_util3.promisify)(this.client[name18]).bind(this.client);
147974
+ } else {
147975
+ return clientMethod;
147976
+ }
147977
+ }
147978
+ }
147979
+ return this.promiseCache[name18];
147980
+ }
147981
+ };
147982
+ var ZedCombinedClient = class _ZedCombinedClient {
147983
+ static {
147984
+ __name(this, "ZedCombinedClient");
147985
+ }
147986
+ client;
147987
+ promiseClient;
147988
+ constructor(client, promiseClient) {
147989
+ this.client = client;
147990
+ this.promiseClient = promiseClient;
147991
+ }
147992
+ static create(endpoint, creds, preconnect, options) {
147993
+ const client = ZedClient.create(endpoint, creds, preconnect, options);
147994
+ const promiseClient = ZedPromiseClient.create(client);
147995
+ return new Proxy({}, new _ZedCombinedClient(client, promiseClient));
147996
+ }
147997
+ get(_target, name18) {
147998
+ if (name18 === "promises") {
147999
+ return this.promiseClient;
148000
+ }
148001
+ return this.client[name18];
148002
+ }
148003
+ };
148004
+ function NewClient(token, endpoint = authzedEndpoint, security = ClientSecurity.SECURE, preconnect = PreconnectServices.PERMISSIONS_SERVICE, options = void 0) {
148005
+ const creds = createClientCreds(endpoint, token, security);
148006
+ return NewClientWithChannelCredentials(endpoint, creds, preconnect, options);
148007
+ }
148008
+ __name(NewClient, "NewClient");
148009
+ function NewClientWithCustomCert(token, endpoint = authzedEndpoint, certificate, preconnect = PreconnectServices.PERMISSIONS_SERVICE, options = void 0) {
148010
+ const creds = createClientCredsWithCustomCert(token, certificate);
148011
+ return NewClientWithChannelCredentials(endpoint, creds, preconnect, options);
148012
+ }
148013
+ __name(NewClientWithCustomCert, "NewClientWithCustomCert");
148014
+ function NewClientWithChannelCredentials(endpoint = authzedEndpoint, creds, preconnect = PreconnectServices.PERMISSIONS_SERVICE, options = void 0) {
148015
+ return ZedCombinedClient.create(endpoint, creds, preconnect, options);
148016
+ }
148017
+ __name(NewClientWithChannelCredentials, "NewClientWithChannelCredentials");
148018
+ function createStructFromObject(data) {
148019
+ try {
148020
+ return Struct.fromJson(data);
148021
+ } catch (error46) {
148022
+ if (error46 instanceof Error && error46.message.includes("Unable to parse message google.protobuf.Struct from JSON")) {
148023
+ throw new Error("Input data for createStructFromObject must be a non-null object.");
148024
+ }
148025
+ throw error46;
148026
+ }
148027
+ }
148028
+ __name(createStructFromObject, "createStructFromObject");
148029
+ var v1_default = {
148030
+ NewClient
148031
+ };
148032
+
148033
+ // ../packages/agents-core/dist/auth/authz/client.js
148034
+ var { RelationshipUpdate_Operation: RelationshipUpdate_Operation2, CheckPermissionResponse_Permissionship: CheckPermissionResponse_Permissionship2 } = v1_exports;
147117
148035
 
147118
148036
  // ../packages/agents-core/dist/constants/execution-limits-shared/defaults.js
147119
148037
  var executionLimitsSharedDefaults = {
@@ -148582,7 +149500,7 @@ __name(buildFullPath, "buildFullPath");
148582
149500
  var import_proxy_from_env = __toESM(require_proxy_from_env(), 1);
148583
149501
  var import_http = __toESM(require("http"), 1);
148584
149502
  var import_https = __toESM(require("https"), 1);
148585
- var import_util7 = __toESM(require("util"), 1);
149503
+ var import_util8 = __toESM(require("util"), 1);
148586
149504
  var import_follow_redirects = __toESM(require_follow_redirects(), 1);
148587
149505
  var import_zlib = __toESM(require("zlib"), 1);
148588
149506
 
@@ -148755,7 +149673,7 @@ var AxiosTransformStream_default = AxiosTransformStream;
148755
149673
  var import_events = require("events");
148756
149674
 
148757
149675
  // ../node_modules/.pnpm/axios@1.12.0/node_modules/axios/lib/helpers/formDataToStream.js
148758
- var import_util6 = __toESM(require("util"), 1);
149676
+ var import_util7 = __toESM(require("util"), 1);
148759
149677
  var import_stream2 = require("stream");
148760
149678
 
148761
149679
  // ../node_modules/.pnpm/axios@1.12.0/node_modules/axios/lib/helpers/readBlob.js
@@ -148775,7 +149693,7 @@ var readBlob_default = readBlob;
148775
149693
 
148776
149694
  // ../node_modules/.pnpm/axios@1.12.0/node_modules/axios/lib/helpers/formDataToStream.js
148777
149695
  var BOUNDARY_ALPHABET = platform_default.ALPHABET.ALPHA_DIGIT + "-_";
148778
- var textEncoder = typeof TextEncoder === "function" ? new TextEncoder() : new import_util6.default.TextEncoder();
149696
+ var textEncoder = typeof TextEncoder === "function" ? new TextEncoder() : new import_util7.default.TextEncoder();
148779
149697
  var CRLF = "\r\n";
148780
149698
  var CRLF_BYTES = textEncoder.encode(CRLF);
148781
149699
  var CRLF_BYTES_COUNT = 2;
@@ -149269,7 +150187,7 @@ var http_default = isHttpAdapterSupported && /* @__PURE__ */ __name(function htt
149269
150187
  headers2.set(data.getHeaders());
149270
150188
  if (!headers2.hasContentLength()) {
149271
150189
  try {
149272
- const knownLength = await import_util7.default.promisify(data.getLength).call(data);
150190
+ const knownLength = await import_util8.default.promisify(data.getLength).call(data);
149273
150191
  Number.isFinite(knownLength) && knownLength >= 0 && headers2.setContentLength(knownLength);
149274
150192
  } catch (e) {
149275
150193
  }