first commit

This commit is contained in:
2026-01-14 16:40:33 +03:00
commit f803480f7b
184 changed files with 5573 additions and 0 deletions

View File

@@ -0,0 +1,50 @@
<?php
namespace Gemini\AlfaBank\Sbp\Requests\CashLink;
use Saloon\Contracts\Body\HasBody;
use Saloon\Enums\Method;
use Saloon\Http\Request;
use Saloon\Traits\Body\HasJsonBody;
class ChangeAccountForCashQrRequest extends Request implements HasBody
{
use HasJsonBody;
protected Method $method = Method::POST;
public function __construct(
protected string $TermNo,
protected string $qrcId,
protected string $account,
protected ?string $NewTermNo = null,
protected ?string $NewMerchantId = null,
protected ?string $redirectUrl = null,
) {}
public function resolveEndpoint(): string
{
return '';
}
protected function defaultBody(): array
{
$body = [
'command' => 'ChangeAccForCashQRc',
'TermNo' => $this->TermNo,
'qrcId' => $this->qrcId,
'account' => $this->account,
];
if ($this->NewTermNo !== null) $body['NewTermNo'] = $this->NewTermNo;
if ($this->NewMerchantId !== null) $body['NewMerchantId'] = $this->NewMerchantId;
if ($this->redirectUrl !== null) $body['redirectUrl'] = $this->redirectUrl;
return $body;
}
public function createDtoFromResponse(\Saloon\Http\Response $response): array
{
return $response->json();
}
}