<?php

namespace App\Http\Requests\Admin;

use App\Http\Requests\ApiFormRequest;

final class AdminSettlementBillAdjustmentRequest extends ApiFormRequest
{
    public function authorize(): bool
    {
        return true;
    }

    public function rules(): array
    {
        return [
            'amount' => ['required', 'integer', 'not_in:0'],
            'adjustment_type' => ['sometimes', 'string', 'in:adjustment,reversal'],
            'reason' => ['sometimes', 'nullable', 'string', 'max:255'],
            'idempotency_key' => ['sometimes', 'nullable', 'string', 'max:64'],
        ];
    }
}
