aboutsummaryrefslogtreecommitdiff
path: root/directory.go
blob: 8dde47eee5462b849834bdbca4e5d4cf1ce77d1c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
package acme

const (
	LEV1      = `https://acme-v01.api.letsencrypt.org/directory`
	LEStaging = `https://acme-staging.api.letsencrypt.org/directory`
)

type Directory struct {
	NewReg     string `json:"new-reg"`
	RecoverReg string `json:"recover-reg"`
	NewAuthz   string `json:"new-authz"`
	NewCert    string `json:"new-cert"`
	RevokeCert string `json:"revoke-cert"`
}

func NewDirectory(uri string) (Directory, error) {
	var dir Directory
	err := Get(uri, &dir)
	return dir, err
}