> For the complete documentation index, see [llms.txt](https://docs.localmail.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.localmail.io/messaging/smpp/submitting-messages-through-smpp.md).

# Submitting Messages Through SMPP

## Submission Types

Messages may be submitted with either submit\_sm or data\_sm, using either the short\_message or message\_payload fields. The message length may not exceed the byte limit for the network that the message is being sent to.

For example, it takes 140 bytes on GSM networks

* Local Mail SMPP does not support submit\_multi. If the same message has to be sent to multiple destinations, each message must be sent separately.
* Concatenated messages are supported by using the User Data Header (UDH), which is included in the message size byte limit

## Submit Responses

1. A positive response to a submit will contain an error code of zero and a non-null message reference.
2. A negative response will contain a localmail [vendor-specific error code](https://docs.localmail.io/messaging/smpp/smpp-error-codes).

## Character Sets, Class and Data Coding

1. Local Mail SMPP supports the following two types of data coding schemes:\
   • GSM 03.38 Encoding (default)\
   • Latin 1 (ISO-8859-1) encoding

The default character set is GSM 338. Although for data\_coding=1 the character set GSM 03.38 is supported, it is NOT RECOMMENDED, as it is known to cause problems with character encoding.

#### **Message Encoding**

Please set data\_coding = 3 for ISO-8859-1(if and only if told so explicitly) encoded messages and data\_coding=0 for GSM 03.38 encoded messages.

#### **Unicode Messages**

For Unicode messages you have to set data\_coding = 8 and the message is expected in UTF-16 Big Endean format.

## Originators and Destination

The default originator type is full International MSISDN. Alpha numeric or network short code\
originators can be sent by using the following **ton values** in **source\_addr\_ton** field.

• Alphabetic 5\
• National / Network Short Code 3\
• International MSISDN 1

Destination Address types are not supported. They can be set to any value but are always interpreted as follows

1. This requires all the destination numbers to be sent in an international format without the leading 00.

## Long Messages

Long Messages, as the name suggests, are messages whose length exceeds the normal length imposed on short messages (160 for text SMS and 70 for Unicode SMS).

## Concatenated Messages

In this method, the long message is sent in parts as multiple short messages which are then\
displayed as a single SMS on the mobile phone.

#### **Note:** The messages will be joined together on the mobile phone only if the mobile supports long messages; else each message part will be displayed as a separate message.

In this method the client sends the UDH (User Data Header) as part of the short\_message\
field. The UDH contains all the details required for the mobile join the parts and make the\
complete message at its end. In this method the client has to set the esm\_class field in the submit\_sm pdu to 0x43 (Store and Forward with UDHI)

## Message Payload

Local Mail SMPP can accept a message with a length up to 64K octets.&#x20;

In this method the client uses the optional message\_payload of the submit\_sm pdu.

To use this method the client should set the interface\_version to 0x34; without which this field will not be available for sending messages.

### Need More Help?

If you need any further Help During your Integration or questions related to technical know-how, you can reach out to our support team at **<support@localmail.io>**


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.localmail.io/messaging/smpp/submitting-messages-through-smpp.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
