See the Pinecone Node.JS SDK documentation for full installation instructions, usage examples, and reference information.

Install

To install the latest version of the Node.js SDK, written in TypeScript, run the following command:

npm install @pinecone-database/pinecone

To check your SDK version, run the following command:

npm list | grep @pinecone-database/pinecone

Upgrade

If you already have the Node.js SDK, upgrade to the latest version as follows:

npm install @pinecone-database/pinecone@latest

Initialize

Once installed, you can import the library and then use an API key to initialize a client instance:

import { Pinecone } from '@pinecone-database/pinecone';

const pc = new Pinecone({
    apiKey: 'YOUR_API_KEY'
});

Was this page helpful?