PHP code example of insightbase / revolut-merchant-api-nette
1. Go to this page and download the library: Download insightbase/revolut-merchant-api-nette library. Choose the download type require. 2. Extract the ZIP file and open the index.php. 3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
insightbase / revolut-merchant-api-nette example snippets
use App\Api\RevolutWebhookController;
use Nette\Application\UI\Presenter;
final class RevolutWebhookPresenter extends Presenter
{
public function __construct(
private readonly RevolutWebhookController $controller
) {
parent::__construct();
}
public function actionIn(): void
{
$result = $this->controller->handle($this->getHttpRequest());
$this->sendJson($result->body, $result->statusCode);
}
}
examples/CreateOrderExample.php
examples/GetOrderPaymentsExample.php
examples/GetPaymentDetailExample.php