404 returned ║ ║ HTTP status 404

I’m facing a persistent issue while working with Pinecone and Next.js 13. I’m trying to perform an upsert to a Pinecone index from a backend developed with Next.js 13, but I keep getting the following error:

roject Context:

  • I’m using Next.js 13 with the new file structure (app/api) to set up API Routes.
  • I’m using Pinecone’s official SDK (@pinecone-database/pinecone).
  • I’ve set up the API Route to handle GET and POST methods. The GET method lists the available indexes and seems to work fine.

Error saving embedding to Pinecone: A call to https://‘…’-‘//’'.pinecone.io/indexes/dev returned HTTP status 404.

Hi @edinsoncode. Welcome to the Pinecone community, and thanks for posting your question.

That error might mean that you’re trying to reach an index that doesn’t exist. Can you share more of your code, with sensitive info stripped, of course?

Best,
Jesse