1. Go to this page and download the library: Download instamojo/instamojo-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/ */
instamojo / instamojo-php example snippets
$authType = "app/user" /**Depend on app or user based authentication**/
$api = Instamojo\Instamojo::init($authType,[
"client_id" => 'XXXXXQAZ',
"client_secret" => 'XXXXQWE',
"username" => 'FOO', /** In case of user based authentication**/
"password" => 'XXXXXXXX' /** In case of user based authentication**/
],true); /** true for sandbox enviorment**/
$api = Instamojo\Instamojo::init($authType,[
"client_id" => 'XXXXXQAZ',
"client_secret" => 'XXXXQWE',
"username" => 'FOO', /** In case of user based authentication**/
"password" => 'XXXXXXXX' /** In case of user based authentication**/
]);