From 1c0368615aea87a8fc98c6974978a9251c2edb59 Mon Sep 17 00:00:00 2001 From: Igor German Date: Tue, 16 Oct 2018 12:42:34 +0300 Subject: [PATCH] Update readme --- README.md | 36 +++++++++++++++++++++++++++++++++++- 1 file changed, 35 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index cdba049..3a0dfca 100644 --- a/README.md +++ b/README.md @@ -3,4 +3,38 @@ [![Build Status](https://www.travis-ci.org/namreg/ded.svg?branch=master)](https://www.travis-ci.org/namreg/ded) [![Go Report Card](https://goreportcard.com/badge/github.com/namreg/ded)](https://goreportcard.com/report/github.com/namreg/ded) [![GitHub](https://img.shields.io/github/license/mashape/apistatus.svg)](https://github.com/namreg/ded/blob/master/LICENSE) -[![GoDoc](https://godoc.org/github.com/namreg/ded?status.svg)](https://godoc.org/github.com/namreg/ded) \ No newline at end of file +[![GoDoc](https://godoc.org/github.com/namreg/ded?status.svg)](https://godoc.org/github.com/namreg/ded) + +Go package that detects disposable emails based on the list [list](https://github.com/wesbos/burner-email-providers). + +_Notice: DED does not check that email address is correct._ + +### Installation +```bash +go get github.com/namreg/ded +``` + +### How to use +```go +package main + +import ( + "fmt" + + "github.com/namreg/ded" +) + +func main() { + disposable, _ := ded.IsDisposableEmail("temp@mail.wtf") + fmt.Println(disposable) // true + + disposable, _ = ded.IsDisposableEmail("temp@google.com") + fmt.Println(false) // false + + disposable, _ := ded.IsDisposableDomain("mail.wtf") + fmt.Println(disposable) // true + + disposable, _ = ded.IsDisposableDomain("google.com") + fmt.Println(false) // false +} +``` \ No newline at end of file