Documentation ¶
Index ¶
- type Client
- func (c *Client) CreateTemplate(template *Template) error
- func (c *Client) CreateTemplateVersion(version *TemplateVersion) error
- func (c *Client) DeleteTemplate(id string) error
- func (c *Client) DeleteTemplateVersion(template, id string) error
- func (c *Client) GetTemplate(id string) (*Template, error)
- func (c *Client) GetTemplateVersion(template, id string) (*TemplateVersion, error)
- func (c *Client) UpdateTemplate(id string, template *Template) error
- func (c *Client) UpdateTemplateVersion(id string, version *TemplateVersion) error
- type Error
- type Provider
- type Template
- type TemplateResource
- type TemplateVersion
- type TemplateVersionResource
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct {
Key string
}
Client represents a SendGrid Client
func (*Client) CreateTemplate ¶
CreateTemplate creates a template
func (*Client) CreateTemplateVersion ¶
func (c *Client) CreateTemplateVersion(version *TemplateVersion) error
CreateTemplateVersion creates a template version
func (*Client) DeleteTemplate ¶
DeleteTemplate deletes a template
func (*Client) DeleteTemplateVersion ¶
DeleteTemplateVersion deletes a template version
func (*Client) GetTemplate ¶
GetTemplate gets a template
func (*Client) GetTemplateVersion ¶
func (c *Client) GetTemplateVersion(template, id string) (*TemplateVersion, error)
GetTemplateVersion gets a template version
func (*Client) UpdateTemplate ¶
UpdateTemplate updates a template
func (*Client) UpdateTemplateVersion ¶
func (c *Client) UpdateTemplateVersion(id string, version *TemplateVersion) error
UpdateTemplateVersion updates a template
type Provider ¶
type Provider struct{}
Provider for Hydra OAuth2 Server
func (*Provider) Definition ¶
Definition returns the provider's schema
type Template ¶
type Template struct { ID string `json:"id,omitempty"` Name string `json:"name,omitempty"` Generation string `json:"generation,omitempty"` Versions []*TemplateVersion `json:"versions,omitempty"` }
Template represents a template
type TemplateResource ¶
type TemplateResource struct{}
TemplateResource represent's the flient resource
func (*TemplateResource) Definition ¶
func (r *TemplateResource) Definition() *schema.Resource
Definition returns the resource
type TemplateVersion ¶
type TemplateVersion struct { ID string `json:"id,omitempty"` Name string `json:"name,omitempty"` TemplateID string `json:"template_id,omitempty"` Subject string `json:"subject,omitempty"` HTMLContent string `json:"html_content,omitempty"` PlainContent string `json:"plain_content,omitempty"` Editor string `json:"editor,omitempty"` Active int `json:"active,omitempty"` }
TemplateVersion is a template content's version
type TemplateVersionResource ¶
type TemplateVersionResource struct{}
TemplateVersionResource represent's the flient resource
func (*TemplateVersionResource) Definition ¶
func (r *TemplateVersionResource) Definition() *schema.Resource
Definition returns the resource