Code Monkey home page Code Monkey logo

laravel-zhima's Introduction

zhima for Laravel 5.*

Installation

  • Run composer require zmop/laravel-zhima

  • Run php artisan vendor:publish

Usage

授权:

        //1:按照手机号进行授权 {"mobileNo":"15158657683"}
        //2:按照身份证+姓名进行授权 {"name":"张三","certType":"IDENTITY_CARD","certNo":"330100xxxxxxxxxxxx"}
        $request = new ZhimaAuthInfoAuthorizeRequest();
        $request->setChannel("app");
        $request->setPlatform("zmop");
        $req->setIdentityType("2");// 必要参数
        $req->setIdentityParam("{\"name\":\"张三\",\"certType\":\"IDENTITY_CARD\",\"certNo\":\"330100xxxxxxxxxxxx\"}");// 必要参数
        $req->setBizParams("{\"auth_code\":\"M_H5\",\"channelType\":\"app\",\"state\":\"商户自定义\"}");//
        $req->setChannel("app");
        $req->setPlatform("zmop");
        $url = Zmop::generatePageRedirectInvokeUrl($req)

信用评分:

         $request = new ZhimaCreditScoreGetRequest();
         $request->setChannel("apppc");
         $request->setPlatform("zmop");
         $request->setTransactionId("201512100936588040000000465158");// 必要参数
         $request->setProductCode("w1010100100000000001");// 必要参数
         $request->setOpenId("268810000007909449496");// 必要参数
         $response = Zmop::execute($request);
         echo json_encode($response);

Config

set the options in config/zmop.php ,

laravel-zhima's People

Watchers

 avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.