Skip to main content

Salesforce Tool

This tool connects to a Salesforce environment and allow the Agent to perform SOQL and SOSL queries.

Usage

This tool is a wrapper tool using the simple salesforce library. More information on this library here

Here's an example usage of the Salesforce Tool:

from llama_index.tools.salesforce import SalesforceToolSpec
from llama_index.core.agent.workflow import FunctionAgent
from llama_index.llms.openai import OpenAI

# Initialize the tool with your Salesforce credentials and other relevant details
sf = SalesforceToolSpec(
    username=sf_username,
    password=sf_password,
    consumer_key=sf_consumer_key,
    consumer_secret=sf_consumer_secret,
    domain="test",
)

agent = FunctionAgent(
    tools=sf.to_tool_list(),
    llm=OpenAI(model="gpt-4.1"),
)

print(await agent.run("List 3 Accounts in Salesforce"))
print(await agent.run("Provide information on a customer account John Doe"))

execute_sosl - Returns the result of a Salesforce search as a dict decoded from the Salesforce response JSON payload.

execute_soql - Returns the full set of results for the query. The returned dict is the decoded JSON payload from the final call to Salesforce, but with the totalSize field representing the full number of results retrieved and the records list representing the full list of records retrieved.

This loader is designed to be used as a way to load data as a Tool in a Agent.

Metadata

Release files for llama-index-tools-salesforce 0.6.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for llama-index-tools-salesforce 0.6.0
File Size Uploaded Provenance Actions
llama_index_tools_salesforce-0.6.0.tar.gz 4.1 kB Without provenance Details for llama_index_tools_salesforce-0.6.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for llama-index-tools-salesforce 0.6.0
File Interpreter ABI Platform Actions
llama_index_tools_salesforce-0.6.0-py3-none-any.whl Python 3 none any Details for llama_index_tools_salesforce-0.6.0-py3-none-any.whl

Total release size: 7.9 kB

Release files / llama_index_tools_salesforce-0.6.0.tar.gz

Download URL llama_index_tools_salesforce-0.6.0.tar.gz
Size 4.1 kB
Tags Source
SHA-256 checksum
How to use checksums
5d4e039f0a6195c85f77cfac7d2b266a900a2c77e82a0e32190476d6c198a122
BLAKE2b-256 checksum
How to use checksums
50167ece1c45d5fcdb4dc20ab812ce9acbcff5bf82ddbba7493b31070686d538
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.12.7 {"installer":{"name":"uv","version":"0.12.7","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Release files / llama_index_tools_salesforce-0.6.0-py3-none-any.whl

Download URL llama_index_tools_salesforce-0.6.0-py3-none-any.whl
Size 3.8 kB
Tags Python 3
SHA-256 checksum
How to use checksums
e1040bb7a2979dc2b07dad9e73596e4bea2a3a038f98900fc42c38c2c7666f6c
BLAKE2b-256 checksum
How to use checksums
2363eb97920f37571832669c9d8eab5bdd0978e5da609d7a45a5b3dc214dc0eb
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.12.7 {"installer":{"name":"uv","version":"0.12.7","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Security for llama-index-tools-salesforce 0.6.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page