dip/vendor/github.com/likexian/whois-parser-go
2019-12-22 18:20:45 +01:00
..
.gitignore first commit 2019-12-22 18:20:45 +01:00
.travis.yml first commit 2019-12-22 18:20:45 +01:00
go.mod first commit 2019-12-22 18:20:45 +01:00
go.sum first commit 2019-12-22 18:20:45 +01:00
LICENSE first commit 2019-12-22 18:20:45 +01:00
parser.go first commit 2019-12-22 18:20:45 +01:00
prepare.go first commit 2019-12-22 18:20:45 +01:00
README.md first commit 2019-12-22 18:20:45 +01:00
rule.go first commit 2019-12-22 18:20:45 +01:00
struct.go first commit 2019-12-22 18:20:45 +01:00
utils.go first commit 2019-12-22 18:20:45 +01:00

whois-parser.go

License GoDoc Build Status Go Report Card Code Cover

whois-parser-go is a simple Go module for domain whois info parse.

Overview

This module parses the provided whois information and return a readable data struct.

Verified Extensions

It is supposed to be working with all domain extensions, but verified extensions must works, because I have checked them one by one manually.

If there is any problems, please feel free to open a new issue.

Installation

go get github.com/likexian/whois-parser-go

Importing

import (
    "github.com/likexian/whois-parser-go"
)

Documentation

Visit the docs on GoDoc

Example

result, err := whoisparser.Parse(whois_raw)
if err == nil {
    // Print the domain status
    fmt.Println(result.Domain.Status)

    // Print the domain created date
    fmt.Println(result.Domain.CreatedDate)

    // Print the domain expiration date
    fmt.Println(result.Domain.ExpirationDate)

    // Print the registrar name
    fmt.Println(result.Registrar.Name)

    // Print the registrant name
    fmt.Println(result.Registrant.Name)

    // Print the registrant email address
    fmt.Println(result.Registrant.Email)
}

Whois info query in Go

Please refer to whois-go

LICENSE

Copyright 2014-2019 Li Kexian

Licensed under the Apache License 2.0

About

DONATE