PHP code example of revenuewire / merchant-gateway-api-sdk-php
1. Go to this page and download the library: Download revenuewire/merchant-gateway-api-sdk-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/ */
revenuewire / merchant-gateway-api-sdk-php example snippets
onfigure API key authorization: APIKeyHeader
Swagger\Client\Configuration::getDefaultConfiguration()->setApiKey('X-API-KEY', 'YOUR_API_KEY');
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// Swagger\Client\Configuration::getDefaultConfiguration()->setApiKeyPrefix('X-API-KEY', 'Bearer');
// Configure API key authorization: JWTHeader
Swagger\Client\Configuration::getDefaultConfiguration()->setApiKey('X-Authorization-JWT', 'YOUR_API_KEY');
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// Swagger\Client\Configuration::getDefaultConfiguration()->setApiKeyPrefix('X-Authorization-JWT', 'Bearer');
$api_instance = new Swagger\Client\Api\MerchantGatewayApi();
$clientId = "clientId_example"; // string |
$gatewayPolicy = "gatewayPolicy_example"; // string |
try {
$result = $api_instance->createMerchantGateway($clientId, $gatewayPolicy);
print_r($result);
} catch (Exception $e) {
echo 'Exception when calling MerchantGatewayApi->createMerchantGateway: ', $e->getMessage(), PHP_EOL;
}
{
"repositories": [
{
"type": "git",
"url": "https://github.com/revenuewire/merchant-gateway-api-sdk-php.git"
}
],
"