Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
tree: 6c082352d7
Fetching contributors…

Cannot retrieve contributors at this time

59 lines (38 sloc) 1.827 kb
Silverpop
====================================================================================================
Silverpop Engage and Transact API -- Extracted from ShoeDazzle.com
Silverpop allows for seamless integration from Ruby with the Engage and Transact API. Built on Rails
2.1.0. Requires hpricot, net/http, net/ftp, and uri.
Examples
====================================================================================================
TRANSACT
Defining recipients:
recipient = { :email => 'test@test.com',
:personalizations => [
{:tag_name => 'FIRST_NAME', :value => 'Joe'},
{:tag_name => 'LAST_NAME', :value => 'Schmoe'}
] }
recipients = [ recipient,
{ :email => 'test2@test.com',
:personalizations => [
{:tag_name => 'FIRST_NAME', :value => 'John'},
{:tag_name => 'LAST_NAME', :value => 'Smith'}
] },
{ :email => 'test3@test.com',
:personalizations => [
{:tag_name => 'FIRST_NAME', :value => 'Jane'},
{:tag_name => 'LAST_NAME', :value => 'Doe'}
] } ]
Transact HTTP Sample Usage:
campaign_id = 1234567
sp = Silverpop::Transact.new campaign_id, recipients
sp.query
Transact FTP Sample Usage:
campaign_id = 1234567
options.merge!( { :send_as_batch => 'true' } )
transact = Silverpop::Transact.new(campaign_id, recipients, options)
transact.save_xml file_path
transact.submit_batch file_path
ENGAGE
Please look through the functions in lib/engage.rb
Copyright (c) 2010 George Truong, released under the MIT license
Jump to Line
Something went wrong with that request. Please try again.