<?php

namespace Fifa\ConnectId\Sdk\ApiClient\Tms;

use Fifa\ConnectId\Sdk\Exception\TmsOperationException;
use Fifa\ConnectId\Sdk\Model\DataStandard\PersonLocal;
use Fifa\ConnectId\Sdk\Model\Transfer\DomesticTransferDeclaration;
use Fifa\ConnectId\Sdk\Model\Transfer\FirstProRegistration;
use Fifa\ConnectId\Sdk\Model\Transfer\ProofOfPayment;

/**
 * Interface TmsApiInterface
 * @package Fifa\ConnectId\Sdk\ApiClient\Tms
 */
interface TmsApiInterface
{
    /**
     * Adds player in TMS system via Service Bus
     *
     * @param string $correlationId - Unique correlation id
     * @param PersonLocal $personLocal - Person details using FIFA Data Standard
     *
     * @throws TmsOperationException
     */
    public function addPlayer(string $correlationId, PersonLocal $personLocal): void;

    /**
     * Updates existing player in TMS system via Service Bus
     *
     * @param string $correlationId - Unique correlation id
     * @param PersonLocal $personLocal - Person details using FIFA Data Standard
     *
     * @throws TmsOperationException
     */
    public function updatePlayer(string $correlationId, PersonLocal $personLocal): void;

    /**
     * Sends DTS declaration to TMS system via Service Bus
     *
     * @param string $correlationId - Unique correlation id
     * @param DomesticTransferDeclaration $declaration - Transfer details using FIFA Data Standard
     *
     * @throws TmsOperationException
     */
    public function declareDomesticTransfer(string $correlationId, DomesticTransferDeclaration $declaration): void;

    /**
     * Sends Proof Of Payment to TMS system via Service Bus
     *
     * @param string $correlationId - Unique correlation id
     * @param ProofOfPayment $proofOfPayment - Payment details using FIFA Data Standard
     *
     * @throws TmsOperationException
     */
    public function provePayment(string $correlationId, ProofOfPayment $proofOfPayment): void;

    /**
     * Sends FirstProRegistration to TMS system via Service Bus
     *
     * @param string $correlationId - Unique correlation id
     * @param FirstProRegistration $firstProRegistration - Registration details using FIFA Data Standard
     *
     * @throws TmsOperationException
     */
    public function declareFirstProRegistration(string $correlationId, FirstProRegistration $firstProRegistration): void;
}