This site contains the documentation that is relevant to older WSO2 product versions and offerings.
For the latest WSO2 documentation, visit https://wso2.com/documentation/.

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 »

 Overview

OperationDescription
addScheduleSchedule a delivery time for an existing Marketing Email.

getSchedule

Retrieve the scheduled delivery time for an existing Marketing  Email.

deleteSchedule

Cancel a scheduled send for a Marketing Email.

 

Operation details

This section provides details on the operations.

Adding a Schedule
The  addSchedule  operation schedules  a delivery time for an existing Marketing Email.

addSchedule
<sendgrid.addSchedule>
    <name>{$ctx:name}</name>
    <at>{$ctx:at}</at>
    <after>{$ctx:after}</after>
</sendgrid.addSchedule>

Properties

name : required - Marketing Email to schedule delivery for. (If Marketing  Email should be sent now, include no additional parameters.)

at: Date / Time to schedule marketing email Delivery.

after: Number  of minutes until delivery should occur.

Retrieves a schedule.
The  getSchedule  operation retrieves  the scheduled delivery time for an existing Marketing Email.

getSchedule
<sendgrid.getSchedule>
    <name>{$ctx:name}</name>
</sendgrid.getSchedule>

Properties

name: Required - Retrieve the delivery time scheduled for this Marketing  Email.

Delete a schedule

The  deleteSchedule  operation cancels  a scheduled send for a Marketing Email.

deleteSchedule
<sendgrid.deleteSchedule>
    <name>{$ctx:name}</name>
</sendgrid.deleteSchedule>

Properties

name: required - Remove the scheduled delivery time from an existing Marketing Email.

 

Sample configuration

 

Following is a sample proxy service that illustrates how to connect to SendGrid with the init operation and use the getSchedule operation. You can use this sample as a template for using other operations in this category.

Sample Proxy
<?xml version="1.0" encoding="UTF-8"?>
<proxy xmlns="http://ws.apache.org/ns/synapse"
       name="sendgrid_getSchedule"
       transports="https,http"
       statistics="disable"
       trace="disable"
       startOnLoad="true">
    <target>
        <inSequence>
            <property name="apiUrl" expression="json-eval($.apiUrl)"/>
            <property name="apiUser" expression="json-eval($.apiUser)"/>
            <property name="apiKey" expression="json-eval($.apiKey)"/>
			<property name="list" expression="json-eval($.list)"/>
			<property name="email" expression="json-eval($.email)"/>
			<property name="unsubscribed" expression="json-eval($.unsubscribed)"/> 
		
			<sendgrid.init>
    			<apiUrl>{$ctx:apiUrl}</apiUrl>
    			<apiUser>{$ctx:apiUser}</apiUser>
    			<apiKey>{$ctx:apiKey}</apiKey>
			</sendgrid.init>
			
		<sendgrid.getSchedule>
    		<name>{$ctx:name}</name>
		</sendgrid.getSchedule>
   
           <respond/>
        </inSequence>
        <outSequence>
            <log/>
            <send/>
        </outSequence>
    </target>
    <description/>
</proxy>


 

  • No labels