Official Library

Go Email Verification SDK

The official Go client for EmailVerify.io, offering high-concurrency, performance-optimized email validation and lead discovery tools for distributed systems.

Free plan available. No credit card required.

sdk-example.worker

Go Get Setup

Add the EmailVerify Go client to your project dependencies.

terminal
$ go get github.com/Clustox/emailverifygo

Usage Samples

1 Real-time Verification

High-performance email verification for Go. Our SDK is designed to be lightweight and fast, providing thread-safe operations for real-time validation.

go
import "github.com/Clustox/emailverifygo"

client := emailverifygo.NewClient("your_api_key")
res, err := client.Validate("[email protected]")

if err == nil && res.Status == "valid" {
    fmt.Println("Safe to send!")
}

2 Large Batch Submission

Process massive datasets without blocking. The Go batch client allows you to submit large slices of emails for background verification.

go
emails :=[]string{"[email protected]", "[email protected]"}
batch, _ := client.ValidateBatch(emails, "My Task")

// Poll or use webhooks
status, _ := client.GetTaskStatus(batch.TaskID)
if status.State == "finished" {
    results, _ := client.GetTaskResults(batch.TaskID)
    fmt.Printf("Processed %d emails\n", len(results))
}

3 Advanced Client & Context

Enterprise-ready configuration. Fully supports Go's context pattern for cancellation and timeouts.

go
ctx, cancel := context.WithTimeout(context.Background(), 5*time.Second)
defer cancel()

// Advanced config with custom HTTP client
client := emailverifygo.NewClient("key")
client.HTTPClient.Timeout = 10 * time.Second

res, err := client.ValidateWithContext(ctx, "[email protected]")

4 AI-Driven Email Finder

Professional lead discovery. Use our Finder API to resolve institutional email addresses from names and domains.

go
lead, err := client.FindEmail("Larry Page", "google.com")

if err == nil && lead.Status == "found" {
    fmt.Printf("Found: %s (Confidence: %d%%)\n", lead.Email, lead.Confidence)
}

5 Real-time Syntax Correction

Minimize user friction. Automatically detect and suggest corrections for common email typos in real-time.

go
check, _ := client.ValidateSyntax("[email protected]")
if check.Suggestion != "" {
    fmt.Printf("Typo detected! Did you mean %s?\n", check.Suggestion)
}

6 Concurrent Batch Verification

Built for speed. Leverage Go's goroutines to perform multiple real-time verifications in parallel.

go
var wg sync.WaitGroup
emails :=[]string{"[email protected]", "[email protected]", "[email protected]"}

for _, email := range emails {
    wg.Add(1)
    go func(e string) {
        defer wg.Done()
        res, _ := client.Validate(e)
        fmt.Println(res.Status)
    }(email)
}
wg.Wait()

7 Robust Type-Safe Errors

Graceful error management. Every API failure is returned as a structured error type for precise failure mode detection.

go
res, err := client.Validate(email)
if err != nil {
    if apiErr, ok := err.(*emailverifygo.APIError); ok {
        fmt.Printf("Status: %d, Message: %s", apiErr.Code, apiErr.Message)
    }
}

8 Spam & Security Detection

Protect your reputation. Detect and block disposable email services and known spam traps before they contact your servers.

go
res, _ := client.Validate("[email protected]")
if res.IsDisposable || res.IsSpamTrap {
    log.Printf("High risk email: %s", res.Email)
}
fmt.Printf("Provider: %s", res.DomainInfo.Provider)
FAQs

Frequently Asked Questions

Question Icon

Is the Go SDK thread-safe?

Yes, the Go client is designed to be thread-safe and can be safely shared across multiple goroutines.

Question Icon

How do I handle errors in the Go SDK?

The SDK follows the standard Go error handling pattern. Every API method returns a result and an error object.

Question Icon

Does the SDK support context?

Yes, our latest Go SDK supports context propagation, allowing you to manage request timeouts effectively.

Question Icon

Can I use it for high-concurrency validation?

Absolutely. The Go SDK is optimized for high-performance and is ideal for high-concurrency microservices.

You're just one click away from clean email lists.

Start verifying your email addresses instantly and improve your campaign deliverability

* No credit card required