zqzl/mofxsdk

There is no license information available for the latest version (1.7.0) of this package.

zqzl's mofxsdk package

1.7.0 2020-06-28 04:06 UTC

This package is not auto-updated.

Last update: 2024-05-12 23:26:19 UTC


README

Install

composer require zqzl/mofxsdk -vvv

Usage

<?php

$dispatch = new \Zqzl\Mofxsdk\Dispatch([
    'token' => '123',
    'debug' => true,
    'log' => [
        'name' => 'mofx',
        'file' => __DIR__ . '/mofx.log',
        'level' => 'debug',
        'permission' => 0777,
    ],
]);


$params = [];

// 获取token 
$result = $dispatch->getToken($params);

// 获取商品列表
$result = $dispatch->goodList($params);

// 获取商品详情
$result = $dispatch->goodInfo($params);

// 创建订单
$result = $dispatch->createOrder($params);

// 订单支付
$result = $dispatch->pay($params);