<?php

namespace Database\Factories;

use App\Models\Conversation;
use App\Models\Message;
use Illuminate\Database\Eloquent\Factories\Factory;

/**
 * @extends Factory<Message>
 */
class MessageFactory extends Factory
{
    /**
     * @return array<string, mixed>
     */
    public function definition(): array
    {
        return [
            'conversation_id' => Conversation::factory(),
            'sender_user_id' => null,
            'sender_type' => 'customer',
            'body' => fake()->sentence(),
            'locale' => 'bn',
            'confidence' => null,
            'metadata' => [],
            'provider' => null,
            'provider_message_id' => null,
            'provider_event_id' => null,
            'provider_timestamp' => null,
            'delivery_status' => null,
            'delivery_error' => null,
            'delivered_at' => null,
            'sent_at' => now(),
        ];
    }
}
