Documentation ¶
Index ¶
- func NewCreateAliasRequest(server string, body Alias) (*http.Request, error)
- func NewCreateAliasRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error)
- func NewCreateDomainRequest(server string, body Domain) (*http.Request, error)
- func NewCreateDomainRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error)
- func NewCreateUserRequest(server string, body User) (*http.Request, error)
- func NewCreateUserRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error)
- func NewDeleteAliasRequest(server string, alias string) (*http.Request, error)
- func NewDeleteAlternativeRequest(server string, alt string) (*http.Request, error)
- func NewDeleteDomainRequest(server string, domain string) (*http.Request, error)
- func NewDeleteUserRequest(server string, email string) (*http.Request, error)
- func NewFindAliasRequest(server string, alias string) (*http.Request, error)
- func NewFindDomainRequest(server string, domain string) (*http.Request, error)
- func NewFindUserRequest(server string, email string) (*http.Request, error)
- func NewUpdateAliasRequest(server string, alias string, body Alias) (*http.Request, error)
- func NewUpdateAliasRequestWithBody(server string, alias string, contentType string, body io.Reader) (*http.Request, error)
- func NewUpdateDomainRequest(server string, domain string, body Domain) (*http.Request, error)
- func NewUpdateDomainRequestWithBody(server string, domain string, contentType string, body io.Reader) (*http.Request, error)
- func NewUpdateUserRequest(server string, email string, body User) (*http.Request, error)
- func NewUpdateUserRequestWithBody(server string, email string, contentType string, body io.Reader) (*http.Request, error)
- type Alias
- type Client
- func (c *Client) CreateAlias(ctx context.Context, body Alias, reqEditors ...RequestEditorFn) (*http.Response, error)
- func (c *Client) CreateDomain(ctx context.Context, body Domain, reqEditors ...RequestEditorFn) (*http.Response, error)
- func (c *Client) CreateUser(ctx context.Context, body User, reqEditors ...RequestEditorFn) (*http.Response, error)
- func (c *Client) DeleteAlias(ctx context.Context, alias string, reqEditors ...RequestEditorFn) (*http.Response, error)
- func (c *Client) DeleteAlternative(ctx context.Context, alt string, reqEditors ...RequestEditorFn) (*http.Response, error)
- func (c *Client) DeleteDomain(ctx context.Context, domain string, reqEditors ...RequestEditorFn) (*http.Response, error)
- func (c *Client) DeleteUser(ctx context.Context, email string, reqEditors ...RequestEditorFn) (*http.Response, error)
- func (c *Client) FindAlias(ctx context.Context, alias string, reqEditors ...RequestEditorFn) (*http.Response, error)
- func (c *Client) FindDomain(ctx context.Context, domain string, reqEditors ...RequestEditorFn) (*http.Response, error)
- func (c *Client) FindUser(ctx context.Context, email string, reqEditors ...RequestEditorFn) (*http.Response, error)
- func (c *Client) UpdateAlias(ctx context.Context, alias string, body Alias, reqEditors ...RequestEditorFn) (*http.Response, error)
- func (c *Client) UpdateDomain(ctx context.Context, domain string, body Domain, reqEditors ...RequestEditorFn) (*http.Response, error)
- func (c *Client) UpdateUser(ctx context.Context, email string, body User, reqEditors ...RequestEditorFn) (*http.Response, error)
- type ClientOption
- type Domain
- type DomainDetails
- type HttpRequestDoer
- type RequestEditorFn
- type User
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewCreateAliasRequest ¶
NewCreateAliasRequest calls the generic CreateAlias builder with application/json body
func NewCreateAliasRequestWithBody ¶
func NewCreateAliasRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error)
NewCreateAliasRequestWithBody generates requests for CreateAlias with any type of body
func NewCreateDomainRequest ¶
NewCreateDomainRequest calls the generic CreateDomain builder with application/json body
func NewCreateDomainRequestWithBody ¶
func NewCreateDomainRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error)
NewCreateDomainRequestWithBody generates requests for CreateDomain with any type of body
func NewCreateUserRequest ¶
NewCreateUserRequest calls the generic CreateUser builder with application/json body
func NewCreateUserRequestWithBody ¶
func NewCreateUserRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error)
NewCreateUserRequestWithBody generates requests for CreateUser with any type of body
func NewDeleteAliasRequest ¶
NewDeleteAliasRequest generates requests for DeleteAlias
func NewDeleteAlternativeRequest ¶
NewDeleteAlternativeRequest generates requests for DeleteAlternative
func NewDeleteDomainRequest ¶
NewDeleteDomainRequest generates requests for DeleteDomain
func NewDeleteUserRequest ¶
NewDeleteUserRequest generates requests for DeleteUser
func NewFindAliasRequest ¶
NewFindAliasRequest generates requests for FindAlias
func NewFindDomainRequest ¶
NewFindDomainRequest generates requests for FindDomain
func NewFindUserRequest ¶
NewFindUserRequest generates requests for FindUser
func NewUpdateAliasRequest ¶
NewUpdateAliasRequest calls the generic UpdateAlias builder with application/json body
func NewUpdateAliasRequestWithBody ¶
func NewUpdateAliasRequestWithBody(server string, alias string, contentType string, body io.Reader) (*http.Request, error)
NewUpdateAliasRequestWithBody generates requests for UpdateAlias with any type of body
func NewUpdateDomainRequest ¶
NewUpdateDomainRequest calls the generic UpdateDomain builder with application/json body
func NewUpdateDomainRequestWithBody ¶
func NewUpdateDomainRequestWithBody(server string, domain string, contentType string, body io.Reader) (*http.Request, error)
NewUpdateDomainRequestWithBody generates requests for UpdateDomain with any type of body
func NewUpdateUserRequest ¶
NewUpdateUserRequest calls the generic UpdateUser builder with application/json body
Types ¶
type Alias ¶
type Alias struct { // Comment a comment Comment *string `json:"comment,omitempty"` Destination *[]string `json:"destination,omitempty"` // Email the alias email address Email string `json:"email"` // Wildcard enable SQL Like wildcard syntax Wildcard *bool `json:"wildcard,omitempty"` }
Alias defines model for Alias.
type Client ¶
type Client struct { // The endpoint of the server conforming to this interface, with scheme, // https://api.deepmap.com for example. This can contain a path relative // to the server, such as https://api.deepmap.com/dev-test, and all the // paths in the swagger spec will be appended to the server. Server string // Doer for performing requests, typically a *http.Client with any // customized settings, such as certificate chains. Client HttpRequestDoer // A list of callbacks for modifying requests which are generated before sending over // the network. RequestEditors []RequestEditorFn }
Client which conforms to the OpenAPI3 specification for this service.
func NewClient ¶
func NewClient(server string, opts ...ClientOption) (*Client, error)
Creates a new Client, with reasonable defaults
func (*Client) CreateAlias ¶
func (*Client) CreateDomain ¶
func (*Client) CreateUser ¶
func (*Client) DeleteAlias ¶
func (*Client) DeleteAlternative ¶
func (*Client) DeleteDomain ¶
func (*Client) DeleteUser ¶
func (*Client) FindDomain ¶
func (*Client) UpdateAlias ¶
type ClientOption ¶
ClientOption allows setting custom parameters during construction
func WithHTTPClient ¶
func WithHTTPClient(doer HttpRequestDoer) ClientOption
WithHTTPClient allows overriding the default Doer, which is automatically created using http.Client. This is useful for tests.
func WithRequestEditorFn ¶
func WithRequestEditorFn(fn RequestEditorFn) ClientOption
WithRequestEditorFn allows setting up a callback function, which will be called right before sending the request. This can be used to mutate the request.
type Domain ¶
type Domain struct { Alternatives *[]string `json:"alternatives,omitempty"` // Comment a comment Comment *string `json:"comment,omitempty"` // MaxAliases maximum number of aliases MaxAliases *int `json:"max_aliases,omitempty"` // MaxQuotaBytes maximum quota for mailbox MaxQuotaBytes *int `json:"max_quota_bytes,omitempty"` // MaxUsers maximum number of users MaxUsers *int `json:"max_users,omitempty"` // Name FQDN (e.g. example.com) Name string `json:"name"` // SignupEnabled allow signup SignupEnabled *bool `json:"signup_enabled,omitempty"` }
Domain defines model for Domain.
type DomainDetails ¶
type DomainDetails struct { Alternatives *[]string `json:"alternatives,omitempty"` // Comment a comment Comment *string `json:"comment,omitempty"` DNSAutoconfig *[]string `json:"dns_autoconfig,omitempty"` // MaxAliases maximum number of aliases MaxAliases *int `json:"max_aliases,omitempty"` // MaxQuotaBytes maximum quota for mailbox MaxQuotaBytes *int `json:"max_quota_bytes,omitempty"` // MaxUsers maximum number of users MaxUsers *int `json:"max_users,omitempty"` // Managers lists managers of this domain Managers *[]string `json:"managers,omitempty"` // Name FQDN (e.g. example.com) Name string `json:"name"` // SignupEnabled allow signup SignupEnabled *bool `json:"signup_enabled,omitempty"` }
type HttpRequestDoer ¶
Doer performs HTTP requests.
The standard http.Client implements this interface.
type RequestEditorFn ¶
RequestEditorFn is the function signature for the RequestEditor callback function
type User ¶
type User struct { // AllowSpoofing Allow the user to spoof the sender (send email as anyone) AllowSpoofing *bool `json:"allow_spoofing,omitempty"` // ChangePwNextLogin Force the user to change their password at next login ChangePwNextLogin *bool `json:"change_pw_next_login,omitempty"` // Comment A description for the user. This description is shown on the Users page Comment *string `json:"comment,omitempty"` // DisplayedName The display name of the user within the Admin GUI DisplayedName *string `json:"displayed_name,omitempty"` // Email The email address of the user Email string `json:"email"` // Enabled Enable the user Enabled *bool `json:"enabled,omitempty"` // EnableImap Allow email retrieval via IMAP EnableImap *bool `json:"enable_imap,omitempty"` // EnablePop Allow email retrieval via POP3 EnablePop *bool `json:"enable_pop,omitempty"` ForwardDestination *[]string `json:"forward_destination,omitempty"` // ForwardEnabled Enable auto forwarding ForwardEnabled *bool `json:"forward_enabled,omitempty"` // ForwardKeep Keep a copy of the forwarded email in the inbox ForwardKeep *bool `json:"forward_keep,omitempty"` // GlobalAdmin Make the user a global administrator GlobalAdmin *bool `json:"global_admin,omitempty"` // Password Hash of the user's password Password *string `json:"password,omitempty"` // QuotaBytes The maximum quota for the user’s email box in bytes QuotaBytes *int64 `json:"quota_bytes,omitempty"` // QuotaBytesUsed The size of the user’s email box in bytes QuotaBytesUsed *int64 `json:"quota_bytes_used,omitempty"` // RawPassword is the plain text password for user creation RawPassword *string `json:"raw_password,omitempty"` // ReplyBody The body of the automatic reply email ReplyBody *string `json:"reply_body,omitempty"` // ReplyEnabled Enable automatic replies. This is also known as out of office (ooo) or out of facility (oof) replies ReplyEnabled *bool `json:"reply_enabled,omitempty"` // ReplyEndDate End date for automatic replies in YYYY-MM-DD format. ReplyEndDate *openapi_types.Date `json:"reply_enddate,omitempty"` // ReplyStartDate Start date for automatic replies in YYYY-MM-DD format. ReplyStartDate *openapi_types.Date `json:"reply_startdate,omitempty"` // ReplySubject Optional subject for the automatic reply ReplySubject *string `json:"reply_subject,omitempty"` // SpamEnabled Enable the spam filter SpamEnabled *bool `json:"spam_enabled,omitempty"` // SpamMarkAsRead Enable marking spam mails as read SpamMarkAsRead *bool `json:"spam_mark_as_read,omitempty"` // SpamThreshold The user defined spam filter tolerance SpamThreshold *int `json:"spam_threshold,omitempty"` }
User defines model for UserGet.