package main

import (

func main() {

    requestData := struct {
        ApiKey   string `json:"apiKey"`     
        Payload string `json:"payload"`
    }{"YOUR API KEY", "someone@disposableemail.com"}

    if jsonBA, err := json.Marshal(&requestData); err == nil {
        resp, err := http.Post("https://api.inboxhit.com/v1/validate-email", "application/json", bytes.NewBuffer(jsonBA))
        defer resp.Body.Close()

        if err == nil {
            var responseData struct {
                Errors []struct {
                    Code   int    `json:"code"`
                    Detail string `json:"detail"`
                } `json:"errors"`
                Payload *struct {
                    Free       float64 `json:"free"`
                    Disposable float64 `json:"disposable"`
                    Spam       float64 `json:"spam"`
                    Scam       float64 `json:"scam"`
                } `json:"payload"`

            if respBA, err := ioutil.ReadAll(resp.Body); err == nil {
                if err := json.Unmarshal(respBA, &responseData); err == nil {
                    if responseData.Payload != nil && responseData.Payload.Disposable > 0.9 {
                        // email is disposable
                        log.Println("Disposable score", responseData.Payload.Disposable)

.NET Python

Get Started Now

Use InboxHit online solution to boost your email deliverability. Get 1000 welcome credits.

Click your favorite button below for a one-click sign-up.

Google Twitter Facebook LinkedIn

InboxHit provides solutions and services to boost email deliverability, increase email marketing efficiency and achieve 100% innox hit rate. Use InboxHit API to detect disposable emails, block disposable emails, detect and block DEAs, validate email addresses, check if a mailbox exists, reduce bounces, boost deliverability, increase email marketing efficiency, reduce email delivery costs. InboxHit API is also available on RapidAPI.