Skip to main content
ClickSend is a cloud-based communications platform that enables developers to send SMS, Email, Voice, Fax, and Post messages through a unified API.

Overview

Integration details

ClassPackageSerializablePython supportVersion
ClickSendTools@clicksend/langchain-clicksend-mcpnpm version

Tool features

  • SMS Messaging: Send text messages to mobile numbers worldwide
  • Email: Send transactional and marketing emails
  • Voice: Send automated voice messages and calls
  • MCP Integration: Connect via Model Context Protocol for seamless agent integration

Setup

The integration lives in the @clicksend/langchain-clicksend-mcp package.
npm install @clicksend/langchain-clicksend-mcp

Credentials

You’ll need a ClickSend account with API credentials. Sign up at clicksend.com to get your username and API key.
Set credentials
import dotenv from 'dotenv';
dotenv.config();

Instantiation

Initialize ClickSend tools by connecting to the ClickSend MCP server:
Initialize ClickSend
import { ClickSendTools } from "@clicksend/langchain-clicksend-mcp";

const tools = await ClickSendTools.fromHTTP({
  url: "https://mcp.clicksend.com",
  username: process.env.CLICKSEND_USERNAME,
  apiKey: process.env.CLICKSEND_API_KEY,
});

console.log(`Loaded ${tools.length} ClickSend tools`);

Invocation

Use the tools in your LangChain agent to send communications:
Use with an agent
import { ChatOpenAI } from "@langchain/openai";
import { createAgent } from "langchain";

// Create agent with tools
const agent = await createAgent({
  model: new ChatOpenAI({ 
    model: "gpt-4o-mini",
    temperature: 0 
  }),
  tools,
});

// Use the agent
const result = await agent.invoke({
  messages: [
    { role: "user", content: "Send an SMS to +1234567890 saying 'Hello from LangChain!'" },
  ],
});

console.log(result);

API reference

For detailed documentation of all features and configurations, please refer to the API reference. For more information about ClickSend’s services and pricing, visit clicksend.com.