PHP code example of sdksio / apimatic-polpay-sdk
1. Go to this page and download the library: Download sdksio/apimatic-polpay-sdk 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/ */
sdksio / apimatic-polpay-sdk example snippets
use PoliApIsLib\Logging\LoggingConfigurationBuilder;
use PoliApIsLib\Logging\RequestLoggingConfigurationBuilder;
use PoliApIsLib\Logging\ResponseLoggingConfigurationBuilder;
use Psr\Log\LogLevel;
use PoliApIsLib\Environment;
use PoliApIsLib\Authentication\BasicAuthCredentialsBuilder;
use PoliApIsLib\PoliApIsClientBuilder;
$client = PoliApIsClientBuilder::init()
->basicAuthCredentials(
BasicAuthCredentialsBuilder::init(
'BasicAuthUserName',
'BasicAuthPassword'
)
)
->environment(Environment::PRODUCTION)
->loggingConfiguration(
LoggingConfigurationBuilder::init()
->level(LogLevel::INFO)
->requestConfiguration(RequestLoggingConfigurationBuilder::init()->body(true))
->responseConfiguration(ResponseLoggingConfigurationBuilder::init()->headers(true))
)
->build();