|
@@ 70-79 (lines=10) @@
|
| 67 |
|
return $this->map($this->makeRequest('cancel', $params), new CancelResponse()); |
| 68 |
|
} |
| 69 |
|
|
| 70 |
|
public function charge(array $params, int $merchantId, string $secretWord): ChargeResponse |
| 71 |
|
{ |
| 72 |
|
$params['token'] = md5( |
| 73 |
|
$merchantId |
| 74 |
|
.($params['payment_id'] ?? '') |
| 75 |
|
.$secretWord |
| 76 |
|
); |
| 77 |
|
|
| 78 |
|
return $this->map($this->makeRequest('charge', $params), new ChargeResponse()); |
| 79 |
|
} |
| 80 |
|
|
| 81 |
|
public function completeAuth(array $params, int $merchantId, string $secretWord): CompleteAuthResponse |
| 82 |
|
{ |
|
@@ 81-90 (lines=10) @@
|
| 78 |
|
return $this->map($this->makeRequest('charge', $params), new ChargeResponse()); |
| 79 |
|
} |
| 80 |
|
|
| 81 |
|
public function completeAuth(array $params, int $merchantId, string $secretWord): CompleteAuthResponse |
| 82 |
|
{ |
| 83 |
|
$params['token'] = md5( |
| 84 |
|
$merchantId |
| 85 |
|
.($params['payment_id'] ?? '') |
| 86 |
|
.$secretWord |
| 87 |
|
); |
| 88 |
|
|
| 89 |
|
return $this->map($this->makeRequest('complete-auth', $params), new CompleteAuthResponse()); |
| 90 |
|
} |
| 91 |
|
|
| 92 |
|
public function cardInit(array $params, int $merchantId, string $secretWord): CardInitResponse |
| 93 |
|
{ |
|
@@ 134-143 (lines=10) @@
|
| 131 |
|
return $this->map($this->makeRequest('recurrent', $params), new RecurrentResponse()); |
| 132 |
|
} |
| 133 |
|
|
| 134 |
|
public function status(array $params, int $merchantId, string $secretWord): StatusResponse |
| 135 |
|
{ |
| 136 |
|
$params['token'] = md5( |
| 137 |
|
$merchantId |
| 138 |
|
.($params['payment_id'] ?? '') |
| 139 |
|
.$secretWord |
| 140 |
|
); |
| 141 |
|
|
| 142 |
|
return $this->map($this->makeRequest('status', $params), new StatusResponse()); |
| 143 |
|
} |
| 144 |
|
|
| 145 |
|
/** |
| 146 |
|
* Generate token for request. |