'array', 'is_active' => 'boolean', 'enable_whitelisted_ips' => 'boolean', ]; public static function boot() { parent::boot(); static::creating(function ($model) { $model->api_key = bin2hex(random_bytes(32)); $model->api_secret = bin2hex(random_bytes(32)); }); } }