VX Agents

API directory · AI & ML

Pinecone Assistant Files & Chat

v1.0.0 · 9 endpoints · 0 connections · shared by vx.ai

Ask questions of your own PDFs, docs and notes through a Pinecone Assistant and get answers with page-level citations. Upload or replace files, watch their processing status, pull raw context snippets for your own prompts, or call the OpenAI-compatible chat completions endpoint.

Connect this API to an AI agent Browse all specs

What you can do with Pinecone Assistant Files & Chat via MCP

Every endpoint below becomes a governed tool your AI agent (Claude, ChatGPT, or a customer-facing VX agent) can call — with scoped permissions, sandbox testing, and audit logs.

MethodPathOperationDescription
GET /files/{assistant_name} listFiles List the files uploaded to an assistant, with their processing status
POST /files/{assistant_name} uploadFile Upload a new file to the assistant; processing runs in the background
GET /files/{assistant_name}/{assistant_file_id} describeFile Get one file's status, metadata and a temporary download link
PUT /files/{assistant_name}/{assistant_file_id} upsertFile Create or replace a file under a file id you choose
GET /operations/{assistant_name} listOperations List recent file upload and replace operations and their progress
GET /operations/{assistant_name}/{operation_id} describeOperation Check whether one upload or replace operation has finished
POST /chat/{assistant_name} chatWithAssistant Ask the assistant a question and get an answer with citations to your files
POST /chat/{assistant_name}/chat/completions chatCompletions Chat with the assistant through an OpenAI-compatible completions call
POST /chat/{assistant_name}/context retrieveContext Fetch the most relevant snippets from your files for a query, without an answer

Authentication

ApiKeyAuth

API key — sent as the Api-Key header

Pinecone API key, sent in the Api-Key header.

How to get a credential

  1. Sign in to the Pinecone console (https://app.pinecone.io).
  2. Pick the project that holds your assistant.
  3. Open API keys and click Create API key; give it a name and copy the value (it is shown once).
  4. Open Assistant, create an assistant if you have none, and note its name and region.

Permissions used

Key permission Operations
All (or Assistant ReadWrite) listFiles, describeFile, listOperations, describeOperation, chatWithAssistant, chatCompletions, retrieveContext
All (or Assistant ReadWrite) uploadFile, upsertFile

Common errors

Status Meaning Fix
401 Key missing or invalid Paste the full key again; it belongs to one project.
403 Key lacks permission or the plan limit is reached Use a key with Assistant access; check plan limits.
404 Assistant name or host is wrong Use the exact assistant name and the host from Describe an assistant (US vs EU).
400 Bad body or version header Keep X-Pinecone-Api-Version at 2026-07; check file type and message format.
429 Rate or token limit hit Back off and retry later.

Store the key as a VX Agents credential of type API key; it is sent as the Api-Key header on every call.

Usage guide

Setup

  1. Add your Pinecone API key as a VX Agents credential (API key, sent as Api-Key).
  2. Set the server variable assistant_host to your assistant's data-plane host, shown as host when you describe the assistant in the Pinecone console or API. US assistants use prod-1-data.ke.pinecone.io (the default), EU assistants use prod-eu-data.ke.pinecone.io.
  3. Pin assistant_name so the agent never guesses it.
  4. X-Pinecone-Api-Version is fixed at 2026-07; leave it as is.

Answer questions from your documents

  1. listFiles to see which files the assistant holds and whether each is Available (still Processing files are not searched yet).
  2. chatWithAssistant with messages ([{"role": "user", "content": "..."}]). Keep stream false. Return the answer together with its citations (file name and pages) so the user can check the source.
  3. For a follow-up, send the earlier user and assistant messages again in messages; the API keeps no chat history.
  4. Use filter to limit the search to files with matching metadata (for example {"department": "legal"}).
  5. To build your own prompt instead of getting an answer, call retrieveContext with query (or messages) and optional top_k; it returns ranked snippets with file references.
  6. chatCompletions takes and returns the OpenAI chat format, without structured citations; use it only when that shape is needed.

Add or replace files

  1. Ask the user to confirm before uploading or replacing a file: it changes what every user of the assistant sees in answers.
  2. uploadFile (multipart file, optional metadata JSON) for a new file, or upsertFile with your own assistant_file_id to replace one in place.
  3. Both are asynchronous: poll describeOperation (or listOperations) until it has finished, then describeFile to confirm the file is Available.

Good to know

  • File ids come from listFiles (or are the id you chose on upsert); operation ids come back from upload and upsert.
  • Timestamps are ISO 8601 UTC. File status is Processing, Available or ProcessingFailed.
  • describeFile with include_url=true adds a temporary signed_url for downloading the original file; it expires quickly, so do not store it.
  • Deleting files or assistants is not in this spec; use the Pinecone console.

Source: Pinecone Assistant API reference (https://docs.pinecone.io/reference/api/2026-07/assistant/list_files), checked 2026-10-20.

How to use this spec

  1. Create a free VX Agents account (sandbox tools included).
  2. Open the marketplace and connect “Pinecone Assistant Files & Chat” to an agent.
  3. Expose it as an MCP server for Claude/ChatGPT, or chat with it directly.

Related APIs