PHP code example of zenki / zenkipay-api-client

1. Go to this page and download the library: Download zenki/zenkipay-api-client 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/ */

    

zenki / zenkipay-api-client example snippets





apiInstance = new Zenkipay\Api\AuthenticationAndAuthorizationApi(
    // If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
    // This is optional, `GuzzleHttp\Client` will be used as default.
    new GuzzleHttp\Client()
);
$content_type = application/json; // string | Tipo de contenido aceptado.
$accept = application/json; // string | Formatos aceptados.
$request_token_o_auth2 = new \Zenkipay\Model\RequestTokenOAuth2(); // \Zenkipay\Model\RequestTokenOAuth2 | Parameters for OAuth 2 token creation.

try {
    $result = $apiInstance->createToken($content_type, $accept, $request_token_o_auth2);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AuthenticationAndAuthorizationApi->createToken: ', $e->getMessage(), PHP_EOL;
}