entity

package
v1.23.0 Latest Latest
Warning

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

Go to latest
Published: Oct 3, 2025 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var AllActivityStatusValues = []string{
	ActivityStatusValuesOpen.String(),
	ActivityStatusValuesClosed.String(),
	ActivityStatusValuesInProgress.String(),
}
View Source
var AllIssueMatchChangeActions = []string{
	IssueMatchChangeActionAdd.String(),
	IssueMatchChangeActionRemove.String(),
}
View Source
var AllIssueTypes = []string{
	IssueTypeVulnerability.String(),
	IssueTypePolicyViolation.String(),
	IssueTypeSecurityEvent.String(),
}
View Source
var StateFilterTypeMap = map[StateFilterType]string{
	Active:  "active",
	Deleted: "deleted",
}

Functions

func GetUserTypeString

func GetUserTypeString(ut UserType) string

Types

type Activity

type Activity struct {
	Metadata
	Id        int64               `json:"id"`
	Status    ActivityStatusValue `json:"status"`
	Service   *Service            `json:"service,omitempty"`
	Issues    []Issue             `json:"issues,omitempty"`
	Evidences []Evidence          `json:"evidences,omitempty"`
}

func (*Activity) GetId

func (a *Activity) GetId() int64

type ActivityAggregations

type ActivityAggregations struct {
}

type ActivityFilter

type ActivityFilter struct {
	Paginated
	Status      []*string         `json:"status"`
	ServiceCCRN []*string         `json:"service_ccrn"`
	Id          []*int64          `json:"id"`
	ServiceId   []*int64          `json:"service_id"`
	IssueId     []*int64          `json:"issue_id"`
	EvidenceId  []*int64          `json:"evidence_id"`
	State       []StateFilterType `json:"state"`
}

type ActivityHasIssue

type ActivityHasIssue struct {
	Metadata
	ActivityId int64 `json:"activity_id"`
	IssueId    int64 `json:"issue_id"`
}

type ActivityResult

type ActivityResult struct {
	WithCursor
	*ActivityAggregations
	*Activity
}

type ActivityStatusValue

type ActivityStatusValue string
const (
	ActivityStatusValuesOpen       ActivityStatusValue = "open"
	ActivityStatusValuesClosed     ActivityStatusValue = "closed"
	ActivityStatusValuesInProgress ActivityStatusValue = "in_progress"
)

func NewActivityStatusValue

func NewActivityStatusValue(s string) ActivityStatusValue

func (ActivityStatusValue) String

func (e ActivityStatusValue) String() string

type BaseIssueRepository

type BaseIssueRepository struct {
	Metadata
	Id            int64          `json:"id"`
	Name          string         `json:"name"`
	Url           string         `json:"url"`
	IssueVariants []IssueVariant `json:"issue_variants,omitempty"`
	Services      []Service      `json:"services,omitempty"`
}

type BaseService

type BaseService struct {
	Metadata
	Id             int64         `json:"id"`
	CCRN           string        `json:"ccrn"`
	Domain         string        `json:"domain"`
	Region         string        `json:"region"`
	SupportGroup   *SupportGroup `json:"support_group,omitempty"`
	SupportGroupId int64         `db:"service_support_group_id"`
	Owners         []User        `json:"owners,omitempty"`
	Activities     []Activity    `json:"activities,omitempty"`
	Priority       int64         `json:"priority"`
}

type Component

type Component struct {
	Metadata
	Id   int64  `json:"id"`
	CCRN string `json:"ccrn"`
	Type string `json:"type"`
}

type ComponentAggregations

type ComponentAggregations struct {
}

type ComponentFilter

type ComponentFilter struct {
	PaginatedX
	CCRN               []*string         `json:"ccrn"`
	ServiceCCRN        []*string         `json:"service_ccrn"`
	Id                 []*int64          `json:"id"`
	ComponentVersionId []*int64          `json:"component_version_id"`
	State              []StateFilterType `json:"state"`
}

type ComponentInstance

type ComponentInstance struct {
	Metadata
	Id                 int64                 `json:"id"`
	CCRN               string                `json:"ccrn"`
	Region             string                `json:"region"`
	Cluster            string                `json:"cluster"`
	Namespace          string                `json:"namespace"`
	Domain             string                `json:"domain"`
	Project            string                `json:"project"`
	Pod                string                `json:"pod"`
	Container          string                `json:"container"`
	Type               ComponentInstanceType `json:"type"`
	ParentId           int64                 `json:"parent_id,omitempty"`
	Context            *Json                 `json:"context"`
	Count              int16                 `json:"count"`
	ComponentVersion   *ComponentVersion     `json:"component_version,omitempty"`
	ComponentVersionId int64                 `db:"componentinstance_component_version_id"`
	Service            *Service              `json:"service,omitempty"`
	ServiceId          int64                 `db:"componentinstance_service_id"`
}

type ComponentInstanceAggregations

type ComponentInstanceAggregations struct {
}

type ComponentInstanceFilter

type ComponentInstanceFilter struct {
	PaginatedX
	IssueMatchId            []*int64          `json:"issue_match_id"`
	ServiceId               []*int64          `json:"service_id"`
	ServiceCcrn             []*string         `json:"service_ccrn"`
	ComponentVersionId      []*int64          `json:"component_version_id"`
	ComponentVersionVersion []*string         `json:"component_version_version"`
	Id                      []*int64          `json:"id"`
	CCRN                    []*string         `json:"ccrn"`
	Region                  []*string         `json:"region"`
	Cluster                 []*string         `json:"cluster"`
	Namespace               []*string         `json:"namespace"`
	Domain                  []*string         `json:"domain"`
	Project                 []*string         `json:"project"`
	Pod                     []*string         `json:"pod"`
	Container               []*string         `json:"container"`
	Type                    []*string         `json:"type"`
	ParentId                []*int64          `json:"parent_id"`
	Context                 []*Json           `json:"context"`
	Search                  []*string         `json:"search"`
	State                   []StateFilterType `json:"state"`
}

type ComponentInstanceType

type ComponentInstanceType string
const (
	ComponentInstanceTypeUnknown              ComponentInstanceType = "Unknown"
	ComponentInstanceTypeProject              ComponentInstanceType = "Project"
	ComponentInstanceTypeServer               ComponentInstanceType = "Server"
	ComponentInstanceTypeSecurityGroup        ComponentInstanceType = "SecurityGroup"
	ComponentInstanceTypeSecurityGroupRule    ComponentInstanceType = "SecurityGroupRule"
	ComponentInstanceTypeDnsZone              ComponentInstanceType = "DnsZone"
	ComponentInstanceTypeFloatingIp           ComponentInstanceType = "FloatingIp"
	ComponentInstanceTypeRbacPolicy           ComponentInstanceType = "RbacPolicy"
	ComponentInstanceTypeUser                 ComponentInstanceType = "User"
	ComponentInstanceTypeContainer            ComponentInstanceType = "Container"
	ComponentInstanceTypeRecordSet            ComponentInstanceType = "RecordSet"
	ComponentInstanceTypeProjectConfiguration ComponentInstanceType = "ProjectConfiguration"
)

func NewComponentInstanceType

func NewComponentInstanceType(s string) ComponentInstanceType

func (ComponentInstanceType) Index

func (e ComponentInstanceType) Index() int

func (ComponentInstanceType) String

func (e ComponentInstanceType) String() string

type ComponentResult

type ComponentResult struct {
	WithCursor
	*ComponentAggregations
	*Component
}

type ComponentVersion

type ComponentVersion struct {
	Metadata
	Id                 int64               `json:"id"`
	Version            string              `json:"version"`
	Component          *Component          `json:"component,omitempty"`
	ComponentId        int64               `db:"componentversion_component_id"`
	Tag                string              `json:"tag"`
	Repository         string              `json:"repository"`
	Organization       string              `json:"organization"`
	ComponentInstances []ComponentInstance `json:"component_instances,omitempty"`
	Issues             []Issue             `json:"issues,omitempty"`
}

type ComponentVersionAggregations

type ComponentVersionAggregations struct {
}

type ComponentVersionFilter

type ComponentVersionFilter struct {
	PaginatedX
	Id            []*int64  `json:"id"`
	IssueId       []*int64  `json:"issue_id"`
	ComponentCCRN []*string `json:"component_ccrn"`
	ComponentId   []*int64  `json:"component_id"`
	// Used for ordering by severity/rating
	IssueRepositoryId []*int64          `json:"issue_repository_id"`
	Version           []*string         `json:"version"`
	ServiceId         []*int64          `json:"service_id"`
	ServiceCCRN       []*string         `json:"service_ccrn"`
	State             []StateFilterType `json:"state"`
	Tag               []*string         `json:"tag"`
	Repository        []*string         `json:"repository"`
	Organization      []*string         `json:"organization"`
}

type ComponentVersionResult

type ComponentVersionResult struct {
	WithCursor
	*ComponentVersion
	*ComponentVersionAggregations
}

type Cursor

type Cursor struct {
	Statement string
	Value     int64
	Limit     int
}

type Cvss

type Cvss struct {
	Vector        string
	ExternalUrl   string
	Base          *metric.Base
	Temporal      *metric.Temporal
	Environmental *metric.Environmental
}

type Evidence

type Evidence struct {
	Metadata
	Id          int64        `json:"id"`
	Description string       `json:"description"`
	Type        EvidenceType `json:"type"`
	RaaEnd      time.Time    `json:"raa_end"`
	Severity    Severity     `json:"severity"`
	User        *User        `json:"user,omitempty"`
	UserId      int64        `db:"evidence_author_id"`
	Activity    *Activity    `json:"activity,omitempty"`
	ActivityId  int64        `db:"evidence_activity_id"`
}

type EvidenceAggregations

type EvidenceAggregations struct {
}

type EvidenceFilter

type EvidenceFilter struct {
	Paginated
	Id           []*int64          `json:"id"`
	ActivityId   []*int64          `json:"activity_id"`
	IssueMatchId []*int64          `json:"issue_match_id"`
	UserId       []*int64          `json:"user_id"`
	State        []StateFilterType `json:"state"`
}

type EvidenceResult

type EvidenceResult struct {
	WithCursor
	*Evidence
	*EvidenceAggregations
}

type EvidenceType

type EvidenceType string
const (
	EvidenceTypeValuesRiskAccepted       EvidenceType = "risk_accepted"
	EvidenceTypeValuesMitigated          EvidenceType = "mitigated"
	EvidenceTypeValuesSeverityAdjustment EvidenceType = "severity_adjustment"
	EvidenceTypeValuesFalsePositive      EvidenceType = "false_positive"
	EvidenceTypeValuesReOpen             EvidenceType = "reopen"
)

func NewEvidenceTypeValue

func NewEvidenceTypeValue(s string) EvidenceType

func (EvidenceType) String

func (e EvidenceType) String() string

type HasCursor

type HasCursor interface {
	Cursor() *string
}

type Issue

type Issue struct {
	Metadata
	Id                int64              `json:"id"`
	Type              IssueType          `json:"type"`
	PrimaryName       string             `json:"primary_name"`
	Description       string             `json:"description"`
	IssueVariants     []IssueVariant     `json:"issue_variants,omitempty"`
	IssueMatches      []IssueMatch       `json:"issue_matches,omitempty"`
	ComponentVersions []ComponentVersion `json:"component_versions,omitempty"`
	Activity          []Activity         `json:"activity,omitempty"`
}

type IssueAggregations

type IssueAggregations struct {
	Activities                    int64
	IssueMatches                  int64
	AffectedServices              int64
	AffectedComponentInstances    int64
	ComponentVersions             int64
	EarliestTargetRemediationDate time.Time
	EarliestDiscoveryDate         time.Time
}

type IssueCount

type IssueCount struct {
	Count int64  `json:"issue_count"`
	Value string `json:"issue_value"`
}

type IssueFilter

type IssueFilter struct {
	PaginatedX
	PrimaryName                     []*string         `json:"primary_name"`
	ServiceCCRN                     []*string         `json:"service_ccrn"`
	AllServices                     bool              `json:"all_services"`
	HasIssueMatches                 bool              `json:"has_issue_matches"`
	SupportGroupCCRN                []*string         `json:"support_group_ccrn"`
	Type                            []*string         `json:"type"`
	Id                              []*int64          `json:"id"`
	ActivityId                      []*int64          `json:"activity_id"`
	IssueMatchId                    []*int64          `json:"issue_match_id"`
	ComponentId                     []*int64          `json:"component_id"`
	ComponentVersionId              []*int64          `json:"component_version_id"`
	IssueVariantId                  []*int64          `json:"issue_variant_id"`
	IssueRepositoryId               []*int64          `json:"issue_repository_id"`
	ServiceId                       []*int64          `json:"service_id"`
	Search                          []*string         `json:"search"`
	IssueMatchStatus                []*string         `json:"issue_match_status"`
	IssueMatchSeverity              []*string         `json:"issue_match_severity"`
	IssueMatchDiscoveryDate         *TimeFilter       `json:"issue_match_discovery_date"`
	IssueMatchTargetRemediationDate *TimeFilter       `json:"issue_match_target_remediation_date"`
	Unique                          bool              `json:"unique"`
	State                           []StateFilterType `json:"state"`
}

type IssueList

type IssueList struct {
	*List[IssueResult]
	VulnerabilityCount   *int64
	PolicyViolationCount *int64
	SecurityEventCount   *int64
}

type IssueListOptions

type IssueListOptions struct {
	ListOptions
	ShowIssueTypeCounts bool
}

type IssueMatch

type IssueMatch struct {
	Metadata
	Id                    int64                 `json:"id"`
	Status                IssueMatchStatusValue `json:"status"`
	User                  *User                 `json:"user,omitempty"`
	UserId                int64                 `json:"user_id"`
	Severity              Severity              `json:"severity,omitempty"`
	Evidences             []Evidence            `json:"evidence,omitempty"`
	ComponentInstance     *ComponentInstance    `json:"component_instance,omitempty"`
	ComponentInstanceId   int64                 `json:"component_instance_id"`
	Issue                 *Issue                `json:"issue,omitempty"`
	IssueId               int64                 `json:"issue_id"`
	RemediationDate       time.Time             `json:"remediation_date"`
	TargetRemediationDate time.Time             `json:"target_remediation_date"`
}

type IssueMatchChange

type IssueMatchChange struct {
	Metadata
	Id           int64 `json:"id"`
	ActivityId   int64 `json:"activity_id"`
	Activity     *Activity
	IssueMatchId int64 `json:"issue_match_id"`
	IssueMatch   *IssueMatch
	Action       string `json:"action"`
}

type IssueMatchChangeAction

type IssueMatchChangeAction string
const (
	IssueMatchChangeActionAdd    IssueMatchChangeAction = "add"
	IssueMatchChangeActionRemove IssueMatchChangeAction = "remove"
)

func NewIssueMatchChangeAction

func NewIssueMatchChangeAction(s string) IssueMatchChangeAction

func (IssueMatchChangeAction) String

func (e IssueMatchChangeAction) String() string

type IssueMatchChangeFilter

type IssueMatchChangeFilter struct {
	Paginated
	Id           []*int64          `json:"id"`
	ActivityId   []*int64          `json:"activity_id"`
	IssueMatchId []*int64          `json:"issue_match_id"`
	Action       []*string         `json:"action"`
	State        []StateFilterType `json:"state"`
}

type IssueMatchChangeResult

type IssueMatchChangeResult struct {
	WithCursor
	*IssueMatchChange
}

type IssueMatchFilter

type IssueMatchFilter struct {
	PaginatedX
	Id                       []*int64          `json:"id"`
	ServiceCCRN              []*string         `json:"service_ccrn"`
	SeverityValue            []*string         `json:"severity_value"`
	Status                   []*string         `json:"status"`
	IssueId                  []*int64          `json:"issue_id"`
	EvidenceId               []*int64          `json:"evidence_id"`
	ComponentInstanceId      []*int64          `json:"component_instance_id"`
	ServiceId                []*int64          `json:"service_id"`
	SupportGroupCCRN         []*string         `json:"support_group_ccrn"`
	Search                   []*string         `json:"search"`
	ComponentCCRN            []*string         `json:"component_ccrn"`
	PrimaryName              []*string         `json:"primary_name"`
	IssueType                []*string         `json:"issue_type"`
	State                    []StateFilterType `json:"state"`
	ServiceOwnerUsername     []*string         `json:"service_owner_username"`
	ServiceOwnerUniqueUserId []*string         `json:"service_owner_unique_user_id"`
}

type IssueMatchResult

type IssueMatchResult struct {
	WithCursor
	*IssueMatch
}

type IssueMatchStatusValue

type IssueMatchStatusValue string
const (
	IssueMatchStatusValuesNew           IssueMatchStatusValue = "new"
	IssueMatchStatusValuesRiskAccepted  IssueMatchStatusValue = "risk_accepted"
	IssueMatchStatusValuesFalsePositive IssueMatchStatusValue = "false_positive"
	IssueMatchStatusValuesMitigated     IssueMatchStatusValue = "mitigated"
	IssueMatchStatusValuesNone          IssueMatchStatusValue = "none"
)

func NewIssueMatchStatusValue

func NewIssueMatchStatusValue(s string) IssueMatchStatusValue

func (IssueMatchStatusValue) String

func (e IssueMatchStatusValue) String() string

type IssueRepository

type IssueRepository struct {
	BaseIssueRepository
	IssueRepositoryService
}

type IssueRepositoryAggregations

type IssueRepositoryAggregations struct {
}

type IssueRepositoryFilter

type IssueRepositoryFilter struct {
	Paginated
	Id          []*int64          `json:"id"`
	ServiceId   []*int64          `json:"service_id"`
	Name        []*string         `json:"name"`
	ServiceCCRN []*string         `json:"service_ccrn"`
	State       []StateFilterType `json:"state"`
}

func NewIssueRepositoryFilter

func NewIssueRepositoryFilter() *IssueRepositoryFilter

type IssueRepositoryResult

type IssueRepositoryResult struct {
	WithCursor
	*IssueRepositoryAggregations
	*IssueRepository
}

type IssueRepositoryService

type IssueRepositoryService struct {
	Metadata
	ServiceId         int64 `json:"service_id"`
	IssueRepositoryId int64 `json:"issue_repository_id"`
	Priority          int64 `json:"priority"`
}

type IssueResult

type IssueResult struct {
	WithCursor
	*IssueAggregations `json:"issue_aggregations"`
	*Issue             `json:"issue"`
	*IssueVariant      `json:"issue_variant"`
}

type IssueSeverityCounts

type IssueSeverityCounts struct {
	Critical int64 `json:"critical"`
	High     int64 `json:"high"`
	Medium   int64 `json:"medium"`
	Low      int64 `json:"low"`
	None     int64 `json:"none"`
	Total    int64 `json:"total"`
}

type IssueType

type IssueType string
const (
	IssueTypeVulnerability   IssueType = "Vulnerability"
	IssueTypePolicyViolation IssueType = "PolicyViolation"
	IssueTypeSecurityEvent   IssueType = "SecurityEvent"
)

func NewIssueType

func NewIssueType(s string) IssueType

func (IssueType) String

func (e IssueType) String() string

type IssueTypeCounts

type IssueTypeCounts struct {
	VulnerabilityCount   int64 `json:"vulnerability_count"`
	PolicyViolationCount int64 `json:"policy_violation_count"`
	SecurityEventCount   int64 `json:"security_event_count"`
}

func (*IssueTypeCounts) TotalIssueCount

func (itc *IssueTypeCounts) TotalIssueCount() int64

type IssueVariant

type IssueVariant struct {
	Metadata
	Id                int64            `json:"id"`
	IssueRepositoryId int64            `json:"issue_repository_id"`
	IssueRepository   *IssueRepository `json:"issue_repository"`
	SecondaryName     string           `json:"secondary_name"`
	IssueId           int64            `json:"issue_id"`
	Issue             *Issue           `json:"issue"`
	Severity          Severity         `json:"severity"`
	Description       string           `json:"description"`
	ExternalUrl       string           `json:"external_url"`
}

type IssueVariantAggregations

type IssueVariantAggregations struct {
}

type IssueVariantFilter

type IssueVariantFilter struct {
	Paginated
	Id                []*int64          `json:"id"`
	SecondaryName     []*string         `json:"secondary_name"`
	IssueId           []*int64          `json:"issue_id"`
	IssueRepositoryId []*int64          `json:"issue_repository_id"`
	ServiceId         []*int64          `json:"service_id"`
	IssueMatchId      []*int64          `json:"issue_match_id"`
	State             []StateFilterType `json:"state"`
}

func NewIssueVariantFilter

func NewIssueVariantFilter() *IssueVariantFilter

type IssueVariantResult

type IssueVariantResult struct {
	WithCursor
	*IssueVariantAggregations
	*IssueVariant
}

type IssueWithAggregations

type IssueWithAggregations struct {
	IssueAggregations
	Issue
}

type Json

type Json map[string]interface{}

func (Json) String

func (e Json) String() string

type List

type List[T interface{}] struct {
	TotalCount *int64
	PageInfo   *PageInfo
	Elements   []T
}

type ListOptions

type ListOptions struct {
	ShowTotalCount      bool `json:"show_total_count"`
	ShowPageInfo        bool `json:"show_page_info"`
	IncludeAggregations bool `json:"include_aggregations"`
	Order               []Order
}

func NewListOptions

func NewListOptions() *ListOptions

type Metadata

type Metadata struct {
	CreatedAt time.Time `json:"created_at"`
	CreatedBy int64     `json:"created_by"`
	UpdatedAt time.Time `json:"updated_at"`
	UpdatedBy int64     `json:"updated_by"`
	DeletedAt time.Time `json:"deleted_at,omitempty"`
}

type Order

type Order struct {
	By        OrderByField
	Direction OrderDirection
}

type OrderByField

type OrderByField int
const (
	ComponentInstanceCcrn OrderByField = iota
	ComponentInstanceId
	ComponentInstanceRegion
	ComponentInstanceCluster
	ComponentInstanceNamespace
	ComponentInstanceDomain
	ComponentInstanceProject
	ComponentInstancePod
	ComponentInstanceContainer
	ComponentInstanceTypeOrder

	ComponentVersionId
	ComponentVersionRepository

	ComponentId
	ComponentCcrn

	IssueId
	IssuePrimaryName

	IssueVariantRating

	IssueMatchId
	IssueMatchRating
	IssueMatchTargetRemediationDate

	CriticalCount
	HighCount
	MediumCount
	LowCount
	NoneCount

	SupportGroupId
	SupportGroupCcrn

	ServiceId
	ServiceCcrn
)

type OrderDirection

type OrderDirection int
const (
	OrderDirectionAsc OrderDirection = iota
	OrderDirectionDesc
)

type Page

type Page struct {
	After      *string `json:"after,omitempty"`
	PageNumber *int    `json:"page_number,omitempty"`
	IsCurrent  bool    `json:"is_current,omitempty"`
	PageCount  *int    `json:"page_count,omitempty"`
}

type PageInfo

type PageInfo struct {
	HasNextPage     *bool   `json:"has_next_page,omitempty"`
	HasPreviousPage *bool   `json:"has_previous_page,omitempty"`
	IsValidPage     *bool   `json:"is_valid_page,omitempty"`
	PageNumber      *int    `json:"page_number,omitempty"`
	NextPageAfter   *string `json:"next_page_after,omitempty"`
	StartCursor     *string `json:"deprecated,omitempty"` //@todo remove as deprecated
	EndCursor       *string `json:"end_cursor,omitempty"` //@todo remove as deprecated
	Pages           []Page  `json:"pages,omitempty"`
}

type Paginated

type Paginated struct {
	First *int   `json:"first"`
	After *int64 `json:"from"`
}

func MaxPaginated

func MaxPaginated() Paginated

type PaginatedX

type PaginatedX struct {
	First *int    `json:"first"`
	After *string `json:"from"`
}

type ResultList

type ResultList struct {
	TotalCount *int64
	PageInfo   *PageInfo
}

type ScannerRun

type ScannerRun struct {
	RunID     int64     `json:"run_id"`
	UUID      string    `json:"uuid"`
	Tag       string    `json:"tag"`
	StartRun  time.Time `json:"start_run"`
	EndRun    time.Time `json:"end_run"`
	Completed bool      `json:"is_completed"`
}

func (ScannerRun) IsCompleted

func (sc ScannerRun) IsCompleted() bool

type ScannerRunFilter

type ScannerRunFilter struct {
	Paginated

	Tag       []string `json:"tag"`
	Completed bool     `json:"is_completed"`
}

func (ScannerRunFilter) HasArgs

func (srf ScannerRunFilter) HasArgs() bool

type Service

type Service struct {
	BaseService
	IssueRepositoryService
}

type ServiceAggregations

type ServiceAggregations struct {
	ComponentInstances int64
	IssueMatches       int64
}

type ServiceFilter

type ServiceFilter struct {
	PaginatedX
	SupportGroupCCRN    []*string         `json:"support_group_ccrn"`
	Id                  []*int64          `json:"id"`
	CCRN                []*string         `json:"ccrn"`
	Domain              []*string         `json:"domian"`
	Region              []*string         `json:"region"`
	OwnerName           []*string         `json:"owner_name"`
	OwnerId             []*int64          `json:"owner_id"`
	IssueId             []*int64          `json:"issue_id"`
	ActivityId          []*int64          `json:"activity_id"`
	ComponentInstanceId []*int64          `json:"component_instance_id"`
	IssueRepositoryId   []*int64          `json:"issue_repository_id"`
	SupportGroupId      []*int64          `json:"support_group_id"`
	Search              []*string         `json:"search"`
	State               []StateFilterType `json:"state"`
}

type ServiceIssueVariant

type ServiceIssueVariant struct {
	IssueVariant
	ServiceId int64 `json:"service_id"`
	Priority  int64 `json:"priority"`
}

type ServiceIssueVariantFilter

type ServiceIssueVariantFilter struct {
	Paginated
	ComponentInstanceId []*int64          `json:"component_instance_id"`
	IssueId             []*int64          `json:"issue_id"`
	State               []StateFilterType `json:"state"`
}

func NewServiceIssueVariantFilter

func NewServiceIssueVariantFilter() *ServiceIssueVariantFilter

type ServiceResult

type ServiceResult struct {
	WithCursor
	*ServiceAggregations
	*Service
}

type ServiceWithAggregations

type ServiceWithAggregations struct {
	Service
	ServiceAggregations
}

type Severity

type Severity struct {
	Value string
	Score float64
	Cvss  Cvss
}

func NewSeverity

func NewSeverity(url string) Severity

func NewSeverityFromRating

func NewSeverityFromRating(rating SeverityValues) Severity

type SeverityFilter

type SeverityFilter struct {
	IssueMatchId []*int64 `json:"issue_match_id"`
	IssueId      []*int64 `json:"issue_id"`
}

type SeverityValues

type SeverityValues string
const (
	SeverityValuesNone     SeverityValues = "None"
	SeverityValuesLow      SeverityValues = "Low"
	SeverityValuesMedium   SeverityValues = "Medium"
	SeverityValuesHigh     SeverityValues = "High"
	SeverityValuesCritical SeverityValues = "Critical"
)

func (SeverityValues) String

func (s SeverityValues) String() string

type StateFilterType

type StateFilterType int
const (
	Active StateFilterType = iota
	Deleted
)

func (StateFilterType) String

func (sft StateFilterType) String() string

type SupportGroup

type SupportGroup struct {
	Metadata
	Id   int64  `json:"id"`
	CCRN string `json:"ccrn"`
}

type SupportGroupAggregations

type SupportGroupAggregations struct {
}

type SupportGroupFilter

type SupportGroupFilter struct {
	PaginatedX
	Id        []*int64          `json:"id"`
	ServiceId []*int64          `json:"service_id"`
	UserId    []*int64          `json:"user_id"`
	IssueId   []*int64          `json:"issue_id"`
	CCRN      []*string         `json:"ccrn"`
	State     []StateFilterType `json:"state"`
}

type SupportGroupResult

type SupportGroupResult struct {
	WithCursor
	*SupportGroupAggregations
	*SupportGroup
}

type SupportGroupService

type SupportGroupService struct {
	Metadata
	SupportGroupId int64 `json:"support_group_id"`
	ServiceId      int64 `json:"service_id"`
}

type SupportGroupUser

type SupportGroupUser struct {
	Metadata
	SupportGroupId int64 `json:"support_group_id"`
	UserId         int64 `json:"user_id"`
}

type TimeFilter

type TimeFilter struct {
	After  time.Time `json:"after"`
	Before time.Time `json:"before"`
}

type User

type User struct {
	Metadata
	Id           int64    `json:"id"`
	Name         string   `json:"name"`
	UniqueUserID string   `json:"uniqueUserId"`
	Type         UserType `json:"type"`
	Email        string   `json:"email"`
}

type UserAggregations

type UserAggregations struct {
}

type UserFilter

type UserFilter struct {
	Paginated
	Name           []*string         `json:"name"`
	UniqueUserID   []*string         `json:"uniqueUserId"`
	Type           []UserType        `json:"type"`
	Id             []*int64          `json:"id"`
	SupportGroupId []*int64          `json:"support_group_id"`
	ServiceId      []*int64          `json:"service_id"`
	State          []StateFilterType `json:"state"`
	Email          []*string         `json:"email"`
}

type UserResult

type UserResult struct {
	WithCursor
	*UserAggregations
	*User
}

type UserType

type UserType int
const (
	InvalidUserType     UserType = 0
	HumanUserType       UserType = 1
	TechnicalUserType   UserType = 2
	MailingListUserType UserType = 3
)

func GetUserTypeFromString

func GetUserTypeFromString(uts string) UserType

type WithCursor

type WithCursor struct {
	Value string
}

func (WithCursor) Cursor

func (c WithCursor) Cursor() *string

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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