// Package kodit provides primitives to interact with the openapi HTTP API.
//
// Code generated by github.com/oapi-codegen/oapi-codegen/v2 version v2.5.1 DO NOT EDIT.
package kodit

import (
	"encoding/json"
	"time"

	"github.com/oapi-codegen/runtime"
)

const (
	Header__X_API_KEY_Scopes = "Header__X_API_KEY_.Scopes"
)

// Defines values for TaskOperation.
const (
	KoditCommit                               TaskOperation = "kodit.commit"
	KoditCommitCreateArchitectureEnrichment   TaskOperation = "kodit.commit.create_architecture_enrichment"
	KoditCommitCreateBm25Index                TaskOperation = "kodit.commit.create_bm25_index"
	KoditCommitCreateCodeEmbeddings           TaskOperation = "kodit.commit.create_code_embeddings"
	KoditCommitCreateCommitDescription        TaskOperation = "kodit.commit.create_commit_description"
	KoditCommitCreateCookbook                 TaskOperation = "kodit.commit.create_cookbook"
	KoditCommitCreateDatabaseSchema           TaskOperation = "kodit.commit.create_database_schema"
	KoditCommitCreateExampleCodeEmbeddings    TaskOperation = "kodit.commit.create_example_code_embeddings"
	KoditCommitCreateExampleSummary           TaskOperation = "kodit.commit.create_example_summary"
	KoditCommitCreateExampleSummaryEmbeddings TaskOperation = "kodit.commit.create_example_summary_embeddings"
	KoditCommitCreatePublicApiDocs            TaskOperation = "kodit.commit.create_public_api_docs"
	KoditCommitCreateSummaryEmbeddings        TaskOperation = "kodit.commit.create_summary_embeddings"
	KoditCommitCreateSummaryEnrichment        TaskOperation = "kodit.commit.create_summary_enrichment"
	KoditCommitExtractExamples                TaskOperation = "kodit.commit.extract_examples"
	KoditCommitExtractSnippets                TaskOperation = "kodit.commit.extract_snippets"
	KoditCommitRescan                         TaskOperation = "kodit.commit.rescan"
	KoditCommitScan                           TaskOperation = "kodit.commit.scan"
	KoditIndexCreate                          TaskOperation = "kodit.index.create"
	KoditIndexRun                             TaskOperation = "kodit.index.run"
	KoditIndexRunClearFileProcessingStatuses  TaskOperation = "kodit.index.run.clear_file_processing_statuses"
	KoditIndexRunCreateBm25Index              TaskOperation = "kodit.index.run.create_bm25_index"
	KoditIndexRunCreateCodeEmbeddings         TaskOperation = "kodit.index.run.create_code_embeddings"
	KoditIndexRunCreateTextEmbeddings         TaskOperation = "kodit.index.run.create_text_embeddings"
	KoditIndexRunDeleteOldSnippets            TaskOperation = "kodit.index.run.delete_old_snippets"
	KoditIndexRunEnrichSnippets               TaskOperation = "kodit.index.run.enrich_snippets"
	KoditIndexRunExtractSnippets              TaskOperation = "kodit.index.run.extract_snippets"
	KoditIndexRunRefreshWorkingCopy           TaskOperation = "kodit.index.run.refresh_working_copy"
	KoditIndexRunUpdateIndexTimestamp         TaskOperation = "kodit.index.run.update_index_timestamp"
	KoditRepository                           TaskOperation = "kodit.repository"
	KoditRepositoryClone                      TaskOperation = "kodit.repository.clone"
	KoditRepositoryCreate                     TaskOperation = "kodit.repository.create"
	KoditRepositoryDelete                     TaskOperation = "kodit.repository.delete"
	KoditRepositorySync                       TaskOperation = "kodit.repository.sync"
	KoditRoot                                 TaskOperation = "kodit.root"
)

// Defines values for TrackingMode.
const (
	Branch TrackingMode = "branch"
	Tag    TrackingMode = "tag"
)

// CommitAttributes Commit attributes following JSON-API spec.
type CommitAttributes struct {
	Author          string    `json:"author"`
	CommitSha       string    `json:"commit_sha"`
	Date            time.Time `json:"date"`
	Message         string    `json:"message"`
	ParentCommitSha string    `json:"parent_commit_sha"`
}

// CommitData Commit data following JSON-API spec.
type CommitData struct {
	// Attributes Commit attributes following JSON-API spec.
	Attributes CommitAttributes `json:"attributes"`
	Id         string           `json:"id"`
	Type       *string          `json:"type,omitempty"`
}

// CommitListResponse Commit list response following JSON-API spec.
type CommitListResponse struct {
	Data []CommitData `json:"data"`
}

// CommitResponse Single commit response following JSON-API spec.
type CommitResponse struct {
	// Data Commit data following JSON-API spec.
	Data CommitData `json:"data"`
}

// EmbeddingAttributes Embedding attributes following JSON-API spec.
type EmbeddingAttributes struct {
	Embedding     []float32 `json:"embedding"`
	EmbeddingType string    `json:"embedding_type"`
	SnippetSha    string    `json:"snippet_sha"`
}

// EmbeddingData Embedding data following JSON-API spec.
type EmbeddingData struct {
	// Attributes Embedding attributes following JSON-API spec.
	Attributes EmbeddingAttributes `json:"attributes"`
	Id         string              `json:"id"`
	Type       *string             `json:"type,omitempty"`
}

// EmbeddingListResponse Embedding list response following JSON-API spec.
type EmbeddingListResponse struct {
	Data []EmbeddingData `json:"data"`
}

// EnrichmentAssociationData Enrichment association data for JSON-API spec.
type EnrichmentAssociationData struct {
	Id   string `json:"id"`
	Type string `json:"type"`
}

// EnrichmentAttributes Enrichment attributes following JSON-API spec.
type EnrichmentAttributes struct {
	Content   string                          `json:"content"`
	CreatedAt *EnrichmentAttributes_CreatedAt `json:"created_at"`
	Subtype   *EnrichmentAttributes_Subtype   `json:"subtype"`
	Type      string                          `json:"type"`
	UpdatedAt *EnrichmentAttributes_UpdatedAt `json:"updated_at"`
}

// EnrichmentAttributesCreatedAt0 defines model for .
type EnrichmentAttributesCreatedAt0 = time.Time

// EnrichmentAttributes_CreatedAt defines model for EnrichmentAttributes.CreatedAt.
type EnrichmentAttributes_CreatedAt struct {
	union json.RawMessage
}

// EnrichmentAttributesSubtype0 defines model for .
type EnrichmentAttributesSubtype0 = string

// EnrichmentAttributes_Subtype defines model for EnrichmentAttributes.Subtype.
type EnrichmentAttributes_Subtype struct {
	union json.RawMessage
}

// EnrichmentAttributesUpdatedAt0 defines model for .
type EnrichmentAttributesUpdatedAt0 = time.Time

// EnrichmentAttributes_UpdatedAt defines model for EnrichmentAttributes.UpdatedAt.
type EnrichmentAttributes_UpdatedAt struct {
	union json.RawMessage
}

// EnrichmentData Enrichment data following JSON-API spec.
type EnrichmentData struct {
	// Attributes Enrichment attributes following JSON-API spec.
	Attributes    EnrichmentAttributes          `json:"attributes"`
	Id            string                        `json:"id"`
	Links         *EnrichmentData_Links         `json:"links"`
	Relationships *EnrichmentData_Relationships `json:"relationships"`
	Type          *string                       `json:"type,omitempty"`
}

// EnrichmentData_Links defines model for EnrichmentData.Links.
type EnrichmentData_Links struct {
	union json.RawMessage
}

// EnrichmentData_Relationships defines model for EnrichmentData.Relationships.
type EnrichmentData_Relationships struct {
	union json.RawMessage
}

// EnrichmentLinks Links following JSON-API spec.
type EnrichmentLinks struct {
	Self string `json:"self"`
}

// EnrichmentListResponse Enrichment list response following JSON-API spec.
type EnrichmentListResponse struct {
	Data []EnrichmentData `json:"data"`
}

// EnrichmentRelationships Enrichment relationships for JSON-API spec.
type EnrichmentRelationships struct {
	Associations *EnrichmentRelationships_Associations `json:"associations"`
	Commit       *EnrichmentRelationships_Commit       `json:"commit"`
}

// EnrichmentRelationshipsAssociations0 defines model for .
type EnrichmentRelationshipsAssociations0 = []EnrichmentAssociationData

// EnrichmentRelationships_Associations defines model for EnrichmentRelationships.Associations.
type EnrichmentRelationships_Associations struct {
	union json.RawMessage
}

// EnrichmentRelationships_Commit defines model for EnrichmentRelationships.Commit.
type EnrichmentRelationships_Commit struct {
	union json.RawMessage
}

// EnrichmentResponse Single enrichment response following JSON-API spec.
type EnrichmentResponse struct {
	// Data Enrichment data following JSON-API spec.
	Data EnrichmentData `json:"data"`
}

// EnrichmentSchema Enrichment schema following JSON-API spec.
type EnrichmentSchema struct {
	Content string `json:"content"`
	Type    string `json:"type"`
}

// EnrichmentUpdateAttributes Attributes for updating an enrichment.
type EnrichmentUpdateAttributes struct {
	Content string `json:"content"`
}

// EnrichmentUpdateData Data for updating an enrichment.
type EnrichmentUpdateData struct {
	// Attributes Attributes for updating an enrichment.
	Attributes EnrichmentUpdateAttributes `json:"attributes"`
	Type       *string                    `json:"type,omitempty"`
}

// EnrichmentUpdateRequest Request to update an enrichment.
type EnrichmentUpdateRequest struct {
	// Data Data for updating an enrichment.
	Data EnrichmentUpdateData `json:"data"`
}

// FileAttributes File attributes following JSON-API spec.
type FileAttributes struct {
	BlobSha   string `json:"blob_sha"`
	Extension string `json:"extension"`
	MimeType  string `json:"mime_type"`
	Path      string `json:"path"`
	Size      int    `json:"size"`
}

// FileData File data following JSON-API spec.
type FileData struct {
	// Attributes File attributes following JSON-API spec.
	Attributes FileAttributes `json:"attributes"`
	Id         string         `json:"id"`
	Type       *string        `json:"type,omitempty"`
}

// FileListResponse File list response following JSON-API spec.
type FileListResponse struct {
	Data []FileData `json:"data"`
}

// FileResponse Single file response following JSON-API spec.
type FileResponse struct {
	// Data File data following JSON-API spec.
	Data FileData `json:"data"`
}

// GitFileSchema Git file schema following JSON-API spec.
type GitFileSchema struct {
	BlobSha  string `json:"blob_sha"`
	MimeType string `json:"mime_type"`
	Path     string `json:"path"`
	Size     int    `json:"size"`
}

// HTTPValidationError defines model for HTTPValidationError.
type HTTPValidationError struct {
	Detail *[]ValidationError `json:"detail,omitempty"`
}

// Relationship A JSON:API relationship.
type Relationship struct {
	Data  *Relationship_Data  `json:"data"`
	Links *Relationship_Links `json:"links"`
}

// RelationshipData1 defines model for .
type RelationshipData1 = []RelationshipData

// Relationship_Data defines model for Relationship.Data.
type Relationship_Data struct {
	union json.RawMessage
}

// Relationship_Links defines model for Relationship.Links.
type Relationship_Links struct {
	union json.RawMessage
}

// RelationshipData Data for a single relationship.
type RelationshipData struct {
	Id   string `json:"id"`
	Type string `json:"type"`
}

// RepositoryAttributes Repository attributes following JSON-API spec.
type RepositoryAttributes struct {
	ClonedPath     *RepositoryAttributes_ClonedPath     `json:"cloned_path"`
	CreatedAt      *RepositoryAttributes_CreatedAt      `json:"created_at"`
	LastScannedAt  *RepositoryAttributes_LastScannedAt  `json:"last_scanned_at"`
	NumBranches    *int                                 `json:"num_branches,omitempty"`
	NumCommits     *int                                 `json:"num_commits,omitempty"`
	NumTags        *int                                 `json:"num_tags,omitempty"`
	RemoteUri      string                               `json:"remote_uri"`
	TrackingBranch *RepositoryAttributes_TrackingBranch `json:"tracking_branch"`
	UpdatedAt      *RepositoryAttributes_UpdatedAt      `json:"updated_at"`
}

// RepositoryAttributesClonedPath0 defines model for .
type RepositoryAttributesClonedPath0 = string

// RepositoryAttributes_ClonedPath defines model for RepositoryAttributes.ClonedPath.
type RepositoryAttributes_ClonedPath struct {
	union json.RawMessage
}

// RepositoryAttributesCreatedAt0 defines model for .
type RepositoryAttributesCreatedAt0 = time.Time

// RepositoryAttributes_CreatedAt defines model for RepositoryAttributes.CreatedAt.
type RepositoryAttributes_CreatedAt struct {
	union json.RawMessage
}

// RepositoryAttributesLastScannedAt0 defines model for .
type RepositoryAttributesLastScannedAt0 = time.Time

// RepositoryAttributes_LastScannedAt defines model for RepositoryAttributes.LastScannedAt.
type RepositoryAttributes_LastScannedAt struct {
	union json.RawMessage
}

// RepositoryAttributesTrackingBranch0 defines model for .
type RepositoryAttributesTrackingBranch0 = string

// RepositoryAttributes_TrackingBranch defines model for RepositoryAttributes.TrackingBranch.
type RepositoryAttributes_TrackingBranch struct {
	union json.RawMessage
}

// RepositoryAttributesUpdatedAt0 defines model for .
type RepositoryAttributesUpdatedAt0 = time.Time

// RepositoryAttributes_UpdatedAt defines model for RepositoryAttributes.UpdatedAt.
type RepositoryAttributes_UpdatedAt struct {
	union json.RawMessage
}

// RepositoryBranchData Repository branch data.
type RepositoryBranchData struct {
	CommitCount int    `json:"commit_count"`
	IsDefault   bool   `json:"is_default"`
	Name        string `json:"name"`
}

// RepositoryCommitData Repository commit data for repository details.
type RepositoryCommitData struct {
	Author    string    `json:"author"`
	Message   string    `json:"message"`
	Sha       string    `json:"sha"`
	Timestamp time.Time `json:"timestamp"`
}

// RepositoryCreateAttributes Repository creation attributes.
type RepositoryCreateAttributes struct {
	RemoteUri string `json:"remote_uri"`
}

// RepositoryCreateData Repository creation data.
type RepositoryCreateData struct {
	// Attributes Repository creation attributes.
	Attributes RepositoryCreateAttributes `json:"attributes"`
	Type       *string                    `json:"type,omitempty"`
}

// RepositoryCreateRequest Repository creation request.
type RepositoryCreateRequest struct {
	// Data Repository creation data.
	Data RepositoryCreateData `json:"data"`
}

// RepositoryData Repository data following JSON-API spec.
type RepositoryData struct {
	// Attributes Repository attributes following JSON-API spec.
	Attributes RepositoryAttributes `json:"attributes"`
	Id         string               `json:"id"`
	Type       *string              `json:"type,omitempty"`
}

// RepositoryDetailsResponse Repository details response with branches and commits.
type RepositoryDetailsResponse struct {
	Branches []RepositoryBranchData `json:"branches"`

	// Data Repository data following JSON-API spec.
	Data          RepositoryData         `json:"data"`
	RecentCommits []RepositoryCommitData `json:"recent_commits"`
}

// RepositoryListResponse Repository list response following JSON-API spec.
type RepositoryListResponse struct {
	Data []RepositoryData `json:"data"`
}

// RepositoryResponse Single repository response following JSON-API spec.
type RepositoryResponse struct {
	// Data Repository data following JSON-API spec.
	Data RepositoryData `json:"data"`
}

// RepositoryStatusSummaryAttributes Attributes for repository status summary.
type RepositoryStatusSummaryAttributes struct {
	// Message Error message if failed
	Message *string `json:"message,omitempty"`

	// Status Overall indexing status
	Status string `json:"status"`

	// UpdatedAt Most recent activity timestamp
	UpdatedAt time.Time `json:"updated_at"`
}

// RepositoryStatusSummaryData Data for repository status summary response.
type RepositoryStatusSummaryData struct {
	// Attributes Attributes for repository status summary.
	Attributes RepositoryStatusSummaryAttributes `json:"attributes"`
	Id         string                            `json:"id"`
	Type       *string                           `json:"type,omitempty"`
}

// RepositoryStatusSummaryResponse JSON:API response for repository status summary.
type RepositoryStatusSummaryResponse struct {
	// Data Data for repository status summary response.
	Data RepositoryStatusSummaryData `json:"data"`
}

// SearchAttributes Search attributes for JSON:API requests.
type SearchAttributes struct {
	// Code Code search query
	Code *SearchAttributes_Code `json:"code"`

	// Filters Search filters
	Filters *SearchAttributes_Filters `json:"filters"`

	// Keywords Search keywords
	Keywords *SearchAttributes_Keywords `json:"keywords"`

	// Limit Maximum number of results to return
	Limit *SearchAttributes_Limit `json:"limit"`

	// Text Text search query
	Text *SearchAttributes_Text `json:"text"`
}

// SearchAttributesCode0 defines model for .
type SearchAttributesCode0 = string

// SearchAttributes_Code Code search query
type SearchAttributes_Code struct {
	union json.RawMessage
}

// SearchAttributes_Filters Search filters
type SearchAttributes_Filters struct {
	union json.RawMessage
}

// SearchAttributesKeywords0 defines model for .
type SearchAttributesKeywords0 = []string

// SearchAttributes_Keywords Search keywords
type SearchAttributes_Keywords struct {
	union json.RawMessage
}

// SearchAttributesLimit0 defines model for .
type SearchAttributesLimit0 = int

// SearchAttributes_Limit Maximum number of results to return
type SearchAttributes_Limit struct {
	union json.RawMessage
}

// SearchAttributesText0 defines model for .
type SearchAttributesText0 = string

// SearchAttributes_Text Text search query
type SearchAttributes_Text struct {
	union json.RawMessage
}

// SearchData Search data for JSON:API requests.
type SearchData struct {
	// Attributes Search attributes for JSON:API requests.
	Attributes SearchAttributes `json:"attributes"`
	Type       *string          `json:"type,omitempty"`
}

// SearchFilters Search filters for JSON:API requests.
type SearchFilters struct {
	// Authors Authors to filter by
	Authors *SearchFilters_Authors `json:"authors"`

	// CommitSha Filter snippets by commit SHAs
	CommitSha *SearchFilters_CommitSha `json:"commit_sha"`

	// EndDate Filter snippets created before this date
	EndDate *SearchFilters_EndDate `json:"end_date"`

	// EnrichmentSubtypes Enrichment subtypes to filter by (e.g., 'snippet', 'example', 'snippet_summary', 'example_summary')
	EnrichmentSubtypes *SearchFilters_EnrichmentSubtypes `json:"enrichment_subtypes"`

	// EnrichmentTypes Enrichment types to filter by (e.g., 'development', 'usage')
	EnrichmentTypes *SearchFilters_EnrichmentTypes `json:"enrichment_types"`

	// FilePatterns File path patterns to filter by
	FilePatterns *SearchFilters_FilePatterns `json:"file_patterns"`

	// Languages Programming languages to filter by
	Languages *SearchFilters_Languages `json:"languages"`

	// Sources Source repositories to filter by
	Sources *SearchFilters_Sources `json:"sources"`

	// StartDate Filter snippets created after this date
	StartDate *SearchFilters_StartDate `json:"start_date"`
}

// SearchFiltersAuthors0 defines model for .
type SearchFiltersAuthors0 = []string

// SearchFilters_Authors Authors to filter by
type SearchFilters_Authors struct {
	union json.RawMessage
}

// SearchFiltersCommitSha0 defines model for .
type SearchFiltersCommitSha0 = []string

// SearchFilters_CommitSha Filter snippets by commit SHAs
type SearchFilters_CommitSha struct {
	union json.RawMessage
}

// SearchFiltersEndDate0 defines model for .
type SearchFiltersEndDate0 = time.Time

// SearchFilters_EndDate Filter snippets created before this date
type SearchFilters_EndDate struct {
	union json.RawMessage
}

// SearchFiltersEnrichmentSubtypes0 defines model for .
type SearchFiltersEnrichmentSubtypes0 = []string

// SearchFilters_EnrichmentSubtypes Enrichment subtypes to filter by (e.g., 'snippet', 'example', 'snippet_summary', 'example_summary')
type SearchFilters_EnrichmentSubtypes struct {
	union json.RawMessage
}

// SearchFiltersEnrichmentTypes0 defines model for .
type SearchFiltersEnrichmentTypes0 = []string

// SearchFilters_EnrichmentTypes Enrichment types to filter by (e.g., 'development', 'usage')
type SearchFilters_EnrichmentTypes struct {
	union json.RawMessage
}

// SearchFiltersFilePatterns0 defines model for .
type SearchFiltersFilePatterns0 = []string

// SearchFilters_FilePatterns File path patterns to filter by
type SearchFilters_FilePatterns struct {
	union json.RawMessage
}

// SearchFiltersLanguages0 defines model for .
type SearchFiltersLanguages0 = []string

// SearchFilters_Languages Programming languages to filter by
type SearchFilters_Languages struct {
	union json.RawMessage
}

// SearchFiltersSources0 defines model for .
type SearchFiltersSources0 = []string

// SearchFilters_Sources Source repositories to filter by
type SearchFilters_Sources struct {
	union json.RawMessage
}

// SearchFiltersStartDate0 defines model for .
type SearchFiltersStartDate0 = time.Time

// SearchFilters_StartDate Filter snippets created after this date
type SearchFilters_StartDate struct {
	union json.RawMessage
}

// SearchRequest JSON:API request for searching snippets.
type SearchRequest struct {
	// Data Search data for JSON:API requests.
	Data SearchData `json:"data"`
}

// SearchResponse JSON:API response for search results.
type SearchResponse struct {
	Data []SnippetData `json:"data"`
}

// SnippetAttributes Snippet attributes for JSON:API responses.
type SnippetAttributes struct {
	// Content Snippet content schema following JSON-API spec.
	Content        SnippetContentSchema         `json:"content"`
	CreatedAt      *SnippetAttributes_CreatedAt `json:"created_at"`
	DerivesFrom    []GitFileSchema              `json:"derives_from"`
	Enrichments    []EnrichmentSchema           `json:"enrichments"`
	OriginalScores []float32                    `json:"original_scores"`
	UpdatedAt      *SnippetAttributes_UpdatedAt `json:"updated_at"`
}

// SnippetAttributesCreatedAt0 defines model for .
type SnippetAttributesCreatedAt0 = time.Time

// SnippetAttributes_CreatedAt defines model for SnippetAttributes.CreatedAt.
type SnippetAttributes_CreatedAt struct {
	union json.RawMessage
}

// SnippetAttributesUpdatedAt0 defines model for .
type SnippetAttributesUpdatedAt0 = time.Time

// SnippetAttributes_UpdatedAt defines model for SnippetAttributes.UpdatedAt.
type SnippetAttributes_UpdatedAt struct {
	union json.RawMessage
}

// SnippetContentSchema Snippet content schema following JSON-API spec.
type SnippetContentSchema struct {
	Language string `json:"language"`
	Value    string `json:"value"`
}

// SnippetData Snippet data for JSON:API responses.
type SnippetData struct {
	// Attributes Snippet attributes for JSON:API responses.
	Attributes SnippetAttributes `json:"attributes"`
	Id         string            `json:"id"`
	Type       string            `json:"type"`
}

// TagAttributes Tag attributes following JSON-API spec.
type TagAttributes struct {
	IsVersionTag    bool   `json:"is_version_tag"`
	Name            string `json:"name"`
	TargetCommitSha string `json:"target_commit_sha"`
}

// TagData Tag data following JSON-API spec.
type TagData struct {
	// Attributes Tag attributes following JSON-API spec.
	Attributes TagAttributes `json:"attributes"`
	Id         string        `json:"id"`
	Type       *string       `json:"type,omitempty"`
}

// TagListResponse Tag list response following JSON-API spec.
type TagListResponse struct {
	Data []TagData `json:"data"`
}

// TagResponse Single tag response following JSON-API spec.
type TagResponse struct {
	// Data Tag data following JSON-API spec.
	Data TagData `json:"data"`
}

// TaskAttributes Task attributes for JSON:API responses.
type TaskAttributes struct {
	CreatedAt *TaskAttributes_CreatedAt `json:"created_at"`
	Payload   map[string]interface{}    `json:"payload"`
	Priority  int                       `json:"priority"`
	Type      string                    `json:"type"`
	UpdatedAt *TaskAttributes_UpdatedAt `json:"updated_at"`
}

// TaskAttributesCreatedAt0 defines model for .
type TaskAttributesCreatedAt0 = time.Time

// TaskAttributes_CreatedAt defines model for TaskAttributes.CreatedAt.
type TaskAttributes_CreatedAt struct {
	union json.RawMessage
}

// TaskAttributesUpdatedAt0 defines model for .
type TaskAttributesUpdatedAt0 = time.Time

// TaskAttributes_UpdatedAt defines model for TaskAttributes.UpdatedAt.
type TaskAttributes_UpdatedAt struct {
	union json.RawMessage
}

// TaskData Task data for JSON:API responses.
type TaskData struct {
	// Attributes Task attributes for JSON:API responses.
	Attributes TaskAttributes `json:"attributes"`
	Id         string         `json:"id"`
	Type       *string        `json:"type,omitempty"`
}

// TaskListResponse JSON:API response for task list.
type TaskListResponse struct {
	Data []TaskData `json:"data"`
}

// TaskOperation Task operation.
type TaskOperation string

// TaskResponse JSON:API response for single task.
type TaskResponse struct {
	// Data Task data for JSON:API responses.
	Data TaskData `json:"data"`
}

// TaskStatusAttributes Task status attributes for JSON:API responses.
type TaskStatusAttributes struct {
	// CreatedAt Task start time
	CreatedAt *TaskStatusAttributes_CreatedAt `json:"created_at"`

	// Current Current number of items processed
	Current *int `json:"current,omitempty"`

	// Error Error message
	Error *string `json:"error,omitempty"`

	// Message Message
	Message *string `json:"message,omitempty"`

	// Progress Progress percentage (0-100)
	Progress *float32 `json:"progress,omitempty"`

	// State Current state of the task
	State string `json:"state"`

	// Step Name of the task/operation
	Step string `json:"step"`

	// Total Total number of items to process
	Total *int `json:"total,omitempty"`

	// UpdatedAt Last update time
	UpdatedAt *TaskStatusAttributes_UpdatedAt `json:"updated_at"`
}

// TaskStatusAttributesCreatedAt0 defines model for .
type TaskStatusAttributesCreatedAt0 = time.Time

// TaskStatusAttributes_CreatedAt Task start time
type TaskStatusAttributes_CreatedAt struct {
	union json.RawMessage
}

// TaskStatusAttributesUpdatedAt0 defines model for .
type TaskStatusAttributesUpdatedAt0 = time.Time

// TaskStatusAttributes_UpdatedAt Last update time
type TaskStatusAttributes_UpdatedAt struct {
	union json.RawMessage
}

// TaskStatusData Task status data for JSON:API responses.
type TaskStatusData struct {
	// Attributes Task status attributes for JSON:API responses.
	Attributes TaskStatusAttributes `json:"attributes"`
	Id         string               `json:"id"`
	Type       *string              `json:"type,omitempty"`
}

// TaskStatusListResponse JSON:API response for task status list.
type TaskStatusListResponse struct {
	Data []TaskStatusData `json:"data"`
}

// TrackingConfigAttributes Tracking configuration attributes following JSON-API spec.
type TrackingConfigAttributes struct {
	// Mode Tracking mode for repository configuration.
	Mode TrackingMode `json:"mode"`

	// Value Branch name when mode is 'branch'. Not used for 'tag' mode.
	Value *TrackingConfigAttributes_Value `json:"value"`
}

// TrackingConfigAttributesValue0 defines model for .
type TrackingConfigAttributesValue0 = string

// TrackingConfigAttributes_Value Branch name when mode is 'branch'. Not used for 'tag' mode.
type TrackingConfigAttributes_Value struct {
	union json.RawMessage
}

// TrackingConfigData Tracking configuration data following JSON-API spec.
type TrackingConfigData struct {
	// Attributes Tracking configuration attributes following JSON-API spec.
	Attributes TrackingConfigAttributes `json:"attributes"`
	Type       *string                  `json:"type,omitempty"`
}

// TrackingConfigResponse Tracking configuration response following JSON-API spec.
type TrackingConfigResponse struct {
	// Data Tracking configuration data following JSON-API spec.
	Data TrackingConfigData `json:"data"`
}

// TrackingConfigUpdateAttributes Tracking configuration update attributes.
type TrackingConfigUpdateAttributes struct {
	// Mode Tracking mode for repository configuration.
	Mode TrackingMode `json:"mode"`

	// Value Branch name when mode is 'branch'. Not used for 'tag' mode.
	Value *TrackingConfigUpdateAttributes_Value `json:"value"`
}

// TrackingConfigUpdateAttributesValue0 defines model for .
type TrackingConfigUpdateAttributesValue0 = string

// TrackingConfigUpdateAttributes_Value Branch name when mode is 'branch'. Not used for 'tag' mode.
type TrackingConfigUpdateAttributes_Value struct {
	union json.RawMessage
}

// TrackingConfigUpdateData Tracking configuration update data.
type TrackingConfigUpdateData struct {
	// Attributes Tracking configuration update attributes.
	Attributes TrackingConfigUpdateAttributes `json:"attributes"`
	Type       *string                        `json:"type,omitempty"`
}

// TrackingConfigUpdateRequest Tracking configuration update request.
type TrackingConfigUpdateRequest struct {
	// Data Tracking configuration update data.
	Data TrackingConfigUpdateData `json:"data"`
}

// TrackingMode Tracking mode for repository configuration.
type TrackingMode string

// ValidationError defines model for ValidationError.
type ValidationError struct {
	Loc  []ValidationError_Loc_Item `json:"loc"`
	Msg  string                     `json:"msg"`
	Type string                     `json:"type"`
}

// ValidationErrorLoc0 defines model for .
type ValidationErrorLoc0 = string

// ValidationErrorLoc1 defines model for .
type ValidationErrorLoc1 = int

// ValidationError_Loc_Item defines model for ValidationError.loc.Item.
type ValidationError_Loc_Item struct {
	union json.RawMessage
}

// ListEnrichmentsApiV1EnrichmentsGetParams defines parameters for ListEnrichmentsApiV1EnrichmentsGet.
type ListEnrichmentsApiV1EnrichmentsGetParams struct {
	// EnrichmentType Filter by enrichment type
	EnrichmentType *struct {
		union json.RawMessage
	} `form:"enrichment_type,omitempty" json:"enrichment_type,omitempty"`

	// EnrichmentSubtype Filter by enrichment subtype
	EnrichmentSubtype *struct {
		union json.RawMessage
	} `form:"enrichment_subtype,omitempty" json:"enrichment_subtype,omitempty"`

	// Page Page number, starting from 1
	Page *int `form:"page,omitempty" json:"page,omitempty"`

	// PageSize Items per page
	PageSize *int `form:"page_size,omitempty" json:"page_size,omitempty"`
}

// ListEnrichmentsApiV1EnrichmentsGetParamsEnrichmentType0 defines parameters for ListEnrichmentsApiV1EnrichmentsGet.
type ListEnrichmentsApiV1EnrichmentsGetParamsEnrichmentType0 = string

// ListEnrichmentsApiV1EnrichmentsGetParamsEnrichmentSubtype0 defines parameters for ListEnrichmentsApiV1EnrichmentsGet.
type ListEnrichmentsApiV1EnrichmentsGetParamsEnrichmentSubtype0 = string

// ListQueueTasksApiV1QueueGetParams defines parameters for ListQueueTasksApiV1QueueGet.
type ListQueueTasksApiV1QueueGetParams struct {
	TaskType *struct {
		union json.RawMessage
	} `form:"task_type,omitempty" json:"task_type,omitempty"`
}

// ListRepositoryCommitsApiV1RepositoriesRepoIdCommitsGetParams defines parameters for ListRepositoryCommitsApiV1RepositoriesRepoIdCommitsGet.
type ListRepositoryCommitsApiV1RepositoriesRepoIdCommitsGetParams struct {
	// Page Page number, starting from 1
	Page *int `form:"page,omitempty" json:"page,omitempty"`

	// PageSize Items per page
	PageSize *int `form:"page_size,omitempty" json:"page_size,omitempty"`
}

// ListCommitEmbeddingsApiV1RepositoriesRepoIdCommitsCommitShaEmbeddingsGetParams defines parameters for ListCommitEmbeddingsApiV1RepositoriesRepoIdCommitsCommitShaEmbeddingsGet.
type ListCommitEmbeddingsApiV1RepositoriesRepoIdCommitsCommitShaEmbeddingsGetParams struct {
	// Full If true, return full vectors. If false, return first 5 values.
	Full *bool `form:"full,omitempty" json:"full,omitempty"`
}

// ListCommitEnrichmentsApiV1RepositoriesRepoIdCommitsCommitShaEnrichmentsGetParams defines parameters for ListCommitEnrichmentsApiV1RepositoriesRepoIdCommitsCommitShaEnrichmentsGet.
type ListCommitEnrichmentsApiV1RepositoriesRepoIdCommitsCommitShaEnrichmentsGetParams struct {
	EnrichmentType *struct {
		union json.RawMessage
	} `form:"enrichment_type,omitempty" json:"enrichment_type,omitempty"`

	// Page Page number, starting from 1
	Page *int `form:"page,omitempty" json:"page,omitempty"`

	// PageSize Items per page
	PageSize *int `form:"page_size,omitempty" json:"page_size,omitempty"`
}

// ListCommitEnrichmentsApiV1RepositoriesRepoIdCommitsCommitShaEnrichmentsGetParamsEnrichmentType0 defines parameters for ListCommitEnrichmentsApiV1RepositoriesRepoIdCommitsCommitShaEnrichmentsGet.
type ListCommitEnrichmentsApiV1RepositoriesRepoIdCommitsCommitShaEnrichmentsGetParamsEnrichmentType0 = string

// ListCommitFilesApiV1RepositoriesRepoIdCommitsCommitShaFilesGetParams defines parameters for ListCommitFilesApiV1RepositoriesRepoIdCommitsCommitShaFilesGet.
type ListCommitFilesApiV1RepositoriesRepoIdCommitsCommitShaFilesGetParams struct {
	// Page Page number, starting from 1
	Page *int `form:"page,omitempty" json:"page,omitempty"`

	// PageSize Items per page
	PageSize *int `form:"page_size,omitempty" json:"page_size,omitempty"`
}

// ListRepositoryEnrichmentsApiV1RepositoriesRepoIdEnrichmentsGetParams defines parameters for ListRepositoryEnrichmentsApiV1RepositoriesRepoIdEnrichmentsGet.
type ListRepositoryEnrichmentsApiV1RepositoriesRepoIdEnrichmentsGetParams struct {
	EnrichmentType *struct {
		union json.RawMessage
	} `form:"enrichment_type,omitempty" json:"enrichment_type,omitempty"`

	// MaxCommitsToCheck Number of recent commits to search for recent enriched commits
	MaxCommitsToCheck *int `form:"max_commits_to_check,omitempty" json:"max_commits_to_check,omitempty"`

	// Page Page number, starting from 1
	Page *int `form:"page,omitempty" json:"page,omitempty"`

	// PageSize Items per page
	PageSize *int `form:"page_size,omitempty" json:"page_size,omitempty"`
}

// ListRepositoryEnrichmentsApiV1RepositoriesRepoIdEnrichmentsGetParamsEnrichmentType0 defines parameters for ListRepositoryEnrichmentsApiV1RepositoriesRepoIdEnrichmentsGet.
type ListRepositoryEnrichmentsApiV1RepositoriesRepoIdEnrichmentsGetParamsEnrichmentType0 = string

// UpdateEnrichmentApiV1EnrichmentsEnrichmentIdPatchJSONRequestBody defines body for UpdateEnrichmentApiV1EnrichmentsEnrichmentIdPatch for application/json ContentType.
type UpdateEnrichmentApiV1EnrichmentsEnrichmentIdPatchJSONRequestBody = EnrichmentUpdateRequest

// CreateRepositoryApiV1RepositoriesPostJSONRequestBody defines body for CreateRepositoryApiV1RepositoriesPost for application/json ContentType.
type CreateRepositoryApiV1RepositoriesPostJSONRequestBody = RepositoryCreateRequest

// UpdateTrackingConfigApiV1RepositoriesRepoIdTrackingConfigPutJSONRequestBody defines body for UpdateTrackingConfigApiV1RepositoriesRepoIdTrackingConfigPut for application/json ContentType.
type UpdateTrackingConfigApiV1RepositoriesRepoIdTrackingConfigPutJSONRequestBody = TrackingConfigUpdateRequest

// SearchSnippetsApiV1SearchPostJSONRequestBody defines body for SearchSnippetsApiV1SearchPost for application/json ContentType.
type SearchSnippetsApiV1SearchPostJSONRequestBody = SearchRequest

// AsEnrichmentAttributesCreatedAt0 returns the union data inside the EnrichmentAttributes_CreatedAt as a EnrichmentAttributesCreatedAt0
func (t EnrichmentAttributes_CreatedAt) AsEnrichmentAttributesCreatedAt0() (EnrichmentAttributesCreatedAt0, error) {
	var body EnrichmentAttributesCreatedAt0
	err := json.Unmarshal(t.union, &body)
	return body, err
}

// FromEnrichmentAttributesCreatedAt0 overwrites any union data inside the EnrichmentAttributes_CreatedAt as the provided EnrichmentAttributesCreatedAt0
func (t *EnrichmentAttributes_CreatedAt) FromEnrichmentAttributesCreatedAt0(v EnrichmentAttributesCreatedAt0) error {
	b, err := json.Marshal(v)
	t.union = b
	return err
}

// MergeEnrichmentAttributesCreatedAt0 performs a merge with any union data inside the EnrichmentAttributes_CreatedAt, using the provided EnrichmentAttributesCreatedAt0
func (t *EnrichmentAttributes_CreatedAt) MergeEnrichmentAttributesCreatedAt0(v EnrichmentAttributesCreatedAt0) error {
	b, err := json.Marshal(v)
	if err != nil {
		return err
	}

	merged, err := runtime.JSONMerge(t.union, b)
	t.union = merged
	return err
}

func (t EnrichmentAttributes_CreatedAt) MarshalJSON() ([]byte, error) {
	b, err := t.union.MarshalJSON()
	return b, err
}

func (t *EnrichmentAttributes_CreatedAt) UnmarshalJSON(b []byte) error {
	err := t.union.UnmarshalJSON(b)
	return err
}

// AsEnrichmentAttributesSubtype0 returns the union data inside the EnrichmentAttributes_Subtype as a EnrichmentAttributesSubtype0
func (t EnrichmentAttributes_Subtype) AsEnrichmentAttributesSubtype0() (EnrichmentAttributesSubtype0, error) {
	var body EnrichmentAttributesSubtype0
	err := json.Unmarshal(t.union, &body)
	return body, err
}

// FromEnrichmentAttributesSubtype0 overwrites any union data inside the EnrichmentAttributes_Subtype as the provided EnrichmentAttributesSubtype0
func (t *EnrichmentAttributes_Subtype) FromEnrichmentAttributesSubtype0(v EnrichmentAttributesSubtype0) error {
	b, err := json.Marshal(v)
	t.union = b
	return err
}

// MergeEnrichmentAttributesSubtype0 performs a merge with any union data inside the EnrichmentAttributes_Subtype, using the provided EnrichmentAttributesSubtype0
func (t *EnrichmentAttributes_Subtype) MergeEnrichmentAttributesSubtype0(v EnrichmentAttributesSubtype0) error {
	b, err := json.Marshal(v)
	if err != nil {
		return err
	}

	merged, err := runtime.JSONMerge(t.union, b)
	t.union = merged
	return err
}

func (t EnrichmentAttributes_Subtype) MarshalJSON() ([]byte, error) {
	b, err := t.union.MarshalJSON()
	return b, err
}

func (t *EnrichmentAttributes_Subtype) UnmarshalJSON(b []byte) error {
	err := t.union.UnmarshalJSON(b)
	return err
}

// AsEnrichmentAttributesUpdatedAt0 returns the union data inside the EnrichmentAttributes_UpdatedAt as a EnrichmentAttributesUpdatedAt0
func (t EnrichmentAttributes_UpdatedAt) AsEnrichmentAttributesUpdatedAt0() (EnrichmentAttributesUpdatedAt0, error) {
	var body EnrichmentAttributesUpdatedAt0
	err := json.Unmarshal(t.union, &body)
	return body, err
}

// FromEnrichmentAttributesUpdatedAt0 overwrites any union data inside the EnrichmentAttributes_UpdatedAt as the provided EnrichmentAttributesUpdatedAt0
func (t *EnrichmentAttributes_UpdatedAt) FromEnrichmentAttributesUpdatedAt0(v EnrichmentAttributesUpdatedAt0) error {
	b, err := json.Marshal(v)
	t.union = b
	return err
}

// MergeEnrichmentAttributesUpdatedAt0 performs a merge with any union data inside the EnrichmentAttributes_UpdatedAt, using the provided EnrichmentAttributesUpdatedAt0
func (t *EnrichmentAttributes_UpdatedAt) MergeEnrichmentAttributesUpdatedAt0(v EnrichmentAttributesUpdatedAt0) error {
	b, err := json.Marshal(v)
	if err != nil {
		return err
	}

	merged, err := runtime.JSONMerge(t.union, b)
	t.union = merged
	return err
}

func (t EnrichmentAttributes_UpdatedAt) MarshalJSON() ([]byte, error) {
	b, err := t.union.MarshalJSON()
	return b, err
}

func (t *EnrichmentAttributes_UpdatedAt) UnmarshalJSON(b []byte) error {
	err := t.union.UnmarshalJSON(b)
	return err
}

// AsEnrichmentLinks returns the union data inside the EnrichmentData_Links as a EnrichmentLinks
func (t EnrichmentData_Links) AsEnrichmentLinks() (EnrichmentLinks, error) {
	var body EnrichmentLinks
	err := json.Unmarshal(t.union, &body)
	return body, err
}

// FromEnrichmentLinks overwrites any union data inside the EnrichmentData_Links as the provided EnrichmentLinks
func (t *EnrichmentData_Links) FromEnrichmentLinks(v EnrichmentLinks) error {
	b, err := json.Marshal(v)
	t.union = b
	return err
}

// MergeEnrichmentLinks performs a merge with any union data inside the EnrichmentData_Links, using the provided EnrichmentLinks
func (t *EnrichmentData_Links) MergeEnrichmentLinks(v EnrichmentLinks) error {
	b, err := json.Marshal(v)
	if err != nil {
		return err
	}

	merged, err := runtime.JSONMerge(t.union, b)
	t.union = merged
	return err
}

func (t EnrichmentData_Links) MarshalJSON() ([]byte, error) {
	b, err := t.union.MarshalJSON()
	return b, err
}

func (t *EnrichmentData_Links) UnmarshalJSON(b []byte) error {
	err := t.union.UnmarshalJSON(b)
	return err
}

// AsEnrichmentRelationships returns the union data inside the EnrichmentData_Relationships as a EnrichmentRelationships
func (t EnrichmentData_Relationships) AsEnrichmentRelationships() (EnrichmentRelationships, error) {
	var body EnrichmentRelationships
	err := json.Unmarshal(t.union, &body)
	return body, err
}

// FromEnrichmentRelationships overwrites any union data inside the EnrichmentData_Relationships as the provided EnrichmentRelationships
func (t *EnrichmentData_Relationships) FromEnrichmentRelationships(v EnrichmentRelationships) error {
	b, err := json.Marshal(v)
	t.union = b
	return err
}

// MergeEnrichmentRelationships performs a merge with any union data inside the EnrichmentData_Relationships, using the provided EnrichmentRelationships
func (t *EnrichmentData_Relationships) MergeEnrichmentRelationships(v EnrichmentRelationships) error {
	b, err := json.Marshal(v)
	if err != nil {
		return err
	}

	merged, err := runtime.JSONMerge(t.union, b)
	t.union = merged
	return err
}

func (t EnrichmentData_Relationships) MarshalJSON() ([]byte, error) {
	b, err := t.union.MarshalJSON()
	return b, err
}

func (t *EnrichmentData_Relationships) UnmarshalJSON(b []byte) error {
	err := t.union.UnmarshalJSON(b)
	return err
}

// AsEnrichmentRelationshipsAssociations0 returns the union data inside the EnrichmentRelationships_Associations as a EnrichmentRelationshipsAssociations0
func (t EnrichmentRelationships_Associations) AsEnrichmentRelationshipsAssociations0() (EnrichmentRelationshipsAssociations0, error) {
	var body EnrichmentRelationshipsAssociations0
	err := json.Unmarshal(t.union, &body)
	return body, err
}

// FromEnrichmentRelationshipsAssociations0 overwrites any union data inside the EnrichmentRelationships_Associations as the provided EnrichmentRelationshipsAssociations0
func (t *EnrichmentRelationships_Associations) FromEnrichmentRelationshipsAssociations0(v EnrichmentRelationshipsAssociations0) error {
	b, err := json.Marshal(v)
	t.union = b
	return err
}

// MergeEnrichmentRelationshipsAssociations0 performs a merge with any union data inside the EnrichmentRelationships_Associations, using the provided EnrichmentRelationshipsAssociations0
func (t *EnrichmentRelationships_Associations) MergeEnrichmentRelationshipsAssociations0(v EnrichmentRelationshipsAssociations0) error {
	b, err := json.Marshal(v)
	if err != nil {
		return err
	}

	merged, err := runtime.JSONMerge(t.union, b)
	t.union = merged
	return err
}

func (t EnrichmentRelationships_Associations) MarshalJSON() ([]byte, error) {
	b, err := t.union.MarshalJSON()
	return b, err
}

func (t *EnrichmentRelationships_Associations) UnmarshalJSON(b []byte) error {
	err := t.union.UnmarshalJSON(b)
	return err
}

// AsRelationship returns the union data inside the EnrichmentRelationships_Commit as a Relationship
func (t EnrichmentRelationships_Commit) AsRelationship() (Relationship, error) {
	var body Relationship
	err := json.Unmarshal(t.union, &body)
	return body, err
}

// FromRelationship overwrites any union data inside the EnrichmentRelationships_Commit as the provided Relationship
func (t *EnrichmentRelationships_Commit) FromRelationship(v Relationship) error {
	b, err := json.Marshal(v)
	t.union = b
	return err
}

// MergeRelationship performs a merge with any union data inside the EnrichmentRelationships_Commit, using the provided Relationship
func (t *EnrichmentRelationships_Commit) MergeRelationship(v Relationship) error {
	b, err := json.Marshal(v)
	if err != nil {
		return err
	}

	merged, err := runtime.JSONMerge(t.union, b)
	t.union = merged
	return err
}

func (t EnrichmentRelationships_Commit) MarshalJSON() ([]byte, error) {
	b, err := t.union.MarshalJSON()
	return b, err
}

func (t *EnrichmentRelationships_Commit) UnmarshalJSON(b []byte) error {
	err := t.union.UnmarshalJSON(b)
	return err
}

// AsRelationshipData returns the union data inside the Relationship_Data as a RelationshipData
func (t Relationship_Data) AsRelationshipData() (RelationshipData, error) {
	var body RelationshipData
	err := json.Unmarshal(t.union, &body)
	return body, err
}

// FromRelationshipData overwrites any union data inside the Relationship_Data as the provided RelationshipData
func (t *Relationship_Data) FromRelationshipData(v RelationshipData) error {
	b, err := json.Marshal(v)
	t.union = b
	return err
}

// MergeRelationshipData performs a merge with any union data inside the Relationship_Data, using the provided RelationshipData
func (t *Relationship_Data) MergeRelationshipData(v RelationshipData) error {
	b, err := json.Marshal(v)
	if err != nil {
		return err
	}

	merged, err := runtime.JSONMerge(t.union, b)
	t.union = merged
	return err
}

// AsRelationshipData1 returns the union data inside the Relationship_Data as a RelationshipData1
func (t Relationship_Data) AsRelationshipData1() (RelationshipData1, error) {
	var body RelationshipData1
	err := json.Unmarshal(t.union, &body)
	return body, err
}

// FromRelationshipData1 overwrites any union data inside the Relationship_Data as the provided RelationshipData1
func (t *Relationship_Data) FromRelationshipData1(v RelationshipData1) error {
	b, err := json.Marshal(v)
	t.union = b
	return err
}

// MergeRelationshipData1 performs a merge with any union data inside the Relationship_Data, using the provided RelationshipData1
func (t *Relationship_Data) MergeRelationshipData1(v RelationshipData1) error {
	b, err := json.Marshal(v)
	if err != nil {
		return err
	}

	merged, err := runtime.JSONMerge(t.union, b)
	t.union = merged
	return err
}

func (t Relationship_Data) MarshalJSON() ([]byte, error) {
	b, err := t.union.MarshalJSON()
	return b, err
}

func (t *Relationship_Data) UnmarshalJSON(b []byte) error {
	err := t.union.UnmarshalJSON(b)
	return err
}

// AsEnrichmentLinks returns the union data inside the Relationship_Links as a EnrichmentLinks
func (t Relationship_Links) AsEnrichmentLinks() (EnrichmentLinks, error) {
	var body EnrichmentLinks
	err := json.Unmarshal(t.union, &body)
	return body, err
}

// FromEnrichmentLinks overwrites any union data inside the Relationship_Links as the provided EnrichmentLinks
func (t *Relationship_Links) FromEnrichmentLinks(v EnrichmentLinks) error {
	b, err := json.Marshal(v)
	t.union = b
	return err
}

// MergeEnrichmentLinks performs a merge with any union data inside the Relationship_Links, using the provided EnrichmentLinks
func (t *Relationship_Links) MergeEnrichmentLinks(v EnrichmentLinks) error {
	b, err := json.Marshal(v)
	if err != nil {
		return err
	}

	merged, err := runtime.JSONMerge(t.union, b)
	t.union = merged
	return err
}

func (t Relationship_Links) MarshalJSON() ([]byte, error) {
	b, err := t.union.MarshalJSON()
	return b, err
}

func (t *Relationship_Links) UnmarshalJSON(b []byte) error {
	err := t.union.UnmarshalJSON(b)
	return err
}

// AsRepositoryAttributesClonedPath0 returns the union data inside the RepositoryAttributes_ClonedPath as a RepositoryAttributesClonedPath0
func (t RepositoryAttributes_ClonedPath) AsRepositoryAttributesClonedPath0() (RepositoryAttributesClonedPath0, error) {
	var body RepositoryAttributesClonedPath0
	err := json.Unmarshal(t.union, &body)
	return body, err
}

// FromRepositoryAttributesClonedPath0 overwrites any union data inside the RepositoryAttributes_ClonedPath as the provided RepositoryAttributesClonedPath0
func (t *RepositoryAttributes_ClonedPath) FromRepositoryAttributesClonedPath0(v RepositoryAttributesClonedPath0) error {
	b, err := json.Marshal(v)
	t.union = b
	return err
}

// MergeRepositoryAttributesClonedPath0 performs a merge with any union data inside the RepositoryAttributes_ClonedPath, using the provided RepositoryAttributesClonedPath0
func (t *RepositoryAttributes_ClonedPath) MergeRepositoryAttributesClonedPath0(v RepositoryAttributesClonedPath0) error {
	b, err := json.Marshal(v)
	if err != nil {
		return err
	}

	merged, err := runtime.JSONMerge(t.union, b)
	t.union = merged
	return err
}

func (t RepositoryAttributes_ClonedPath) MarshalJSON() ([]byte, error) {
	b, err := t.union.MarshalJSON()
	return b, err
}

func (t *RepositoryAttributes_ClonedPath) UnmarshalJSON(b []byte) error {
	err := t.union.UnmarshalJSON(b)
	return err
}

// AsRepositoryAttributesCreatedAt0 returns the union data inside the RepositoryAttributes_CreatedAt as a RepositoryAttributesCreatedAt0
func (t RepositoryAttributes_CreatedAt) AsRepositoryAttributesCreatedAt0() (RepositoryAttributesCreatedAt0, error) {
	var body RepositoryAttributesCreatedAt0
	err := json.Unmarshal(t.union, &body)
	return body, err
}

// FromRepositoryAttributesCreatedAt0 overwrites any union data inside the RepositoryAttributes_CreatedAt as the provided RepositoryAttributesCreatedAt0
func (t *RepositoryAttributes_CreatedAt) FromRepositoryAttributesCreatedAt0(v RepositoryAttributesCreatedAt0) error {
	b, err := json.Marshal(v)
	t.union = b
	return err
}

// MergeRepositoryAttributesCreatedAt0 performs a merge with any union data inside the RepositoryAttributes_CreatedAt, using the provided RepositoryAttributesCreatedAt0
func (t *RepositoryAttributes_CreatedAt) MergeRepositoryAttributesCreatedAt0(v RepositoryAttributesCreatedAt0) error {
	b, err := json.Marshal(v)
	if err != nil {
		return err
	}

	merged, err := runtime.JSONMerge(t.union, b)
	t.union = merged
	return err
}

func (t RepositoryAttributes_CreatedAt) MarshalJSON() ([]byte, error) {
	b, err := t.union.MarshalJSON()
	return b, err
}

func (t *RepositoryAttributes_CreatedAt) UnmarshalJSON(b []byte) error {
	err := t.union.UnmarshalJSON(b)
	return err
}

// AsRepositoryAttributesLastScannedAt0 returns the union data inside the RepositoryAttributes_LastScannedAt as a RepositoryAttributesLastScannedAt0
func (t RepositoryAttributes_LastScannedAt) AsRepositoryAttributesLastScannedAt0() (RepositoryAttributesLastScannedAt0, error) {
	var body RepositoryAttributesLastScannedAt0
	err := json.Unmarshal(t.union, &body)
	return body, err
}

// FromRepositoryAttributesLastScannedAt0 overwrites any union data inside the RepositoryAttributes_LastScannedAt as the provided RepositoryAttributesLastScannedAt0
func (t *RepositoryAttributes_LastScannedAt) FromRepositoryAttributesLastScannedAt0(v RepositoryAttributesLastScannedAt0) error {
	b, err := json.Marshal(v)
	t.union = b
	return err
}

// MergeRepositoryAttributesLastScannedAt0 performs a merge with any union data inside the RepositoryAttributes_LastScannedAt, using the provided RepositoryAttributesLastScannedAt0
func (t *RepositoryAttributes_LastScannedAt) MergeRepositoryAttributesLastScannedAt0(v RepositoryAttributesLastScannedAt0) error {
	b, err := json.Marshal(v)
	if err != nil {
		return err
	}

	merged, err := runtime.JSONMerge(t.union, b)
	t.union = merged
	return err
}

func (t RepositoryAttributes_LastScannedAt) MarshalJSON() ([]byte, error) {
	b, err := t.union.MarshalJSON()
	return b, err
}

func (t *RepositoryAttributes_LastScannedAt) UnmarshalJSON(b []byte) error {
	err := t.union.UnmarshalJSON(b)
	return err
}

// AsRepositoryAttributesTrackingBranch0 returns the union data inside the RepositoryAttributes_TrackingBranch as a RepositoryAttributesTrackingBranch0
func (t RepositoryAttributes_TrackingBranch) AsRepositoryAttributesTrackingBranch0() (RepositoryAttributesTrackingBranch0, error) {
	var body RepositoryAttributesTrackingBranch0
	err := json.Unmarshal(t.union, &body)
	return body, err
}

// FromRepositoryAttributesTrackingBranch0 overwrites any union data inside the RepositoryAttributes_TrackingBranch as the provided RepositoryAttributesTrackingBranch0
func (t *RepositoryAttributes_TrackingBranch) FromRepositoryAttributesTrackingBranch0(v RepositoryAttributesTrackingBranch0) error {
	b, err := json.Marshal(v)
	t.union = b
	return err
}

// MergeRepositoryAttributesTrackingBranch0 performs a merge with any union data inside the RepositoryAttributes_TrackingBranch, using the provided RepositoryAttributesTrackingBranch0
func (t *RepositoryAttributes_TrackingBranch) MergeRepositoryAttributesTrackingBranch0(v RepositoryAttributesTrackingBranch0) error {
	b, err := json.Marshal(v)
	if err != nil {
		return err
	}

	merged, err := runtime.JSONMerge(t.union, b)
	t.union = merged
	return err
}

func (t RepositoryAttributes_TrackingBranch) MarshalJSON() ([]byte, error) {
	b, err := t.union.MarshalJSON()
	return b, err
}

func (t *RepositoryAttributes_TrackingBranch) UnmarshalJSON(b []byte) error {
	err := t.union.UnmarshalJSON(b)
	return err
}

// AsRepositoryAttributesUpdatedAt0 returns the union data inside the RepositoryAttributes_UpdatedAt as a RepositoryAttributesUpdatedAt0
func (t RepositoryAttributes_UpdatedAt) AsRepositoryAttributesUpdatedAt0() (RepositoryAttributesUpdatedAt0, error) {
	var body RepositoryAttributesUpdatedAt0
	err := json.Unmarshal(t.union, &body)
	return body, err
}

// FromRepositoryAttributesUpdatedAt0 overwrites any union data inside the RepositoryAttributes_UpdatedAt as the provided RepositoryAttributesUpdatedAt0
func (t *RepositoryAttributes_UpdatedAt) FromRepositoryAttributesUpdatedAt0(v RepositoryAttributesUpdatedAt0) error {
	b, err := json.Marshal(v)
	t.union = b
	return err
}

// MergeRepositoryAttributesUpdatedAt0 performs a merge with any union data inside the RepositoryAttributes_UpdatedAt, using the provided RepositoryAttributesUpdatedAt0
func (t *RepositoryAttributes_UpdatedAt) MergeRepositoryAttributesUpdatedAt0(v RepositoryAttributesUpdatedAt0) error {
	b, err := json.Marshal(v)
	if err != nil {
		return err
	}

	merged, err := runtime.JSONMerge(t.union, b)
	t.union = merged
	return err
}

func (t RepositoryAttributes_UpdatedAt) MarshalJSON() ([]byte, error) {
	b, err := t.union.MarshalJSON()
	return b, err
}

func (t *RepositoryAttributes_UpdatedAt) UnmarshalJSON(b []byte) error {
	err := t.union.UnmarshalJSON(b)
	return err
}

// AsSearchAttributesCode0 returns the union data inside the SearchAttributes_Code as a SearchAttributesCode0
func (t SearchAttributes_Code) AsSearchAttributesCode0() (SearchAttributesCode0, error) {
	var body SearchAttributesCode0
	err := json.Unmarshal(t.union, &body)
	return body, err
}

// FromSearchAttributesCode0 overwrites any union data inside the SearchAttributes_Code as the provided SearchAttributesCode0
func (t *SearchAttributes_Code) FromSearchAttributesCode0(v SearchAttributesCode0) error {
	b, err := json.Marshal(v)
	t.union = b
	return err
}

// MergeSearchAttributesCode0 performs a merge with any union data inside the SearchAttributes_Code, using the provided SearchAttributesCode0
func (t *SearchAttributes_Code) MergeSearchAttributesCode0(v SearchAttributesCode0) error {
	b, err := json.Marshal(v)
	if err != nil {
		return err
	}

	merged, err := runtime.JSONMerge(t.union, b)
	t.union = merged
	return err
}

func (t SearchAttributes_Code) MarshalJSON() ([]byte, error) {
	b, err := t.union.MarshalJSON()
	return b, err
}

func (t *SearchAttributes_Code) UnmarshalJSON(b []byte) error {
	err := t.union.UnmarshalJSON(b)
	return err
}

// AsSearchFilters returns the union data inside the SearchAttributes_Filters as a SearchFilters
func (t SearchAttributes_Filters) AsSearchFilters() (SearchFilters, error) {
	var body SearchFilters
	err := json.Unmarshal(t.union, &body)
	return body, err
}

// FromSearchFilters overwrites any union data inside the SearchAttributes_Filters as the provided SearchFilters
func (t *SearchAttributes_Filters) FromSearchFilters(v SearchFilters) error {
	b, err := json.Marshal(v)
	t.union = b
	return err
}

// MergeSearchFilters performs a merge with any union data inside the SearchAttributes_Filters, using the provided SearchFilters
func (t *SearchAttributes_Filters) MergeSearchFilters(v SearchFilters) error {
	b, err := json.Marshal(v)
	if err != nil {
		return err
	}

	merged, err := runtime.JSONMerge(t.union, b)
	t.union = merged
	return err
}

func (t SearchAttributes_Filters) MarshalJSON() ([]byte, error) {
	b, err := t.union.MarshalJSON()
	return b, err
}

func (t *SearchAttributes_Filters) UnmarshalJSON(b []byte) error {
	err := t.union.UnmarshalJSON(b)
	return err
}

// AsSearchAttributesKeywords0 returns the union data inside the SearchAttributes_Keywords as a SearchAttributesKeywords0
func (t SearchAttributes_Keywords) AsSearchAttributesKeywords0() (SearchAttributesKeywords0, error) {
	var body SearchAttributesKeywords0
	err := json.Unmarshal(t.union, &body)
	return body, err
}

// FromSearchAttributesKeywords0 overwrites any union data inside the SearchAttributes_Keywords as the provided SearchAttributesKeywords0
func (t *SearchAttributes_Keywords) FromSearchAttributesKeywords0(v SearchAttributesKeywords0) error {
	b, err := json.Marshal(v)
	t.union = b
	return err
}

// MergeSearchAttributesKeywords0 performs a merge with any union data inside the SearchAttributes_Keywords, using the provided SearchAttributesKeywords0
func (t *SearchAttributes_Keywords) MergeSearchAttributesKeywords0(v SearchAttributesKeywords0) error {
	b, err := json.Marshal(v)
	if err != nil {
		return err
	}

	merged, err := runtime.JSONMerge(t.union, b)
	t.union = merged
	return err
}

func (t SearchAttributes_Keywords) MarshalJSON() ([]byte, error) {
	b, err := t.union.MarshalJSON()
	return b, err
}

func (t *SearchAttributes_Keywords) UnmarshalJSON(b []byte) error {
	err := t.union.UnmarshalJSON(b)
	return err
}

// AsSearchAttributesLimit0 returns the union data inside the SearchAttributes_Limit as a SearchAttributesLimit0
func (t SearchAttributes_Limit) AsSearchAttributesLimit0() (SearchAttributesLimit0, error) {
	var body SearchAttributesLimit0
	err := json.Unmarshal(t.union, &body)
	return body, err
}

// FromSearchAttributesLimit0 overwrites any union data inside the SearchAttributes_Limit as the provided SearchAttributesLimit0
func (t *SearchAttributes_Limit) FromSearchAttributesLimit0(v SearchAttributesLimit0) error {
	b, err := json.Marshal(v)
	t.union = b
	return err
}

// MergeSearchAttributesLimit0 performs a merge with any union data inside the SearchAttributes_Limit, using the provided SearchAttributesLimit0
func (t *SearchAttributes_Limit) MergeSearchAttributesLimit0(v SearchAttributesLimit0) error {
	b, err := json.Marshal(v)
	if err != nil {
		return err
	}

	merged, err := runtime.JSONMerge(t.union, b)
	t.union = merged
	return err
}

func (t SearchAttributes_Limit) MarshalJSON() ([]byte, error) {
	b, err := t.union.MarshalJSON()
	return b, err
}

func (t *SearchAttributes_Limit) UnmarshalJSON(b []byte) error {
	err := t.union.UnmarshalJSON(b)
	return err
}

// AsSearchAttributesText0 returns the union data inside the SearchAttributes_Text as a SearchAttributesText0
func (t SearchAttributes_Text) AsSearchAttributesText0() (SearchAttributesText0, error) {
	var body SearchAttributesText0
	err := json.Unmarshal(t.union, &body)
	return body, err
}

// FromSearchAttributesText0 overwrites any union data inside the SearchAttributes_Text as the provided SearchAttributesText0
func (t *SearchAttributes_Text) FromSearchAttributesText0(v SearchAttributesText0) error {
	b, err := json.Marshal(v)
	t.union = b
	return err
}

// MergeSearchAttributesText0 performs a merge with any union data inside the SearchAttributes_Text, using the provided SearchAttributesText0
func (t *SearchAttributes_Text) MergeSearchAttributesText0(v SearchAttributesText0) error {
	b, err := json.Marshal(v)
	if err != nil {
		return err
	}

	merged, err := runtime.JSONMerge(t.union, b)
	t.union = merged
	return err
}

func (t SearchAttributes_Text) MarshalJSON() ([]byte, error) {
	b, err := t.union.MarshalJSON()
	return b, err
}

func (t *SearchAttributes_Text) UnmarshalJSON(b []byte) error {
	err := t.union.UnmarshalJSON(b)
	return err
}

// AsSearchFiltersAuthors0 returns the union data inside the SearchFilters_Authors as a SearchFiltersAuthors0
func (t SearchFilters_Authors) AsSearchFiltersAuthors0() (SearchFiltersAuthors0, error) {
	var body SearchFiltersAuthors0
	err := json.Unmarshal(t.union, &body)
	return body, err
}

// FromSearchFiltersAuthors0 overwrites any union data inside the SearchFilters_Authors as the provided SearchFiltersAuthors0
func (t *SearchFilters_Authors) FromSearchFiltersAuthors0(v SearchFiltersAuthors0) error {
	b, err := json.Marshal(v)
	t.union = b
	return err
}

// MergeSearchFiltersAuthors0 performs a merge with any union data inside the SearchFilters_Authors, using the provided SearchFiltersAuthors0
func (t *SearchFilters_Authors) MergeSearchFiltersAuthors0(v SearchFiltersAuthors0) error {
	b, err := json.Marshal(v)
	if err != nil {
		return err
	}

	merged, err := runtime.JSONMerge(t.union, b)
	t.union = merged
	return err
}

func (t SearchFilters_Authors) MarshalJSON() ([]byte, error) {
	b, err := t.union.MarshalJSON()
	return b, err
}

func (t *SearchFilters_Authors) UnmarshalJSON(b []byte) error {
	err := t.union.UnmarshalJSON(b)
	return err
}

// AsSearchFiltersCommitSha0 returns the union data inside the SearchFilters_CommitSha as a SearchFiltersCommitSha0
func (t SearchFilters_CommitSha) AsSearchFiltersCommitSha0() (SearchFiltersCommitSha0, error) {
	var body SearchFiltersCommitSha0
	err := json.Unmarshal(t.union, &body)
	return body, err
}

// FromSearchFiltersCommitSha0 overwrites any union data inside the SearchFilters_CommitSha as the provided SearchFiltersCommitSha0
func (t *SearchFilters_CommitSha) FromSearchFiltersCommitSha0(v SearchFiltersCommitSha0) error {
	b, err := json.Marshal(v)
	t.union = b
	return err
}

// MergeSearchFiltersCommitSha0 performs a merge with any union data inside the SearchFilters_CommitSha, using the provided SearchFiltersCommitSha0
func (t *SearchFilters_CommitSha) MergeSearchFiltersCommitSha0(v SearchFiltersCommitSha0) error {
	b, err := json.Marshal(v)
	if err != nil {
		return err
	}

	merged, err := runtime.JSONMerge(t.union, b)
	t.union = merged
	return err
}

func (t SearchFilters_CommitSha) MarshalJSON() ([]byte, error) {
	b, err := t.union.MarshalJSON()
	return b, err
}

func (t *SearchFilters_CommitSha) UnmarshalJSON(b []byte) error {
	err := t.union.UnmarshalJSON(b)
	return err
}

// AsSearchFiltersEndDate0 returns the union data inside the SearchFilters_EndDate as a SearchFiltersEndDate0
func (t SearchFilters_EndDate) AsSearchFiltersEndDate0() (SearchFiltersEndDate0, error) {
	var body SearchFiltersEndDate0
	err := json.Unmarshal(t.union, &body)
	return body, err
}

// FromSearchFiltersEndDate0 overwrites any union data inside the SearchFilters_EndDate as the provided SearchFiltersEndDate0
func (t *SearchFilters_EndDate) FromSearchFiltersEndDate0(v SearchFiltersEndDate0) error {
	b, err := json.Marshal(v)
	t.union = b
	return err
}

// MergeSearchFiltersEndDate0 performs a merge with any union data inside the SearchFilters_EndDate, using the provided SearchFiltersEndDate0
func (t *SearchFilters_EndDate) MergeSearchFiltersEndDate0(v SearchFiltersEndDate0) error {
	b, err := json.Marshal(v)
	if err != nil {
		return err
	}

	merged, err := runtime.JSONMerge(t.union, b)
	t.union = merged
	return err
}

func (t SearchFilters_EndDate) MarshalJSON() ([]byte, error) {
	b, err := t.union.MarshalJSON()
	return b, err
}

func (t *SearchFilters_EndDate) UnmarshalJSON(b []byte) error {
	err := t.union.UnmarshalJSON(b)
	return err
}

// AsSearchFiltersEnrichmentSubtypes0 returns the union data inside the SearchFilters_EnrichmentSubtypes as a SearchFiltersEnrichmentSubtypes0
func (t SearchFilters_EnrichmentSubtypes) AsSearchFiltersEnrichmentSubtypes0() (SearchFiltersEnrichmentSubtypes0, error) {
	var body SearchFiltersEnrichmentSubtypes0
	err := json.Unmarshal(t.union, &body)
	return body, err
}

// FromSearchFiltersEnrichmentSubtypes0 overwrites any union data inside the SearchFilters_EnrichmentSubtypes as the provided SearchFiltersEnrichmentSubtypes0
func (t *SearchFilters_EnrichmentSubtypes) FromSearchFiltersEnrichmentSubtypes0(v SearchFiltersEnrichmentSubtypes0) error {
	b, err := json.Marshal(v)
	t.union = b
	return err
}

// MergeSearchFiltersEnrichmentSubtypes0 performs a merge with any union data inside the SearchFilters_EnrichmentSubtypes, using the provided SearchFiltersEnrichmentSubtypes0
func (t *SearchFilters_EnrichmentSubtypes) MergeSearchFiltersEnrichmentSubtypes0(v SearchFiltersEnrichmentSubtypes0) error {
	b, err := json.Marshal(v)
	if err != nil {
		return err
	}

	merged, err := runtime.JSONMerge(t.union, b)
	t.union = merged
	return err
}

func (t SearchFilters_EnrichmentSubtypes) MarshalJSON() ([]byte, error) {
	b, err := t.union.MarshalJSON()
	return b, err
}

func (t *SearchFilters_EnrichmentSubtypes) UnmarshalJSON(b []byte) error {
	err := t.union.UnmarshalJSON(b)
	return err
}

// AsSearchFiltersEnrichmentTypes0 returns the union data inside the SearchFilters_EnrichmentTypes as a SearchFiltersEnrichmentTypes0
func (t SearchFilters_EnrichmentTypes) AsSearchFiltersEnrichmentTypes0() (SearchFiltersEnrichmentTypes0, error) {
	var body SearchFiltersEnrichmentTypes0
	err := json.Unmarshal(t.union, &body)
	return body, err
}

// FromSearchFiltersEnrichmentTypes0 overwrites any union data inside the SearchFilters_EnrichmentTypes as the provided SearchFiltersEnrichmentTypes0
func (t *SearchFilters_EnrichmentTypes) FromSearchFiltersEnrichmentTypes0(v SearchFiltersEnrichmentTypes0) error {
	b, err := json.Marshal(v)
	t.union = b
	return err
}

// MergeSearchFiltersEnrichmentTypes0 performs a merge with any union data inside the SearchFilters_EnrichmentTypes, using the provided SearchFiltersEnrichmentTypes0
func (t *SearchFilters_EnrichmentTypes) MergeSearchFiltersEnrichmentTypes0(v SearchFiltersEnrichmentTypes0) error {
	b, err := json.Marshal(v)
	if err != nil {
		return err
	}

	merged, err := runtime.JSONMerge(t.union, b)
	t.union = merged
	return err
}

func (t SearchFilters_EnrichmentTypes) MarshalJSON() ([]byte, error) {
	b, err := t.union.MarshalJSON()
	return b, err
}

func (t *SearchFilters_EnrichmentTypes) UnmarshalJSON(b []byte) error {
	err := t.union.UnmarshalJSON(b)
	return err
}

// AsSearchFiltersFilePatterns0 returns the union data inside the SearchFilters_FilePatterns as a SearchFiltersFilePatterns0
func (t SearchFilters_FilePatterns) AsSearchFiltersFilePatterns0() (SearchFiltersFilePatterns0, error) {
	var body SearchFiltersFilePatterns0
	err := json.Unmarshal(t.union, &body)
	return body, err
}

// FromSearchFiltersFilePatterns0 overwrites any union data inside the SearchFilters_FilePatterns as the provided SearchFiltersFilePatterns0
func (t *SearchFilters_FilePatterns) FromSearchFiltersFilePatterns0(v SearchFiltersFilePatterns0) error {
	b, err := json.Marshal(v)
	t.union = b
	return err
}

// MergeSearchFiltersFilePatterns0 performs a merge with any union data inside the SearchFilters_FilePatterns, using the provided SearchFiltersFilePatterns0
func (t *SearchFilters_FilePatterns) MergeSearchFiltersFilePatterns0(v SearchFiltersFilePatterns0) error {
	b, err := json.Marshal(v)
	if err != nil {
		return err
	}

	merged, err := runtime.JSONMerge(t.union, b)
	t.union = merged
	return err
}

func (t SearchFilters_FilePatterns) MarshalJSON() ([]byte, error) {
	b, err := t.union.MarshalJSON()
	return b, err
}

func (t *SearchFilters_FilePatterns) UnmarshalJSON(b []byte) error {
	err := t.union.UnmarshalJSON(b)
	return err
}

// AsSearchFiltersLanguages0 returns the union data inside the SearchFilters_Languages as a SearchFiltersLanguages0
func (t SearchFilters_Languages) AsSearchFiltersLanguages0() (SearchFiltersLanguages0, error) {
	var body SearchFiltersLanguages0
	err := json.Unmarshal(t.union, &body)
	return body, err
}

// FromSearchFiltersLanguages0 overwrites any union data inside the SearchFilters_Languages as the provided SearchFiltersLanguages0
func (t *SearchFilters_Languages) FromSearchFiltersLanguages0(v SearchFiltersLanguages0) error {
	b, err := json.Marshal(v)
	t.union = b
	return err
}

// MergeSearchFiltersLanguages0 performs a merge with any union data inside the SearchFilters_Languages, using the provided SearchFiltersLanguages0
func (t *SearchFilters_Languages) MergeSearchFiltersLanguages0(v SearchFiltersLanguages0) error {
	b, err := json.Marshal(v)
	if err != nil {
		return err
	}

	merged, err := runtime.JSONMerge(t.union, b)
	t.union = merged
	return err
}

func (t SearchFilters_Languages) MarshalJSON() ([]byte, error) {
	b, err := t.union.MarshalJSON()
	return b, err
}

func (t *SearchFilters_Languages) UnmarshalJSON(b []byte) error {
	err := t.union.UnmarshalJSON(b)
	return err
}

// AsSearchFiltersSources0 returns the union data inside the SearchFilters_Sources as a SearchFiltersSources0
func (t SearchFilters_Sources) AsSearchFiltersSources0() (SearchFiltersSources0, error) {
	var body SearchFiltersSources0
	err := json.Unmarshal(t.union, &body)
	return body, err
}

// FromSearchFiltersSources0 overwrites any union data inside the SearchFilters_Sources as the provided SearchFiltersSources0
func (t *SearchFilters_Sources) FromSearchFiltersSources0(v SearchFiltersSources0) error {
	b, err := json.Marshal(v)
	t.union = b
	return err
}

// MergeSearchFiltersSources0 performs a merge with any union data inside the SearchFilters_Sources, using the provided SearchFiltersSources0
func (t *SearchFilters_Sources) MergeSearchFiltersSources0(v SearchFiltersSources0) error {
	b, err := json.Marshal(v)
	if err != nil {
		return err
	}

	merged, err := runtime.JSONMerge(t.union, b)
	t.union = merged
	return err
}

func (t SearchFilters_Sources) MarshalJSON() ([]byte, error) {
	b, err := t.union.MarshalJSON()
	return b, err
}

func (t *SearchFilters_Sources) UnmarshalJSON(b []byte) error {
	err := t.union.UnmarshalJSON(b)
	return err
}

// AsSearchFiltersStartDate0 returns the union data inside the SearchFilters_StartDate as a SearchFiltersStartDate0
func (t SearchFilters_StartDate) AsSearchFiltersStartDate0() (SearchFiltersStartDate0, error) {
	var body SearchFiltersStartDate0
	err := json.Unmarshal(t.union, &body)
	return body, err
}

// FromSearchFiltersStartDate0 overwrites any union data inside the SearchFilters_StartDate as the provided SearchFiltersStartDate0
func (t *SearchFilters_StartDate) FromSearchFiltersStartDate0(v SearchFiltersStartDate0) error {
	b, err := json.Marshal(v)
	t.union = b
	return err
}

// MergeSearchFiltersStartDate0 performs a merge with any union data inside the SearchFilters_StartDate, using the provided SearchFiltersStartDate0
func (t *SearchFilters_StartDate) MergeSearchFiltersStartDate0(v SearchFiltersStartDate0) error {
	b, err := json.Marshal(v)
	if err != nil {
		return err
	}

	merged, err := runtime.JSONMerge(t.union, b)
	t.union = merged
	return err
}

func (t SearchFilters_StartDate) MarshalJSON() ([]byte, error) {
	b, err := t.union.MarshalJSON()
	return b, err
}

func (t *SearchFilters_StartDate) UnmarshalJSON(b []byte) error {
	err := t.union.UnmarshalJSON(b)
	return err
}

// AsSnippetAttributesCreatedAt0 returns the union data inside the SnippetAttributes_CreatedAt as a SnippetAttributesCreatedAt0
func (t SnippetAttributes_CreatedAt) AsSnippetAttributesCreatedAt0() (SnippetAttributesCreatedAt0, error) {
	var body SnippetAttributesCreatedAt0
	err := json.Unmarshal(t.union, &body)
	return body, err
}

// FromSnippetAttributesCreatedAt0 overwrites any union data inside the SnippetAttributes_CreatedAt as the provided SnippetAttributesCreatedAt0
func (t *SnippetAttributes_CreatedAt) FromSnippetAttributesCreatedAt0(v SnippetAttributesCreatedAt0) error {
	b, err := json.Marshal(v)
	t.union = b
	return err
}

// MergeSnippetAttributesCreatedAt0 performs a merge with any union data inside the SnippetAttributes_CreatedAt, using the provided SnippetAttributesCreatedAt0
func (t *SnippetAttributes_CreatedAt) MergeSnippetAttributesCreatedAt0(v SnippetAttributesCreatedAt0) error {
	b, err := json.Marshal(v)
	if err != nil {
		return err
	}

	merged, err := runtime.JSONMerge(t.union, b)
	t.union = merged
	return err
}

func (t SnippetAttributes_CreatedAt) MarshalJSON() ([]byte, error) {
	b, err := t.union.MarshalJSON()
	return b, err
}

func (t *SnippetAttributes_CreatedAt) UnmarshalJSON(b []byte) error {
	err := t.union.UnmarshalJSON(b)
	return err
}

// AsSnippetAttributesUpdatedAt0 returns the union data inside the SnippetAttributes_UpdatedAt as a SnippetAttributesUpdatedAt0
func (t SnippetAttributes_UpdatedAt) AsSnippetAttributesUpdatedAt0() (SnippetAttributesUpdatedAt0, error) {
	var body SnippetAttributesUpdatedAt0
	err := json.Unmarshal(t.union, &body)
	return body, err
}

// FromSnippetAttributesUpdatedAt0 overwrites any union data inside the SnippetAttributes_UpdatedAt as the provided SnippetAttributesUpdatedAt0
func (t *SnippetAttributes_UpdatedAt) FromSnippetAttributesUpdatedAt0(v SnippetAttributesUpdatedAt0) error {
	b, err := json.Marshal(v)
	t.union = b
	return err
}

// MergeSnippetAttributesUpdatedAt0 performs a merge with any union data inside the SnippetAttributes_UpdatedAt, using the provided SnippetAttributesUpdatedAt0
func (t *SnippetAttributes_UpdatedAt) MergeSnippetAttributesUpdatedAt0(v SnippetAttributesUpdatedAt0) error {
	b, err := json.Marshal(v)
	if err != nil {
		return err
	}

	merged, err := runtime.JSONMerge(t.union, b)
	t.union = merged
	return err
}

func (t SnippetAttributes_UpdatedAt) MarshalJSON() ([]byte, error) {
	b, err := t.union.MarshalJSON()
	return b, err
}

func (t *SnippetAttributes_UpdatedAt) UnmarshalJSON(b []byte) error {
	err := t.union.UnmarshalJSON(b)
	return err
}

// AsTaskAttributesCreatedAt0 returns the union data inside the TaskAttributes_CreatedAt as a TaskAttributesCreatedAt0
func (t TaskAttributes_CreatedAt) AsTaskAttributesCreatedAt0() (TaskAttributesCreatedAt0, error) {
	var body TaskAttributesCreatedAt0
	err := json.Unmarshal(t.union, &body)
	return body, err
}

// FromTaskAttributesCreatedAt0 overwrites any union data inside the TaskAttributes_CreatedAt as the provided TaskAttributesCreatedAt0
func (t *TaskAttributes_CreatedAt) FromTaskAttributesCreatedAt0(v TaskAttributesCreatedAt0) error {
	b, err := json.Marshal(v)
	t.union = b
	return err
}

// MergeTaskAttributesCreatedAt0 performs a merge with any union data inside the TaskAttributes_CreatedAt, using the provided TaskAttributesCreatedAt0
func (t *TaskAttributes_CreatedAt) MergeTaskAttributesCreatedAt0(v TaskAttributesCreatedAt0) error {
	b, err := json.Marshal(v)
	if err != nil {
		return err
	}

	merged, err := runtime.JSONMerge(t.union, b)
	t.union = merged
	return err
}

func (t TaskAttributes_CreatedAt) MarshalJSON() ([]byte, error) {
	b, err := t.union.MarshalJSON()
	return b, err
}

func (t *TaskAttributes_CreatedAt) UnmarshalJSON(b []byte) error {
	err := t.union.UnmarshalJSON(b)
	return err
}

// AsTaskAttributesUpdatedAt0 returns the union data inside the TaskAttributes_UpdatedAt as a TaskAttributesUpdatedAt0
func (t TaskAttributes_UpdatedAt) AsTaskAttributesUpdatedAt0() (TaskAttributesUpdatedAt0, error) {
	var body TaskAttributesUpdatedAt0
	err := json.Unmarshal(t.union, &body)
	return body, err
}

// FromTaskAttributesUpdatedAt0 overwrites any union data inside the TaskAttributes_UpdatedAt as the provided TaskAttributesUpdatedAt0
func (t *TaskAttributes_UpdatedAt) FromTaskAttributesUpdatedAt0(v TaskAttributesUpdatedAt0) error {
	b, err := json.Marshal(v)
	t.union = b
	return err
}

// MergeTaskAttributesUpdatedAt0 performs a merge with any union data inside the TaskAttributes_UpdatedAt, using the provided TaskAttributesUpdatedAt0
func (t *TaskAttributes_UpdatedAt) MergeTaskAttributesUpdatedAt0(v TaskAttributesUpdatedAt0) error {
	b, err := json.Marshal(v)
	if err != nil {
		return err
	}

	merged, err := runtime.JSONMerge(t.union, b)
	t.union = merged
	return err
}

func (t TaskAttributes_UpdatedAt) MarshalJSON() ([]byte, error) {
	b, err := t.union.MarshalJSON()
	return b, err
}

func (t *TaskAttributes_UpdatedAt) UnmarshalJSON(b []byte) error {
	err := t.union.UnmarshalJSON(b)
	return err
}

// AsTaskStatusAttributesCreatedAt0 returns the union data inside the TaskStatusAttributes_CreatedAt as a TaskStatusAttributesCreatedAt0
func (t TaskStatusAttributes_CreatedAt) AsTaskStatusAttributesCreatedAt0() (TaskStatusAttributesCreatedAt0, error) {
	var body TaskStatusAttributesCreatedAt0
	err := json.Unmarshal(t.union, &body)
	return body, err
}

// FromTaskStatusAttributesCreatedAt0 overwrites any union data inside the TaskStatusAttributes_CreatedAt as the provided TaskStatusAttributesCreatedAt0
func (t *TaskStatusAttributes_CreatedAt) FromTaskStatusAttributesCreatedAt0(v TaskStatusAttributesCreatedAt0) error {
	b, err := json.Marshal(v)
	t.union = b
	return err
}

// MergeTaskStatusAttributesCreatedAt0 performs a merge with any union data inside the TaskStatusAttributes_CreatedAt, using the provided TaskStatusAttributesCreatedAt0
func (t *TaskStatusAttributes_CreatedAt) MergeTaskStatusAttributesCreatedAt0(v TaskStatusAttributesCreatedAt0) error {
	b, err := json.Marshal(v)
	if err != nil {
		return err
	}

	merged, err := runtime.JSONMerge(t.union, b)
	t.union = merged
	return err
}

func (t TaskStatusAttributes_CreatedAt) MarshalJSON() ([]byte, error) {
	b, err := t.union.MarshalJSON()
	return b, err
}

func (t *TaskStatusAttributes_CreatedAt) UnmarshalJSON(b []byte) error {
	err := t.union.UnmarshalJSON(b)
	return err
}

// AsTaskStatusAttributesUpdatedAt0 returns the union data inside the TaskStatusAttributes_UpdatedAt as a TaskStatusAttributesUpdatedAt0
func (t TaskStatusAttributes_UpdatedAt) AsTaskStatusAttributesUpdatedAt0() (TaskStatusAttributesUpdatedAt0, error) {
	var body TaskStatusAttributesUpdatedAt0
	err := json.Unmarshal(t.union, &body)
	return body, err
}

// FromTaskStatusAttributesUpdatedAt0 overwrites any union data inside the TaskStatusAttributes_UpdatedAt as the provided TaskStatusAttributesUpdatedAt0
func (t *TaskStatusAttributes_UpdatedAt) FromTaskStatusAttributesUpdatedAt0(v TaskStatusAttributesUpdatedAt0) error {
	b, err := json.Marshal(v)
	t.union = b
	return err
}

// MergeTaskStatusAttributesUpdatedAt0 performs a merge with any union data inside the TaskStatusAttributes_UpdatedAt, using the provided TaskStatusAttributesUpdatedAt0
func (t *TaskStatusAttributes_UpdatedAt) MergeTaskStatusAttributesUpdatedAt0(v TaskStatusAttributesUpdatedAt0) error {
	b, err := json.Marshal(v)
	if err != nil {
		return err
	}

	merged, err := runtime.JSONMerge(t.union, b)
	t.union = merged
	return err
}

func (t TaskStatusAttributes_UpdatedAt) MarshalJSON() ([]byte, error) {
	b, err := t.union.MarshalJSON()
	return b, err
}

func (t *TaskStatusAttributes_UpdatedAt) UnmarshalJSON(b []byte) error {
	err := t.union.UnmarshalJSON(b)
	return err
}

// AsTrackingConfigAttributesValue0 returns the union data inside the TrackingConfigAttributes_Value as a TrackingConfigAttributesValue0
func (t TrackingConfigAttributes_Value) AsTrackingConfigAttributesValue0() (TrackingConfigAttributesValue0, error) {
	var body TrackingConfigAttributesValue0
	err := json.Unmarshal(t.union, &body)
	return body, err
}

// FromTrackingConfigAttributesValue0 overwrites any union data inside the TrackingConfigAttributes_Value as the provided TrackingConfigAttributesValue0
func (t *TrackingConfigAttributes_Value) FromTrackingConfigAttributesValue0(v TrackingConfigAttributesValue0) error {
	b, err := json.Marshal(v)
	t.union = b
	return err
}

// MergeTrackingConfigAttributesValue0 performs a merge with any union data inside the TrackingConfigAttributes_Value, using the provided TrackingConfigAttributesValue0
func (t *TrackingConfigAttributes_Value) MergeTrackingConfigAttributesValue0(v TrackingConfigAttributesValue0) error {
	b, err := json.Marshal(v)
	if err != nil {
		return err
	}

	merged, err := runtime.JSONMerge(t.union, b)
	t.union = merged
	return err
}

func (t TrackingConfigAttributes_Value) MarshalJSON() ([]byte, error) {
	b, err := t.union.MarshalJSON()
	return b, err
}

func (t *TrackingConfigAttributes_Value) UnmarshalJSON(b []byte) error {
	err := t.union.UnmarshalJSON(b)
	return err
}

// AsTrackingConfigUpdateAttributesValue0 returns the union data inside the TrackingConfigUpdateAttributes_Value as a TrackingConfigUpdateAttributesValue0
func (t TrackingConfigUpdateAttributes_Value) AsTrackingConfigUpdateAttributesValue0() (TrackingConfigUpdateAttributesValue0, error) {
	var body TrackingConfigUpdateAttributesValue0
	err := json.Unmarshal(t.union, &body)
	return body, err
}

// FromTrackingConfigUpdateAttributesValue0 overwrites any union data inside the TrackingConfigUpdateAttributes_Value as the provided TrackingConfigUpdateAttributesValue0
func (t *TrackingConfigUpdateAttributes_Value) FromTrackingConfigUpdateAttributesValue0(v TrackingConfigUpdateAttributesValue0) error {
	b, err := json.Marshal(v)
	t.union = b
	return err
}

// MergeTrackingConfigUpdateAttributesValue0 performs a merge with any union data inside the TrackingConfigUpdateAttributes_Value, using the provided TrackingConfigUpdateAttributesValue0
func (t *TrackingConfigUpdateAttributes_Value) MergeTrackingConfigUpdateAttributesValue0(v TrackingConfigUpdateAttributesValue0) error {
	b, err := json.Marshal(v)
	if err != nil {
		return err
	}

	merged, err := runtime.JSONMerge(t.union, b)
	t.union = merged
	return err
}

func (t TrackingConfigUpdateAttributes_Value) MarshalJSON() ([]byte, error) {
	b, err := t.union.MarshalJSON()
	return b, err
}

func (t *TrackingConfigUpdateAttributes_Value) UnmarshalJSON(b []byte) error {
	err := t.union.UnmarshalJSON(b)
	return err
}

// AsValidationErrorLoc0 returns the union data inside the ValidationError_Loc_Item as a ValidationErrorLoc0
func (t ValidationError_Loc_Item) AsValidationErrorLoc0() (ValidationErrorLoc0, error) {
	var body ValidationErrorLoc0
	err := json.Unmarshal(t.union, &body)
	return body, err
}

// FromValidationErrorLoc0 overwrites any union data inside the ValidationError_Loc_Item as the provided ValidationErrorLoc0
func (t *ValidationError_Loc_Item) FromValidationErrorLoc0(v ValidationErrorLoc0) error {
	b, err := json.Marshal(v)
	t.union = b
	return err
}

// MergeValidationErrorLoc0 performs a merge with any union data inside the ValidationError_Loc_Item, using the provided ValidationErrorLoc0
func (t *ValidationError_Loc_Item) MergeValidationErrorLoc0(v ValidationErrorLoc0) error {
	b, err := json.Marshal(v)
	if err != nil {
		return err
	}

	merged, err := runtime.JSONMerge(t.union, b)
	t.union = merged
	return err
}

// AsValidationErrorLoc1 returns the union data inside the ValidationError_Loc_Item as a ValidationErrorLoc1
func (t ValidationError_Loc_Item) AsValidationErrorLoc1() (ValidationErrorLoc1, error) {
	var body ValidationErrorLoc1
	err := json.Unmarshal(t.union, &body)
	return body, err
}

// FromValidationErrorLoc1 overwrites any union data inside the ValidationError_Loc_Item as the provided ValidationErrorLoc1
func (t *ValidationError_Loc_Item) FromValidationErrorLoc1(v ValidationErrorLoc1) error {
	b, err := json.Marshal(v)
	t.union = b
	return err
}

// MergeValidationErrorLoc1 performs a merge with any union data inside the ValidationError_Loc_Item, using the provided ValidationErrorLoc1
func (t *ValidationError_Loc_Item) MergeValidationErrorLoc1(v ValidationErrorLoc1) error {
	b, err := json.Marshal(v)
	if err != nil {
		return err
	}

	merged, err := runtime.JSONMerge(t.union, b)
	t.union = merged
	return err
}

func (t ValidationError_Loc_Item) MarshalJSON() ([]byte, error) {
	b, err := t.union.MarshalJSON()
	return b, err
}

func (t *ValidationError_Loc_Item) UnmarshalJSON(b []byte) error {
	err := t.union.UnmarshalJSON(b)
	return err
}
