PHP code example of devmehq / sdk-php
1. Go to this page and download the library: Download devmehq/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' );
devmehq / sdk-php example snippets
use DevmeSdk \Authentication \APIKeyHeaderAuthentication ;
use Jane \Component \OpenApiRuntime \Client \Plugin \AuthenticationRegistry ;
$authenticationRegistry = new AuthenticationRegistry([new APIKeyHeaderAuthentication('demo-key' )]);
$apiClient = \DevmeSdk\Client::create(null , [$authenticationRegistry]);
$apiClient->v1ConvertCurrency(['from' => 'USD' , 'to' => 'EUR' , 'amount' => 10 ]);
use DevmeSdk \Authentication \APIKeyHeaderAuthentication ;
use Jane \Component \OpenApiRuntime \Client \Plugin \AuthenticationRegistry ;
$authenticationRegistry = new AuthenticationRegistry([new APIKeyHeaderAuthentication('demo-key' )]);
$apiClient = \DevmeSdk\Client::create(null , [$authenticationRegistry]);
$apiClient->v1GetIpDetails([ 'ip' => '52.45.23.11' ]);
use DevmeSdk \Authentication \APIKeyHeaderAuthentication ;
use Jane \Component \OpenApiRuntime \Client \Plugin \AuthenticationRegistry ;
$authenticationRegistry = new AuthenticationRegistry([new APIKeyHeaderAuthentication('demo-key' )]);
$apiClient = \DevmeSdk\Client::create(null , [$authenticationRegistry]);
$apiClient->v1GetEmailDetails(['email' => 'myemail@yahoo.com' , 'verifyMx' => true , 'verifySmtp' => true , 'timeout' => 3 ]);
shell
composer