eklundkristoffer / assently
此包已被放弃且不再维护。未建议替代包。
Assently API for Laravel
dev-master
2016-09-02 14:48 UTC
Requires
- guzzlehttp/guzzle: ^6.2
This package is not auto-updated.
Last update: 2020-01-24 16:23:31 UTC
README
使用composer安装:运行 composer require eklundkristoffer/assently
将 Assently\AssentlyServiceProvider
添加到您的提供者数组中。
将以下行添加到您的 .env 文件中,并用您自己的密钥更新它们
ASSENTLY_DEBUG=true
ASSENTLY_KEY=<KEY_HERE>
ASSENTLY_SECRET=<SECRET_HERE>
示例
创建并发送新案例。
$assently = new Assently\Assently; $assently->authenticate(env('ASSENTLY_KEY'), env('ASSENTLY_SECRET')); $data = [ 'name' => 'Employmeent agreement '. rand(111, 999), 'NameAlias' => 'employmeent-agreement-'. rand(111, 999), 'AllowedSignatureTypes' => [ 'electronicid' ], 'Documents' => [ $assently->document()->create('path/to/document.pdf') ], "Parties" => [ $assently->party()->create([ 'Name' => 'John Doe', 'EmailAddress' => 'johndoe@gmail.com', 'AnyoneCanSign' => false ]) ] ]; $assently->case()->create($data)->send();
发送案例提醒
$assently = new Assently\Assently; $assently->authenticate(env('ASSENTLY_KEY'), env('ASSENTLY_SECRET')); $assently->case()->find('5a0e0869-6807-4b79-3712-466ea5cca5ce')->remind();