Download the PHP package shebaoting/laravel-huifu without Composer

On this page you can find all versions of the php package shebaoting/laravel-huifu. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package laravel-huifu

Laravel Huifu

Latest Version on Packagist Total Downloads Laravel 12

可能是最懂开发者、最“傻瓜化”的汇付天下(斗拱平台)Laravel 扩展包。

shebaoting 倾力打造,专为 Laravel 12 设计。它不仅封装了复杂的汇付 SDK,还彻底解决了 wx_data 多层嵌套、金额精度格式化、私有属性解析等所有初学者容易“踩坑”的问题。

✨ 特性

⚙️ 安装

通过 Composer 安装:

发布配置文件:

🛠️ 配置

在你的 .env 文件中添加以下配置:

🚀 快速上手

1. 微信小程序支付(自动处理嵌套)

无需关心汇付文档里复杂的 method_expandwx_data 字符串,包内自动帮你处理:

2. 傻瓜式分账(延迟结算)

在拼团成功或核销服务后,将钱分给商户:

3. 一键处理回调(自动验签)

在你的回调路由中,一行代码完成验签和逻辑处理:

4. 商户进件:证照上传

5. 查询商户余额

🏗️ 万能请求工厂

如果你需要调用包内未直接封装的汇付接口,可以使用 request 方法,它会自动帮你填充日期、流水号和主商户号:

📖 异常处理

本扩展包会抛出 Shebaoting\Huifu\Exceptions\HuifuApiException。 你可以通过 $e->raw 获取汇付接口返回的完整原始数据,通过 $e->getMessage() 获取汇付给出的中文错误描述。

🤝 贡献

如果你在使用过程中发现了 Bug 或有更好的改进建议,欢迎提交 PR。

📄 开源协议

本项目遵循 MIT 开源协议。


Maintained by shebaoting


All versions of laravel-huifu with dependencies

PHP Build Version
Package Version
Requires php Version ^8.2
illuminate/support Version ^11.0|^12.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package shebaoting/laravel-huifu contains the following files

Loading the files please wait ...