job do
every 1.day, at: '00:01'
product_hunt do
posts 'https://keen.io'
day 1
end
step do |response|
if response['posts'].length > 0
response['posts']
else
false
end
end
sendgrid do |response|
to 'marketing@somewhere.com'
from 'pushpop@somewhere.com'
subject 'We were on Product Hunt yesterday!'
body template 'pushpop_alert.html.erb', response
end
end