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/.

Working with Visitor Notifications



Overview

The following operations allow you to work with visitor notifications. Click an operation name to see details on how to use it.

For a sample proxy service that illustrates how to work with visitor notifications, see Sample configuration .

OperationDescription
createAVisitorNotification Creates a new visitor notification.
updateAVisitorNotificationUpdates a visitor notification.
getAllVisitorNotificationsRetrieves all notifications from visitors.
getAVisitorNotification Retrieves the notifications from a visitor id.
deleteAVisitorNotificationDeletes the notifications from a visitor associated with the specified visitor id.

Operation Details

This section provides further details on the operations related to Visitor Notifications.

Create A Visitor Notification

The createAVisitorNotification operation creates a visitor notification.

createAVisitorNotification
<eloquaStandardAPI.createAVisitorNotification>
    <userId>10</userId>
    <isEnabled>true</isEnabled>
    <emailAddress>myemail@gmail.com</emailAddress>
    <name>new visitor notification</name>
    <ruleLogicType>multipleComparisonAnd</ruleLogicType>
    <visitorMustBeMappedToContact>true</visitorMustBeMappedToContact>
    <isRestrictedToSchedule>false</isRestrictedToSchedule>
    <ruleIds>["1"]</ruleIds>
</eloquaStandardAPI.createAVisitorNotification>
properties
  • userId                       : Unique identifier of the user.

  • isEnabled                    : Boolean value, to enable the visitor.

  • emailAddress                 : Email address of the visitor.
  • name                         : The name of the visitor to create the visitor on this name.
  • ruleLogicType                : It can be 'multipleComparisonAnd' or 'multipleComparisonOr' or 'advancedLogicComparison'.
  • visitorMustBeMappedToContact : Boolean value, to indicate the status of contact mapping.
  • isRestrictedToSchedule       : Boolean value, to set the permission to schedule.
  • ruleIds                      : List of identifiers of rules.
Sample request

Following is a sample REST/JSON request that can be handled by the createAVisitorNotification operation.

Sample request for createAVisitorNotification
{
   "username":"myusername",
   "password":"mypassword",
   "siteName":"mysiteName",
   "name":"new notification",
   "userId":"10",
   "isEnabled":true,
   "emailAddress":"myemail@gmail.com",
   "isRestrictedToSchedule":false,
   "ruleLogicType":"multipleComparisonAnd",
   "visitorMustBeMappedToContact":true,
   "ruleIds":["1"]
}

Update A Visitor Notification

The updateAVisitorNotification operation updates the notification of a visitor associated with the specified id.

updateAVisitorNotification
<eloquaStandardAPI.updateAVisitorNotification>
    <visitorId>1</visitorId>
    <userId>10</userId>
    <isEnabled>true</isEnabled>
    <emailAddress>myemail@gmail.com</emailAddress>
    <name>new visitor notification</name>
    <ruleLogicType>multipleComparisonAnd</ruleLogicType>
    <visitorMustBeMappedToContact>true</visitorMustBeMappedToContact>
    <isRestrictedToSchedule>false</isRestrictedToSchedule>
    <ruleIds>["1"]</ruleIds>
</eloquaStandardAPI.updateAVisitorNotification>
properties
  • visitorId                    : Unique identifier of the account.

  • userId                       : Unique identifier of the user.

  • isEnabled                    : Boolean value, to enable the visitor.

  • emailAddress                 : Email address of the visitor.
  • name                         : The name of the visitor to update as it is.
  • ruleLogicType                : It can be 'multipleComparisonAnd' or 'multipleComparisonOr' or 'advancedLogicComparison'.
  • visitorMustBeMappedToContact : Boolean value, to indicate the status of contact mapping.
  • isRestrictedToSchedule       : Boolean value, to set the permission to schedule.
  • ruleIds                      : List of identifiers of rules.
Sample request

Following is a sample REST/JSON request that can be handled by the updateAVisitorNotification operation.

Sample request for updateAVisitorNotification
{   
   "username":"myusername",
   "password":"mypassword",
   "siteName":"mysiteName",
   "accountId":"1",
   "name":"updated notification",
   "userId":"10",
   "isEnabled":true,
   "emailAddress":"myemail@gmail.com",
   "isRestrictedToSchedule":false,
   "ruleLogicType":"multipleComparisonAnd",
   "visitorMustBeMappedToContact":true,
   "ruleIds":["1"]
}

Get All Visitor Notifications

The getAllVisitorNotifications operation retrieves all notifications from all visitors.

getAllVisitorNotifications
<eloquaStandardAPI.getAllVisitorNotifications>
    <userId>10</userId>
    <count>2</count>
    <depth>1</depth>
    <search></search>
    <page>1</page>
    <orderBy></orderBy>
    <lastUpdatedAt>1426066807</lastUpdatedAt>
    <extensions></extensions>
</eloquaStandardAPI.getAllVisitorNotifications>
properties
  • userId        : Unique identifier of the user.

  • count         : The number of results in a page to display. This must me in between 1 and 1000.

  • depth         : The RequestDepth. It can be 'complete' or 'Reference' or 'Minimal' or 'Partial'.

  • search        : The search field, to search for that field.

  • page          : The page number to display. This must be greater than 1.

  • orderBy       : The order by property to order the fields.

  • lastUpdatedAt : The date time of the last update.

  • extensions    : The extensions to filter. Must follow the pattern : ^[A-Za-z0-9]+$.

     

Sample Request

Following is a sample REST/JSON request that can be handled by getAllVisitorNotifications operation.

Sample request for getAllVisitorNotifications
{   
   "username":"myusername",
   "password":"mypassword",
   "siteName":"mysiteName",
   "userId":"10",
   "count":2,
   "page":1,
   "lastUpdatedAt":1297278690,
   "depth":"Complete"
}

Get A Visitor Notification

The getAVisitorNotification operation retrieves the notification of a visitor associated with the specified id.

getAVisitorNotification
<eloquaStandardAPI.getAVisitorNotification>
	<visitorId>1</visitorId>
	<depth>Complete</depth>
	<extensions></extensions>
</eloquaStandardAPI.getAVisitorNotification>
properties
  • visitorId  : Unique identifier of the visitor.

  • depth      : The RequestDepth. It can be 'Complete' or 'Reference' or 'Minimal' or 'Partial'.

  • extensions : The extensions to filter. Must follow the pattern : ^[A-Za-z0-9]+$.

Sample request

Following is a sample REST/JSON request that can be handled by the getAVisitorNotification operation.

Sample request for getAVisitorNotification
{   
   "username":"myusername",
   "password":"mypassword",
   "siteName":"mysiteName",
   "visitorId":"1",
   "depth":"Complete"
}

Delete A Visitor Notification

The deleteAVisitorNotification operation deletes the notification of a visitor associated with the specified id.

deleteAVisitorNotification
<eloquaStandardAPI.deleteAVisitorNotification>
	<visitorId>1</visitorId>
</eloquaStandardAPI.deleteAVisitorNotification>
properties
  • visitorId : Unique identifier of the visitor.

Sample request

Following is a sample REST/JSON request that can be handled by the deleteAVisitorNotification operation.

Sample request for deleteAVisitorNotification
{  
   "username":"myusername",
   "password":"mypassword",
   "siteName":"mysiteName",
   "visitorId":"1"
}

Sample Configuration

Following is a sample proxy service that illustrates how to connect to Eloqua Standard API with the init operation to use the getAllVisitorNotifications operation. The sample request for this proxy can be found in  getAllVisitorNotifications sample request . You can use this sample as a template for using other operations in this category.

Sample proxy
<proxy xmlns="http://ws.apache.org/ns/synapse"
       name="eloqua_getAllVisitorNotifications"
       transports="https,http"
       statistics="disable"
       trace="disable"
       startOnLoad="true">
    <target>
        <inSequence>
            <property name="siteName" expression="json-eval($.siteName)"/>
            <property name="username" expression="json-eval($.username)"/>
            <property name="password" expression="json-eval($.password)"/>
            <property name="userId" expression="json-eval($.userId)"/>
            <property name="count" expression="json-eval($.count)"/>
            <property name="depth" expression="json-eval($.depth)"/>
            <property name="search" expression="json-eval($.search)"/>
            <property name="page" expression="json-eval($.page)"/>
            <property name="orderBy" expression="json-eval($.orderBy)"/>
            <property name="lastUpdatedAt" expression="json-eval($.lastUpdatedAt)"/>
            <property name="extensions" expression="json-eval($.extensions)"/>
            <eloquaStandardAPI.init>
                <siteName>{$ctx:siteName}</siteName>
                <username>{$ctx:username}</username>
                <password>{$ctx:password}</password>
            </eloquaStandardAPI.init>
            <eloquaStandardAPI.getAllVisitorNotifications>
                <userId>{$ctx:userId}</userId>
                <count>{$ctx:count}</count>
                <depth>{$ctx:depth}</depth>
                <search>{$ctx:search}</search>
                <page>{$ctx:page}</page>
                <orderBy>{$ctx:orderBy}</orderBy>
                <lastUpdatedAt>{$ctx:lastUpdatedAt}</lastUpdatedAt>
                <extensions>{$ctx:extensions}</extensions>
            </eloquaStandardAPI.getAllVisitorNotifications>
            <respond/>
        </inSequence>
        <outSequence/>
        <faultSequence/>
    </target>
    <description/>
</proxy>