Creating A Permission

Creating a permission programatically:

$Permission = Permission::create([
           'title' => '',
           'description' => ''
           'key' => ''
]);

 

Parameters
title String The title/label of the permission. Eg. "Manage Users" etc.
description string The description of the permission
key string The key of this permission. Eg. user.create, user.update, user.delete etc.