# Messaging

Endpoint that lets yoy send different types of messages and manually trigger automations that send SMS.

In this endpoint you will also find a complete set of methods to create a 2F verfication solution by SMS.


## Send SMS

 - [POST /messaging/sms](https://dev.triggloyalty.com/openapi/messaging/sendsmsmessage.md): Sends an SMS with a given sender name.

## Create Code

 - [GET /messaging/sms/code/create/{phoneNumber}](https://dev.triggloyalty.com/openapi/messaging/createsmscode.md): Creates and sends an SMS with a unique code that can be used in 2 factor logins or customer verification processes.

The sender, length and expiration time is configurable.

## Verify code

 - [GET /messaging/sms/code/verify/{phoneNumber}/{code}](https://dev.triggloyalty.com/openapi/messaging/verifysmscode.md): Verifies the SMS code recevied in the Create Code endpoint.

## Trigger sms

 - [GET /messaging/sms/trigger/{customerId}/{id}](https://dev.triggloyalty.com/openapi/messaging/triggersmsautomation.md): Triggers the send out of a pre-defined message. This message has to be configured by Oculos in advance.

