| 12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758 |
- <?php
- /**
- * 重庆赤晓店信息科技有限公司
- * https://www.chixiaodian.com
- * Copyright (c) 2023 赤店商城 All rights reserved.
- */
- /*
- * This file is part of the overtrue/wechat.
- *
- * (c) overtrue <i@overtrue.me>
- *
- * This source file is subject to the MIT license that is bundled
- * with this source code in the file LICENSE.
- */
- namespace ByteDance\MiniProgram\Order;
- use ByteDance\Kernel\Exceptions\InvalidArgumentException;
- use ByteDance\Kernel\Exceptions\InvalidConfigException;
- use ByteDance\Kernel\Support;
- use ByteDance\Kernel\Support\Collection;
- use ByteDance\Kernel\BaseClient;
- use Psr\Http\Message\ResponseInterface;
- class Client extends BaseClient
- {
- /**
- * Unify order.
- *
- * @param array $params
- *
- * @return ResponseInterface|Collection|array|object|string
- *
- * @throws \ByteDance\Kernel\Exceptions\InvalidArgumentException
- * @throws \ByteDance\Kernel\Exceptions\InvalidConfigException
- * @throws \GuzzleHttp\Exception\GuzzleException
- */
- public function unify(array $params)
- {
- return $this->httpPostJson('api/apps/ecpay/v1/create_order', $params);
- }
- /**
- * Refund order.
- *
- * @param array $params
- *
- * @return ResponseInterface|Collection|array|object|string
- *
- * @throws \ByteDance\Kernel\Exceptions\InvalidArgumentException
- * @throws \ByteDance\Kernel\Exceptions\InvalidConfigException
- * @throws \GuzzleHttp\Exception\GuzzleException
- */
- public function refund(array $params)
- {
- return $this->httpPostJson('api/apps/ecpay/v1/create_refund', $params);
- }
- }
|