Jump to content
guy

WireMailSendGrid

Recommended Posts

Github: https://github.com/theGC/WireMailSendGrid

What it does:

Extend WireMail to bypass PHP mail and send mail via SendGrids Web API.

What you need:

A SendGrid account, use this to generate an API Key with Full Mail Send permissions.

Once installed, the API Key is popped into the modules config and you should be good to go.

Use Cases:

It simplifies the process of sending email from servers by removing the need to configure sendmail or other email routing applications on the server. Instead it relies solely on PHP and offloads the sending to SendGrid which can be heavily configured via its UI to ensure better delivery rates for your domain.

 

  • Like 4

Share this post


Link to post
Share on other sites

Hey @guy, thanks for sharing this!

Unless I've missed something important, note that your module doesn't actually have to hook into WireMail::___send() – it's a WireMail module, so it should implement its own ___send() method instead. This is how WireMail modules are designed to work, and it also guarantees proper interoperability in the case that other WireMail modules are installed 🙂

See WireMailMailgun for a reference.

  • Like 3

Share this post


Link to post
Share on other sites

@teppo thanks pal

Yeah I noticed as soon as this was uploaded. Just tweaking it now but as you say no need for the hook as allows it to play better with other WireMail modules.

  • Like 2

Share this post


Link to post
Share on other sites

hey @guy

i installed this module and have a free-sendgrid account. generated an API key and did this:

	$m = new wireMail();
	$m->body('hello');
	$m->from($email = 'test@test.com', $name = 'John');
	$m->to($email = 'mail@test.com', $name = 'Jane', $substitutions = null, $subject = 'TESTING');
	$m->___send();

Email is send out and delivered. But i don't see any statistics about them being sent on sendgrid. Did i forgot something?
Tracking is enabled.

Share this post


Link to post
Share on other sites

did the update
i guess there's a typo

this appears on the settingspage of the module

image.thumb.png.f392f06190cea03afbd869c7804d8dd3.png
 

Edited by ngrmm

Share this post


Link to post
Share on other sites

hi @guy
i corrected that comma on line 132

still getting no statistics/activity-data on sendgrid. maybe its like this because of SSL (https)?

Share this post


Link to post
Share on other sites

@ngrmm thanks for letting me know about that config issue. Will get that sorted in a min.

On the SendGrid front I'm not too sure. SendGrid should show sent and received stats for all messages, therefore if you're not even seeing that (and the message is delivered) then something else is probably not quite right.

  • Like 1

Share this post


Link to post
Share on other sites
4 minutes ago, guy said:

just updated to v1.1.4 with the bug fix

thx

it's weird, maybe i try mailgun and see what happens there

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...