@authzed/authzed-js-node
Version:
authzed js client for nodejs
117 lines • 7.81 kB
JavaScript
// @generated by protobuf-ts 2.9.1 with parameter generate_dependencies,long_type_string,client_grpc1
// @generated from protobuf file "authzed/api/v1/experimental_service.proto" (package "authzed.api.v1", syntax proto3)
// tslint:disable
import { ExperimentalService } from "./experimental_service.js";
import * as grpc from "@grpc/grpc-js";
/**
* ExperimentalService exposes a number of APIs that are currently being
* prototyped and tested for future inclusion in the stable API.
*
* @generated from protobuf service authzed.api.v1.ExperimentalService
*/
export class ExperimentalServiceClient extends grpc.Client {
_binaryOptions;
constructor(address, credentials, options = {}, binaryOptions = {}) {
super(address, credentials, options);
this._binaryOptions = binaryOptions;
}
/**
* DEPRECATED: Promoted to ImportBulkRelationships in the stable API.
*
* @deprecated
* @generated from protobuf rpc: BulkImportRelationships(stream authzed.api.v1.BulkImportRelationshipsRequest) returns (authzed.api.v1.BulkImportRelationshipsResponse);
*/
bulkImportRelationships(metadata, options, callback) {
const method = ExperimentalService.methods[0];
return this.makeClientStreamRequest(`/${ExperimentalService.typeName}/${method.name}`, (value) => Buffer.from(method.I.toBinary(value, this._binaryOptions)), (value) => method.O.fromBinary(value, this._binaryOptions), metadata, options, callback);
}
/**
* DEPRECATED: Promoted to ExportBulkRelationships in the stable API.
*
* @deprecated
* @generated from protobuf rpc: BulkExportRelationships(authzed.api.v1.BulkExportRelationshipsRequest) returns (stream authzed.api.v1.BulkExportRelationshipsResponse);
*/
bulkExportRelationships(input, metadata, options) {
const method = ExperimentalService.methods[1];
return this.makeServerStreamRequest(`/${ExperimentalService.typeName}/${method.name}`, (value) => Buffer.from(method.I.toBinary(value, this._binaryOptions)), (value) => method.O.fromBinary(value, this._binaryOptions), input, metadata, options);
}
/**
* DEPRECATED: Promoted to CheckBulkPermission in the stable API.
*
* @deprecated
* @generated from protobuf rpc: BulkCheckPermission(authzed.api.v1.BulkCheckPermissionRequest) returns (authzed.api.v1.BulkCheckPermissionResponse);
*/
bulkCheckPermission(input, metadata, options, callback) {
const method = ExperimentalService.methods[2];
return this.makeUnaryRequest(`/${ExperimentalService.typeName}/${method.name}`, (value) => Buffer.from(method.I.toBinary(value, this._binaryOptions)), (value) => method.O.fromBinary(value, this._binaryOptions), input, metadata, options, callback);
}
/**
* DEPRECATED: Promoted to ReflectSchema in the stable API.
*
* @deprecated
* @generated from protobuf rpc: ExperimentalReflectSchema(authzed.api.v1.ExperimentalReflectSchemaRequest) returns (authzed.api.v1.ExperimentalReflectSchemaResponse);
*/
experimentalReflectSchema(input, metadata, options, callback) {
const method = ExperimentalService.methods[3];
return this.makeUnaryRequest(`/${ExperimentalService.typeName}/${method.name}`, (value) => Buffer.from(method.I.toBinary(value, this._binaryOptions)), (value) => method.O.fromBinary(value, this._binaryOptions), input, metadata, options, callback);
}
/**
* DEPRECATED: Promoted to ComputablePermissions in the stable API.
*
* @deprecated
* @generated from protobuf rpc: ExperimentalComputablePermissions(authzed.api.v1.ExperimentalComputablePermissionsRequest) returns (authzed.api.v1.ExperimentalComputablePermissionsResponse);
*/
experimentalComputablePermissions(input, metadata, options, callback) {
const method = ExperimentalService.methods[4];
return this.makeUnaryRequest(`/${ExperimentalService.typeName}/${method.name}`, (value) => Buffer.from(method.I.toBinary(value, this._binaryOptions)), (value) => method.O.fromBinary(value, this._binaryOptions), input, metadata, options, callback);
}
/**
* DEPRECATED: Promoted to DependentRelations in the stable API.
*
* @deprecated
* @generated from protobuf rpc: ExperimentalDependentRelations(authzed.api.v1.ExperimentalDependentRelationsRequest) returns (authzed.api.v1.ExperimentalDependentRelationsResponse);
*/
experimentalDependentRelations(input, metadata, options, callback) {
const method = ExperimentalService.methods[5];
return this.makeUnaryRequest(`/${ExperimentalService.typeName}/${method.name}`, (value) => Buffer.from(method.I.toBinary(value, this._binaryOptions)), (value) => method.O.fromBinary(value, this._binaryOptions), input, metadata, options, callback);
}
/**
* DEPRECATED: Promoted to DiffSchema in the stable API.
*
* @deprecated
* @generated from protobuf rpc: ExperimentalDiffSchema(authzed.api.v1.ExperimentalDiffSchemaRequest) returns (authzed.api.v1.ExperimentalDiffSchemaResponse);
*/
experimentalDiffSchema(input, metadata, options, callback) {
const method = ExperimentalService.methods[6];
return this.makeUnaryRequest(`/${ExperimentalService.typeName}/${method.name}`, (value) => Buffer.from(method.I.toBinary(value, this._binaryOptions)), (value) => method.O.fromBinary(value, this._binaryOptions), input, metadata, options, callback);
}
/**
* EXPERIMENTAL: RegisterRelationshipCounter registers a new filter for counting relationships. A filter must be registered before
* a count can be requested.
*
* @generated from protobuf rpc: ExperimentalRegisterRelationshipCounter(authzed.api.v1.ExperimentalRegisterRelationshipCounterRequest) returns (authzed.api.v1.ExperimentalRegisterRelationshipCounterResponse);
*/
experimentalRegisterRelationshipCounter(input, metadata, options, callback) {
const method = ExperimentalService.methods[7];
return this.makeUnaryRequest(`/${ExperimentalService.typeName}/${method.name}`, (value) => Buffer.from(method.I.toBinary(value, this._binaryOptions)), (value) => method.O.fromBinary(value, this._binaryOptions), input, metadata, options, callback);
}
/**
* EXPERIMENTAL: CountRelationships returns the count of relationships for *pre-registered* filter.
*
* @generated from protobuf rpc: ExperimentalCountRelationships(authzed.api.v1.ExperimentalCountRelationshipsRequest) returns (authzed.api.v1.ExperimentalCountRelationshipsResponse);
*/
experimentalCountRelationships(input, metadata, options, callback) {
const method = ExperimentalService.methods[8];
return this.makeUnaryRequest(`/${ExperimentalService.typeName}/${method.name}`, (value) => Buffer.from(method.I.toBinary(value, this._binaryOptions)), (value) => method.O.fromBinary(value, this._binaryOptions), input, metadata, options, callback);
}
/**
* EXPERIMENTAL: UnregisterRelationshipCounter unregisters an existing filter for counting relationships.
*
* @generated from protobuf rpc: ExperimentalUnregisterRelationshipCounter(authzed.api.v1.ExperimentalUnregisterRelationshipCounterRequest) returns (authzed.api.v1.ExperimentalUnregisterRelationshipCounterResponse);
*/
experimentalUnregisterRelationshipCounter(input, metadata, options, callback) {
const method = ExperimentalService.methods[9];
return this.makeUnaryRequest(`/${ExperimentalService.typeName}/${method.name}`, (value) => Buffer.from(method.I.toBinary(value, this._binaryOptions)), (value) => method.O.fromBinary(value, this._binaryOptions), input, metadata, options, callback);
}
}
//# sourceMappingURL=experimental_service.grpc-client.js.map