id(); $table->bigInteger('update_id'); $table->string('token')->nullable(); // message 資料 $table->bigInteger('message_message_id')->nullable(); $table->bigInteger('message_from_id')->nullable(); $table->boolean('message_from_is_bot')->nullable(); $table->string('message_from_first_name')->nullable(); $table->string('message_from_last_name')->nullable(); $table->string('message_from_username')->nullable(); $table->string('message_from_language_code')->nullable(); $table->bigInteger('message_chat_id')->nullable(); $table->string('message_chat_title')->nullable(); $table->string('message_chat_type')->nullable(); $table->boolean('message_chat_all_members_are_administrators')->nullable(); $table->dateTime('message_date')->nullable(); // 👈 已改為 datetime $table->text('message_text')->nullable(); // entities 陣列中的第一個 mention 項目 $table->integer('message_entities_0_offset')->nullable(); $table->integer('message_entities_0_length')->nullable(); $table->string('message_entities_0_type')->nullable(); // 原始資料 $table->json('raw')->nullable(); // Laravel timestamps $table->dateTime('created_at')->nullable(); $table->dateTime('updated_at')->nullable(); }); } public function down(): void { Schema::dropIfExists('telegram_messages'); } };