Documentation
¶
Index ¶
- type Client
- func (c *Client) PartiallyUpdateWebhook(webhookId string, request WebhookRequest) (*WebhookResponse, error)
- func (c *Client) RegisterWebhook(request WebhookRequest) (*WebhookResponse, error)
- func (c *Client) RemoveWebhook(webhookId string) (*common.MetadataResponse, error)
- func (c *Client) RetrieveWebhook(webhookId string) (*WebhookResponse, error)
- func (c *Client) RetrieveWebhooks() (*WebhooksResponse, error)
- func (c *Client) UpdateWebhook(webhookId string, request WebhookRequest) (*WebhookResponse, error)
- type ContentType
- type WebhookRequest
- type WebhookResponse
- type WebhooksResponse
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
func NewClient ¶
func NewClient(configuration *configuration.Configuration, apiClient client.HttpClient) *Client
func (*Client) PartiallyUpdateWebhook ¶
func (c *Client) PartiallyUpdateWebhook(webhookId string, request WebhookRequest) (*WebhookResponse, error)
func (*Client) RegisterWebhook ¶
func (c *Client) RegisterWebhook(request WebhookRequest) (*WebhookResponse, error)
func (*Client) RemoveWebhook ¶
func (c *Client) RemoveWebhook(webhookId string) (*common.MetadataResponse, error)
func (*Client) RetrieveWebhook ¶
func (c *Client) RetrieveWebhook(webhookId string) (*WebhookResponse, error)
func (*Client) RetrieveWebhooks ¶
func (c *Client) RetrieveWebhooks() (*WebhooksResponse, error)
func (*Client) UpdateWebhook ¶
func (c *Client) UpdateWebhook(webhookId string, request WebhookRequest) (*WebhookResponse, error)
type WebhookRequest ¶
type WebhookRequest struct {
Url string `json:"url"`
Active bool `json:"active,omitempty" default:"true"`
Headers map[string]interface{} `json:"headers,omitempty"`
ContentType ContentType `json:"content_type,omitempty" default:"json"`
EventTypes []string `json:"event_types"`
}
type WebhookResponse ¶
type WebhookResponse struct {
HttpResponse common.HttpMetadata
Id string `json:"id,omitempty"`
Url string `json:"url,omitempty"`
Active bool `json:"active,omitempty"`
Headers interface{} `json:"headers,omitempty"`
ContentType ContentType `json:"content_type,omitempty"`
EventTypes []string `json:"event_types,omitempty"`
Links map[string]common.Link `json:"_links" json:"links,omitempty"`
}
type WebhooksResponse ¶
type WebhooksResponse struct {
HttpResponse common.HttpMetadata
WebhookArray []WebhookResponse
}
func (*WebhooksResponse) UnmarshalJSON ¶
func (e *WebhooksResponse) UnmarshalJSON(data []byte) error
Click to show internal directories.
Click to hide internal directories.