//go:build !ignore_autogenerated

// Code generated by remove-junk-from-types-now-9000; DO NOT EDIT.
// Generator module: gitlab.com/gitlab-org/cluster-integration/remove-junk-from-types-now-9000
// Generator version: v0.0.0-20251110001802-ac4f0ee40261
// Configuration file: no_junk_config.json
// Source module: github.com/fluxcd/notification-controller/api
// Source module version: v1.6.0
// Source module query:
// Source module sum: h1:t0k662zxnUZlnDvFrk4DBDl6iivFmJxbwuRdyhH9Ot4=
// Source module package: v1

package v1

import (
	meta "github.com/fluxcd/pkg/apis/meta"
)

// CrossNamespaceObjectReference contains enough information to let you locate the
// typed referenced object at cluster level
type CrossNamespaceObjectReference struct {
	// API version of the referent
	// +optional
	APIVersion string `json:"apiVersion,omitempty"`
	// Kind of the referent
	// +kubebuilder:validation:Enum=Bucket;GitRepository;Kustomization;HelmRelease;HelmChart;HelmRepository;ImageRepository;ImagePolicy;ImageUpdateAutomation;OCIRepository
	// +required
	Kind string `json:"kind"`
	// Name of the referent
	// If multiple resources are targeted `*` may be set.
	// +kubebuilder:validation:MinLength=1
	// +kubebuilder:validation:MaxLength=253
	// +required
	Name string `json:"name"`
	// Namespace of the referent
	// +kubebuilder:validation:MinLength=1
	// +kubebuilder:validation:MaxLength=253
	// +kubebuilder:validation:Optional
	// +optional
	Namespace string `json:"namespace,omitempty"`
}

// Receiver is the Schema for the receivers API.
type Receiver struct {
	Spec ReceiverSpec `json:"spec,omitempty"`
}

// ReceiverSpec defines the desired state of the Receiver.
type ReceiverSpec struct {
	// A list of resources to be notified about changes.
	// +required
	Resources []CrossNamespaceObjectReference `json:"resources"`
	// SecretRef specifies the Secret containing the token used
	// to validate the payload authenticity.
	// +required
	SecretRef meta.LocalObjectReference `json:"secretRef"`
}
