2017 © Pedro Peláez
 

project insurance-sdk

haimianbao insurance SDK

image

haimianbao/insurance-sdk

haimianbao insurance SDK

  • Friday, July 18, 2014
  • by twocabbages
  • Repository
  • 1 Watchers
  • 0 Stars
  • 10 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 2 Versions
  • 0 % Grown

The README.md

insurance-sdk

安装

终端, (*1)

composer require "haimianbao/insurance-sdk":"dev-master"

composer.json, (*2)

"require": {
   "haimianbao/insurance-sdk" : "dev-master"
}

海绵保保险购买接口调用使用

use haimianbao\InsuranceSdk;
require __DIR__ . '/vendor/autoload.php';

$appkey = '';       //系统分配得到
$appsecret = '';    //系统分配得到

//InsuranceSdk::ENV_TEST 测试环境
//InsuranceSdk::ENV_PRO 正式环境
$insurance_sdk = new InsuranceSdk( $appkey, $appkey, InsuranceSdk::ENV_TEST );


$insurance_code = 'B604FA6F';    //保险险种代号  每种保险对应一个
//获取保险介绍页面
var_dump($insurance_sdk->info($insurance_code));


//获取保险详情
var_dump($insurance_sdk->detail($insurance_code));


//获取保险有效地区
var_dump($insurance_sdk->region($insurance_code));


$mobile = '15888661177';   //用户手机号
//发送手机验证码
var_dump($insurance_sdk->verify($mobile));


//购买保险
//城市根据 $insurance_sdk->region($insurance_code) 中获取的 地区
var_dump($insurance_sdk->buy($insurance_code, '用户姓名', $mobile, '手机验证码 int(4)', '身份证号 string(18)', '用户省份 string(16) 如:北京市', '用户城市 string(16) 如:北京市', '您的代理号 int(4)'));

The Versions

18/07 2014

dev-master

9999999-dev http://www.okchexian.com/

haimianbao insurance SDK

  Sources   Download

BSD-3-Clause

The Requires

 

sdk insurance haimianbao

17/07 2014

v1.0.0

1.0.0.0 http://www.okchexian.com/

haimianbao insurance SDK

  Sources   Download

BSD-3-Clause

The Requires

 

sdk insurance haimianbao