<?php

namespace App\Http\Requests\Families;

use App\Http\Requests\ApiFormRequest;

class FamilySetPrimaryHomeRequest extends ApiFormRequest
{
    public function authorize(): bool
    {
        return auth()->check();
    }

    public function rules(): array
    {
        return [
            'family_id' => ['required', 'integer', 'min:1'],
            'student_id' => ['required', 'integer', 'min:1'],
            'is_primary_home' => ['required', 'boolean'],
        ];
    }
}
