Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type APIError ¶
type APIResponse ¶
type APIResponse struct { Success bool `json:"success"` Errors []APIError `json:"errors"` Messages []string `json:"messages"` Result json.RawMessage `json:"result"` }
type Builder ¶ added in v0.10.0
type Builder struct {
// contains filtered or unexported fields
}
func NewBuilder ¶ added in v0.10.0
func NewBuilder() *Builder
func (*Builder) WithClient ¶ added in v0.10.0
func (*Builder) WithServiceKey ¶ added in v0.10.0
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
func (*Client) Sign ¶
func (c *Client) Sign(ctx context.Context, req *SignRequest) (*SignResponse, error)
type Interface ¶
type Interface interface {
Sign(context.Context, *SignRequest) (*SignResponse, error)
}
type Options ¶
type Options func(c *Client)
func WithClient ¶
func WithEndpoint ¶ added in v0.6.1
func WithServiceKey ¶ added in v0.10.0
type SignRequest ¶
type SignResponse ¶
type SignResponse struct { Id string `json:"id"` Certificate string `json:"certificate"` Hostnames []string `json:"hostnames"` Expiration time.Time `json:"expires_on"` Type string `json:"request_type"` Validity int `json:"requested_validity"` CSR string `json:"csr"` }
func (*SignResponse) UnmarshalJSON ¶ added in v0.5.1
func (r *SignResponse) UnmarshalJSON(p []byte) error
adapted from http://choly.ca/post/go-json-marshalling/
Click to show internal directories.
Click to hide internal directories.