onenet/laravel
Composer 安装命令:
composer require onenet/laravel
包简介
This package can be used to connect to onenet
README 文档
README
Note: The Cache in laravel will be used to determine duplicate data. Please try to configue the cache as nosql (redis,etc.)
Onenet for laravel is a laravel library for OneNet platform data reception
install
- Insatll the package
Please read the OneNet development documentation before use
composer require "hazmaaslam-cs/laravel-onenet-sdk:1.1.0"\
configure
- manually register 'ServiceProvider'
Onenet\Laravel\OneNetServiceProvider::class,
- Create a configuratioin file:
php artisan vendor:publish --provider="Onenet\Laravel\OneNetServiceProvider"
- (optional) Edit config/onenet.php file or write the following in the .env file
OnetNet_Token=Token OnetNet_EncodingAESKey=Message encryption and decryption key OneNet_APIKey=Key in device operation 4. Add the appearance to the 'alaises' in 'confit/app.php' (laravel 5.5+ doesn't need to be added manually) ```php 'OneNet'=>Onenet\Laravel\Facades\OneNet::class,
Receive platform data from
Lraravel csrf issues
- Exclude api routing in CSRF middleware 2 .Turn off CSRF middleware (not recommended)
The following is an example of receiving push data from the OneNet platform:
If your domain name app.devis , please log in to the "Third Party Open Platform" of the OneNet platform and modify the "URL (please fill in the server configuration)" as: http://app.dev/onenet.
routing:
Route::any('\onenet','OneNetController@onenet'); > Note: It must be Route::any, because when the OneNet platform is certified, it is when the GETplatform message is pushed.POST
onenet/laravel 适用场景与选型建议
onenet/laravel 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 20 次下载、GitHub Stars 达 1, 最近一次更新时间为 2022 年 03 月 22 日, 在 PHP 生态内属于活跃度较高的组件。
我们在过去多个企业项目中使用过 onenet/laravel 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。
基于 onenet/laravel 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。
线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。
承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。
统计信息
- 总下载量: 20
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 1
- 点击次数: 0
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2022-03-22