Skip to main content
PATCH
/
admin
/
api-keys
/
{api_key_id}
PINECONE_ACCESS_TOKEN="YOUR_ACCESS_TOKEN"
PINECONE_API_KEY_ID="YOUR_API_KEY_ID"

curl -X PATCH "https://api.pinecone.io/admin/api-keys/$PINECONE_API_KEY_ID" \
	-H "X-Pinecone-Api-Version: 2025-10" \
	-H "Authorization: Bearer $PINECONE_ACCESS_TOKEN" \
	-d '{
		"name": "New API key name",
		"roles": ["ProjectEditor"]
	}'
{
  "key": {
    "id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
    "name": "New API key name",
    "project_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
    "roles": [
      "ProjectEditor"
    ]
  },
  "value": "string"
}
PINECONE_ACCESS_TOKEN="YOUR_ACCESS_TOKEN"
PINECONE_API_KEY_ID="YOUR_API_KEY_ID"

curl -X PATCH "https://api.pinecone.io/admin/api-keys/$PINECONE_API_KEY_ID" \
	-H "X-Pinecone-Api-Version: 2025-10" \
	-H "Authorization: Bearer $PINECONE_ACCESS_TOKEN" \
	-d '{
		"name": "New API key name",
		"roles": ["ProjectEditor"]
	}'
{
  "key": {
    "id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
    "name": "New API key name",
    "project_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
    "roles": [
      "ProjectEditor"
    ]
  },
  "value": "string"
}

Authorizations

Authorization
string
header
required

An access token must be provided in the Authorization header using the Bearer scheme.

Headers

X-Pinecone-Api-Version
string
default:2025-10
required

Required date-based version header

Path Parameters

api_key_id
string<uuid>
required

API key ID

Body

application/json

Updated name and roles for the API key.

name
string

A new name for the API key. The name must be 1-80 characters long. If omitted, the name will not be updated.

Required string length: 1 - 80
Example:

"devkey"

roles
string[]

A new set of roles for the API key. Existing roles will be removed if not included. If this field is omitted, the roles will not be updated.

A role that can be assigned to an API key. Possible values: ProjectEditor, ProjectViewer, ControlPlaneEditor, ControlPlaneViewer, DataPlaneEditor, or DataPlaneViewer.

Response

API key updated successfully.

The details of an API key, without the secret.

id
string<uuid>
required

The unique ID of the API key.

name
string
required

The name of the API key.

project_id
string<uuid>
required

The ID of the project containing the API key.

roles
string[]
required

The roles assigned to the API key.

A role that can be assigned to an API key. Possible values: ProjectEditor, ProjectViewer, ControlPlaneEditor, ControlPlaneViewer, DataPlaneEditor, or DataPlaneViewer.