<?php

namespace Modules\Bms\Services\Contracts;

/**
 * Outbound notifications boundary. Routes a message through the ERP shared
 * comms layer across the channels configured in the P1 notification matrix
 * (email, push/FCM, WhatsApp, SMS).
 */
interface NotificationServiceContract
{
    /**
     * @param  array  $payload  [
     *     'to'        => string|array  (phone/email/user-id depending on channel),
     *     'channels'  => array         (['email','whatsapp','sms','push']),
     *     'subject'   => string|null,
     *     'body'      => string,
     *     'data'      => array          (template variables / push payload),
     *     'update_type' => string|null  (key into the notification matrix),
     *  ]
     * @return array  per-channel dispatch result
     */
    public function send(int $businessId, array $payload): array;
}
