mandrill

Sending object as a variable to Mandrill via Rails

删除回忆录丶 提交于 2019-12-12 02:27:49
问题 I'm converting an email template from Rails to Mandrill, the content for which requires a fair amount of data, some of which is nested through several associations. Therefore, I'd like to pass objects via Mandrill's global_merge_vars, such as the (simplified) following: [{ 'name'=>'order', 'content'=> @order.to_json(include: { user: { only: :first_name } }, methods: [:method1, :method2, :method3, :method4]) }] Which passes through to the mandrill template under the order variable similar to

Issue including calendar attachment in Mandrill Mailer and Rails

左心房为你撑大大i 提交于 2019-12-12 02:24:03
问题 I'm currently using the icalendar gem to create a new ical calendar and then send it via the mandrill_mailer gem as an attachment. I've tried a variety of different methods - so far I believe I've gotten closest with: Event.rb require 'base64' def self.export_events(user) @event = Event.last @calendar = Icalendar::Calendar.new event = Icalendar::Event.new event.summary = @event.title event.dtstart = @event.start_time.strftime("%Y%m%dT%H%M%S") event.dtend = @event.end_time.strftime("%Y%m%dT%H

Gem not initializing when running job from worker?

回眸只為那壹抹淺笑 提交于 2019-12-12 01:06:38
问题 I am using the Mandrill api gem to send scheduled emails with the delayed jobs gem. When the delayed job is executed by the worker the job is crashing at the line which creates the mandrill message with the following error: DailyMailJob failed with NameError: uninitialized constant Mandrill::API If I execute this job from the rails console it runs fine. Why does this job not work when running from the worker? 回答1: I managed to fix the issue by installing the gem into the computer rather than

How To Handle Mandrill WebHooks in .net

人走茶凉 提交于 2019-12-12 00:57:48
问题 I'm a student trying to work with mandrill and to be quite honest, I haven't a clue what I'm at. I'm able to send emails no problem using mandrill in .net What I want to do now is use webhooks to catch bounce emails at the moment and maybe more once I have accomplished that. Here is the code I have so far (from the internet) public ActionResult HandleMandrillWebhook(FormCollection fc) { string json = fc["mandrill_events"]; var events = JsonConvert.DeserializeObject<IEnumerable<Mandrill

How can I send cyrillic emails with Mandrill and Windows1251 encoding?

﹥>﹥吖頭↗ 提交于 2019-12-11 19:23:12
问题 I have started to use Mandrill to send all mails from our site but faced a problem with encoding. Encoding of the site is still Windows1251 / CP-1251 (I really don't have time to change it). I can send emails in English. But when I try to send cyrillic emails (Ukrainian, Russian, etc) it shows me an error "You must specify a key value...". I need always to encode body of email to UTF-8. In this case Mandrill sends letter well but emails are with broken encoding. Does somebody know if it

get data from return value of mandrillapp array [duplicate]

假装没事ソ 提交于 2019-12-11 13:35:45
问题 This question already has answers here : How do I extract data from JSON with PHP? (7 answers) Closed 3 years ago . Mandrill app return this : [{"email":"steven@gmail.com","status":"sent","_id":"234we4fvba4a3e8517d7a9","reject_reason":null}] I need to get only the value of "status". Something like this: echo $result['status']; How can I do it in PHP? 回答1: use json_decode() to get the status.. like this : <?php $str = '[{"email":"steven@gmail.com","status":"sent","_id":"234we4fvba4a3e8517d7a9"

Is it possible to change the STMP port from 587 to 2525?

北城余情 提交于 2019-12-11 11:44:31
问题 I'm deploying an app on Google Compute Engine (GCE) instance, with send email features, using mandrill as my email server. GCE blocks ports 25, 465, and 587 except for service partners (Sendgrid). When configuring mandrill only port 587 is setted. Is it possible to configure a different port on mandrill such as 2525? Thank you in advance. 回答1: Mandrill supports several other ports besides 587, as shown in the documentation here. You don't need to change anything in your account, just select

Image attachment is not working properly with email using Mandrill API in iOS

♀尐吖头ヾ 提交于 2019-12-11 00:59:25
问题 I am using Mandrill API to send email. Everything is working fine even image attachment is working good. But the problem with image is that email don't have attachment sign in subject line and also attached image don't have a name. The problem is with name key here is image attachment part of JSON. I tried many ways to give name but none of them works for me. images:[ { "type": "image/png", "name": "IMAGECID", "content": "ZXhhbXBsZSBmaWxl" } ] 回答1: The attachment icon is going to be somewhat

Mandrill embed image cannot get interpreted properly

牧云@^-^@ 提交于 2019-12-10 23:48:35
问题 I'm using Mandrill in Nodejs to send emails to customers, and want to embed an image in my html content attached to the emails. I found some solutions from https://mandrill.zendesk.com/hc/en-us/articles/205582457-Tips-for-using-images-in-Mandrill-emails and decided to use the 4th one, which includes the image inline in the html. The code is as below: var message = { html: htmlContent, subject: "Subject", ... images = [{ "type": logo.logoType, // which is "image/jpeg" "name": "logo", "content"

Universal Deep Links with Mandrill sub domain

微笑、不失礼 提交于 2019-12-10 18:45:15
问题 I have Universal Deep Links working for my iOS app, Neighbourly (associated with neighbourly.co.nz) We send out emails to our users and use Mandrill to track clicks. The email links go to a subdomain clicks.neighbourly.co.nz/path which points to mandrillapp.com/path and the links redirect to neighbourly.co.nz/newpath Ive added applinks:clicks.neighbourly.co.nz to the apps associated domains. My apple-app-site-association file's paths is a wildcard: ["*"] But, while links to neighbourly.co.nz