Skip to content

Technical

Components

Addon Manual SMS uses the following different components in Lime CRM:

  • Web components
  • Custom endpoints
  • Lime Marketing
  • Task Handler
  • Data structure
  • Security policies
  • Lime Bootstrap apps
  • Actionpads
  • Runtime configuration in Lime Admin
  • Application configuration

Custom adjustments

Handle phone numbers

Phone numbers expects the current format: +<COUNTRY_CODE>701234567 i.e. +46701234567

The format of a phone number is quite strict. So if the phone numbers in your solution don't follow the same strict rules we recommend you to write your own custom formatting.

You can in a custom limeobject on your limetype containing the phone number. Set the formatted version of the phone number in a hidden field or maybe just replace the phone number if you'd like.

Here's one example on how it could look if you always expects the phone number to be swedish.

def format_phone_number(phone_number: str):
    valid_chars = [
        '0', '1', '2', '3', '4', '5', '6', '7', '8', '9', '+'
    ]
    formatted_phone_number = ''.join([
        c for c
        in phone_number
        if c in valid_chars
    ])
    if (
        len(formatted_phone_number) == 10
        and formatted_phone_number.startswith('0')
    ):
        return f'+46{formatted_phone_number[1:]}'

    return formatted_phone_number

Table and Field Definitions Lime CRM

smssendout (SMS sendout)

Field name Suggested local name(en/sv) Field type Description
name Name/Namn Text field (32 characters) ReadOnly
message Message/Meddelande Text field (4000 characters) ReadOnly
send_date Send date/Utskicksdatum Time field Default value getdate().ReadOnly
smssendoutstatus Sendout status/Utskicksstatus Option field Option keys (finished, failed, init, sending, created (default)) ReadOnly
bw_sms_message_id SMS Message ID/SMS-meddelande ID Integer field The SMS message ID from Lime Marketing ReadOnly
smsrecipient Recipient/Mottagare relation (1:n smssendout-smsrecipient) Relation tab to the SMS recipients, a SMS sendout can have many SMS recipients ReadOnly

smstemplate (SMS template)

Field name Suggested local name(en/sv) Field type Description
name Name/Namn Text field (256 characters)
inactive Inactive/Inaktiv Yes/No field
fortable For table/Mot tabell Text field (256 characters), (Make sure to add empty option if the customer is using the desktop version)
default Default/Standardvärde Yes/No field
message Message/Meddelande Text field (1024 characters)

smsrecipient (SMS recipient)

Field name Suggested local name(en/sv) Field type Description
smssendout SMS sendout/SMS-utskick Relation field ReadOnly
smsrecipientstatus Delivery status/Leveransstatus Option field Option keys (init, queued, delivered, failed, sent) ReadOnly
bw_smsrecipient_id Recipient ID/MottagarID Integer field The SMS recipient ID from Lime Marketing ReadOnly
phoneno Phone number/Telefonnummer Formatted text field (128 characters) ReadOnly

Permissions

If the solution is using Object Access make sure that the API user is a member of a group with access to the data that should be available for the integration to use

Policy name R W A D Apply to
tbl_smssendout smssendout table
tbl_smsrecipient smsrecipient table
tbl_smstemplate smstemplate table
tbl_xyz xyz table if relation to xyz exists and is used on smsrecipient