<?php

namespace App\Models;

use Illuminate\Database\Eloquent\Model;

class CrmSetting extends Model
{
    protected $guarded = ['id'];
    protected $hidden = ['access_token'];
    protected $casts = ['use_templates' => 'boolean', 'verified_at' => 'datetime'];

    public static function current(): self
    {
        return static::first() ?? static::create([]);
    }
}
