Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 3 Next »

Here you can find list of “skeletons” for email templates customization. Primaly we’re using Sendgrid, but examples below are valid for others systems.

Data format:

  • type – to determine appropriate content in the dynamic template, one of values:

    • bookingConfirmation – Customer created booking

    • bookingReminder – Booking reminder for customer

    • bookingActivated – Booking is activate and is a queue ticket now

    • positionCancelled – staff removed future booking created by the customer

    • positionCalled – Position called by staff

    • positionRetry – staff pressed ‘Retry’ because customer did not show up

    • positionReject – staff pressed ‘Reject’ to remove ticket

  • position – ticket information, including dates, labels, language and more information that can be should be used in the template

  • actionLink – link to present to customer, link depends on email type (see below)

Example of data:

{
    "id": "_id_",
    "location": null,
    "type": "booking",
    "priority": 100,
    "locale": "en",
    "notification": {
        "type": "phoneNumber",
        "settings": {
            "from": "",
            "to": "+phoneNumber"
        },
    },
    "booking": {
        "start": "yyyy-MM-dd HH:mm", // with respect to timezone
        "end": "yyyy-MM-dd HH:mm" // with respect to timezone
    },
    "status": "draft",
    "label": "", // label will generated when time comes
    "queue": "_queue_id_",
    "createdAt": "2020-05-26T08:47:37.1700000Z",
    "fulfilledAt": "2020-05-26T17:15:59.6100000Z",
    "bookingReminderAt": null
}

Template by type:

  1. bookingConfirmation:

    {
        "position": {
            "locale": "en",
            "booking": {
              "start": "yyyy-MM-dd HH:mm"
            }      
        },
        "actionLink": "linkToTicket"    
    }

    <html><head><title></title></head>
      <body>
      <div data-role="module-unsubscribe" class="module" role="module" data-type="unsubscribe" style="color:#444444; font-size:12px; line-height:20px; padding:16px 16px 16px 16px; text-align:Center;" data-muid="4e838cf3-9892-4a6d-94d6-170e474d21e5">
        
        <p>        
        {{#equals position.locale "ar"}}
            حجزك لـ ‪{{position.date}}‬ مؤكد الآن.
            تذكرة: ‪{{actionLink}}‬
        {{else}}
            Your booking for {{position.booking.start}} is now confirmed. Ticket: {{actionLink}}
        {{/equals}}
        </p>        
        
      </div>
    </body>
    </html>

  2. bookingReminder:

    {
        "position": {
            "locale": "en"   
        },
        "actionLink": "timeForReminder"    
    }

      <html>
        <head>
          <title></title>
        </head>
        <body>
          <div data-role="module-unsubscribe" class="module" role="module" data-type="unsubscribe" style="color:#444444; font-size:12px; line-height:20px; padding:16px 16px 16px 16px; text-align:Center;" data-muid="4e838cf3-9892-4a6d-94d6-170e474d21e5">
          
            <p>        
            {{#equals position.locale "ar"}}
                لا تنس حجزك في ‪{{actionLink}}‬
            {{else}}
                Don't forget your booking in {{actionLink}}
            {{/equals}}
            </p>
                
          </div>
        </body>
      </html>
    

  3. bookingActivated:

    {
        "position": {
            "locale": "en",
            "label": "B1"        
        },
        "actionLink": "linkToTicket"    
    }

      <html>
        <head>
          <title></title>
        </head>
        <body>
          <div data-role="module-unsubscribe" class="module" role="module" data-type="unsubscribe" style="color:#444444; font-size:12px; line-height:20px; padding:16px 16px 16px 16px; text-align:Center;" data-muid="4e838cf3-9892-4a6d-94d6-170e474d21e5">
            
            <p>        
            {{#equals position.locale "ar"}}
    "رقم موعدك: ‪{{position.label}}‬. يرجى الحضور في خلال 15 دقيقة لتجنب إلغاء الموعد تذكرة: ‪{{actionLink}}‬" 
            {{else}}
                Your position: {{position.label}}. Please come within 15 minutes to avoid cancellation of your appointment. Ticket: {{actionLink}}
            {{/equals}}
            </p>
                
          </div>
        </body>
      </html>
    

  4. positionCancelled:

    {
        "position": {
            "locale": "en",
            "label": "B1"        
        },
        "actionLink": "linkToQueueForGettingNewTicket"    
    }

      <html>
        <head>
          <title></title>
        </head>
        <body>
          <div data-role="module-unsubscribe" class="module" role="module" data-type="unsubscribe" style="color:#444444; font-size:12px; line-height:20px; padding:16px 16px 16px 16px; text-align:Center;" data-muid="4e838cf3-9892-4a6d-94d6-170e474d21e5">
            
            <p>        
            {{#equals position.locale "ar"}}
                تم إلغاء الحجز. {{position.label}} برجاء زيارة {{actionLink}} إذا كنت ترغب في حجز موعد جديد
            {{else}}
                Position {{position.label}} was cancelled. Visit {{actionLink}} if you would like to request a new position.
            {{/equals}}
            </p>
                
          </div>
        </body>
      </html>
    

  5. positionCalled

    {
        "position": {
            "locale": "en"        
        }    
    }

      <html>
        <head>
          <title></title>
        </head>
        <body>
          <div data-role="module-unsubscribe" class="module" role="module" data-type="unsubscribe" style="color:#444444; font-size:12px; line-height:20px; padding:16px 16px 16px 16px; text-align:Center;" data-muid="4e838cf3-9892-4a6d-94d6-170e474d21e5">
            
            <p>        
            {{#equals position.locale "ar"}}
                حان دورك الآن.
            {{else}}
                It is your turn now.
            {{/equals}}
            </p>
                
          </div>
        </body>
      </html>
    

  6. positionRetry

    {
        "position": {
            "locale": "en"        
        }   
    }

      <html>
        <head>
          <title></title>
        </head>
        <body>
          <div data-role="module-unsubscribe" class="module" role="module" data-type="unsubscribe" style="color:#444444; font-size:12px; line-height:20px; padding:16px 16px 16px 16px; text-align:Center;" data-muid="4e838cf3-9892-4a6d-94d6-170e474d21e5">
            
            <p>        
            {{#equals position.locale "ar"}}
                تم الوصول لدورك، لكنك لم تدخل. سنحاول مرة أخرى في غضون دقائق قليلة. الرجاء الإقتراب من المدخل
            {{else}}
                We called your ticket, but did not find you. We will try again in few minutes. Please approach the entrance.
            {{/equals}}
            </p>
                
          </div>
        </body>
      </html>
    

  7. positionReject

    {
        "position": {
            "locale": "en",
            "label": "B1"
        },
        "actionLink": "linkToQueueForGettingNewTicket"   
    }  

      <html>
        <head>
          <title></title>
        </head>
        <body>
          <div data-role="module-unsubscribe" class="module" role="module" data-type="unsubscribe" style="color:#444444; font-size:12px; line-height:20px; padding:16px 16px 16px 16px; text-align:Center;" data-muid="4e838cf3-9892-4a6d-94d6-170e474d21e5">
            
            <p>        
            {{#equals position.locale "ar"}}
                تم إلغاء الحجز. {{position.label}} برجاء زيارة {{actionLink}} إذا كنت ترغب في حجز موعد جديد
            {{else}}
                Position {{position.label}} was cancelled. Visit {{actionLink}} if you would like to request a new position.
            {{/equals}}
            </p>
                
          </div>
        </body>
      </html>
    

  • No labels