Skip to main content

langchain-sendmux

LangChain toolkit for Sendmux, the email API for AI agents. Give a LangChain agent tools to send email and read its own inbox.

Installation

pip install langchain-sendmux

Usage

import os

from langchain.agents import create_agent
from langchain_sendmux import SendmuxToolkit

smx = SendmuxToolkit(api_key=os.environ["SENDMUX_API_KEY"])

agent = create_agent(
    model="gpt-4o",
    tools=smx.get_tools(),
    system_prompt="You triage the support inbox.",
)

agent.invoke({"messages": [{"role": "user", "content": "Reply to Sarah."}]})

Tools

SendmuxToolkit(api_key=...).get_tools() returns three tools:

  • send_email - send an email to any recipient through Sendmux.
  • list_messages - list recent messages in the agent's mailbox.
  • reply - send a message from the agent's own mailbox.

Configuration

  • api_key (required) - a send + receive capable mailbox API key (smx_mbx_*) or a scoped agent token.
  • default_from (optional) - default From address for send_email when a call omits var_from.

Licence

MIT. See the licence file.

Download files

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

Source Distribution

langchain_sendmux-0.2.0.tar.gz (3.6 kB view details)

Uploaded Source

Built Distribution

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

langchain_sendmux-0.2.0-py3-none-any.whl (4.7 kB view details)

Uploaded Python 3

File details

Details for the file langchain_sendmux-0.2.0.tar.gz.

File metadata

  • Download URL: langchain_sendmux-0.2.0.tar.gz
  • Upload date:
  • Size: 3.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.13

File hashes

Hashes for langchain_sendmux-0.2.0.tar.gz
Algorithm Hash digest
SHA256 a1c3aed88bdc2f9af2e2ac3cad9063d4638af524c53e56afda0a108f2006674d
MD5 d0a1234c0494628748629d9ba6cbaa24
BLAKE2b-256 4b0b20a4f0d0d80514c640535418a0940f7b84732f8d9d0ab5f1c5fda88a6007

See more details on using hashes here.

Provenance

The following attestation bundles were made for langchain_sendmux-0.2.0.tar.gz:

Publisher: release-please.yml on Sendmux/sendmux-sdk

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

File details

Details for the file langchain_sendmux-0.2.0-py3-none-any.whl.

File metadata

File hashes

Hashes for langchain_sendmux-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 7719ad364ace9fb3c3ded8b80a4bf22fd3fc3bd7299062cdcb907182b933a0f8
MD5 98d7c27437db7395f90f9a3cc4da8b77
BLAKE2b-256 a84deea5e37e9633e16c5ec790c23c868617314b962ea0433861a0f48710c52c

See more details on using hashes here.

Provenance

The following attestation bundles were made for langchain_sendmux-0.2.0-py3-none-any.whl:

Publisher: release-please.yml on Sendmux/sendmux-sdk

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 Sentry Error logging StatusPage Status page