Description
The "Remove Collection" endpoint allows you to remove a collection.
Proto Definition
service BGSearch {
rpc RemoveCollection (RemoveCollectionArgs) returns (google.protobuf.Empty) {}
}
Input Message
Name: RemoveCollectionArgs
Attribute | Type | Description |
---|---|---|
collection | string | The name of the collection. |
message RemoveCollectionArgs {
string collection = 1;
}
Output Message
Name: google.protobuf.Empty
Status Code
5: NOT_FOUND
if a collection with the provided name does not exist.0: OK
if the collection is created successfully.
Code Examples
proto::EmptyResult result;
proto::RemoveCollectionArgs request;
auto context = grpc::ClientContext>();
request.set_collection(name);
auto status = stub->RemoveCollection(&context, request, &result);
import bgearch_pb2_grpc #Contains the server functions
import bgsearch_pb2 #Contains the types for the messages and arguments in the .proto file
args= bgsearch_pb2.RemoveCollectionArgs(collection="YOUR_COLLECTION_NAME")
stub.removeCollection(args)