Skip to main content

A Salesforce API Adapter for Python

Project description

Salesforce Toolkit for Python

A modern, Pythonic interface to Salesforce APIs.

Features

  • Clean, intuitive API design
  • Both synchronous and asynchronous client support
  • Simple SObject modeling using Python classes
  • Powerful query builder for SOQL queries
  • Efficient batch operations
  • Automatic session management and token refresh

Installation

pip install sf-toolkit

Quick Start

from sf_toolkit import SalesforceClient, SObject, cli_login, query
from sf_toolkit.data.fields import IdField, TextField

# Define a Salesforce object model
class Account(SObject):
    Id = IdField()
    Name = TextField()
    Industry = TextField()
    Description = TextField()

# Connect to Salesforce using the CLI authentication
with SalesforceClient(login=cli_login()) as sf:
    # Create a new account
    account = Account(Name="Acme Corp", Industry="Technology")
    account.save()

    # Query accounts
    result = Account.query().execute()

    for acc in result:
        print(f"{acc.Name} ({acc.Industry}) {acc.Description}")

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

sf_toolkit-0.3.0.tar.gz (36.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

sf_toolkit-0.3.0-py3-none-any.whl (45.3 kB view details)

Uploaded Python 3

File details

Details for the file sf_toolkit-0.3.0.tar.gz.

File metadata

  • Download URL: sf_toolkit-0.3.0.tar.gz
  • Upload date:
  • Size: 36.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for sf_toolkit-0.3.0.tar.gz
Algorithm Hash digest
SHA256 80f3acc537ac87dc27d900888d6a4eae1a62625be938a71d03448d511557928c
MD5 7936022867c030a387f44841969037c4
BLAKE2b-256 2d648f7dea2d3d61b94197088ee006fd10bdf13f95f6ae7a9740fcd55ba0fded

See more details on using hashes here.

Provenance

The following attestation bundles were made for sf_toolkit-0.3.0.tar.gz:

Publisher: pypi-publish.yml on AndroxxTraxxon/python-sf-toolkit

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file sf_toolkit-0.3.0-py3-none-any.whl.

File metadata

  • Download URL: sf_toolkit-0.3.0-py3-none-any.whl
  • Upload date:
  • Size: 45.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for sf_toolkit-0.3.0-py3-none-any.whl
Algorithm Hash digest
SHA256 cb8961ae0d79b69737430d7b4c441effd627bf1046db043ca2dae545081ede06
MD5 014be38f3e88d6f13d362897a8fef273
BLAKE2b-256 d143ad6148ca7ddf5ff3961fc39d419b6df7940a9e63f408d021b21aee63f962

See more details on using hashes here.

Provenance

The following attestation bundles were made for sf_toolkit-0.3.0-py3-none-any.whl:

Publisher: pypi-publish.yml on AndroxxTraxxon/python-sf-toolkit

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page