{"id":1767,"date":"2017-04-03T07:31:16","date_gmt":"2017-04-03T07:31:16","guid":{"rendered":"https:\/\/www.botreetechnologies.com\/blog\/?p=1767"},"modified":"2022-12-14T16:07:44","modified_gmt":"2022-12-14T10:37:44","slug":"send-automated-email-ruby-rails-mailgun","status":"publish","type":"post","link":"https:\/\/www.botreetechnologies.com\/blog\/send-automated-email-ruby-rails-mailgun\/","title":{"rendered":"Send Automated Email in Ruby on Rails with Mailgun"},"content":{"rendered":"\n<h3 class=\"wp-block-heading\">Assumptions<\/h3>\n\n\n\n<p>You have a Rails project and you want to send an email when a certain event occurs. Lets assume that when user sign up you want to send welcome email to user.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Sign up for&nbsp;Mailgun<\/h3>\n\n\n\n<p>Mailgun&nbsp;is a developer tool and API for sending transactional emails. You get&nbsp;<b>10,000 emails per month for free<\/b>.<\/p>\n\n\n\n<p>Create an account and add a subdomain to start.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Set up Ruby on Rails Action&nbsp;Mailer<\/h3>\n\n\n\n<p><a href=\"http:\/\/guides.rubyonrails.org\/action_mailer_basics.html\" target=\"_blank\" rel=\"noopener noreferrer\">Action Mailer<\/a>&nbsp;enables you to send emails from your application using mailer classes and views.<\/p>\n\n\n\n<p>Generate your mailer by typing this in Terminal:<\/p>\n\n\n\n<blockquote class=\"wp-block-quote is-layout-flow wp-block-quote-is-layout-flow\"><p><code>rails g mailer model_mailer new_user_notification<\/code><\/p><\/blockquote>\n\n\n\n<p>Here&nbsp;<code>model_mailer<\/code>&nbsp;is the name of the mailer and&nbsp;<code>new_user_notification<\/code>&nbsp;is the method.<\/p>\n\n\n\n<p>This create following files.<\/p>\n\n\n\n<p><i><code>model_mailer.rb<\/code><\/i>&nbsp;is where the logic will go for sending email and&nbsp;<i><code>new_user_notification.text.erb<\/code><\/i>&nbsp;is the content of the email that will be sent.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Configure Your Development Environment<\/h3>\n\n\n\n<p>Log in to\u00a0Mailgun\u00a0and click on your domain to find your SMTP settings.<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"800\" height=\"421\" src=\"https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2020\/12\/mailgun.jpg\" alt=\"mailgun\" class=\"wp-image-13869\" srcset=\"https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2020\/12\/mailgun.jpg 800w, https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2020\/12\/mailgun-300x158.jpg 300w, https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2020\/12\/mailgun-768x404.jpg 768w\" sizes=\"auto, (max-width: 800px) 100vw, 800px\" \/><\/figure>\n\n\n\n<p>Now open up&nbsp;<i><b>config\/environments\/development.rb<\/b><\/i><\/p>\n\n\n\n<p>Add the following:<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"600\" height=\"202\" src=\"https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2020\/12\/mailgun-config.jpeg\" alt=\"mailgun configuration\" class=\"wp-image-13870\" srcset=\"https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2020\/12\/mailgun-config.jpeg 600w, https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2020\/12\/mailgun-config-300x101.jpeg 300w\" sizes=\"auto, (max-width: 600px) 100vw, 600px\" \/><\/figure>\n\n\n\n<p>Be sure to&nbsp;<b>replace MYDOMAIN<\/b>&nbsp;with your Mailgun domain.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Add logic to send the&nbsp;emails<\/h3>\n\n\n\n<p>Open up&nbsp;<i><b>app\/mailers\/model_mailer.rb<\/b><\/i>&nbsp;and change the default from email:<\/p>\n\n\n\n<p><i><b>default from: &#8220;me@MYDOMAIN.com&#8221;<\/b><\/i><\/p>\n\n\n\n<p>Then define your&nbsp;<i><b>new_user_notification&nbsp;method:<\/b><\/i><\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"541\" height=\"100\" src=\"https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2020\/12\/mailgun-new-user-notification.jpeg\" alt=\"new user notification\" class=\"wp-image-13871\" srcset=\"https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2020\/12\/mailgun-new-user-notification.jpeg 541w, https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2020\/12\/mailgun-new-user-notification-300x55.jpeg 300w\" sizes=\"auto, (max-width: 541px) 100vw, 541px\" \/><\/figure>\n\n\n\n<p>Couple of things to note above:<\/p>\n\n\n\n<ul class=\"wp-block-list\"><li>The &#8220;to:&#8221; is the email recipient. This could be you or a user, depending on the use case.<\/li><li>We&#8217;re passing the &#8220;user&#8221; model. This will allow us to use those values in the email content if we wish.<\/li><\/ul>\n\n\n\n<p><b>Create a view template (content) for the&nbsp;email<\/b><\/p>\n\n\n\n<p>Open up&nbsp;<i><b>app\/views\/model_mailer\/new_user_notification.text.erb<\/b><\/i><\/p>\n\n\n\n<p>In this view we add the body content of our email.<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"426\" height=\"60\" src=\"https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2020\/12\/thanks-email-setup.jpeg\" alt=\"body content of our email\" class=\"wp-image-13872\" srcset=\"https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2020\/12\/thanks-email-setup.jpeg 426w, https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2020\/12\/thanks-email-setup-300x42.jpeg 300w, https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2020\/12\/thanks-email-setup-420x60.jpeg 420w\" sizes=\"auto, (max-width: 426px) 100vw, 426px\" \/><\/figure>\n\n\n\n<h3 class=\"wp-block-heading\">Send the&nbsp;email<\/h3>\n\n\n\n<p>Last thing to do is to call the email method from your controller.<\/p>\n\n\n\n<p>Whenever you want to send this email, in this case when a user sign up, call this mailer method:<\/p>\n\n\n\n<p><i><code>ModelMailer.new_user_notification(@user).deliver<\/code><\/i><\/p>\n\n\n\n<p>To clarify, your full create action might look something like this:<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"679\" height=\"181\" src=\"https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2020\/12\/create-action.jpeg\" alt=\"create action\" class=\"wp-image-13873\" srcset=\"https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2020\/12\/create-action.jpeg 679w, https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2020\/12\/create-action-300x80.jpeg 300w\" sizes=\"auto, (max-width: 679px) 100vw, 679px\" \/><\/figure>\n\n\n\n<h4 class=\"wp-block-heading\">All Done<\/h4>\n\n\n\n<p>Now you can use Mailgun&#8217;s logs to check sent and delivered emails.<\/p>\n\n\n\n<p><a href=\"https:\/\/www.botreetechnologies.com\/ruby-on-rails-development\" target=\"_blank\" rel=\"noopener noreferrer\"><strong>Click here for more details&#8230;<\/strong><\/a><\/p>\n\n\n\n<hr class=\"wp-block-separator has-css-opacity\"\/>\n\n\n\n<p>At <a href=\"https:\/\/www.botreetechnologies.com\/\" target=\"_blank\" rel=\"noopener noreferrer\">BoTree Technologies<\/a>, we build enterprise applications with our RoR team of 25+ engineers.<\/p>\n\n\n\n<p>We also specialize in RPA, AI, Python, Django, JavaScript and ReactJS.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\"><a href=\"https:\/\/www.botreetechnologies.com\/contact\" target=\"_blank\" rel=\"noopener noreferrer\">Consulting is free<\/a> &#8211; let us help you grow!<\/h3>\n","protected":false},"excerpt":{"rendered":"<p>Assumptions You have a Rails project and you want to&#8230;<\/p>\n","protected":false},"author":6,"featured_media":13868,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[73,10],"tags":[],"class_list":["post-1767","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-ruby-on-rails","category-technology"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.2 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>Send Automated Email in Ruby on Rails with Mailgun<\/title>\n<meta name=\"description\" content=\"Learn more about how to send automated email in ruby on rails with mailgun. Mailgun is a developer tool and API for sending transactional emails.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.botreetechnologies.com\/blog\/send-automated-email-ruby-rails-mailgun\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Send Automated Email in Ruby on Rails with Mailgun\" \/>\n<meta property=\"og:description\" content=\"Learn more about how to send automated email in ruby on rails with mailgun. Mailgun is a developer tool and API for sending transactional emails.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.botreetechnologies.com\/blog\/send-automated-email-ruby-rails-mailgun\/\" \/>\n<meta property=\"og:site_name\" content=\"BoTree Technologies\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/BoTreeTechnologies\/\" \/>\n<meta property=\"article:published_time\" content=\"2017-04-03T07:31:16+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2022-12-14T10:37:44+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2017\/04\/automated-email-ruby-on-rails.jpg\" \/>\n\t<meta property=\"og:image:width\" content=\"1024\" \/>\n\t<meta property=\"og:image:height\" content=\"683\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/jpeg\" \/>\n<meta name=\"author\" content=\"Parth Barot\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@BoTreeTech\" \/>\n<meta name=\"twitter:site\" content=\"@BoTreeTech\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Parth Barot\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"3 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/www.botreetechnologies.com\/blog\/send-automated-email-ruby-rails-mailgun\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/www.botreetechnologies.com\/blog\/send-automated-email-ruby-rails-mailgun\/\"},\"author\":{\"name\":\"Parth Barot\",\"@id\":\"https:\/\/www.botreetechnologies.com\/blog\/#\/schema\/person\/1952b3c6679346e5a2792581a67b1b0f\"},\"headline\":\"Send Automated Email in Ruby on Rails with Mailgun\",\"datePublished\":\"2017-04-03T07:31:16+00:00\",\"dateModified\":\"2022-12-14T10:37:44+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/www.botreetechnologies.com\/blog\/send-automated-email-ruby-rails-mailgun\/\"},\"wordCount\":403,\"commentCount\":0,\"image\":{\"@id\":\"https:\/\/www.botreetechnologies.com\/blog\/send-automated-email-ruby-rails-mailgun\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2017\/04\/automated-email-ruby-on-rails.jpg\",\"articleSection\":[\"Ruby on Rails\",\"Technology\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\/\/www.botreetechnologies.com\/blog\/send-automated-email-ruby-rails-mailgun\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.botreetechnologies.com\/blog\/send-automated-email-ruby-rails-mailgun\/\",\"url\":\"https:\/\/www.botreetechnologies.com\/blog\/send-automated-email-ruby-rails-mailgun\/\",\"name\":\"Send Automated Email in Ruby on Rails with Mailgun\",\"isPartOf\":{\"@id\":\"https:\/\/www.botreetechnologies.com\/blog\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/www.botreetechnologies.com\/blog\/send-automated-email-ruby-rails-mailgun\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/www.botreetechnologies.com\/blog\/send-automated-email-ruby-rails-mailgun\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2017\/04\/automated-email-ruby-on-rails.jpg\",\"datePublished\":\"2017-04-03T07:31:16+00:00\",\"dateModified\":\"2022-12-14T10:37:44+00:00\",\"author\":{\"@id\":\"https:\/\/www.botreetechnologies.com\/blog\/#\/schema\/person\/1952b3c6679346e5a2792581a67b1b0f\"},\"description\":\"Learn more about how to send automated email in ruby on rails with mailgun. Mailgun is a developer tool and API for sending transactional emails.\",\"breadcrumb\":{\"@id\":\"https:\/\/www.botreetechnologies.com\/blog\/send-automated-email-ruby-rails-mailgun\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.botreetechnologies.com\/blog\/send-automated-email-ruby-rails-mailgun\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/www.botreetechnologies.com\/blog\/send-automated-email-ruby-rails-mailgun\/#primaryimage\",\"url\":\"https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2017\/04\/automated-email-ruby-on-rails.jpg\",\"contentUrl\":\"https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2017\/04\/automated-email-ruby-on-rails.jpg\",\"width\":1024,\"height\":683,\"caption\":\"send automated email in ruby on rails with mailgun\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.botreetechnologies.com\/blog\/send-automated-email-ruby-rails-mailgun\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/www.botreetechnologies.com\/blog\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Send Automated Email in Ruby on Rails with Mailgun\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.botreetechnologies.com\/blog\/#website\",\"url\":\"https:\/\/www.botreetechnologies.com\/blog\/\",\"name\":\"BoTree Technologies\",\"description\":\"Committed to inspire generation.\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/www.botreetechnologies.com\/blog\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/www.botreetechnologies.com\/blog\/#\/schema\/person\/1952b3c6679346e5a2792581a67b1b0f\",\"name\":\"Parth Barot\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2020\/10\/parth-barot-150x150.png\",\"url\":\"https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2020\/10\/parth-barot-150x150.png\",\"contentUrl\":\"https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2020\/10\/parth-barot-150x150.png\",\"caption\":\"Parth Barot\"},\"description\":\"Parth is the co-founder and CTO at BoTree Technologies. He has worked on building products in different domains and technologies. He is now managing research and pre-sales by supporting it with his problem-solving approach.\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Send Automated Email in Ruby on Rails with Mailgun","description":"Learn more about how to send automated email in ruby on rails with mailgun. Mailgun is a developer tool and API for sending transactional emails.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.botreetechnologies.com\/blog\/send-automated-email-ruby-rails-mailgun\/","og_locale":"en_US","og_type":"article","og_title":"Send Automated Email in Ruby on Rails with Mailgun","og_description":"Learn more about how to send automated email in ruby on rails with mailgun. Mailgun is a developer tool and API for sending transactional emails.","og_url":"https:\/\/www.botreetechnologies.com\/blog\/send-automated-email-ruby-rails-mailgun\/","og_site_name":"BoTree Technologies","article_publisher":"https:\/\/www.facebook.com\/BoTreeTechnologies\/","article_published_time":"2017-04-03T07:31:16+00:00","article_modified_time":"2022-12-14T10:37:44+00:00","og_image":[{"width":1024,"height":683,"url":"https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2017\/04\/automated-email-ruby-on-rails.jpg","type":"image\/jpeg"}],"author":"Parth Barot","twitter_card":"summary_large_image","twitter_creator":"@BoTreeTech","twitter_site":"@BoTreeTech","twitter_misc":{"Written by":"Parth Barot","Est. reading time":"3 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.botreetechnologies.com\/blog\/send-automated-email-ruby-rails-mailgun\/#article","isPartOf":{"@id":"https:\/\/www.botreetechnologies.com\/blog\/send-automated-email-ruby-rails-mailgun\/"},"author":{"name":"Parth Barot","@id":"https:\/\/www.botreetechnologies.com\/blog\/#\/schema\/person\/1952b3c6679346e5a2792581a67b1b0f"},"headline":"Send Automated Email in Ruby on Rails with Mailgun","datePublished":"2017-04-03T07:31:16+00:00","dateModified":"2022-12-14T10:37:44+00:00","mainEntityOfPage":{"@id":"https:\/\/www.botreetechnologies.com\/blog\/send-automated-email-ruby-rails-mailgun\/"},"wordCount":403,"commentCount":0,"image":{"@id":"https:\/\/www.botreetechnologies.com\/blog\/send-automated-email-ruby-rails-mailgun\/#primaryimage"},"thumbnailUrl":"https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2017\/04\/automated-email-ruby-on-rails.jpg","articleSection":["Ruby on Rails","Technology"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/www.botreetechnologies.com\/blog\/send-automated-email-ruby-rails-mailgun\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/www.botreetechnologies.com\/blog\/send-automated-email-ruby-rails-mailgun\/","url":"https:\/\/www.botreetechnologies.com\/blog\/send-automated-email-ruby-rails-mailgun\/","name":"Send Automated Email in Ruby on Rails with Mailgun","isPartOf":{"@id":"https:\/\/www.botreetechnologies.com\/blog\/#website"},"primaryImageOfPage":{"@id":"https:\/\/www.botreetechnologies.com\/blog\/send-automated-email-ruby-rails-mailgun\/#primaryimage"},"image":{"@id":"https:\/\/www.botreetechnologies.com\/blog\/send-automated-email-ruby-rails-mailgun\/#primaryimage"},"thumbnailUrl":"https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2017\/04\/automated-email-ruby-on-rails.jpg","datePublished":"2017-04-03T07:31:16+00:00","dateModified":"2022-12-14T10:37:44+00:00","author":{"@id":"https:\/\/www.botreetechnologies.com\/blog\/#\/schema\/person\/1952b3c6679346e5a2792581a67b1b0f"},"description":"Learn more about how to send automated email in ruby on rails with mailgun. Mailgun is a developer tool and API for sending transactional emails.","breadcrumb":{"@id":"https:\/\/www.botreetechnologies.com\/blog\/send-automated-email-ruby-rails-mailgun\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.botreetechnologies.com\/blog\/send-automated-email-ruby-rails-mailgun\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.botreetechnologies.com\/blog\/send-automated-email-ruby-rails-mailgun\/#primaryimage","url":"https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2017\/04\/automated-email-ruby-on-rails.jpg","contentUrl":"https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2017\/04\/automated-email-ruby-on-rails.jpg","width":1024,"height":683,"caption":"send automated email in ruby on rails with mailgun"},{"@type":"BreadcrumbList","@id":"https:\/\/www.botreetechnologies.com\/blog\/send-automated-email-ruby-rails-mailgun\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.botreetechnologies.com\/blog\/"},{"@type":"ListItem","position":2,"name":"Send Automated Email in Ruby on Rails with Mailgun"}]},{"@type":"WebSite","@id":"https:\/\/www.botreetechnologies.com\/blog\/#website","url":"https:\/\/www.botreetechnologies.com\/blog\/","name":"BoTree Technologies","description":"Committed to inspire generation.","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.botreetechnologies.com\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Person","@id":"https:\/\/www.botreetechnologies.com\/blog\/#\/schema\/person\/1952b3c6679346e5a2792581a67b1b0f","name":"Parth Barot","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2020\/10\/parth-barot-150x150.png","url":"https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2020\/10\/parth-barot-150x150.png","contentUrl":"https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2020\/10\/parth-barot-150x150.png","caption":"Parth Barot"},"description":"Parth is the co-founder and CTO at BoTree Technologies. He has worked on building products in different domains and technologies. He is now managing research and pre-sales by supporting it with his problem-solving approach."}]}},"amp_enabled":true,"_links":{"self":[{"href":"https:\/\/www.botreetechnologies.com\/blog\/wp-json\/wp\/v2\/posts\/1767","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.botreetechnologies.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.botreetechnologies.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.botreetechnologies.com\/blog\/wp-json\/wp\/v2\/users\/6"}],"replies":[{"embeddable":true,"href":"https:\/\/www.botreetechnologies.com\/blog\/wp-json\/wp\/v2\/comments?post=1767"}],"version-history":[{"count":3,"href":"https:\/\/www.botreetechnologies.com\/blog\/wp-json\/wp\/v2\/posts\/1767\/revisions"}],"predecessor-version":[{"id":18295,"href":"https:\/\/www.botreetechnologies.com\/blog\/wp-json\/wp\/v2\/posts\/1767\/revisions\/18295"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.botreetechnologies.com\/blog\/wp-json\/wp\/v2\/media\/13868"}],"wp:attachment":[{"href":"https:\/\/www.botreetechnologies.com\/blog\/wp-json\/wp\/v2\/media?parent=1767"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.botreetechnologies.com\/blog\/wp-json\/wp\/v2\/categories?post=1767"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.botreetechnologies.com\/blog\/wp-json\/wp\/v2\/tags?post=1767"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}