POST
/
collections
# pip install "pinecone[grpc]"
from pinecone.grpc import PineconeGRPC as Pinecone

pc = Pinecone(api_key="API_KEY")
pc.create_collection("example-collection", "docs-example")
{
  "name": "example-collection",
  "size": 10000000,
  "status": "Initializing",
  "dimension": 1536,
  "vector_count": 120000,
  "environment": "us-east1-gcp"
}
# pip install "pinecone[grpc]"
from pinecone.grpc import PineconeGRPC as Pinecone

pc = Pinecone(api_key="API_KEY")
pc.create_collection("example-collection", "docs-example")

Authorizations

Api-Key
string
header
required

An API Key is required to call Pinecone APIs. Get yours from the console.

Body

application/json

The desired configuration for the collection.

The configuration needed to create a Pinecone collection.

Response

201
application/json

The collection has been successfully created.

The CollectionModel describes the configuration and status of a Pinecone collection.