GATUM
By Sempico Solutions

Content Autoreplacement Rules for Aggregator: How to Create?

The GATUM platform is quite flexible and automated, so the process of sending SMS traffic is quite easy and fast. One of the functions that ensures secure SMS sending is autoreplacement SMS content sent to the aggregator. With the help of ready-made or created by you rules, you can regulate the content of SMS, in accordance with your or general requirements. In this mechanism, it is possible to use both rules created by developers, they are called macros, or create your own, based on the content of the traffic passing through your platform.

When you set a content autocorrect rule for an aggregator, then all traffic sent to this aggregator, regardless of the client, will go through these rules.

In order to create a rule for an aggregator, you need:

  1. Go to the Current traffic -> Routing -> Aggregators page.
  2. Click on the eye icon in the line of the aggregator you need.
create-the-autoreplacement-rule-for-aggregator
  1. In the Replacement rules block, click the green Create button.
start-creating-the-autoreplacement-rule-for-aggregator

Let’s create an example rule. For example, you want the word code to be replaced with password in all SMS of this aggregator.

  1. In the Destination field, select the direction for which this rule will apply.
  2. In the ID User field, if necessary, select the client, when sending SMS from which this rule will apply. You can choose not to choose a specific one and then the rule will apply to all clients.
  3. In the Sender field, if necessary, write the name of the sender and then the rule will apply only for those SMS that have this sender’s name. You can leave this field blank and the rule will apply to all names.
set-main-configurations-for-the-rule
  1. In the Search message field, enter the search phrase, in this case code.
enter-the-word-to-replace-in-sms
  1. In the Replace message field, enter a replacement phrase, in this case password.
set-the-word-of-replacing
  1. In the Priority field, enter the priority for this rule. The unit is the highest priority.
priority-for-the-rule
  1. Click on the green Save button.
save-the-rule-of-autoreplacement-for-aggregator

Now, when this client sends SMS, the content of which will contain the word code, it will be replaced with the word password.

There are also rules built by developers. One of the built-in replacement rules is the replacement of Arabic or Roman numerals with Persian. In the dropdown line, you will need to select the Persian digits value.

The NULL rule erases the value you specify in the Searched phrase string. For example, you do not want the word dump to appear in the SMS content, set up this rule and now in every SMS where the word dump is found, it will be erased.

content-auto-replacement-mechanisms-for-aggregator

In addition, there are macros that perform specific actions on content.

Macro {SAVEDIGITS} – searches and saves stand-alone digits. For example, you send your customers passwords consisting of numbers, and in order not to manually create many SMS with different passwords, you can use macros. This macro searches for and remembers phrases consisting of numbers, but does not replace them. Also, if you send passwords in parentheses or quotes, you will need to create rules to remove them: one rule for the left parenthesis / quote, another rule for the right parenthesis / quote. That is, there must be spaces or emptiness in front and after the phrase of numbers. Also, if you have other free-standing numbers in your message, the {SAVEDIGITS} macro will remember them too, so you will need to create a rule that will remove them.

auto-replace-content-macros-for-aggregator

The same principle of action with the {SAVEURL} macro, only now this rule will remember not a phrase of numbers, but a link.

Again, the {SAVEPHONE} macro, it searches and remembers phone numbers in SMS content. It is important to remember that for all three macros the search phrase must be free-standing, separated by spaces or empty.

The {EMPTY} macro is used in cases where the SMS has no text at all. That is, according to the created rule {EMPTY}, the system finds SMS that have no content and replaces them with the text specified in the Replacement field of this rule. This is often used if many rules for replacing content have been established and there is a possibility that after passing the rules, nothing will remain in the SMS content at all. Then the text from the Replacement field will be sent.

Macro {TRIM} – removes spaces at the beginning and at the end of SMS. For example, if there is an SMS “Hi, Steve”, it will remove only spaces at the beginning and at the end, they will remain between words. The text will end up like “Hi Steve”.

Macro {TRIM-RTL} – removes the character that reverses the spelling of text from right to left. This is used when working with content in Arabic and Hebrew. The macro removes this character and the SMS will go in the usual direction from left to right.

Macro {UPPERCASE} – converts all SMS text to upper case.

Macro {LOWERCASE} – converts all SMS text to lower case.

Macro {CLEAR} – erases all SMS content, erases text.

Macro {CUTONEPART} – cuts SMS to 1 part, the first part remains, all the rest are erased.

Macro {CUTIFMORE} – removes unnecessary parts from SMS if there are more of them as a result of content replacement rules.

It is not necessary to enter any values ​​in the Replacement field when using these macros:

Macro {BEGIN} – inserts at the beginning of the SMS the value that you define in the Replacement field. Here you can use the data found by the {SAVEDIGITS}, {SAVEURL} and {SAVEPHONE} macros, which you put in the Replacement field, just change it to {PHONE}, {URL} and {DIGITS}. For example, using the {SAVEDIGITS} rule, the system found a code or password, and now, through the {BEGIN} rule, it will insert it at the beginning of the SMS. That is, there was an SMS “- your code”, the system remembered the code 743564 from the previous SMS and will now insert it into this SMS. It will come out like this: “743564 – your code”. This works if the two rules are configured together for the same client.

The {END} macro works similarly, only it inserts the value from the Replacement field at the end of the SMS.

Macros {RANDOM_SYMBOLS_BEGIN} and {RANDOM_SYMBOLS_END} – insert random characters at the beginning or at the end of SMS, respectively. The number of characters is indicated in the Replacement field.

Similar macros {RANDOM_DIGITS_BEGIN} and {RANDOM_DIGITS_END} – only they already insert not symbols, but numbers. The number of digits is also indicated in the Replacement field.

And the last macro is {CUTBYLENGTH}. It truncates the SMS text to a certain number of characters specified in the Replacement field. This rule minimizes the likelihood of an increase in the cost of SMS, which can be triggered by an increase in parts of SMS.

If necessary, if you want to automate a rule for closing certain tasks, contact our developers and they will make an individual macro for you.

In addition, this mechanism has the ability to give priority to rules, put them in a logical order. For example, you have set up the {SAVEDIGITS}, {END}, and {CUTBYLENGTH} rules for a client. It is logical that the system must first find the numbers, then insert them at the end, then check for the allowed number of characters. Therefore, the rule {SAVEDIGITS} will have the highest priority – 1, lower priority will be for {END} – 2, and the lowest for {CUTBYLENGTH} – 3.

With the help of the SMS content autocorrect mechanism, you can protect your traffic from unnecessary content, save time and increase its efficiency.

Share the Post: