This library provides phone number information functionality including ability to access number look up APIs. It includes a Go client and CLI app for the Numverify API, and Twilio API.
https://numverify.com/documentation
Install | Command |
---|---|
SDK only | $ go get github.com/grokify/gophonenumbers |
CLI only | $ go get github.com/grokify/gophonenumbers/apps/numverify |
SDK and CLI | $ go get github.com/grokify/gophonenumbers/... |
Options | Long | Short | Example |
---|---|---|---|
.env File |
--env |
-e |
-e=/path/to/.env |
Access Token | --token |
-t |
-t=<myToken> |
Validate Number | --number |
-n |
-n=<number> |
List Countries | --countries |
-c |
-c |
$ numverify -e=/path/to/.env -n=+16505550100
$ numverify -t=<myToken> -n=+16505550100
$ numverify -e=/path/to/.env -c
$ numverify -t=<myToken> -c
import(
nv "github.com/grokify/gophonenumbers/numverify"
)
func main() {
client := nv.NumverifyClient{AccessKey: "myAccessKey"}
apiSuccessInfo, apiErrorInfo, resp, err := client.Validate(
nv.NumverifyParams{Number: number})
[...]
}
import(
nv "github.com/grokify/gophonenumbers/numverify"
)
func main() {
client := nv.NumverifyClient{AccessKey: "myAccessKey"}
countries, apiErrorInfo, resp, err := client.Countries()
[...]
}