Documentation ¶
Index ¶
- func CreateJSONPayload(data interface{}) (*bytes.Buffer, error)
- func RemoveAtIndex(s []string, index int) []string
- type Destination
- type DestinationList
- type DestinationListMeta
- type Meta
- type NewDestination
- type Status
- type UmbrellaClient
- func (u *UmbrellaClient) Delete(scope string, endpoint string, headers map[string]string, ...) (UmbrellaResponse, error)
- func (u *UmbrellaClient) Get(scope string, endpoint string, headers map[string]string, ...) (UmbrellaResponse, error)
- func (u *UmbrellaClient) Patch(scope string, endpoint string, headers map[string]string, ...) (UmbrellaResponse, error)
- func (u *UmbrellaClient) Post(scope string, endpoint string, headers map[string]string, ...) (UmbrellaResponse, error)
- func (u *UmbrellaClient) Request(method string, url string, headers map[string]string, params map[string]string, ...) (UmbrellaResponse, error)
- type UmbrellaConnector
- func (u *UmbrellaConnector) AddDestinations(destinationList DestinationList, destinationsToAdd []string, chunkSize int) (DestinationList, error)
- func (u *UmbrellaConnector) CreateDestinationList(access string, isGlobal bool, name string) (DestinationList, error)
- func (u *UmbrellaConnector) DeleteDestinationList(id int) error
- func (u *UmbrellaConnector) DeleteDestinations(destinationList DestinationList, destinationsToRemove []string, ...) (DestinationList, error)
- func (u *UmbrellaConnector) GetDestinationList(id int) (DestinationList, error)
- func (u *UmbrellaConnector) GetDestinationLists(limit int) ([]DestinationList, error)
- func (u *UmbrellaConnector) GetDestinations(id int, limit int) ([]Destination, error)
- func (u *UmbrellaConnector) UpdateDestinationList(id int, name string) (DestinationList, error)
- func (u *UmbrellaConnector) ValidateDestinationValues(destinations []string) ([]string, error)
- type UmbrellaResponse
- type UmbrellaResponseError
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CreateJSONPayload ¶
func RemoveAtIndex ¶
Types ¶
type Destination ¶
type DestinationList ¶
type DestinationList struct { ID int `json:"id"` OrganizationID int `json:"organizatioNId"` Access string `json:"access"` IsGlobal bool `json:"isGlobal"` Name string `json:"name"` ThirdpartyCategoryId string `json:"thirdpartyCategoryId"` CreatedAt int `json:"createdAt"` ModifiedAt int `json:"modifiedAt"` IsMspDefault bool `json:"isMspDefault"` MarkedForDeletion bool `json:"markedForDeletion"` BundleTypeId int `json:"bundleTypeId"` Meta DestinationListMeta `json:"meta"` }
type DestinationListMeta ¶
type NewDestination ¶
type NewDestination struct {
Destination string `json:"destination"`
}
type UmbrellaClient ¶
type UmbrellaClient struct {
// contains filtered or unexported fields
}
func CreateUmbrellaClient ¶
func CreateUmbrellaClient(configurationManager configurationManager.ConfigurationManager, logger logging.Logger) *UmbrellaClient
func (*UmbrellaClient) Get ¶
func (u *UmbrellaClient) Get(scope string, endpoint string, headers map[string]string, params map[string]string) (UmbrellaResponse, error)
type UmbrellaConnector ¶
type UmbrellaConnector struct {
// contains filtered or unexported fields
}
func New ¶
func New(client *UmbrellaClient, configurationManager configurationManager.ConfigurationManager, logger logging.Logger) (*UmbrellaConnector, error)
func (*UmbrellaConnector) AddDestinations ¶
func (u *UmbrellaConnector) AddDestinations(destinationList DestinationList, destinationsToAdd []string, chunkSize int) (DestinationList, error)
Add destinations to a destination list
func (*UmbrellaConnector) CreateDestinationList ¶
func (u *UmbrellaConnector) CreateDestinationList(access string, isGlobal bool, name string) (DestinationList, error)
Creates a new destination list
func (*UmbrellaConnector) DeleteDestinationList ¶
func (u *UmbrellaConnector) DeleteDestinationList(id int) error
func (*UmbrellaConnector) DeleteDestinations ¶
func (u *UmbrellaConnector) DeleteDestinations(destinationList DestinationList, destinationsToRemove []string, existingDestinations []Destination, chunkSize int) (DestinationList, error)
Removes destinations from a destination list
func (*UmbrellaConnector) GetDestinationList ¶
func (u *UmbrellaConnector) GetDestinationList(id int) (DestinationList, error)
Gets a single destination list
func (*UmbrellaConnector) GetDestinationLists ¶
func (u *UmbrellaConnector) GetDestinationLists(limit int) ([]DestinationList, error)
Gets all destination lists using pagination
func (*UmbrellaConnector) GetDestinations ¶
func (u *UmbrellaConnector) GetDestinations(id int, limit int) ([]Destination, error)
Gets all destinations from a destination list
func (*UmbrellaConnector) UpdateDestinationList ¶
func (u *UmbrellaConnector) UpdateDestinationList(id int, name string) (DestinationList, error)
Updates a destination lists name
func (*UmbrellaConnector) ValidateDestinationValues ¶
func (u *UmbrellaConnector) ValidateDestinationValues(destinations []string) ([]string, error)
type UmbrellaResponse ¶
type UmbrellaResponse struct { Status Status `json:"status"` Meta Meta `json:"meta"` Data *json.RawMessage `json:"data"` }
type UmbrellaResponseError ¶
Click to show internal directories.
Click to hide internal directories.