Coder Social home page Coder Social logo

17twenty / go-mailgun-mailing-list-api Goto Github PK

View Code? Open in Web Editor NEW

This project forked from amyboyd/go-mailgun-mailing-list-api

0.0 2.0 0.0 5 KB

A simple API, written in Go, for subscribing new emails to a Mailgun mailing list

Go 88.02% Shell 6.41% HTML 5.58%

go-mailgun-mailing-list-api's Introduction

Mailgun mailing list API

A simple API, written in Go, for subscribing new emails to a Mailgun mailing list.

Usage

Set environment variables to configure the application:

export MAILGUN_DOMAIN=mg.yourdomain.com
export MAILGUN_API_KEY=key-abcdefghijkl
export [email protected]
export SUBSCRIBE_HTTP_PORT=8000
export SUBSCRIBE_REDIRECT_URL=http://yourdomain.com/newsletter/success

Download and run the application:

curl -L https://github.com/amyboyd/go-mailgun-mailing-list-api/releases/download/v0.2.0/mailgun-mailing-list-api -o mailgun-mailing-list-api
chmod +x mailgun-mailing-list-api
./mailgun-mailing-list-api

Add a form to your web page that submits the user's email address to the API:

<form action="http://host:8000/subscribe">
	<input type="email" name="email" placeholder="Email your email address..." />
	<input type="submit" value="Subscribe to the newsletter" />
</form>

Monitoring

If you want to set up monitoring, to check the API is running at all times, the API has a URL for that, /health-check

go-mailgun-mailing-list-api's People

Contributors

amyboyd avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.