<?php

declare(strict_types=1);

namespace Database\Factories;

use App\Models\CannedResponse;
use App\Models\User;
use Illuminate\Database\Eloquent\Factories\Factory;

/**
 * @extends \Illuminate\Database\Eloquent\Factories\Factory<\App\Models\CannedResponse>
 */
class CannedResponseFactory extends Factory
{
    protected $model = CannedResponse::class;

    /** @return array<string, mixed> */
    public function definition(): array
    {
        return [
            'title' => fake()->sentence(4),
            'content' => fake()->paragraphs(2, true),
            'category' => fake()->optional()->randomElement(['greeting', 'billing', 'technical', 'closing']),
            'is_shared' => true,
            'created_by' => User::factory(),
            'usage_count' => fake()->numberBetween(0, 100),
        ];
    }
}
