redwello/teya-payment-client 问题修复 & 功能扩展

解决BUG、新增功能、兼容多环境部署,快速响应你的开发需求

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

redwello/teya-payment-client

最新稳定版本:v0.1.0

Composer 安装命令:

composer require redwello/teya-payment-client

包简介

PHP Teya Payment Client Library

README 文档

README

teya logo

Teya Payment PHP Client Library

Teya PHP Client Library is a PHP package designed to interact with the Teya API, enabling seamless integration of Teya's services into PHP applications. It provides a structured and easy-to-use interface for making API requests, handling authentication, and managing data exchanges. The library simplifies complex API interactions by offering pre-built methods for common operations, ensuring developers can efficiently integrate Teya's features with minimal effort. Ideal for businesses and developers looking to incorporate Teya's payment and transactional services into their PHP-based systems.

https://teya.com

Install

composer require redwello/teya-payment-client

RPG Payment Gateway

Official documentation

$client = new Redwello\TeyaPayment\TeyaPaymentGatewayClient([
    'PrivateKey' => '856293_pr0lxnW8PG1SeCwVJ3WPH0lXCeU0/sYLtX'
    ]);

$client->payment([
        'Amount' => 100,
        'Currency' => 352,
        'OrderId' => 'ORDER1230001',
        'PaymentMethod' => [
            'PaymentType' => 'Card',
            'PAN' => '4176669999000104',
            'ExpYear' => 2031,
            'ExpMonth' => 12
        ]
    ]);

SecurePay

Official documentation

        $client = new Redwello\TeyaPayment\TeyaSecurePayClient([
            'MerchantId' => '9256684', 
            'PaymentGatewayId' => 7, 
            'SecretKey' => 'cdedfbb6ecab4a4994ac880144dd92dc',
            'RedirectSuccess' => '/SecurePay/SuccessPage.aspx',
            'RedirectSuccessServer' => 'SUCCESS_SERVER',
            "Currency" => "HUF"
        ]);

        $this->client->addItems([
            new \Redwello\TeyaPayment\Model\TeyaItem('Test Item', 1, 10000)
        ]);

        //prepare transaction and redirect user
        $response = $this->client->start([
            "reference" => "TEST00000001",
        ]);

        header('Location: '.$response['paymentUrl']);
      
        //or a shortcut:
        $this->client->open([
            "reference" => "TEST00000001",
        ]);

Logging

 $logger = new Logger('TeyaSecurePayClient');
 $logger->pushHandler(new StreamHandler('teya_secure_pay_client.log'), \Monolog\Level::Debug);

 $client = new Redwello\TeyaPayment\TeyaPaymentGatewayClient([
            'PrivateKey' => '856293_pr0lxnW8PG1SeCwVJ3WPH0lXCeU0/sYLtX'
            'logger' => $logger
        ]);

SecurePay Playground

playground.php

Contribution

Contributions are welcome! If you'd like to improve this project, fork the repository, create a new branch, and submit a pull request. Please follow best practices and ensure your code is clean and well-documented.

统计信息

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

GitHub 信息

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

其他信息

  • 授权协议: MIT
  • 更新时间: 2026-04-10