interface SerializesCastableAttributes (View source)
| mixed | serialize(Model $model, string $key, mixed $value, array $attributes) Serialize the attribute when converting the model to an array. | 
Serialize the attribute when converting the model to an array.
    © Taylor Otwell
Licensed under the MIT License.
Laravel is a trademark of Taylor Otwell.
    https://laravel.com/api/8.x/Illuminate/Contracts/Database/Eloquent/SerializesCastableAttributes.html