KosmoKrator

data

Pinecone CLI for AI Agents

Use the Pinecone CLI from KosmoKrator to call Pinecone tools headlessly, return JSON, inspect schemas, and automate workflows from coding agents, scripts, and CI.

Pinecone CLI Setup

Pinecone can be configured headlessly with `kosmokrator integrations:configure pinecone`.

Install, configure, and verify
# Install KosmoKrator first if it is not available on PATH.
curl -fsSL https://raw.githubusercontent.com/OpenCompanyApp/kosmokrator/main/install.sh | bash

# Configure and verify this integration.
kosmokrator integrations:configure pinecone --set api_key="$PINECONE_API_KEY" --enable --read allow --write ask --json
kosmokrator integrations:doctor pinecone --json
kosmokrator integrations:status --json

Credentials

Authentication type: API key api_key. Configure credentials once, then reuse the same stored profile from scripts, coding CLIs, Lua, and MCP.

KeyEnv varTypeRequiredLabel
api_key PINECONE_API_KEY Secret secret yes API Key
url PINECONE_URL URL url no Pinecone API URL
api_version PINECONE_API_VERSION Text text no API Version

Command Patterns

The generic command is stable across every integration. The provider shortcut is shorter for humans.

Generic CLI call
kosmo integrations:call pinecone.pinecone_list_indexes '{}' --json
Provider shortcut
kosmo integrations:pinecone pinecone_list_indexes '{}' --json

Discovery

These commands return structured output for coding agents that need to inspect capabilities before choosing a function.

Discovery commands
kosmo integrations:docs pinecone --json
kosmo integrations:docs pinecone.pinecone_list_indexes --json
kosmo integrations:schema pinecone.pinecone_list_indexes --json
kosmo integrations:search "Pinecone" --json
kosmo integrations:list --json

Automation Contexts

The same configured command surface works in these environments. The command does not change unless the host wrapper, credentials, or permissions change.

CLI Functions

Every function below can be called headlessly. Commands are highlighted, copyable, and scroll horizontally when payloads are long.

pinecone.pinecone_list_indexes

List all vector indexes in your Pinecone project. Returns index names, dimensions, metrics, and status.

Read read
Parameters
none
Generic call
kosmo integrations:call pinecone.pinecone_list_indexes '{}' --json
Shortcut
kosmo integrations:pinecone pinecone_list_indexes '{}' --json

pinecone.pinecone_get_index

Get detailed information about a specific Pinecone vector index, including its dimension, metric, host URL, and status.

Read read
Parameters
name
Generic call
kosmo integrations:call pinecone.pinecone_get_index '{"name":"example_name"}' --json
Shortcut
kosmo integrations:pinecone pinecone_get_index '{"name":"example_name"}' --json

pinecone.pinecone_create_index

Create a new serverless vector index in Pinecone. Specify the index name, vector dimension, and similarity metric (cosine, euclidean, or dotproduct).

Write write
Parameters
name, dimension, metric, cloud, region
Generic call
kosmo integrations:call pinecone.pinecone_create_index '{"name":"example_name","dimension":1,"metric":"example_metric","cloud":"example_cloud","region":"example_region"}' --json
Shortcut
kosmo integrations:pinecone pinecone_create_index '{"name":"example_name","dimension":1,"metric":"example_metric","cloud":"example_cloud","region":"example_region"}' --json

pinecone.pinecone_configure_index

Configure an existing Pinecone index, such as deletion protection, tags, or supported scaling settings.

Write write
Parameters
name, config
Generic call
kosmo integrations:call pinecone.pinecone_configure_index '{"name":"example_name","config":"example_config"}' --json
Shortcut
kosmo integrations:pinecone pinecone_configure_index '{"name":"example_name","config":"example_config"}' --json

pinecone.pinecone_delete_index

Delete a Pinecone index by name. Deletion protection must be disabled on the index first.

Write write
Parameters
name
Generic call
kosmo integrations:call pinecone.pinecone_delete_index '{"name":"example_name"}' --json
Shortcut
kosmo integrations:pinecone pinecone_delete_index '{"name":"example_name"}' --json

pinecone.pinecone_upsert_vectors

Upsert vectors into a Pinecone index using an index host URL.

Write write
Parameters
index_host, vectors, namespace
Generic call
kosmo integrations:call pinecone.pinecone_upsert_vectors '{"index_host":"example_index_host","vectors":"example_vectors","namespace":"example_namespace"}' --json
Shortcut
kosmo integrations:pinecone pinecone_upsert_vectors '{"index_host":"example_index_host","vectors":"example_vectors","namespace":"example_namespace"}' --json

pinecone.pinecone_query_vectors

Search for similar vectors in a Pinecone index using a query embedding.

Read read
Parameters
index_host, vector, top_k, filter, include_metadata, include_values, namespace
Generic call
kosmo integrations:call pinecone.pinecone_query_vectors '{"index_host":"example_index_host","vector":"example_vector","top_k":1,"filter":"example_filter","include_metadata":true,"include_values":true,"namespace":"example_namespace"}' --json
Shortcut
kosmo integrations:pinecone pinecone_query_vectors '{"index_host":"example_index_host","vector":"example_vector","top_k":1,"filter":"example_filter","include_metadata":true,"include_values":true,"namespace":"example_namespace"}' --json

pinecone.pinecone_fetch_vectors

Fetch vectors by ID from a Pinecone index namespace.

Read read
Parameters
index_host, ids, namespace
Generic call
kosmo integrations:call pinecone.pinecone_fetch_vectors '{"index_host":"example_index_host","ids":"example_ids","namespace":"example_namespace"}' --json
Shortcut
kosmo integrations:pinecone pinecone_fetch_vectors '{"index_host":"example_index_host","ids":"example_ids","namespace":"example_namespace"}' --json

pinecone.pinecone_update_vector

Update vector values, sparse values, metadata, or filtered metadata in a Pinecone namespace.

Write write
Parameters
index_host, id, values, sparse_values, set_metadata, filter, namespace, dry_run
Generic call
kosmo integrations:call pinecone.pinecone_update_vector '{"index_host":"example_index_host","id":"example_id","values":"example_values","sparse_values":"example_sparse_values","set_metadata":"example_set_metadata","filter":"example_filter","namespace":"example_namespace","dry_run":true}' --json
Shortcut
kosmo integrations:pinecone pinecone_update_vector '{"index_host":"example_index_host","id":"example_id","values":"example_values","sparse_values":"example_sparse_values","set_metadata":"example_set_metadata","filter":"example_filter","namespace":"example_namespace","dry_run":true}' --json

pinecone.pinecone_delete_vectors

Delete vectors from a Pinecone namespace by IDs, metadata filter, or delete_all flag.

Write write
Parameters
index_host, ids, filter, delete_all, namespace
Generic call
kosmo integrations:call pinecone.pinecone_delete_vectors '{"index_host":"example_index_host","ids":"example_ids","filter":"example_filter","delete_all":true,"namespace":"example_namespace"}' --json
Shortcut
kosmo integrations:pinecone pinecone_delete_vectors '{"index_host":"example_index_host","ids":"example_ids","filter":"example_filter","delete_all":true,"namespace":"example_namespace"}' --json

pinecone.pinecone_describe_index_stats

Describe vector count, dimensions, and namespace statistics for a Pinecone index.

Read read
Parameters
index_host, filter
Generic call
kosmo integrations:call pinecone.pinecone_describe_index_stats '{"index_host":"example_index_host","filter":"example_filter"}' --json
Shortcut
kosmo integrations:pinecone pinecone_describe_index_stats '{"index_host":"example_index_host","filter":"example_filter"}' --json

pinecone.pinecone_list_collections

List all collections in your Pinecone project. Collections are static snapshots of indexes used for backups or creating new indexes.

Read read
Parameters
none
Generic call
kosmo integrations:call pinecone.pinecone_list_collections '{}' --json
Shortcut
kosmo integrations:pinecone pinecone_list_collections '{}' --json

Function Schemas

Use these parameter tables when building CLI payloads without calling integrations:schema first.

pinecone.pinecone_list_indexes 0 parameters
Schema command
kosmo integrations:schema pinecone.pinecone_list_indexes --json
ParameterTypeRequiredDescription
No parameters.
pinecone.pinecone_get_index 1 parameters
Schema command
kosmo integrations:schema pinecone.pinecone_get_index --json
ParameterTypeRequiredDescription
name string yes The name of the index to retrieve.
pinecone.pinecone_create_index 5 parameters
Schema command
kosmo integrations:schema pinecone.pinecone_create_index --json
ParameterTypeRequiredDescription
name string yes The name for the new index. Must be unique within the project.
dimension integer yes The dimension size of the vectors to be stored (e.g., 1536 for OpenAI text-embedding-ada-002, 3072 for text-embedding-3-large).
metric string no The similarity metric to use: "cosine" (default), "euclidean", or "dotproduct".
cloud string no Serverless cloud provider. Defaults to aws.
region string no Serverless cloud region. Defaults to us-east-1.
pinecone.pinecone_configure_index 2 parameters
Schema command
kosmo integrations:schema pinecone.pinecone_configure_index --json
ParameterTypeRequiredDescription
name string yes The index name.
config object yes PATCH body for the index configuration.
pinecone.pinecone_delete_index 1 parameters
Schema command
kosmo integrations:schema pinecone.pinecone_delete_index --json
ParameterTypeRequiredDescription
name string yes The index name to delete.
pinecone.pinecone_upsert_vectors 3 parameters
Schema command
kosmo integrations:schema pinecone.pinecone_upsert_vectors --json
ParameterTypeRequiredDescription
index_host string yes The index host URL, such as "https://example.svc.us-east-1.pinecone.io".
vectors array yes Vector records with id, values, and optional metadata.
namespace string no Optional namespace where vectors are upserted.
pinecone.pinecone_query_vectors 7 parameters
Schema command
kosmo integrations:schema pinecone.pinecone_query_vectors --json
ParameterTypeRequiredDescription
index_host string yes The index host URL.
vector array yes Query embedding vector values.
top_k integer no Number of top matches to return (default: 10).
filter object no Optional metadata filter expression.
include_metadata boolean no Whether to include metadata in matches (default: true).
include_values boolean no Whether to include vector values in matches (default: false).
namespace string no Optional namespace to query.
pinecone.pinecone_fetch_vectors 3 parameters
Schema command
kosmo integrations:schema pinecone.pinecone_fetch_vectors --json
ParameterTypeRequiredDescription
index_host string yes The index host URL.
ids array yes Vector IDs to fetch.
namespace string no Optional namespace.
pinecone.pinecone_update_vector 8 parameters
Schema command
kosmo integrations:schema pinecone.pinecone_update_vector --json
ParameterTypeRequiredDescription
index_host string yes The index host URL.
id string no Vector ID for single-record updates.
values array no Replacement vector values.
sparse_values object no Sparse vector values.
set_metadata object no Metadata fields to set.
filter object no Metadata filter for bulk metadata updates.
namespace string no Optional namespace.
dry_run boolean no Return matched count without updating when using a filter.
pinecone.pinecone_delete_vectors 5 parameters
Schema command
kosmo integrations:schema pinecone.pinecone_delete_vectors --json
ParameterTypeRequiredDescription
index_host string yes The index host URL.
ids array no Vector IDs to delete.
filter object no Metadata filter selecting vectors to delete.
delete_all boolean no Set true to delete all vectors in the namespace.
namespace string no Optional namespace.
pinecone.pinecone_describe_index_stats 2 parameters
Schema command
kosmo integrations:schema pinecone.pinecone_describe_index_stats --json
ParameterTypeRequiredDescription
index_host string yes The index host URL.
filter object no Optional metadata filter.
pinecone.pinecone_list_collections 0 parameters
Schema command
kosmo integrations:schema pinecone.pinecone_list_collections --json
ParameterTypeRequiredDescription
No parameters.

Permissions

Headless calls still follow the integration read/write permission policy. Configure read/write defaults with integrations:configure. Add --force only for trusted automation that should bypass that policy.