For each Pinecone index, there is a unique DNS endpoint for performing data operations such as upsert, query, update, and delete. The Python and Node SDKs construct these index endpoints for you. However, when using the API directly, you need to explicitly specify these endpoints.

There are two ways to get an index endpoint for direct API calls: the Pinecone console or use the describe_index endpoint.

Use the Pinecone console

To get an index endpoint from the Pinecone console:

  1. Open the Pinecone console.
  2. Select the project containing the index.
  3. Select the index.
  4. Copy the URL under HOST.

Use describe_index

The describe_index operation uses a different API (api.pinecone.io) than data plane operations such as upsert and query. In production, you should therefore not rely on describe_index to programmatically get an index endpoint for data manipulation operations. Instead, you should get an index endpoint once and cache it for reuse or specify the endpoint directly.

The describe_index operation returns the index endpoint as the host value: