finbox/sdk

v1.0.1 2022-05-05 16:07 UTC

This package is auto-updated.

Last update: 2024-09-05 21:24:03 UTC


README

Finbox

| 与Finbox系统交互的主要接口。

参数

方法

Result

属性

方法

示例

    $finbox = new Finbox(
        '{TOKEN}',
        '{SECRET}',
        '{API_URL}'
    );

    $command = new ClientCreateCommand(
        ClientType::INDIVIDUAL,
        [
            'name' => 'Test client name',
            'surname' => 'Test client surname',
            'patronymic' => 'Test client patronymic',
        ],
        '+7 (000) 000-00-00'
    );

    $result = $finbox->send($command);
    
    if ($result->success) {
        $newClient = $result->getResult();    
    } else {
        die($result->errorMessage);
    }

命令

ClientCreateCommand

| 创建新客户

参数

结果

成功创建客户时,将返回 ClientEntity

ClientGetCommand

| 通过ID查询客户

参数

结果

成功查询时,将返回 ClientEntity