1# Go library for accessing the Porkdun API
2
3[![Build Status](https://github.com/nrdcg/porkbun/workflows/Main/badge.svg?branch=master)](https://github.com/nrdcg/porkbun/actions)
4[![PkgGoDev](https://pkg.go.dev/badge/github.com/nrdcg/porkbun)](https://pkg.go.dev/github.com/nrdcg/porkbun)
5[![Go Report Card](https://goreportcard.com/badge/github.com/nrdcg/porkbun)](https://goreportcard.com/report/github.com/nrdcg/porkbun)
6
7An [Porkbun](https://porkbun.com) API client written in Go.
8
9porkbun is a Go client library for accessing the Porkbun API.
10
11## Examples
12
13```go
14package main
15
16import (
17	"context"
18	"fmt"
19
20	"github.com/nrdcg/porkbun"
21)
22
23func main() {
24	client := porkbun.New("secret", "key")
25
26	ctx := context.Background()
27
28	yourIP, err := client.Ping(ctx)
29	if err != nil {
30		panic(err)
31	}
32
33	fmt.Println(yourIP)
34}
35```
36
37## API Documentation
38
39- [API docs](https://porkbun.com/api/json/v3/documentation)
40