How to send SMS through SMPP from LibreChat
This guide explains how to connect LibreChat to Ozeki SMS Gateway's built in SMS MCP server, enabling the AI assistant to send and receive SMS messages through your own on-premises SMS gateway. You will learn how to install Ozeki SMS Gateway, create an MCP user account, generate an API key, register the MCP endpoint in LibreChat, and verify the setup by sending a test message.
Solution: How to send SMS from LibreChat
LibreChat connects to the SMPP SMS MCP Server through the MCP protocol, where LibreChat acts as the MCP client and Ozeki SMS Gateway acts as the MCP server. Ozeki SMS Gateway is installed on your local machine or server and connects to the SMS service provider over the internet using an SMPP client connection. When an SMS is sent, it first travels from LibreChat to the Ozeki SMS Gateway as an MCP tool call, and the gateway forwards it to the SMS service provider over SMPP, which delivers it to the recipient's mobile phone.
What is LibreChat?
LibreChat is an open-source, self-hosted chat application that supports multiple AI providers including OpenAI, Anthropic, and locally hosted models. It can be deployed using Docker and supports MCP servers, which allows it to be extended with external tools such as SMS messaging, database access, and more.
What is an SMPP SMS MCP Server?
An SMPP SMS MCP Server is a standardized software bridge that uses the Model Context Protocol to connect AI assistants (like Claude) to an SMS gateway system such as Ozeki SMS Gateway, which in turn delivers messages to the mobile network over an SMPP client connection. It exposes tools like "send_message" or "list_incomings" that an AI can autonomously call to perform real-world texting tasks without custom coding. This allows users to simply ask an AI to "send John a reminder text" and have the AI securely execute the action through the server. The SMS MCP Server built into Ozeki SMS Gateway also makes receiving SMS messages possible.
Download Ozeki SMS Gateway
To use this solution you need to install the SMS Gateway on your system.
Download the software: SMS Gateway
https://ozeki-sms-gateway.com/p_727-download-sms-gateway.html
Steps to follow
You will need LibreChat installed on your system. If you have not set it up yet, follow our LibreChat installation guide.
- Install Ozeki SMS Gateway
- Setup the SMPP SMS connection
- Create an MCP user account
- LibreChat SMS MCP Server Config
- Add the SMS MCP Server config to LibreChat
- Send a test SMS
- Check the SMS in the SMS Gateway logs
Install Ozeki SMS Gateway
For a full tutorial on installing Ozeki SMS Gateway, check out our How to install Ozeki SMS Gateway on Windows guide.
Before you can use the SMS MCP Server, you need to install Ozeki SMS Gateway on your Windows machine or server. Download the installer zip file from the website, extract it, and run the executable to complete the installation. Once installed, the gateway will start automatically and its web-based management interface will be accessible from your browser.
Setup the SMPP SMS connection
For a full tutorial on setting up an SMPP Client connection, check out our SMPP Client Connection guide.
Before creating the MCP user, you need to connect Ozeki SMS Gateway to the mobile network by setting up an SMPP client. In the Connections panel, select Add new connection, and install a new SMPP client connection. Enter the host, port, and credentials provided by your SMS service provider, then save and activate the connection to bring the gateway online.
Create an MCP user account
For a full tutorial on creating an MCP User, check out our Create an MCP User guide.
Click Add new user/application, and select the MCP user type from the list. Enter a username and password for the account, then open the Advanced tab to generate an API key. Copy this key and store it in a safe location, as you will need it in the next steps.
LibreChat MCP server configuration
# librechat.yaml ->
mcpSettings:
allowedDomains:
- "{address}"
# For example: - "192.168.88.15"
# Restart the Docker container to apply changes
docker compose down
docker compose up -d
# LibreChat address
http://localhost:3080/
# Add the MCP server with the following details:
Name: Ozeki
MCP Server URL: http://{address}:9529/mcp
Transport: Streamable HTTP
Authentication: API Key
Example prompt
Send an SMS to +36301234567, the message should be "Hello from LibreChat".
Add the SMS MCP Server config to LibreChat
The following video shows how to add the Ozeki SMPP SMS MCP Server to LibreChat step-by-step.
Open the librechat.yaml configuration file in a text editor. This file
controls LibreChat's behavior, including which external domains are permitted to be
used as MCP server endpoints (Figure 1).
Locate the mcpSettings section in the file and add your Ozeki SMS
Gateway's IP address or hostname under allowedDomains as shown below (Figure 2).
mcpSettings:
allowedDomains:
- "{address}"
Save the configuration file and close the text editor. The change will not take effect until the Docker container is restarted in the next step (Figure 3).
Open a terminal in your LibreChat folder (Figure 4).
Run the following commands to stop and restart the LibreChat Docker container.
This reloads the updated librechat.yaml configuration (Figure 5).
docker compose down docker compose up -d
Open LibreChat in your browser at http://localhost:3080/ and log in.
Navigate to the MCP Servers section in the interface and click Add to open
the MCP server registration window (Figure 6).
Enter Ozeki as the server name and enter the URL of your Ozeki SMS
Gateway in the MCP Server URL field following the format
http://{address}:9529/mcp. Make sure Streamable HTTP
is selected as the transport type (Figure 7).
Set the Authentication type to API Key -> Bearer and paste the API key you generated for your MCP user account into the token field. Check the I trust this application checkbox, then press Create to save the MCP server entry (Figure 8).
The Ozeki MCP server will now appear in the MCP server list. Click the Connect button next to it to establish the connection. Once connected, the SMS tools exposed by the SMS Gateway will be available (Figure 9).
Send a test SMS
The following video shows how to send an SMS message from LibreChat using the Ozeki SMPP SMS MCP server step-by-step.
Before sending a message, verify that the Ozeki MCP server is connected in LibreChat. If it is not connected, open the MCP Servers list and click the Connect button before proceeding (Figure 10).
In the chat input, type your SMS request in plain language and press the Send button. The AI model will interpret the request and invoke the appropriate MCP tool to deliver the message (Figure 11).
Send an SMS to +36301234567, the message should be "Hello from LibreChat".
Once the tool has been executed, the result will appear in the chat. A successful response confirms that the message was submitted to the gateway and handed off for delivery (Figure 12).
Check the SMS in the SMS Gateway logs
The following video shows how to check the SMS in the logs in Ozeki SMS Gateway step-by-step.
Open Ozeki SMS Gateway in your browser and navigate to the MCP user details page by clicking on the MCP user entry in the Users and applications panel (Figure 13).
In the MCP user event log, you should see an entry for the outgoing message, including the recipient number and message text, confirming that it was successfully processed by the gateway (Figure 14).
Conclusion
In this guide, you have learned how to connect LibreChat to Ozeki SMS Gateway's built-in SMS MCP Server and use it to send SMS messages directly from the chat interface. By installing the gateway, setting up an SMPP connection to the mobile network, creating an MCP user account, and registering the MCP endpoint in LibreChat, you now have a fully functional on-premises SMS integration that your locally hosted AI model can use to communicate with any mobile phone.