Skip to main content

Destination

Nexla's bi-directional connectors allow data to flow both to and from any location, making it simple to create a FlexFlow, DB-CDC, Spark ETL, or Replication data flow that sends data to a Pinecone API endpoint.
pinecone_api.png

Pinecone API

Create a Pinecone Destination

  1. Click the + icon on the Nexset that will be sent to the Pinecone destination, and select the Send to Destination option from the menu.

  2. Select the Pinecone API connector from the list of available destination connectors. Then, select the credential that will be used to connect to your Pinecone account, and click Next; or, create a new Pinecone APIcredential for use in this flow.

  3. In Nexla, Pinecone API destinations can be created using pre-built endpoint templates, which expedite destination setup for common Pinecone endpoints. Each template is designed specifically for the corresponding Pinecone endpoint, making destination configuration easy and efficient.
    • To configure this destination using a template, follow the instructions in Configure Using a Template.

    Pinecone API destinations can also be configured manually, allowing you to send data to Pinecone endpoints not included in the pre-built templates or apply further customizations to exactly suit your needs.
    • To configure this destination manually, follow the instructions in Configure Manually.

Configure Using a Template

Nexla provides pre-built templates that can be used to rapidly configure destinations to send data to common Pinecone endpoints. Each template is designed specifically for the corresponding Pinecone endpoint, making destination setup easy and efficient.

  • To configure this destination using a template, select the endpoint to which data will be sent from the Endpoint pulldown menu. Then, click on the template in the list below to expand it, and follow the instructions to configure additional endpoint settings.

    Upsert Vectors

    This endpoint template writes vectors into a namespace in your Pinecone index using records from a Nexset. Use this template when you need to insert or update vectors in your Pinecone index for similarity search, recommendation systems, or other AI-powered applications. Check out the documentation URL for more details on record schema.

    • Enter the namespace in the Namespace field. This should be the namespace name where you want to upsert vectors. The namespace determines which namespace will receive the vectors. Leave this field empty to upsert vectors to the default namespace. Note: Namespaces are not supported by projects on the gcp-starter environment.

    This endpoint sends data as JSON in the request body to upsert vectors into your Pinecone index. The endpoint uses batch mode to efficiently send multiple vectors in a single request. Each record from your Nexset will be included in the batch, and vectors will be upserted in batches of up to 20 vectors per request.

    The vector structure must match the Pinecone API's expected format. Each vector should include an ID, vector values, and optional metadata. Check out the documentation URL for more details on record schema. For detailed information about vector upsert, request body formats, batch processing, and available vector properties, see the Pinecone API documentation.

Configure Manually

Pinecone API destinations can be manually configured to send data to any valid Pinecone API endpoint. Manual configuration provides maximum flexibility for accessing endpoints not covered by pre-built templates or when you need custom API configurations.

Using manual configuration, you can also configure Nexla to automatically send the response received from the Pinecone API after each call to a new Nexla webhook data source.

API Method

  1. To manually configure this destination, select the Advanced tab at the top of the configuration screen.

  2. Select the API method that will be used for calls to the Pinecone API from the Method pulldown menu. Pinecone API typically uses POST method for upserting vectors.

Data Format

  1. Select the format in which the Nexset data will be sent to the Pinecone API from the Content Format pulldown menu. Pinecone API expects JSON format for all requests.

API Endpoint URL

  1. Enter the URL of the Pinecone API endpoint to which data will be sent in the URL field. This should be the complete URL including your index host URL (from your credential), the API path (e.g., /vectors/upsert), and any required query parameters. Include any required path parameters in the URL.

Ensure the API endpoint URL is correct and accessible with your current credentials. The Pinecone API endpoint URL should point to the endpoint where you want to upsert vectors. The endpoint URL should include your index host URL and the appropriate API path. You can test the endpoint using the Test button after configuring the URL.

Request Body

  1. Configure the request body that will be sent to the Pinecone API. The request body should contain the vector data formatted as JSON, with field names matching the Pinecone API's expected structure. The request body format is typically {message.json} to send the entire Nexset data as JSON, or you can construct a custom JSON structure with specific field mappings. For batch operations, you may need to format the request body to include a vectors array containing multiple vectors.

The request body must be valid JSON and must match the Pinecone API's expected format for the specific endpoint you're using. Pinecone API uses specific structures for different endpoints (upsert, delete, etc.). Each vector should include an ID, vector values, and optional metadata. For detailed information about request body formats, available endpoints, and vector structures, see the Pinecone API documentation.

Save the Destination

  1. Once all of the relevant steps in the above sections have been completed, click the Next button to proceed with the rest of the data flow configuration, or click Save to save the destination configuration for later use.