--- /dev/null
+<?php
+
+namespace App\Models;
+
+use Illuminate\Database\Eloquent\Factories\HasFactory;
+use Illuminate\Database\Eloquent\Model;
+
+class AlttpSeed extends Model
+{
+ use HasFactory;
+
+ protected $casts = [
+ 'error_detail' => 'array',
+ 'mystery' => 'boolean',
+ 'race' => 'boolean',
+ 'settings' => 'array',
+ ];
+
+}
--- /dev/null
+<?php
+
+use Illuminate\Database\Migrations\Migration;
+use Illuminate\Database\Schema\Blueprint;
+use Illuminate\Support\Facades\Schema;
+
+return new class extends Migration
+{
+ /**
+ * Run the migrations.
+ *
+ * @return void
+ */
+ public function up()
+ {
+ Schema::create('alttp_seeds', function (Blueprint $table) {
+ $table->id();
+ $table->binary('hash');
+ $table->string('generator');
+ $table->string('preset');
+ $table->boolean('race')->default(false);
+ $table->boolean('mystery')->default(false);
+ $table->string('seed');
+ $table->text('settings');
+ $table->string('status')->default('pending');
+ $table->text('error_detail')->nullable()->default(null);
+ $table->timestamps();
+ $table->unique('hash');
+ });
+ }
+
+ /**
+ * Reverse the migrations.
+ *
+ * @return void
+ */
+ public function down()
+ {
+ Schema::dropIfExists('alttp_seeds');
+ }
+};