承接 rodineiti/smartfastpay-sdk-php 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

rodineiti/smartfastpay-sdk-php

最新稳定版本:v1.0.5

Composer 安装命令:

composer require rodineiti/smartfastpay-sdk-php

包简介

SDK with PHP for Smartfastpay to process payments and payouts

README 文档

README

Version PHP License

Welcome to the initial release of the Smartfastpay SDK for PHP - a powerful and flexible library for processing payments and payouts.

Key Features:

  1. Payments and Payouts Implementation: Full support for processing payments and payouts.

  2. Design Patterns and Best Practices: Utilizes design patterns like Strategy, following best practices for clean and maintainable code.

  3. Flexible Configurations: Easily configure client keys and secrets.

  4. Guzzle HTTP Requests: Integrates with Guzzle HTTP for efficient and reliable requests.

  5. Exception Handling: Implements specific exceptions for each resource, along with the use of HTTP exceptions for error handling.

  6. Secure Authentication: Implements secure authentication with automatic access token renewal.

Getting Started:

  1. Installation via Composer:

    composer require rodineiti/smartfastpay-sdk-php
  2. Quick Setup:

    use Rodineiti\SmartfastpaySdk\Config\Config;
    use Rodineiti\SmartfastpaySdk\Payment;
    use Rodineiti\SmartfastpaySdk\Strategy\Payment\Pix\PixPaymentStrategy;
    
    $config = new Config('client_id', 'client_secret');
    
    $payment = new Payment($config);
    $payment->setStrategy(new PixPaymentStrategy());
  3. Payment Processing:

     use Rodineiti\SmartfastpaySdk\Strategy\Payment\Pix\PixParams;
    
     try {
         $respose = $payment->processPayment(new PixParams(
             uniqid(),
             'John Doe',
             'john.doe@example.com',
             '12345678909',
             2.00,
             'BRL',
             'http://example.com/callback',
             uniqid(),
         ));
    
         header("Content-Type: application/json");
         echo $respose;
     } catch (Exception $e) {
         var_dump("Error on create payment: {$e->getMessage()}");
     }

统计信息

  • 总下载量: 784
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 1
  • 点击次数: 0
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 1
  • Watchers: 2
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2024-01-22