// Auto-generated types - DO NOT EDIT manually
// Run `npm run codegen` to regenerate from GraphQL schema

export type Maybe<T> = T | null;

// ============== Scalars ==============
export type Scalars = {
  ID: string;
  String: string;
  Boolean: boolean;
  Int: number;
  Float: number;
  DateTime: string;
};

// ============== Enums ==============
export type EnrollmentStatus = 'ACTIVE' | 'CANCELLED' | 'COMPLETED';

// ============== Types ==============
export type Student = {
  __typename?: 'Student';
  id: Scalars['Int'];
  name: Scalars['String'];
  email: Scalars['String'];
  totalCredits: Scalars['Int'];
  enrollments: Array<Enrollment>;
  createdAt: Scalars['DateTime'];
  updatedAt: Maybe<Scalars['DateTime']>;
};

export type Subject = {
  __typename?: 'Subject';
  id: Scalars['Int'];
  name: Scalars['String'];
  credits: Scalars['Int'];
  professor: Professor;
  professorId: Scalars['Int'];
};

export type Professor = {
  __typename?: 'Professor';
  id: Scalars['Int'];
  name: Scalars['String'];
  subjects: Array<Subject>;
};

export type Enrollment = {
  __typename?: 'Enrollment';
  id: Scalars['Int'];
  studentId: Scalars['Int'];
  student: Student;
  subjectId: Scalars['Int'];
  subject: Subject;
  enrolledAt: Scalars['DateTime'];
  status: EnrollmentStatus;
};

export type AvailableSubject = {
  __typename?: 'AvailableSubject';
  id: Scalars['Int'];
  name: Scalars['String'];
  credits: Scalars['Int'];
  professor: Professor;
  isAvailable: Scalars['Boolean'];
  unavailableReason: Maybe<Scalars['String']>;
};

export type ClassmateGroup = {
  __typename?: 'ClassmateGroup';
  subjectId: Scalars['Int'];
  subjectName: Scalars['String'];
  students: Array<ClassmateInfo>;
};

export type ClassmateInfo = {
  __typename?: 'ClassmateInfo';
  id: Scalars['Int'];
  name: Scalars['String'];
};

// ============== Input Types ==============
export type CreateStudentInput = {
  name: Scalars['String'];
  email: Scalars['String'];
};

export type UpdateStudentInput = {
  name?: Maybe<Scalars['String']>;
  email?: Maybe<Scalars['String']>;
};

export type EnrollStudentInput = {
  studentId: Scalars['Int'];
  subjectId: Scalars['Int'];
};

// ============== Mutation Payloads ==============
export type CreateStudentPayload = {
  __typename?: 'CreateStudentPayload';
  student: Maybe<Student>;
  errors: Maybe<Array<Scalars['String']>>;
};

export type UpdateStudentPayload = {
  __typename?: 'UpdateStudentPayload';
  student: Maybe<Student>;
  errors: Maybe<Array<Scalars['String']>>;
};

export type DeleteStudentPayload = {
  __typename?: 'DeleteStudentPayload';
  success: Scalars['Boolean'];
  errors: Maybe<Array<Scalars['String']>>;
};

export type EnrollStudentPayload = {
  __typename?: 'EnrollStudentPayload';
  enrollment: Maybe<Enrollment>;
  errors: Maybe<Array<Scalars['String']>>;
};

export type UnenrollStudentPayload = {
  __typename?: 'UnenrollStudentPayload';
  success: Scalars['Boolean'];
  errors: Maybe<Array<Scalars['String']>>;
};

// ============== Query Types ==============
export type GetStudentsQuery = {
  __typename?: 'Query';
  students: Array<Student>;
};

export type GetStudentQuery = {
  __typename?: 'Query';
  student: Maybe<Student>;
};

export type GetStudentQueryVariables = {
  id: Scalars['Int'];
};

export type GetSubjectsQuery = {
  __typename?: 'Query';
  subjects: Array<Subject>;
};

export type GetAvailableSubjectsQuery = {
  __typename?: 'Query';
  availableSubjects: Array<AvailableSubject>;
};

export type GetAvailableSubjectsQueryVariables = {
  studentId: Scalars['Int'];
};

export type GetClassmatesQuery = {
  __typename?: 'Query';
  classmates: Array<ClassmateGroup>;
};

export type GetClassmatesQueryVariables = {
  studentId: Scalars['Int'];
};

export type GetProfessorsQuery = {
  __typename?: 'Query';
  professors: Array<Professor>;
};

// ============== Mutation Types ==============
export type CreateStudentMutation = {
  __typename?: 'Mutation';
  createStudent: CreateStudentPayload;
};

export type CreateStudentMutationVariables = {
  input: CreateStudentInput;
};

export type UpdateStudentMutation = {
  __typename?: 'Mutation';
  updateStudent: UpdateStudentPayload;
};

export type UpdateStudentMutationVariables = {
  id: Scalars['Int'];
  input: UpdateStudentInput;
};

export type DeleteStudentMutation = {
  __typename?: 'Mutation';
  deleteStudent: DeleteStudentPayload;
};

export type DeleteStudentMutationVariables = {
  id: Scalars['Int'];
};

export type EnrollStudentMutation = {
  __typename?: 'Mutation';
  enrollStudent: EnrollStudentPayload;
};

export type EnrollStudentMutationVariables = {
  input: EnrollStudentInput;
};

export type UnenrollStudentMutation = {
  __typename?: 'Mutation';
  unenrollStudent: UnenrollStudentPayload;
};

export type UnenrollStudentMutationVariables = {
  enrollmentId: Scalars['Int'];
};
