// Package academy 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 academy

import (
	"time"

	core "github.com/meshery/schemas/models/core"
	invitationv1beta3 "github.com/meshery/schemas/models/v1beta3/invitation"
	openapi_types "github.com/oapi-codegen/runtime/types"
	"github.com/gofrs/uuid"
)

// Defines values for AcademyRegistrationStatus.
const (
	Completed  AcademyRegistrationStatus = "completed"
	Failed     AcademyRegistrationStatus = "failed"
	Registered AcademyRegistrationStatus = "registered"
	Withdrawn  AcademyRegistrationStatus = "withdrawn"
)

// Defines values for ContentType.
const (
	Certification ContentType = "certification"
	Challenge     ContentType = "challenge"
	LearningPath  ContentType = "learning-path"
)

// Defines values for Level.
const (
	Advanced     Level = "advanced"
	Beginner     Level = "beginner"
	Intermediate Level = "intermediate"
)

// Defines values for QuestionType.
const (
	QuestionTypeEssay           QuestionType = "essay"
	QuestionTypeMultipleAnswers QuestionType = "multiple-answers"
	QuestionTypeShortAnswer     QuestionType = "short-answer"
	QuestionTypeSingleAnswer    QuestionType = "single-answer"
)

// Defines values for Status.
const (
	Archived Status = "archived"
	NotReady Status = "not_ready"
	Ready    Status = "ready"
)

// Defines values for TestSubmissionStatus.
const (
	TestSubmissionStatusFailed       TestSubmissionStatus = "failed"
	TestSubmissionStatusNotAttempted TestSubmissionStatus = "not-attempted"
	TestSubmissionStatusPassed       TestSubmissionStatus = "passed"
)

// Defines values for Visibility.
const (
	Private Visibility = "private"
	Public  Visibility = "public"
)

// AcademyCurricula AcademyCurricula entity schema.
type AcademyCurricula struct {
	// BadgeId ID of the badge to be awarded on completion of this curricula
	BadgeId *core.Uuid `db:"badge_id" json:"badgeId" yaml:"badgeId"`

	// CreatedAt When the Curricula item was created
	CreatedAt AcademyCurriculaCreatedAt `db:"created_at" json:"createdAt" yaml:"createdAt"`
	DeletedAt AcademyCurriculaDeletedAt `db:"deleted_at" json:"deletedAt" yaml:"deletedAt"`

	// ID Id of the Curricula
	ID uuid.UUID `db:"id" json:"id" yaml:"id"`

	// InviteId ID of the invite associated with this Curricula
	InviteId *AcademyCurriculaInviteId `db:"invite_id" json:"inviteId" yaml:"inviteId"`
	Level    Level                     `db:"level" json:"level" yaml:"level"`

	// Metadata Additional metadata about the Curricula
	Metadata AcademyCurriculaMetadata `db:"metadata" json:"metadata" yaml:"metadata"`

	// OrgId Organization ID that owns this learning path
	OrgId AcademyCurriculaOrgId `db:"org_id" json:"orgId" yaml:"orgId"`

	// Slug slug of the Curricula
	Slug   string      `json:"slug" yaml:"slug"`
	Status Status      `db:"status" json:"status" yaml:"status"`
	Type   ContentType `db:"type" json:"type" yaml:"type"`

	// UpdatedAt When the Curricula was last updated
	UpdatedAt  AcademyCurriculaUpdatedAt `db:"updated_at" json:"updatedAt" yaml:"updatedAt"`
	Visibility Visibility                `db:"visibility" json:"visibility" yaml:"visibility"`

	// WorkspaceId ID of the workspace to which this Curricula belongs
	WorkspaceId *AcademyCurriculaWorkspaceId `db:"workspace_id" json:"workspaceId" yaml:"workspaceId"`
}

// AcademyCurriculaAccessExpiresAt defines model for AcademyCurriculaAccessExpiresAt.
type AcademyCurriculaAccessExpiresAt = core.Time

// AcademyCurriculaCreatedAt defines model for AcademyCurriculaCreatedAt.
type AcademyCurriculaCreatedAt = core.Time

// AcademyCurriculaDeletedAt Timestamp when the resource was deleted.
type AcademyCurriculaDeletedAt = core.DeletedAt

// AcademyCurriculaInviteId A Universally Unique Identifier used to uniquely identify entities in Meshery. The UUID core definition is used across different schemas.
type AcademyCurriculaInviteId = core.Uuid

// AcademyCurriculaListResponse defines model for AcademyCurriculaListResponse.
type AcademyCurriculaListResponse struct {
	// Data The data of the academycurriculalistresponse.
	Data []AcademyCurricula `json:"data" yaml:"data"`

	// Total Total number of Curricula
	Total int `json:"total" yaml:"total"`
}

// AcademyCurriculaMetadata Additional metadata about the Curricula
type AcademyCurriculaMetadata = core.Map

// AcademyCurriculaOrgId Organization ID that owns this learning path
type AcademyCurriculaOrgId = string

// AcademyCurriculaUpdatedAt defines model for AcademyCurriculaUpdatedAt.
type AcademyCurriculaUpdatedAt = core.Time

// AcademyCurriculaWithMetrics defines model for AcademyCurriculaWithMetrics.
type AcademyCurriculaWithMetrics struct {
	// BadgeId ID of the badge to be awarded on completion of this curricula
	BadgeId *core.Uuid `db:"badge_id" json:"badgeId" yaml:"badgeId"`

	// CreatedAt When the Curricula item was created
	CreatedAt AcademyCurriculaCreatedAt `db:"created_at" json:"createdAt" yaml:"createdAt"`
	DeletedAt AcademyCurriculaDeletedAt `db:"deleted_at" json:"deletedAt" yaml:"deletedAt"`

	// ID Id of the Curricula
	ID uuid.UUID `db:"id" json:"id" yaml:"id"`

	// InviteId ID of the invite associated with this Curricula
	InviteId *AcademyCurriculaInviteId `db:"invite_id" json:"inviteId" yaml:"inviteId"`
	Level    Level                     `db:"level" json:"level" yaml:"level"`

	// Metadata Additional metadata about the Curricula
	Metadata AcademyCurriculaMetadata `db:"metadata" json:"metadata" yaml:"metadata"`

	// OrgId Organization ID that owns this learning path
	OrgId AcademyCurriculaOrgId `db:"org_id" json:"orgId" yaml:"orgId"`

	// RegistrationCount Number of registrations associated with this curriculum.
	RegistrationCount float32 `db:"registration_count,omitempty" json:"registrationCount,omitempty" yaml:"registrationCount,omitempty"`

	// Slug slug of the Curricula
	Slug   string      `json:"slug" yaml:"slug"`
	Status Status      `db:"status" json:"status" yaml:"status"`
	Type   ContentType `db:"type" json:"type" yaml:"type"`

	// UpdatedAt When the Curricula was last updated
	UpdatedAt  AcademyCurriculaUpdatedAt `db:"updated_at" json:"updatedAt" yaml:"updatedAt"`
	Visibility Visibility                `db:"visibility" json:"visibility" yaml:"visibility"`

	// WorkspaceId ID of the workspace to which this Curricula belongs
	WorkspaceId *AcademyCurriculaWorkspaceId `db:"workspace_id" json:"workspaceId" yaml:"workspaceId"`
}

// AcademyCurriculaWithMetricsListResponse defines model for AcademyCurriculaWithMetricsListResponse.
type AcademyCurriculaWithMetricsListResponse struct {
	// Data The data of the academycurriculawithmetricslistresponse.
	Data []AcademyCurriculaWithMetrics `json:"data" yaml:"data"`

	// Total Total number of Curricula
	Total int `json:"total" yaml:"total"`
}

// AcademyCurriculaWorkspaceId A Universally Unique Identifier used to uniquely identify entities in Meshery. The UUID core definition is used across different schemas.
type AcademyCurriculaWorkspaceId = core.Uuid

// AcademyRegistration defines model for AcademyRegistration.
type AcademyRegistration struct {
	Certificate core.Map `db:"certificate" json:"certificate" yaml:"certificate"`

	// ContentId ID of the course content
	ContentId uuid.UUID `db:"content_id" json:"contentId" yaml:"contentId"`
	CreatedAt core.Time  `db:"created_at" json:"createdAt" yaml:"createdAt"`

	// DeletedAt Timestamp when the resource was deleted.
	DeletedAt core.NullTime `db:"deleted_at" json:"deletedAt,omitempty" yaml:"deletedAt,omitempty"`

	// Id A Universally Unique Identifier used to uniquely identify entities in Meshery. The UUID core definition is used across different schemas.
	ID core.Uuid `db:"id" json:"id" yaml:"id"`

	// Metadata Additional metadata about the registration
	Metadata core.Map `db:"metadata" json:"metadata" yaml:"metadata"`

	// OrgId A Universally Unique Identifier used to uniquely identify entities in Meshery. The UUID core definition is used across different schemas.
	OrgId core.Uuid `db:"org_id" json:"orgId" yaml:"orgId"`

	// Status Status of the user's course registration
	Status    AcademyRegistrationStatus `db:"status" json:"status" yaml:"status"`
	UpdatedAt core.Time         `db:"updated_at" json:"updatedAt" yaml:"updatedAt"`

	// UserId A Universally Unique Identifier used to uniquely identify entities in Meshery. The UUID core definition is used across different schemas.
	UserId core.Uuid `db:"owner" json:"userId" yaml:"userId"`
}

// AcademyRegistrationStatus Status of the user's course registration
type AcademyRegistrationStatus string

// AcademyRegistrationsListResponse defines model for AcademyRegistrationsListResponse.
type AcademyRegistrationsListResponse struct {
	// Data The data of the academyregistrationslistresponse.
	Data []AcademyRegistration `json:"data" yaml:"data"`

	// Total Total number of learning paths
	Total int `json:"total" yaml:"total"`
}

// AllTestSubmissionsForCurricula Test submissions made by the user (map of test IDs to Submissions)
type AllTestSubmissionsForCurricula map[string]TestSubmissions

// Certificate defines model for Certificate.
type Certificate struct {
	// Description Description of the certificate
	Description string `json:"description" yaml:"description"`

	// ExpirationDate Date when the certificate expires. Dynamically calculated from issued_date and expires_in; not specified by instructors.
	ExpirationDate *time.Time `json:"expirationDate,omitempty" yaml:"expirationDate,omitempty"`

	// ExpiresIn Number of months after which the certificate expires
	ExpiresIn *int `json:"expiresIn,omitempty" yaml:"expiresIn,omitempty"`

	// ID Unique identifier for the certificate
	ID uuid.UUID `json:"id" yaml:"id"`

	// IssuedDate Date when the certificate was issued
	IssuedDate time.Time `json:"issuedDate" yaml:"issuedDate"`

	// IssuingAuthorities List of issuing authorities for the certificate
	IssuingAuthorities []CertificateIssuingAuthority `json:"issuingAuthorities" yaml:"issuingAuthorities"`

	// OrgId A Universally Unique Identifier used to uniquely identify entities in Meshery. The UUID core definition is used across different schemas.
	OrgId core.Uuid `json:"orgId" yaml:"orgId"`

	// RecipientId ID of the recipient (user) who received the certificate
	RecipientId uuid.UUID `json:"recipientId" yaml:"recipientId"`

	// RecipientName Name of the recipient (user) who received the certificate
	RecipientName string `json:"recipientName" yaml:"recipientName"`

	// Title Title of the certificate
	Title string `json:"title" yaml:"title"`
}

// CertificateIssuingAuthority defines model for CertificateIssuingAuthority.
type CertificateIssuingAuthority struct {
	// Name Name of the issuing authority
	Name string `json:"name" yaml:"name"`

	// Role Role of the issuing authority
	Role *string `json:"role,omitempty" yaml:"role,omitempty"`

	// SignatureUrl URL to the signature image of the issuing authority should be a publicly accessible URL and transparent PNG or SVG format
	SignatureUrl *string `json:"signatureUrl,omitempty" yaml:"signatureUrl,omitempty"`
}

// ChallengeMetadata defines model for ChallengeMetadata.
type ChallengeMetadata = CurriculaMetadata

// ChildNode defines model for ChildNode.
type ChildNode struct {
	// Banner Filename of the banner image, which should be placed in the same directory as the _index.md file
	Banner *string `json:"banner" yaml:"banner"`

	// Children List of child nodes (sub-courses or modules)
	Children *[]ChildNode `json:"children,omitempty" yaml:"children,omitempty"`

	// Description Course description
	Description string `json:"description" yaml:"description"`

	// ID Unique identifier for the course
	ID uuid.UUID `db:"id" json:"id" yaml:"id"`

	// Permalink URL to the course content
	Permalink string `json:"permalink" yaml:"permalink"`

	// Title Title of the course
	Title string       `json:"title" yaml:"title"`
	Type  *ContentType `json:"type,omitempty" yaml:"type,omitempty"`

	// Weight A numeric value to determine the display order. A smaller number appears first. If not specified, items will be sorted alphabetically by title.
	Weight *float32 `json:"weight,omitempty" yaml:"weight,omitempty"`
}

// ContentType defines model for ContentType.
type ContentType string

// CreateAcademyCurriculaRequest defines model for CreateAcademyCurriculaRequest.
type CreateAcademyCurriculaRequest struct {
	// AccessExpiresAt Expiry time for curricula access
	AccessExpiresAt AcademyCurriculaAccessExpiresAt `db:"access_expires_at" json:"accessExpiresAt" yaml:"accessExpiresAt"`

	// AccessStatus Status of the invitation, where enabled means the invitation is active and can be used, disabled means the invitation is no longer valid and is temporarily inactive. Disabled invitations can be re-enabled later.
	AccessStatus invitationv1beta3.InvitationStatus `db:"access_status" json:"accessStatus" yaml:"accessStatus"`

	// BadgeId ID of the badge to be awarded on completion of this curricula
	BadgeId *core.Uuid `db:"badge_id" json:"badgeId" yaml:"badgeId"`

	// Metadata Additional metadata about the Curricula
	Metadata AcademyCurriculaMetadata `db:"metadata" json:"metadata" yaml:"metadata"`

	// OrgId Organization ID that owns this learning path
	OrgId AcademyCurriculaOrgId `db:"org_id" json:"orgId" yaml:"orgId"`

	// TeamId A Universally Unique Identifier used to uniquely identify entities in Meshery. The UUID core definition is used across different schemas.
	TeamId core.Uuid `db:"team_id" json:"teamId" yaml:"teamId"`

	// Title Title of the curricula
	Title string      `json:"title" yaml:"title"`
	Type  ContentType `json:"type" yaml:"type"`

	// WorkspaceId ID of the workspace to which this Curricula belongs
	WorkspaceId AcademyCurriculaWorkspaceId `db:"workspace_id" json:"workspaceId" yaml:"workspaceId"`
}

// CurriculaCurrentItemData defines model for CurriculaCurrentItemData.
type CurriculaCurrentItemData struct {
	ContentType ContentType `json:"contentType" yaml:"contentType"`

	// Id CurriculaCurrentItemData ID. Identifies the Hugo content page the learner currently has open, not a database row, so it is an opaque content-scoped string. Not a UUID - production values include slugs, full permalink URLs and the empty string.
	ID string `json:"id" yaml:"id"`

	// LastOpened The last opened of the curriculacurrentitemdata.
	LastOpened time.Time `json:"lastOpened" yaml:"lastOpened"`
}

// CurriculaMetadata defines model for CurriculaMetadata.
type CurriculaMetadata struct {
	// Banner Filename of the banner image, which should be placed in the same directory as the _index.md file
	Banner      *string      `json:"banner" yaml:"banner"`
	Certificate *Certificate `json:"certificate,omitempty" yaml:"certificate,omitempty"`

	// Children List of children items in the top-level curricula
	Children *[]ChildNode `json:"children,omitempty" yaml:"children,omitempty"`

	// Description Short description of the curricula
	Description string `json:"description" yaml:"description"`

	// DetailedDescription Detailed description of the curricula
	DetailedDescription *string `json:"detailedDescription,omitempty" yaml:"detailedDescription,omitempty"`

	// Permalink Canonical URL for the learning path
	Permalink string `json:"permalink" yaml:"permalink"`

	// Title Title of the learning path
	Title string `json:"title" yaml:"title"`
}

// CurriculaProgressTracker defines model for CurriculaProgressTracker.
type CurriculaProgressTracker struct {
	// Completed The completed of the curriculaprogresstracker.
	Completed core.NullTime `json:"completed" yaml:"completed"`

	// CompletedItems Items that have been completed (map of item IDs to item data)
	CompletedItems map[string]ProgressItemCompleted `json:"completedItems" yaml:"completedItems"`

	// CurrentItem The current item of the curriculaprogresstracker.
	CurrentItem map[string]CurriculaCurrentItemData `json:"currentItem" yaml:"currentItem"`

	// Grades The grades of the curriculaprogresstracker.
	Grades map[string]QuizEvaluationResult `json:"grades" yaml:"grades"`

	// TimeSpent Total time spent in seconds
	TimeSpent int `json:"timeSpent" yaml:"timeSpent"`
}

// CurriculaRegistrationsFilter defines model for CurriculaRegistrationsFilter.
type CurriculaRegistrationsFilter struct {
	// ContentType The content type of the curricularegistrationsfilter.
	ContentType []string `json:"contentType" yaml:"contentType"`

	// Page Current page number of the result set.
	Page int `json:"page" yaml:"page"`

	// PageSize The pageSize of the curricularegistrationsfilter.
	PageSize int `json:"pageSize" yaml:"pageSize"`

	// Status Current status of the resource.
	Status []string `json:"status" yaml:"status"`
}

// CurriculaRegistrationsResponse defines model for CurriculaRegistrationsResponse.
type CurriculaRegistrationsResponse struct {
	// Data The data of the curricularegistrationsresponse.
	Data []UserRegistration `json:"data" yaml:"data"`

	// Page Current page number of the result set.
	Page int `json:"page" yaml:"page"`

	// PageSize Number of items per page.
	PageSize int `json:"pageSize" yaml:"pageSize"`

	// TotalCount Total number of items available.
	TotalCount int64 `json:"totalCount" yaml:"totalCount"`
}

// ErrorResponse defines model for ErrorResponse.
type ErrorResponse struct {
	// Details The details of the errorresponse.
	Details *string `json:"details,omitempty" yaml:"details,omitempty"`

	// Error The error of the errorresponse.
	Error *string `json:"error,omitempty" yaml:"error,omitempty"`
}

// InstructorConsoleSummary Aggregate metrics for the instructor console, mirroring the deployed handler's InstructorConsoleSummary struct.
type InstructorConsoleSummary struct {
	// Curricula Per-content-type registration counts.
	Curricula *[]struct {
		// TotalCount Registrations for this content type.
		TotalCount *int `json:"totalCount,omitempty" yaml:"totalCount,omitempty"`

		// Type Academy content type.
		Type *string `json:"type,omitempty" yaml:"type,omitempty"`
	} `json:"curricula,omitempty" yaml:"curricula,omitempty"`
	CurriculaList *AcademyCurriculaWithMetricsListResponse `json:"curriculaList,omitempty" yaml:"curriculaList,omitempty"`

	// OrgConfig Academy module configuration for the organization.
	OrgConfig *struct {
		// Module Academy module assigned to the organization.
		Module *string `json:"module,omitempty" yaml:"module,omitempty"`

		// Version Version of the assigned academy module.
		Version *string `json:"version,omitempty" yaml:"version,omitempty"`
	} `json:"orgConfig,omitempty" yaml:"orgConfig,omitempty"`

	// RegistrationsSummary Per-status registration counts.
	RegistrationsSummary *[]struct {
		// Status Registration status.
		Status *string `json:"status,omitempty" yaml:"status,omitempty"`

		// TotalCount Registrations in this status.
		TotalCount *int `json:"totalCount,omitempty" yaml:"totalCount,omitempty"`
	} `json:"registrationsSummary,omitempty" yaml:"registrationsSummary,omitempty"`

	// Tests Per-test outcome counts.
	Tests *[]struct {
		Attempts *int  `json:"attempts,omitempty" yaml:"attempts,omitempty"`
		Failed   *int  `json:"failed,omitempty" yaml:"failed,omitempty"`
		Passed   *int  `json:"passed,omitempty" yaml:"passed,omitempty"`
		Test     *Quiz `json:"test,omitempty" yaml:"test,omitempty"`
	} `json:"tests,omitempty" yaml:"tests,omitempty"`

	// TestsSummary Aggregate test outcomes across the organization.
	TestsSummary *struct {
		TotalAttempts *int `json:"totalAttempts,omitempty" yaml:"totalAttempts,omitempty"`
		TotalFailed   *int `json:"totalFailed,omitempty" yaml:"totalFailed,omitempty"`
		TotalPassed   *int `json:"totalPassed,omitempty" yaml:"totalPassed,omitempty"`
	} `json:"testsSummary,omitempty" yaml:"testsSummary,omitempty"`

	// TotalActiveLearners Learners with at least one active registration.
	TotalActiveLearners *int `json:"totalActiveLearners,omitempty" yaml:"totalActiveLearners,omitempty"`

	// TotalLearners Total distinct learners registered for the organization.
	TotalLearners *int `json:"totalLearners,omitempty" yaml:"totalLearners,omitempty"`
}

// LearningPathMetadata defines model for LearningPathMetadata.
type LearningPathMetadata = CurriculaMetadata

// Level defines model for Level.
type Level string

// Parent defines model for Parent.
type Parent struct {
	// Id Parent ID. Identifies a Hugo content page, not a database row, so it is an opaque content-scoped string. Not a UUID. See `Quiz.id`.
	ID string `json:"id" yaml:"id"`

	// RelPermalink The rel permalink of the parent.
	RelPermalink string `json:"relPermalink" yaml:"relPermalink"`

	// Title The title of the parent.
	Title string `json:"title" yaml:"title"`

	// Type Type of the resource.
	Type string `json:"type" yaml:"type"`
}

// ProgressItemCompleted defines model for ProgressItemCompleted.
type ProgressItemCompleted struct {
	// CompletedAt Timestamp when the item was completed
	CompletedAt time.Time `json:"completedAt" yaml:"completedAt"`
	ItemData    Parent    `json:"itemData" yaml:"itemData"`
}

// Question defines model for Question.
type Question struct {
	// CorrectAnswer The correct answer of the question.
	CorrectAnswer string `json:"correctAnswer" yaml:"correctAnswer"`

	// Id Question ID. Authored in the quiz's Hugo front matter, not a database row, so it is an opaque content-scoped string. Not a UUID.
	ID string `json:"id" yaml:"id"`

	// Marks The marks of the question.
	Marks int `json:"marks" yaml:"marks"`

	// MultipleAnswers The multiple answers of the question.
	MultipleAnswers *bool `json:"multipleAnswers,omitempty" yaml:"multipleAnswers,omitempty"`

	// Options The options of the question.
	Options []QuestionOption `json:"options" yaml:"options"`

	// Text The text of the question.
	Text string       `json:"text" yaml:"text"`
	Type QuestionType `json:"type" yaml:"type"`
}

// QuestionOption defines model for QuestionOption.
type QuestionOption struct {
	// Id QuestionOption ID. Authored in the quiz's Hugo front matter, not a database row, so it is an opaque content-scoped string. Not a UUID.
	ID string `json:"id" yaml:"id"`

	// IsCorrect The is correct of the questionoption.
	IsCorrect bool `json:"isCorrect" yaml:"isCorrect"`

	// Text The text of the questionoption.
	Text string `json:"text" yaml:"text"`
}

// QuestionType defines model for QuestionType.
type QuestionType string

// Quiz defines model for Quiz.
type Quiz struct {
	// Date The date of the quiz.
	Date openapi_types.Date `json:"date" yaml:"date"`

	// Description Description of the quiz.
	Description string `json:"description" yaml:"description"`

	// Draft The draft of the quiz.
	Draft bool `json:"draft" yaml:"draft"`

	// FilePath The file path of the quiz.
	FilePath string `json:"filePath" yaml:"filePath"`

	// Final Indicates if the quiz is final . i.e this quiz will used to evaluate the completion of parent section eg course , module , learning path
	Final bool `json:"final" yaml:"final"`

	// ID Quiz ID. Identifies a Hugo content page, not a database row, so it is an opaque content-scoped string. Not a UUID - stored records carry authored slugs.
	ID string `json:"id" yaml:"id"`

	// Lastmod The lastmod of the quiz.
	Lastmod openapi_types.Date `json:"lastmod" yaml:"lastmod"`

	// Layout The layout of the quiz.
	Layout string `json:"layout" yaml:"layout"`

	// MaxAttempts Maximum number of attempts allowed for the quiz. A value of 0 indicates unlimited attempts.
	MaxAttempts int    `json:"maxAttempts" yaml:"maxAttempts"`
	NextPage    Parent `json:"nextPage" yaml:"nextPage"`

	// OrgId Organization ID that owns this quiz
	OrgId  uuid.UUID `db:"org_id" json:"orgId" yaml:"orgId"`
	Parent *Parent            `json:"parent,omitempty" yaml:"parent,omitempty"`

	// PassPercentage The pass percentage of the quiz.
	PassPercentage float32 `json:"passPercentage" yaml:"passPercentage"`

	// Permalink The permalink of the quiz.
	Permalink string `json:"permalink" yaml:"permalink"`

	// Prerequisites The prerequisites of the quiz.
	Prerequisites []Parent `json:"prerequisites" yaml:"prerequisites"`

	// Questions The questions of the quiz.
	Questions []Question `json:"questions" yaml:"questions"`

	// RelPermalink The rel permalink of the quiz.
	RelPermalink string `json:"relPermalink" yaml:"relPermalink"`

	// Section The section of the quiz.
	Section string `json:"section" yaml:"section"`

	// Slug The slug of the quiz.
	Slug string `json:"slug" yaml:"slug"`

	// TimeLimit Time limit for the quiz in minutes. A value of 0 indicates no time limit. Accepts a number or a string because both forms are real production data - the Hugo theme emits a JSON number, while payloads persisted by earlier revisions hold a string such as "25" or the non-numeric sentinel "infinite". A string that does not parse to a positive number means "no time limit" and normalizes to 0.
	TimeLimit QuizTimeLimit `json:"timeLimit" yaml:"timeLimit"`

	// Title The title of the quiz.
	Title string `json:"title" yaml:"title"`

	// TotalMarks The total marks of the quiz.
	TotalMarks int `json:"totalMarks" yaml:"totalMarks"`

	// TotalQuestionSets The total question sets of the quiz.
	TotalQuestionSets int `json:"totalQuestionSets" yaml:"totalQuestionSets"`

	// TotalQuestions The total questions of the quiz.
	TotalQuestions int `json:"totalQuestions" yaml:"totalQuestions"`

	// TotalQuestionsInBank The total questions in bank of the quiz.
	TotalQuestionsInBank int `json:"totalQuestionsInBank" yaml:"totalQuestionsInBank"`

	// Type Type of the resource.
	Type string `json:"type" yaml:"type"`
}

// QuizEvaluationResult defines model for QuizEvaluationResult.
type QuizEvaluationResult struct {
	// AttemptedAt The attempted at of the quizevaluationresult.
	AttemptedAt time.Time `json:"attemptedAt" yaml:"attemptedAt"`

	// Attempts The attempts of the quizevaluationresult.
	Attempts int `json:"attempts" yaml:"attempts"`

	// CorrectSubmissions The correct submissions of the quizevaluationresult.
	CorrectSubmissions map[string]bool `json:"correctSubmissions" yaml:"correctSubmissions"`

	// PassPercentage The pass percentage of the quizevaluationresult.
	PassPercentage float32 `json:"passPercentage" yaml:"passPercentage"`

	// Passed The passed of the quizevaluationresult.
	Passed bool `json:"passed" yaml:"passed"`

	// PercentageScored The percentage scored of the quizevaluationresult.
	PercentageScored float32 `json:"percentageScored" yaml:"percentageScored"`
	Quiz             Quiz    `json:"quiz" yaml:"quiz"`

	// Score The score of the quizevaluationresult.
	Score int `json:"score" yaml:"score"`

	// TotalMarks The total marks of the quizevaluationresult.
	TotalMarks int `json:"totalMarks" yaml:"totalMarks"`
}

// QuizSubmission A learner's answers to a quiz. Submitted as the `submitQuiz` request body and persisted verbatim as `TestSubmission.submissionData`. `registrationId` and `userId` are a convenience echo of the authoritative values on the enclosing `TestSubmission` (`registrationId` / `userId`, backed by the `registration_id` and `owner` `uuid NOT NULL` columns); read them from the enclosing submission, not from here.
type QuizSubmission struct {
	// Answers The answers of the quizsubmission.
	Answers []SubmittedAnswer `json:"answers" yaml:"answers"`

	// QuizAbsPath The quiz abs path of the quizsubmission.
	QuizAbsPath string `json:"quizAbsPath" yaml:"quizAbsPath"`

	// RegistrationId ID of the associated registration. Optional, because a submission may not carry this echo; when it is absent the authoritative value is `TestSubmission.registrationId`. Absence MUST be expressed as `null` or an omitted property - the empty string is not a valid identifier.
	RegistrationId *uuid.UUID `json:"registrationId,omitempty" yaml:"registrationId,omitempty"`

	// TestSessionId A Universally Unique Identifier used to uniquely identify entities in Meshery. The UUID core definition is used across different schemas.
	TestSessionId core.Uuid `json:"testSessionId" yaml:"testSessionId"`

	// UserId ID of the user who owns or created this resource. Optional, because a submission may not carry this echo; when it is absent the authoritative value is `TestSubmission.userId`. Absence MUST be expressed as `null` or an omitted property - the empty string is not a valid identifier.
	UserId *uuid.UUID `json:"userId,omitempty" yaml:"userId,omitempty"`
}

// RegisterToAcademyContentRequest defines model for RegisterToAcademyContentRequest.
type RegisterToAcademyContentRequest struct {
	// ContentId ID of the academy content to register for
	ContentId   uuid.UUID `json:"contentId" yaml:"contentId"`
	ContentType *ContentType       `json:"contentType,omitempty" yaml:"contentType,omitempty"`

	// UserId ID of the user registering for the content.
	UserId uuid.UUID `json:"userId" yaml:"userId"`
}

// SingleAcademyCurriculaResponse defines model for SingleAcademyCurriculaResponse.
type SingleAcademyCurriculaResponse struct {
	// BadgeId ID of the badge to be awarded on completion of this curricula
	BadgeId *core.Uuid `db:"badge_id" json:"badgeId" yaml:"badgeId"`

	// CreatedAt When the Curricula item was created
	CreatedAt AcademyCurriculaCreatedAt `db:"created_at" json:"createdAt" yaml:"createdAt"`
	DeletedAt AcademyCurriculaDeletedAt `db:"deleted_at" json:"deletedAt" yaml:"deletedAt"`

	// ID Id of the Curricula
	ID uuid.UUID `db:"id" json:"id" yaml:"id"`

	// Invitation Invitation entity schema.
	Invitation *invitationv1beta3.Invitation `json:"invitation,omitempty" yaml:"invitation,omitempty"`

	// InviteId ID of the invite associated with this Curricula
	InviteId *AcademyCurriculaInviteId `db:"invite_id" json:"inviteId" yaml:"inviteId"`
	Level    Level                     `db:"level" json:"level" yaml:"level"`

	// Metadata Additional metadata about the Curricula
	Metadata AcademyCurriculaMetadata `db:"metadata" json:"metadata" yaml:"metadata"`

	// OrgId Organization ID that owns this learning path
	OrgId AcademyCurriculaOrgId `db:"org_id" json:"orgId" yaml:"orgId"`

	// RegistrationCount Number of registrations associated with this curriculum.
	RegistrationCount float32 `db:"registration_count,omitempty" json:"registrationCount,omitempty" yaml:"registrationCount,omitempty"`

	// Slug slug of the Curricula
	Slug   string      `json:"slug" yaml:"slug"`
	Status Status      `db:"status" json:"status" yaml:"status"`
	Type   ContentType `db:"type" json:"type" yaml:"type"`

	// UpdatedAt When the Curricula was last updated
	UpdatedAt  AcademyCurriculaUpdatedAt `db:"updated_at" json:"updatedAt" yaml:"updatedAt"`
	Visibility Visibility                `db:"visibility" json:"visibility" yaml:"visibility"`

	// WorkspaceId ID of the workspace to which this Curricula belongs
	WorkspaceId *AcademyCurriculaWorkspaceId `db:"workspace_id" json:"workspaceId" yaml:"workspaceId"`
}

// StartTestRequest defines model for StartTestRequest.
type StartTestRequest struct {
	// RegistrationId ID of the associated registration.
	RegistrationId uuid.UUID `json:"registrationId" yaml:"registrationId"`

	// TestAbsPath The test abs path of the starttestrequest.
	TestAbsPath string `json:"testAbsPath" yaml:"testAbsPath"`
}

// Status defines model for Status.
type Status string

// SubmittedAnswer defines model for SubmittedAnswer.
type SubmittedAnswer struct {
	// AnswerText The answer text of the submittedanswer.
	AnswerText string `json:"answerText" yaml:"answerText"`

	// QuestionId ID of the associated question. Mirrors `Question.id`, a content-authored string rather than a database row identifier, so it is not a UUID.
	QuestionId string `json:"questionId" yaml:"questionId"`

	// SelectedOptionId Map of selected option IDs to a boolean value indicating if it was selected.
	SelectedOptionId map[string]bool `json:"selectedOptionId" yaml:"selectedOptionId"`
}

// TestSubmission defines model for TestSubmission.
type TestSubmission struct {
	// CreatedAt When the submission was created or started
	CreatedAt time.Time `db:"created_at" json:"createdAt" yaml:"createdAt"`

	// DeletedAt Timestamp when the resource was deleted.
	DeletedAt core.NullTime `db:"deleted_at" json:"deletedAt,omitempty" yaml:"deletedAt,omitempty"`

	// ExpiresAt Expiry time for the test submission ( based on the time limit of the test )
	ExpiresAt *time.Time `db:"expires_at" json:"expiresAt,omitempty" yaml:"expiresAt,omitempty"`

	// Id A Universally Unique Identifier used to uniquely identify entities in Meshery. The UUID core definition is used across different schemas.
	ID core.Uuid `db:"id" json:"id" yaml:"id"`

	// RegistrationId A Universally Unique Identifier used to uniquely identify entities in Meshery. The UUID core definition is used across different schemas.
	RegistrationId core.Uuid     `db:"registration_id" json:"registrationId" yaml:"registrationId"`
	Result         *QuizEvaluationResult `db:"result" json:"result,omitempty" yaml:"result,omitempty"`
	Status         TestSubmissionStatus  `json:"status" yaml:"status"`

	// SubmissionData A learner's answers to a quiz. Submitted as the `submitQuiz` request body and persisted verbatim as `TestSubmission.submissionData`. `registrationId` and `userId` are a convenience echo of the authoritative values on the enclosing `TestSubmission` (`registrationId` / `userId`, backed by the `registration_id` and `owner` `uuid NOT NULL` columns); read them from the enclosing submission, not from here.
	SubmissionData *QuizSubmission `db:"submission_data" json:"submissionData,omitempty" yaml:"submissionData,omitempty"`

	// SubmittedAt The submitted at of the testsubmission.
	SubmittedAt *time.Time `db:"submitted_at" json:"submittedAt,omitempty" yaml:"submittedAt,omitempty"`
	Test        Quiz       `json:"test" yaml:"test"`

	// TestAbsPath The test abs path of the testsubmission.
	TestAbsPath string `db:"test_abs_path" json:"testAbsPath" yaml:"testAbsPath"`

	// UpdatedAt When the submission was last updated
	UpdatedAt *time.Time `db:"updated_at" json:"updatedAt,omitempty" yaml:"updatedAt,omitempty"`

	// UserId A Universally Unique Identifier used to uniquely identify entities in Meshery. The UUID core definition is used across different schemas.
	UserId core.Uuid `db:"owner" json:"userId" yaml:"userId"`
}

// TestSubmissionStatus defines model for TestSubmissionStatus.
type TestSubmissionStatus string

// TestSubmissions Test submissions made by the user (array of QuizEvaluationResult)
type TestSubmissions = []QuizEvaluationResult

// UpdateCurrentItemProgressResponse defines model for UpdateCurrentItemProgressResponse.
type UpdateCurrentItemProgressResponse struct {
	ContentType *ContentType              `json:"contentType,omitempty" yaml:"contentType,omitempty"`
	ItemData    *CurriculaCurrentItemData `json:"itemData,omitempty" yaml:"itemData,omitempty"`

	// Message The message of the updatecurrentitemprogressresponse.
	Message         *string                   `json:"message,omitempty" yaml:"message,omitempty"`
	ProgressTracker *CurriculaProgressTracker `json:"progressTracker,omitempty" yaml:"progressTracker,omitempty"`

	// RegistrationId ID of the associated registration.
	RegistrationId *uuid.UUID `json:"registrationId,omitempty" yaml:"registrationId,omitempty"`
}

// UpdateCurrentItemRequest defines model for UpdateCurrentItemRequest.
type UpdateCurrentItemRequest struct {
	ContentType ContentType              `json:"contentType" yaml:"contentType"`
	ItemData    CurriculaCurrentItemData `json:"itemData" yaml:"itemData"`
}

// UserRegistration defines model for UserRegistration.
type UserRegistration struct {
	// CreatedAt When the registration was created
	CreatedAt *time.Time `db:"created_at" json:"createdAt,omitempty" yaml:"createdAt,omitempty"`

	// CurriculaPermalink Permalink of the curricula
	CurriculaPermalink string `db:"curricula_permalink" json:"curriculaPermalink" yaml:"curriculaPermalink"`

	// CurriculaTitle Title of the curricula
	CurriculaTitle string      `db:"curricula_title" json:"curriculaTitle" yaml:"curriculaTitle"`
	CurriculaType  ContentType `db:"curricula_type" json:"curriculaType" yaml:"curriculaType"`

	// RegistrationId Unique ID of the registration
	RegistrationId uuid.UUID `db:"registration_id" json:"registrationId" yaml:"registrationId"`

	// Status Status of the user's course registration
	Status AcademyRegistrationStatus `db:"status" json:"status" yaml:"status"`

	// TotalCount Total count for pagination
	TotalCount int64 `db:"total_count" json:"totalCount" yaml:"totalCount"`

	// UserAvatarUrl Avatar URL of the user
	UserAvatarUrl string `db:"user_avatar_url" json:"userAvatarUrl" yaml:"userAvatarUrl"`

	// UserEmail Email of the user
	UserEmail openapi_types.Email `db:"user_email" json:"userEmail" yaml:"userEmail"`

	// UserFirstName First name of the user
	UserFirstName string `db:"user_first_name" json:"userFirstName" yaml:"userFirstName"`

	// UserId ID of the user
	UserId uuid.UUID `db:"user_id" json:"userId" yaml:"userId"`

	// UserLastName Last name of the user
	UserLastName string `db:"user_last_name" json:"userLastName" yaml:"userLastName"`
}

// Visibility defines model for Visibility.
type Visibility string

// Id defines model for id.
type Id = string
