sipay-tr / sipay-php-sdk
PHP SDK for the Sipay API
Requires
- php: >=7.4.0
- ext-curl: *
- ext-json: *
- ext-openssl: *
Requires (Dev)
- friendsofphp/php-cs-fixer: ^3.68
- phpunit/phpunit: ^9.6
- satooshi/php-coveralls: ~0.6.1
- symfony/var-dumper: ^5.4
This package is auto-updated.
Last update: 2025-05-25 10:46:59 UTC
README
Sipay, is a payment gateway that provides a secure and easy-to-use payment infrastructure.
This package is a PHP SDK for the Sipay API.
Important: This package is still in development. Please use it with caution and report any issues you encounter.
Requirements
- PHP 7.4+
- ext-curl, ext-json, ext-openssl extensions
Installation
Run the following command under your project to install the package via Composer
composer require sipay/sipay-php-sdk
Getting Started
You can create a new instance of the Sipay class by passing the required parameters to the constructor. You can find the required parameters in the sample code below.
$sipayOptions = new \Sipay\SipayOptions( '<API KEY>', '<API SECRET>', '<MERCHANT KEY>', '<MERCHANT ID>', 'https://app.sipay.com.tr/ccpayment' ); $sipay = new Sipay($sipayOptions);
Note: For Test API server and credentials, you can check the Sipay API Documentation
Examples
Included in the project are a number of examples that cover almost all use-cases. Refer to the samples
folder for more info.
Testing
You can run the tests as following command below:
./vendor/bin/phpunit
To run a test file, you can use the following example command:
.vendor/bin/phpunit tests/Sipay/Resources/TokenTest.php
To run a test method in test file, you can use the following example command:
./vendor/bin/phpunit --filter testRetrieveWithSuccessfulResponse tests/Sipay/Resources/CardListTest.php