jwohlfert23/laravel-avalara
最新稳定版本:0.3.3
Composer 安装命令:
composer require jwohlfert23/laravel-avalara
包简介
This is my package laravel-avalara
README 文档
README
We built this client because of problems with the existing SDK provided by Avalara:
- Lack of support for PHP8.
- No transformation of responses to PHP models/objects.
- Avalara only has a 99.5% SLA, and we thought built-in retries for certain endpoints would be helpful.
Installation
You can install the package via composer:
composer require jwohlfert23/laravel-avalara
You should publish the config file:
php artisan vendor:publish --tag="avalara-config"
Usage
$transaction = new CreateTransaction(); $transaction->date = now(); $transaction->type = AvalaraDocType::SALES_ORDER; $transaction->customerCode = 'jack@gmail.com'; $transaction->addresses['ShipFrom'] = new \App\Services\Avalara\Models\AddressModel(); $transaction->addresses['ShipTo'] = new \App\Services\Avalara\Models\AddressModel(); $transaction->lines[] = new CreateLineItem( number: 0, amount: 50.00, quantity: 2, taxCode: 'P0000000' ); return AvalaraClient::createTransaction($transaction); // or return $transaction->create();
License
The MIT License (MIT). Please see License File for more information.
统计信息
- 总下载量: 12.27k
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 1
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2022-05-06