subscriptions

package
v2.108.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 12, 2026 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DeleteByID added in v2.107.0

func DeleteByID(client newclient.Client, spaceID string, id string) error

DeleteByID deletes the subscription that matches the input ID.

func Get added in v2.107.0

Get returns a collection of subscriptions based on the criteria defined by its input query parameter.

Types

type EventNotificationSubscription added in v2.107.0

type EventNotificationSubscription struct {
	EmailDigestLastProcessed            *time.Time                           `json:"EmailDigestLastProcessed,omitempty"`
	EmailDigestLastProcessedEventAutoId *int64                               `json:"EmailDigestLastProcessedEventAutoId,omitempty"`
	EmailFrequencyPeriod                string                               `json:"EmailFrequencyPeriod"`
	EmailPriority                       string                               `json:"EmailPriority"`
	EmailShowDatesInTimeZoneId          string                               `json:"EmailShowDatesInTimeZoneId"`
	EmailTeams                          []string                             `json:"EmailTeams"`
	Filter                              *EventNotificationSubscriptionFilter `json:"Filter"`
	WebhookHeaderKey                    string                               `json:"WebhookHeaderKey"`
	WebhookHeaderValue                  string                               `json:"WebhookHeaderValue"`
	WebhookLastProcessed                *time.Time                           `json:"WebhookLastProcessed,omitempty"`
	WebhookLastProcessedEventAutoId     *int64                               `json:"WebhookLastProcessedEventAutoId,omitempty"`
	WebhookTeams                        []string                             `json:"WebhookTeams"`
	WebhookTimeout                      string                               `json:"WebhookTimeout"`
	WebhookURI                          string                               `json:"WebhookURI"`
}

type EventNotificationSubscriptionFilter added in v2.107.0

type EventNotificationSubscriptionFilter struct {
	DocumentTypes   []string `json:"DocumentTypes"`
	EventAgents     []string `json:"EventAgents"`
	EventCategories []string `json:"EventCategories"`
	EventGroups     []string `json:"EventGroups"`
	Environments    []string `json:"Environments"`
	ProjectGroups   []string `json:"ProjectGroups"`
	Projects        []string `json:"Projects"`
	Tags            []string `json:"Tags"`
	Tenants         []string `json:"Tenants"`
	Users           []string `json:"Users"`
}

type Subscription added in v2.107.0

type Subscription struct {
	EventNotificationSubscription *EventNotificationSubscription `json:"EventNotificationSubscription"`
	IsDisabled                    bool                           `json:"IsDisabled"`
	Name                          string                         `json:"Name" validate:"required"`
	SpaceID                       string                         `json:"SpaceId,omitempty"`
	Type                          string                         `json:"Type,omitempty"`

	resources.Resource
}

func Add added in v2.107.0

func Add(client newclient.Client, spaceID string, subscription *Subscription) (*Subscription, error)

Add creates a new subscription.

func GetAll added in v2.107.0

func GetAll(client newclient.Client, spaceID string) ([]*Subscription, error)

GetAll returns all subscriptions for the given space.

func GetByID added in v2.107.0

func GetByID(client newclient.Client, spaceID string, id string) (*Subscription, error)

GetByID returns the subscription that matches the input ID.

func NewSubscription added in v2.107.0

func NewSubscription(name string) *Subscription

func Update added in v2.107.0

func Update(client newclient.Client, spaceID string, subscription *Subscription) (*Subscription, error)

Update modifies a subscription based on the one provided as input.

func (*Subscription) GetName added in v2.107.0

func (s *Subscription) GetName() string

func (*Subscription) SetName added in v2.107.0

func (s *Subscription) SetName(name string)

func (*Subscription) Validate added in v2.107.0

func (s *Subscription) Validate() error

type SubscriptionService

type SubscriptionService struct {
	services.CanDeleteService
}

func NewSubscriptionService

func NewSubscriptionService(sling *sling.Sling, uriTemplate string) *SubscriptionService

type SubscriptionsQuery

type SubscriptionsQuery struct {
	IDs         []string `uri:"ids,omitempty" url:"ids,omitempty"`
	PartialName string   `uri:"partialName,omitempty" url:"partialName,omitempty"`
	Skip        int      `uri:"skip,omitempty" url:"skip,omitempty"`
	Spaces      []string `uri:"spaces,omitempty" url:"spaces,omitempty"`
	Take        int      `uri:"take,omitempty" url:"take,omitempty"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL