Relay SMS Platform
Available Templates

Transaction Templates

Four production-ready templates for e-commerce and payment notifications.

Starter Tier: Use sendTypedTemplate

If you're on Starter tier, use the SDK's sendTypedTemplate() method or the /v1/messages/send-template API endpoint. These examples show template rendering only - see Using Templates for complete sending examples.

Allowed on Starter Tier

All Transaction templates are approved for Starter tier shared numbers (Customer Care campaign type).

Order Confirmed

Confirm order placement with tracking link.

TypeScriptCode
import { getTemplate, renderTemplate } from '@relay-works/templates'; const template = getTemplate('order-confirmed'); const result = renderTemplate(template, { company: 'Acme Store', orderNumber: 'A1B2C3', itemCount: 3, amount: '49.99', url: 'https://relay.link/order-123' }); // "Acme Store: Order #A1B2C3 confirmed! 3 items, $49.99. Track: https://relay.link/order-123"

Variables:

  • company (string) - Your store name
  • orderNumber (string) - Order ID
  • itemCount (number) - Number of items
  • amount (string) - Total amount (formatted)
  • url (string) - Order tracking URL

Best for: E-commerce order confirmations


Order Shipped

Notify when order has shipped.

TypeScriptCode
import { getTemplate, renderTemplate } from '@relay-works/templates'; const template = getTemplate('order-shipped'); const result = renderTemplate(template, { company: 'Acme', orderNumber: 'A1B2C3', date: 'Oct 15', url: 'https://relay.link/track-123' }); // "Acme: Order A1B2C3 shipped! Arriving Oct 15. Track: https://relay.link/track-123"

Variables:

  • company (string) - Your company name
  • orderNumber (string) - Order ID
  • date (string) - Expected delivery date (short format, e.g., "Oct 15")
  • url (string) - Shipment tracking URL

Best for: Shipping notifications, delivery updates


Payment Confirmed

Confirm successful payment received.

TypeScriptCode
import { getTemplate, renderTemplate } from '@relay-works/templates'; const template = getTemplate('payment-confirmed'); const result = renderTemplate(template, { company: 'Acme', amount: '99.99', transactionId: 'TXN-4829X' }); // "Acme: Payment of $99.99 received. Transaction TXN-4829X."

Variables:

  • company (string) - Your company or service name
  • amount (string) - Payment amount (do not include $ symbol)
  • transactionId (string) - Transaction or receipt ID

Best for: Payment confirmations, receipt notifications


Payment Failed

Alert when payment has failed.

TypeScriptCode
import { getTemplate, renderTemplate } from '@relay-works/templates'; const template = getTemplate('payment-failed'); const result = renderTemplate(template, { company: 'Acme', amount: '99.99', url: 'https://relay.link/payment-abc' }); // "Acme: Payment of $99.99 declined. Update payment: https://relay.link/payment-abc"

Variables:

  • company (string) - Your company or service name
  • amount (string) - Failed payment amount (do not include $ symbol)
  • url (string) - Link to payment update page

Best for: Failed payment alerts, billing issues


Next Steps:

Last modified on