@textile/buckets-grpc
Advanced tools
Comparing version 2.0.0-rc7 to 2.0.0-rc8
@@ -115,2 +115,20 @@ // package: api.buckets.pb | ||
type APIServicePushPathAccessRoles = { | ||
readonly methodName: string; | ||
readonly service: typeof APIService; | ||
readonly requestStream: false; | ||
readonly responseStream: false; | ||
readonly requestType: typeof buckets_pb.PushPathAccessRolesRequest; | ||
readonly responseType: typeof buckets_pb.PushPathAccessRolesResponse; | ||
}; | ||
type APIServicePullPathAccessRoles = { | ||
readonly methodName: string; | ||
readonly service: typeof APIService; | ||
readonly requestStream: false; | ||
readonly responseStream: false; | ||
readonly requestType: typeof buckets_pb.PullPathAccessRolesRequest; | ||
readonly responseType: typeof buckets_pb.PullPathAccessRolesResponse; | ||
}; | ||
type APIServiceArchive = { | ||
@@ -166,2 +184,4 @@ readonly methodName: string; | ||
static readonly RemovePath: APIServiceRemovePath; | ||
static readonly PushPathAccessRoles: APIServicePushPathAccessRoles; | ||
static readonly PullPathAccessRoles: APIServicePullPathAccessRoles; | ||
static readonly Archive: APIServiceArchive; | ||
@@ -289,2 +309,20 @@ static readonly ArchiveStatus: APIServiceArchiveStatus; | ||
): UnaryResponse; | ||
pushPathAccessRoles( | ||
requestMessage: buckets_pb.PushPathAccessRolesRequest, | ||
metadata: grpc.Metadata, | ||
callback: (error: ServiceError|null, responseMessage: buckets_pb.PushPathAccessRolesResponse|null) => void | ||
): UnaryResponse; | ||
pushPathAccessRoles( | ||
requestMessage: buckets_pb.PushPathAccessRolesRequest, | ||
callback: (error: ServiceError|null, responseMessage: buckets_pb.PushPathAccessRolesResponse|null) => void | ||
): UnaryResponse; | ||
pullPathAccessRoles( | ||
requestMessage: buckets_pb.PullPathAccessRolesRequest, | ||
metadata: grpc.Metadata, | ||
callback: (error: ServiceError|null, responseMessage: buckets_pb.PullPathAccessRolesResponse|null) => void | ||
): UnaryResponse; | ||
pullPathAccessRoles( | ||
requestMessage: buckets_pb.PullPathAccessRolesRequest, | ||
callback: (error: ServiceError|null, responseMessage: buckets_pb.PullPathAccessRolesResponse|null) => void | ||
): UnaryResponse; | ||
archive( | ||
@@ -291,0 +329,0 @@ requestMessage: buckets_pb.ArchiveRequest, |
@@ -121,2 +121,20 @@ // package: api.buckets.pb | ||
APIService.PushPathAccessRoles = { | ||
methodName: "PushPathAccessRoles", | ||
service: APIService, | ||
requestStream: false, | ||
responseStream: false, | ||
requestType: buckets_pb.PushPathAccessRolesRequest, | ||
responseType: buckets_pb.PushPathAccessRolesResponse | ||
}; | ||
APIService.PullPathAccessRoles = { | ||
methodName: "PullPathAccessRoles", | ||
service: APIService, | ||
requestStream: false, | ||
responseStream: false, | ||
requestType: buckets_pb.PullPathAccessRolesRequest, | ||
responseType: buckets_pb.PullPathAccessRolesResponse | ||
}; | ||
APIService.Archive = { | ||
@@ -567,2 +585,64 @@ methodName: "Archive", | ||
APIServiceClient.prototype.pushPathAccessRoles = function pushPathAccessRoles(requestMessage, metadata, callback) { | ||
if (arguments.length === 2) { | ||
callback = arguments[1]; | ||
} | ||
var client = grpc.unary(APIService.PushPathAccessRoles, { | ||
request: requestMessage, | ||
host: this.serviceHost, | ||
metadata: metadata, | ||
transport: this.options.transport, | ||
debug: this.options.debug, | ||
onEnd: function (response) { | ||
if (callback) { | ||
if (response.status !== grpc.Code.OK) { | ||
var err = new Error(response.statusMessage); | ||
err.code = response.status; | ||
err.metadata = response.trailers; | ||
callback(err, null); | ||
} else { | ||
callback(null, response.message); | ||
} | ||
} | ||
} | ||
}); | ||
return { | ||
cancel: function () { | ||
callback = null; | ||
client.close(); | ||
} | ||
}; | ||
}; | ||
APIServiceClient.prototype.pullPathAccessRoles = function pullPathAccessRoles(requestMessage, metadata, callback) { | ||
if (arguments.length === 2) { | ||
callback = arguments[1]; | ||
} | ||
var client = grpc.unary(APIService.PullPathAccessRoles, { | ||
request: requestMessage, | ||
host: this.serviceHost, | ||
metadata: metadata, | ||
transport: this.options.transport, | ||
debug: this.options.debug, | ||
onEnd: function (response) { | ||
if (callback) { | ||
if (response.status !== grpc.Code.OK) { | ||
var err = new Error(response.statusMessage); | ||
err.code = response.status; | ||
err.metadata = response.trailers; | ||
callback(err, null); | ||
} else { | ||
callback(null, response.message); | ||
} | ||
} | ||
} | ||
}); | ||
return { | ||
cancel: function () { | ||
callback = null; | ||
client.close(); | ||
} | ||
}; | ||
}; | ||
APIServiceClient.prototype.archive = function archive(requestMessage, metadata, callback) { | ||
@@ -569,0 +649,0 @@ if (arguments.length === 2) { |
@@ -6,2 +6,25 @@ // package: api.buckets.pb | ||
export class Metadata extends jspb.Message { | ||
getRolesMap(): jspb.Map<string, PathAccessRoleMap[keyof PathAccessRoleMap]>; | ||
clearRolesMap(): void; | ||
getUpdatedAt(): number; | ||
setUpdatedAt(value: number): void; | ||
serializeBinary(): Uint8Array; | ||
toObject(includeInstance?: boolean): Metadata.AsObject; | ||
static toObject(includeInstance: boolean, msg: Metadata): Metadata.AsObject; | ||
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>}; | ||
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>}; | ||
static serializeBinaryToWriter(message: Metadata, writer: jspb.BinaryWriter): void; | ||
static deserializeBinary(bytes: Uint8Array): Metadata; | ||
static deserializeBinaryFromReader(message: Metadata, reader: jspb.BinaryReader): Metadata; | ||
} | ||
export namespace Metadata { | ||
export type AsObject = { | ||
rolesMap: Array<[string, PathAccessRoleMap[keyof PathAccessRoleMap]]>, | ||
updatedAt: number, | ||
} | ||
} | ||
export class Root extends jspb.Message { | ||
@@ -26,2 +49,13 @@ getKey(): string; | ||
getOwner(): string; | ||
setOwner(value: string): void; | ||
getVersion(): number; | ||
setVersion(value: number): void; | ||
hasMetadata(): boolean; | ||
clearMetadata(): void; | ||
getMetadata(): Metadata | undefined; | ||
setMetadata(value?: Metadata): void; | ||
serializeBinary(): Uint8Array; | ||
@@ -45,2 +79,5 @@ toObject(includeInstance?: boolean): Root.AsObject; | ||
thread: string, | ||
owner: string, | ||
version: number, | ||
metadata?: Metadata.AsObject, | ||
} | ||
@@ -270,4 +307,4 @@ } | ||
clearItem(): void; | ||
getItem(): ListPathItem | undefined; | ||
setItem(value?: ListPathItem): void; | ||
getItem(): PathItem | undefined; | ||
setItem(value?: PathItem): void; | ||
@@ -291,3 +328,3 @@ hasRoot(): boolean; | ||
export type AsObject = { | ||
item?: ListPathItem.AsObject, | ||
item?: PathItem.AsObject, | ||
root?: Root.AsObject, | ||
@@ -297,3 +334,3 @@ } | ||
export class ListPathItem extends jspb.Message { | ||
export class PathItem extends jspb.Message { | ||
getCid(): string; | ||
@@ -315,17 +352,25 @@ setCid(value: string): void; | ||
clearItemsList(): void; | ||
getItemsList(): Array<ListPathItem>; | ||
setItemsList(value: Array<ListPathItem>): void; | ||
addItems(value?: ListPathItem, index?: number): ListPathItem; | ||
getItemsList(): Array<PathItem>; | ||
setItemsList(value: Array<PathItem>): void; | ||
addItems(value?: PathItem, index?: number): PathItem; | ||
getItemsCount(): number; | ||
setItemsCount(value: number): void; | ||
hasMetadata(): boolean; | ||
clearMetadata(): void; | ||
getMetadata(): Metadata | undefined; | ||
setMetadata(value?: Metadata): void; | ||
serializeBinary(): Uint8Array; | ||
toObject(includeInstance?: boolean): ListPathItem.AsObject; | ||
static toObject(includeInstance: boolean, msg: ListPathItem): ListPathItem.AsObject; | ||
toObject(includeInstance?: boolean): PathItem.AsObject; | ||
static toObject(includeInstance: boolean, msg: PathItem): PathItem.AsObject; | ||
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>}; | ||
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>}; | ||
static serializeBinaryToWriter(message: ListPathItem, writer: jspb.BinaryWriter): void; | ||
static deserializeBinary(bytes: Uint8Array): ListPathItem; | ||
static deserializeBinaryFromReader(message: ListPathItem, reader: jspb.BinaryReader): ListPathItem; | ||
static serializeBinaryToWriter(message: PathItem, writer: jspb.BinaryWriter): void; | ||
static deserializeBinary(bytes: Uint8Array): PathItem; | ||
static deserializeBinaryFromReader(message: PathItem, reader: jspb.BinaryReader): PathItem; | ||
} | ||
export namespace ListPathItem { | ||
export namespace PathItem { | ||
export type AsObject = { | ||
@@ -337,3 +382,5 @@ cid: string, | ||
isDir: boolean, | ||
itemsList: Array<ListPathItem.AsObject>, | ||
itemsList: Array<PathItem.AsObject>, | ||
itemsCount: number, | ||
metadata?: Metadata.AsObject, | ||
} | ||
@@ -365,4 +412,4 @@ } | ||
clearItem(): void; | ||
getItem(): ListPathItem | undefined; | ||
setItem(value?: ListPathItem): void; | ||
getItem(): PathItem | undefined; | ||
setItem(value?: PathItem): void; | ||
@@ -381,3 +428,3 @@ serializeBinary(): Uint8Array; | ||
export type AsObject = { | ||
item?: ListPathItem.AsObject, | ||
item?: PathItem.AsObject, | ||
} | ||
@@ -742,2 +789,88 @@ } | ||
export class PushPathAccessRolesRequest extends jspb.Message { | ||
getKey(): string; | ||
setKey(value: string): void; | ||
getPath(): string; | ||
setPath(value: string): void; | ||
getRolesMap(): jspb.Map<string, PathAccessRoleMap[keyof PathAccessRoleMap]>; | ||
clearRolesMap(): void; | ||
serializeBinary(): Uint8Array; | ||
toObject(includeInstance?: boolean): PushPathAccessRolesRequest.AsObject; | ||
static toObject(includeInstance: boolean, msg: PushPathAccessRolesRequest): PushPathAccessRolesRequest.AsObject; | ||
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>}; | ||
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>}; | ||
static serializeBinaryToWriter(message: PushPathAccessRolesRequest, writer: jspb.BinaryWriter): void; | ||
static deserializeBinary(bytes: Uint8Array): PushPathAccessRolesRequest; | ||
static deserializeBinaryFromReader(message: PushPathAccessRolesRequest, reader: jspb.BinaryReader): PushPathAccessRolesRequest; | ||
} | ||
export namespace PushPathAccessRolesRequest { | ||
export type AsObject = { | ||
key: string, | ||
path: string, | ||
rolesMap: Array<[string, PathAccessRoleMap[keyof PathAccessRoleMap]]>, | ||
} | ||
} | ||
export class PushPathAccessRolesResponse extends jspb.Message { | ||
serializeBinary(): Uint8Array; | ||
toObject(includeInstance?: boolean): PushPathAccessRolesResponse.AsObject; | ||
static toObject(includeInstance: boolean, msg: PushPathAccessRolesResponse): PushPathAccessRolesResponse.AsObject; | ||
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>}; | ||
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>}; | ||
static serializeBinaryToWriter(message: PushPathAccessRolesResponse, writer: jspb.BinaryWriter): void; | ||
static deserializeBinary(bytes: Uint8Array): PushPathAccessRolesResponse; | ||
static deserializeBinaryFromReader(message: PushPathAccessRolesResponse, reader: jspb.BinaryReader): PushPathAccessRolesResponse; | ||
} | ||
export namespace PushPathAccessRolesResponse { | ||
export type AsObject = { | ||
} | ||
} | ||
export class PullPathAccessRolesRequest extends jspb.Message { | ||
getKey(): string; | ||
setKey(value: string): void; | ||
getPath(): string; | ||
setPath(value: string): void; | ||
serializeBinary(): Uint8Array; | ||
toObject(includeInstance?: boolean): PullPathAccessRolesRequest.AsObject; | ||
static toObject(includeInstance: boolean, msg: PullPathAccessRolesRequest): PullPathAccessRolesRequest.AsObject; | ||
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>}; | ||
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>}; | ||
static serializeBinaryToWriter(message: PullPathAccessRolesRequest, writer: jspb.BinaryWriter): void; | ||
static deserializeBinary(bytes: Uint8Array): PullPathAccessRolesRequest; | ||
static deserializeBinaryFromReader(message: PullPathAccessRolesRequest, reader: jspb.BinaryReader): PullPathAccessRolesRequest; | ||
} | ||
export namespace PullPathAccessRolesRequest { | ||
export type AsObject = { | ||
key: string, | ||
path: string, | ||
} | ||
} | ||
export class PullPathAccessRolesResponse extends jspb.Message { | ||
getRolesMap(): jspb.Map<string, PathAccessRoleMap[keyof PathAccessRoleMap]>; | ||
clearRolesMap(): void; | ||
serializeBinary(): Uint8Array; | ||
toObject(includeInstance?: boolean): PullPathAccessRolesResponse.AsObject; | ||
static toObject(includeInstance: boolean, msg: PullPathAccessRolesResponse): PullPathAccessRolesResponse.AsObject; | ||
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>}; | ||
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>}; | ||
static serializeBinaryToWriter(message: PullPathAccessRolesResponse, writer: jspb.BinaryWriter): void; | ||
static deserializeBinary(bytes: Uint8Array): PullPathAccessRolesResponse; | ||
static deserializeBinaryFromReader(message: PullPathAccessRolesResponse, reader: jspb.BinaryReader): PullPathAccessRolesResponse; | ||
} | ||
export namespace PullPathAccessRolesResponse { | ||
export type AsObject = { | ||
rolesMap: Array<[string, PathAccessRoleMap[keyof PathAccessRoleMap]]>, | ||
} | ||
} | ||
export class ArchiveRequest extends jspb.Message { | ||
@@ -973,1 +1106,10 @@ getKey(): string; | ||
export interface PathAccessRoleMap { | ||
PATH_ACCESS_ROLE_UNSPECIFIED: 0; | ||
PATH_ACCESS_ROLE_READER: 1; | ||
PATH_ACCESS_ROLE_WRITER: 2; | ||
PATH_ACCESS_ROLE_ADMIN: 3; | ||
} | ||
export const PathAccessRole: PathAccessRoleMap; | ||
{ | ||
"name": "@textile/buckets-grpc", | ||
"version": "2.0.0-rc7", | ||
"version": "2.0.0-rc8", | ||
"description": "A client for interacting with the Textile Buckets gRPC API.", | ||
@@ -5,0 +5,0 @@ "repository": { |
Sorry, the diff of this file is too big to display
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
334838
9231