Class protos.google.ai.generativelanguage.v1beta.PermissionService (2.6.0)

Represents a PermissionService

Inheritance

$protobuf.rpc.Service > protos.google.ai.generativelanguage.v1beta.PermissionService

Package

@google-ai/generativelanguage

Constructors

(constructor)(rpcImpl, requestDelimited, responseDelimited)

constructor(rpcImpl: $protobuf.RPCImpl, requestDelimited?: boolean, responseDelimited?: boolean);

Constructs a new PermissionService service.

Parameters
Name Description
rpcImpl $protobuf.RPCImpl

RPC implementation

requestDelimited boolean

Whether requests are length-delimited

responseDelimited boolean

Whether responses are length-delimited

Methods

create(rpcImpl, requestDelimited, responseDelimited)

public static create(rpcImpl: $protobuf.RPCImpl, requestDelimited?: boolean, responseDelimited?: boolean): PermissionService;

Creates new PermissionService service using the specified rpc implementation.

Parameters
Name Description
rpcImpl $protobuf.RPCImpl

RPC implementation

requestDelimited boolean

Whether requests are length-delimited

responseDelimited boolean

Whether responses are length-delimited

Returns
Type Description
PermissionService

RPC service. Useful where requests and/or responses are streamed.

createPermission(request, callback)

public createPermission(request: google.ai.generativelanguage.v1beta.ICreatePermissionRequest, callback: google.ai.generativelanguage.v1beta.PermissionService.CreatePermissionCallback): void;

Calls CreatePermission.

Parameters
Name Description
request ICreatePermissionRequest

CreatePermissionRequest message or plain object

callback CreatePermissionCallback

Node-style callback called with the error, if any, and Permission

Returns
Type Description
void

createPermission(request)

public createPermission(request: google.ai.generativelanguage.v1beta.ICreatePermissionRequest): Promise<google.ai.generativelanguage.v1beta.Permission>;

Calls CreatePermission.

Parameter
Name Description
request ICreatePermissionRequest

CreatePermissionRequest message or plain object

Returns
Type Description
Promise<google.ai.generativelanguage.v1beta.Permission>

Promise

deletePermission(request, callback)

public deletePermission(request: google.ai.generativelanguage.v1beta.IDeletePermissionRequest, callback: google.ai.generativelanguage.v1beta.PermissionService.DeletePermissionCallback): void;

Calls DeletePermission.

Parameters
Name Description
request IDeletePermissionRequest

DeletePermissionRequest message or plain object

callback DeletePermissionCallback

Node-style callback called with the error, if any, and Empty

Returns
Type Description
void

deletePermission(request)

public deletePermission(request: google.ai.generativelanguage.v1beta.IDeletePermissionRequest): Promise<google.protobuf.Empty>;

Calls DeletePermission.

Parameter
Name Description
request IDeletePermissionRequest

DeletePermissionRequest message or plain object

Returns
Type Description
Promise<google.protobuf.Empty>

Promise

getPermission(request, callback)

public getPermission(request: google.ai.generativelanguage.v1beta.IGetPermissionRequest, callback: google.ai.generativelanguage.v1beta.PermissionService.GetPermissionCallback): void;

Calls GetPermission.

Parameters
Name Description
request IGetPermissionRequest

GetPermissionRequest message or plain object

callback GetPermissionCallback

Node-style callback called with the error, if any, and Permission

Returns
Type Description
void

getPermission(request)

public getPermission(request: google.ai.generativelanguage.v1beta.IGetPermissionRequest): Promise<google.ai.generativelanguage.v1beta.Permission>;

Calls GetPermission.

Parameter
Name Description
request IGetPermissionRequest

GetPermissionRequest message or plain object

Returns
Type Description
Promise<google.ai.generativelanguage.v1beta.Permission>

Promise

listPermissions(request, callback)

public listPermissions(request: google.ai.generativelanguage.v1beta.IListPermissionsRequest, callback: google.ai.generativelanguage.v1beta.PermissionService.ListPermissionsCallback): void;

Calls ListPermissions.

Parameters
Name Description
request IListPermissionsRequest

ListPermissionsRequest message or plain object

callback ListPermissionsCallback

Node-style callback called with the error, if any, and ListPermissionsResponse

Returns
Type Description
void

listPermissions(request)

public listPermissions(request: google.ai.generativelanguage.v1beta.IListPermissionsRequest): Promise<google.ai.generativelanguage.v1beta.ListPermissionsResponse>;

Calls ListPermissions.

Parameter
Name Description
request IListPermissionsRequest

ListPermissionsRequest message or plain object

Returns
Type Description
Promise<google.ai.generativelanguage.v1beta.ListPermissionsResponse>

Promise

transferOwnership(request, callback)

public transferOwnership(request: google.ai.generativelanguage.v1beta.ITransferOwnershipRequest, callback: google.ai.generativelanguage.v1beta.PermissionService.TransferOwnershipCallback): void;

Calls TransferOwnership.

Parameters
Name Description
request ITransferOwnershipRequest

TransferOwnershipRequest message or plain object

callback TransferOwnershipCallback

Node-style callback called with the error, if any, and TransferOwnershipResponse

Returns
Type Description
void

transferOwnership(request)

public transferOwnership(request: google.ai.generativelanguage.v1beta.ITransferOwnershipRequest): Promise<google.ai.generativelanguage.v1beta.TransferOwnershipResponse>;

Calls TransferOwnership.

Parameter
Name Description
request ITransferOwnershipRequest

TransferOwnershipRequest message or plain object

Returns
Type Description
Promise<google.ai.generativelanguage.v1beta.TransferOwnershipResponse>

Promise

updatePermission(request, callback)

public updatePermission(request: google.ai.generativelanguage.v1beta.IUpdatePermissionRequest, callback: google.ai.generativelanguage.v1beta.PermissionService.UpdatePermissionCallback): void;

Calls UpdatePermission.

Parameters
Name Description
request IUpdatePermissionRequest

UpdatePermissionRequest message or plain object

callback UpdatePermissionCallback

Node-style callback called with the error, if any, and Permission

Returns
Type Description
void

updatePermission(request)

public updatePermission(request: google.ai.generativelanguage.v1beta.IUpdatePermissionRequest): Promise<google.ai.generativelanguage.v1beta.Permission>;

Calls UpdatePermission.

Parameter
Name Description
request IUpdatePermissionRequest

UpdatePermissionRequest message or plain object

Returns
Type Description
Promise<google.ai.generativelanguage.v1beta.Permission>

Promise