<?php
namespace Database\Seeders\Admin;
use Illuminate\Database\Seeder;
use App\Models\Admin\Admin;
use Illuminate\Support\Facades\Hash;
class AdminSeeder extends Seeder
{
/**
* Run the database seeds.
*
* @return void
*/
public function run()
{
$data = [
[
'firstname' => "Super",
'lastname' => "Admin",
'username' => "superadmin",
'email' => "superadmin@appdevs.net",
'password' => Hash::make("appdevs"),
'created_at' => now(),
'status' => true,
],
];
Admin::insert($data);
}
}
In case of an error, the API will return an error response containing a specific error code 400, 403 Failed and a user-friendly message. Refer to our API documentation for a comprehensive list of error codes and their descriptions.