Esau Romano
Posts: 0
Joined: Sun Jun 02, 2013 7:03 pm

MAILGUN API

curl -s --user 'api:key-3ax6xnjp29jd6fds4gc373sgvjxteol0' \
https://api.mailgun.net/v2/samples.ma... \
-F from='Excited User ' \
-F to=a href="mailto:baz@example.com" rel="nofollow"baz@example.com/a\
-F to=a href="mailto:bar@example.com" rel="nofollow"bar@example.com/a \
-F subject='Hello' \
-F text='Testing some Mailgun awesomness!'

THIS IS A CURL TO SEND TROUGTH MAILGUN, CAN ANYONE GIVE THE CORRECT WAY TO CONFIGURE THIS AS A SERVICE IN APPERY?

maxkatz
Posts: 0
Joined: Fri Aug 13, 2010 3:24 pm

MAILGUN API

Define the URL like this:

https://api:key-3ax6xnjp29jd6fds4gc37...

The rest should be defined as request parameters.

Madi Anas
Posts: 0
Joined: Thu Sep 03, 2015 9:52 pm

MAILGUN API

In case someone has stumbled on this and still didn't get it, just like me at first.

mailgun provides REST API email delivery free for 10K of emails per month as of September 2015. Sendgrid does not have free plan anymore, just for 15 days.

Here's sample code for sending an email with curl:

precurl -s --user 'api:key-3ax6xnjp29jd6fds4gc373sgvjxteol0' \
https://api.mailgun.net/v3/samples.mailgun.org/messages \
-F from='Excited User ' \
-F to='devs@mailgun.net' \
-F subject='Hello' \
-F text='Testing some Mailgun awesomeness!'/pre

Your URL in appery service should be:
prehttps://api:key-3ax6xnjp29jd6fds4gc373sgvjxteol0@api.mailgun.net/v3/samples.mailgun.org/messages/pre

Method should be POST

Then request query should be:
Image

Return to “Issues”