Skip to content

Latest commit

 

History

History
50 lines (33 loc) · 1.31 KB

README.zh-CN.md

File metadata and controls

50 lines (33 loc) · 1.31 KB

Go ArNS

GitHub go.mod Go version GitHub tag (latest SemVer) Go Report Card Unit-Tests Coverage Status Go Reference

什么是 ArNS

ArNS: https://ar.io/arns/

安装

go get github.com/everFinance/goarns

如何使用

package example

import (
	"github.com/everFinance/goarns"
	"time"
)

func QueryArNS() {

	dreUrl := "https://dre-3.warp.cc"
	arNSAddress := "bLAgYxAdX2Ry-nt6aH2ixgvJXbpsEYm28NgJgyqfs-U"
	timeout := 10 * time.Second

	domain := "arseeding"

	a := goarns.NewArNS(dreUrl, arNSAddress, timeout)

	txId, err := a.QueryLatestRecord(domain)

	if err != nil {
		print(err)
	}
	print(txId)

}