How to send SMS from HTTP API

This guide explains how to install and configure Ozeki SMS Client on an Android phone, enable its HTTP API service, and send SMS messages through the phone’s SIM card. You will learn how to test the API with Postman and cURL, then use the built-in web interface and logs to verify requests and troubleshoot message delivery.

How does it work

How does it work

End-to-End Message sending Flow

sequenceDiagram autonumber participant Client as Postman or cURL participant API as Ozeki SMS Client HTTP API participant Android as Android SMS Service participant SIM as SIM / Mobile Network Client->>API: POST /api/sms/send
Authorization: Bearer token
JSON: to, text, subscription_id API->>Android: Submit outgoing SMS request Android->>SIM: Send SMS through SIM card SIM-->>Android: Submission result Android-->>API: Message accepted or sent API-->>Client: Success response

How to install the Ozeki SMS Client on Android

The following video tutorial takes you through the steps of Installing the Android SMS Client software on your Android mobile. Note, that you will need to download the Android SMS app from android-sms-gateway.com. After installation make sure you enable the necessary permissions for Ozeki app. This will enable the app to run seamlessly in the background.

Installation steps

Open the Android SMS Gateway download page in the phone’s browser. Download the Ozeki SMS Client APK installation package. Wait until the download finishes before opening the file.

Download APK file

Figure 1 - Download APK file

Open the downloaded APK from the browser notification or Downloads folder. Android may display a security prompt because the app was not installed from Google Play. Continue to the installation settings when prompted.

Open APK file

Figure 2 - Open APK file

Tap Settings in the Android security warning dialog. This opens the permission page for the app that downloaded or opened the APK. The next step is to allow that app to install external applications.

Open Settings

Figure 3 - Open Settings

Enable Allow from this source or Install unknown apps. This temporarily authorizes the browser or file manager to install the Ozeki APK. Return to the installation screen after enabling the setting.

Allow to install unknown apps

Figure 4 - Allow to install unknown apps

Android may warn that installing apps from unknown sources can be unsafe. Confirm the warning only after verifying that the APK was downloaded from the official source. This allows the Ozeki SMS Client installation to continue.

Accept danger

Figure 5 - Accept danger

Tap Install to copy and install the Ozeki SMS Client on the phone. Keep the phone unlocked and wait for Android to complete the process. When installation finishes, select Open to launch the application.

Install Ozeki SMS Client

Figure 6 - Install Ozeki SMS Client

Android or Google Play Protect may scan the newly installed application. Allow the scan to finish so the installation can be reviewed for potential risks. If the official Ozeki application is confirmed, proceed with the installation.

Scan app

Figure 7 - Scan app

If Play Protect displays a warning, select Install anyway for the verified Ozeki APK. Use this option only when the file came from the official Android SMS Gateway site. The application can then be installed and started normally.

Install Anyway

Figure 8 - Install Anyway

Launch the Ozeki SMS Client from the installation screen or app drawer. The application provides a local web interface and HTTP API for SMS sending. Keep it installed on the Android phone that contains the SIM card.

Open Ozeki SMS Client app

Figure 9 - Open Ozeki SMS Client app

How to start HTTP API service

In Ozeki SMS Client, start the HTTP Service from the main screen. The service listens for web requests sent to the phone over the local Wi-Fi network. Note the displayed IP address and port for opening the browser interface later.

Start HTTP Service

Figure 10 - Start HTTP Service

Accept the requested Android permissions when the application asks for them. These permissions are necessary for sending SMS messages and maintaining service operation. Without them, the HTTP interface may be available but cannot send messages correctly.

Allow permissions

Figure 11 - Allow permissions

Open the Android application settings for Ozeki SMS Client. Review the permissions, battery, and restricted-settings options available for the app. Configure them so the gateway can continue working in the background.

Open APP settings

Figure 12 - Open APP settings

Enable restricted settings for Ozeki SMS Client if Android blocks sensitive permissions. This makes it possible to grant the app the access it needs for gateway operation. Return to the app’s permission page once the setting is enabled.

Allow restricted settings

Figure 13 - Allow restricted settings

Grant the SMS permission to Ozeki SMS Client. This permission allows the Android phone to submit outgoing SMS messages through its SIM card. It is essential for messages sent from the browser or HTTP API.

Allow SMS permission

Figure 14 - Allow SMS permission

Grant camera permission if the application requests it for QR-code or setup functions. This can simplify connection or configuration tasks within the Ozeki application. The core SMS sending workflow still depends primarily on SMS and network access.

Allow Camera permission

Figure 15 - Allow Camera permission

Set battery usage for Ozeki SMS Client to Unrestricted or disable battery optimization. This prevents Android from stopping the HTTP service while the phone is idle. The gateway can then remain reachable from the browser for longer periods.

Disable battery restrictions

Figure 16 - Disable battery restrictions

Verify that the HTTP Service status is shown as running in Ozeki SMS Client. Use the displayed local IP address and port as the browser access address. Ensure the phone stays connected to Wi-Fi while you send SMS messages.

HTTP Service running

Figure 17 - HTTP Service running

How to send SMS from Postman

Open Postman and create a new HTTP request for the Ozeki SMS Client API. Enter the phone’s HTTP Service address, including its local IP address and port, as the request URL. Use the SMS-sending API endpoint so Postman sends the request directly to the Android gateway.

Set SMS Client URL in Postman
Figure 18 - Set SMS Client URL in Postman

Open the Authorization tab in Postman and select the authentication method configured in Ozeki SMS Client. Provide the appropriate username and password or other required credentials for the HTTP API. Authentication ensures that only authorized clients can submit SMS messages through the gateway.

Set authentication in Postman
Figure 19 - Set authentication in Postman

Configure the request body with the recipient telephone number and the SMS text to deliver. Check that the HTTP method, URL, authentication, and message parameters are correct before sending. Click Send to submit the SMS request from Postman to the Ozeki SMS Client.

Send message
Figure 20 - Send message

Review the response returned by the API after submitting the request. A successful response confirms that the gateway accepted the message for processing and delivery. If the request fails, use the returned status and error details to identify configuration or connectivity issues.

Message sent successfully
Figure 21 - Message sent successfully

How to send SMS from Curl

Open a command prompt, terminal, or shell on a computer that can reach the Android phone over the network. Ensure that curl is installed and that the phone’s HTTP Service is running. You will use the command line to call the same HTTP API without a graphical client.

Open command line
Figure 22 - Open command line

Run a curl command that targets the Ozeki SMS Client API URL and includes valid authentication details. Supply the destination phone number and message text using the API parameters or request body required by the endpoint. The command sends the request to the Android gateway, which uses its SIM card to transmit the SMS.

curl --location "http://192.168.0.100:9532/api/sms/send" ^
  --header "Content-Type: application/json" ^
  --header "Authorization: Bearer 91f5cb8ca47bd2a0c21d3344ff0e8d02" ^
  --data "{\"to\": \"+36201234567\",\"text\": \"Hello from Ozeki HTTP API\",\"subscription_id\": 1}"

Send message using Curl
Figure 23 - Send message using Curl

Inspect the response printed by curl after the request completes. A successful API result shows that the gateway received and accepted the SMS submission. Keep the response when troubleshooting, as it can reveal authentication, network, or request-format errors.

Message sent successfully
Figure 24 - Message sent successfully

How to check logs

Open a web browser and navigate to the HTTP Service address displayed by Ozeki SMS Client. Sign in with the credentials configured for the gateway’s web interface. The interface provides access to message activity, configuration, and diagnostic information.

Login to web interface
Figure 25 - Login to web interface

Select the Logs tab after successfully signing in to the web interface. This section records gateway events and provides visibility into HTTP requests and SMS processing. Use it when you need to confirm whether a submitted message reached the Android SMS Client.

Open Logs tab
Figure 26 - Open Logs tab

Review the messaging log entries to see submitted, accepted, sent, or failed SMS operations. Each entry helps correlate an API request with its processing result and any reported error. Logs are especially useful for diagnosing invalid recipients, authentication failures, network problems, or SIM-related delivery issues.

Messaging logs
Figure 27 - Messaging logs


More information