1. Go to this page and download the library: Download iyzico/kolai-php 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/ */
iyzico / kolai-php example snippets
use Kolai\Auth\{RequestVerifier, SignedRequest, Scope};
$verifier = new RequestVerifier($apiKey, $secretKey, $nonceStore, $psrLogger);
$request = SignedRequest::fromRequestUri(
$headers['Authorization'] ?? '',
$_SERVER['REQUEST_URI'],
$rawBody // GET için ''
);
$verifier->verify($request, Scope::CREATE_ORDER); // başarısızsa UnauthorizedException