Skip to content

Files

Latest commit

bb492b0 · May 21, 2025

History

History

salesforce-watsonx-apic-connector

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
May 21, 2025
Oct 16, 2024
Oct 16, 2024
Nov 1, 2024

README.md

salesforce-watsonx-apic-connector

Salesforce Open LLM Connector to watsonx.ai.

Description

This repository contains instructions on how to setup or connect to an IBM API Connect based connector that translates Salesforce Open LLM Connector specification to watsonx.ai API calls. There are 2 options to use the connector.

  1. A multi-tenant connector is already hosted on an IBM API Connect instance on IBM Cloud. It should be used only for PoC and testing. The API calls may be limited, and no high availability or performance guarantees are provided. This should not be used for production.

    Use the following URL to connect to the hosted service. Substitute the projectid and region parameters based on your watsonx.ai instance.

    https://dsce-apico-12e7a051-gateway-dsce-apiconnect.dsce-ocp-us-south-1-bx2-1-8516f8a0a0d756a8a5eb1ab83a990b56-0000.us-south.containers.appdomain.cloud/dsce-apic/sandbox?projectid=<your-wx-project-id>&region=<your-wx-region>

    Note: The hosted connector link may change over time. Please check for the latest URL on this page.

  2. Use the code and instructions in this repo to setup your own connector on an IBM API Connect instance.

Folder structure

code folder contains the connector code files.

resources folder contains resource documents.

  • llm-open-connector.yml: The connector code is built using this version of the Salesforce Open LLM Connector specification.
  • api-parameters-mapping.pdf: The documentation for mapping parameters from Salesforce Open LLM Connector specification to watsonx.ai API specification.

Setup steps

  1. Pre-requisites:

    • An IBM API Connect SaaS / Software instance. Get a free trial.

      Note: The current hosted connector uses IBM API Connect software version 10.0.6.0

    • A watsonx.ai instance on IBM cloud (get a watsonx trial account).
  2. In IBM API Connect manager, add a new API.

    image

  3. Import the Salesforce Open LLM Connector specification as shown here.

    image

    image

    image

    image

  4. Switch to 'Source' view.

    image

  5. Replace the full source with the content provided in code/apic-converter.yml file.

    image

  6. 'Save' the changes.

  7. Make the API online.

    image

  8. Go to 'Test' tab on the UI to test the API.

    image

    Alternatively, use code/test-connection.js file from your local machine to test the API.

       node test-connection.js
  9. API Connect is configured with some default properties as shown here.

    image

  10. Create a new connection to watsonx.ai model from your Salesforce Einstein Studio using a recipe.