定制 iliakondrashov/inmotiv-sdk-php 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

iliakondrashov/inmotiv-sdk-php

最新稳定版本:v0.3.2

Composer 安装命令:

composer require iliakondrashov/inmotiv-sdk-php

包简介

InMotiv RDC SOAP PHP client

README 文档

README

Build Status

InMotiv (https://www.rdc.nl/) is one of the official RDW partners. It provides SOAP endpoints to access RDW database. For example you can check whether driver licence is valid or not by number and owner birthday.

Requirements

  • PHP 7.1
  • SOAP extension

How to use

Fill your InMotiv credentials and driver license details in the code below:

$endpointProvider = new ProductionEndpointProvider();
$xmlBuilder = new XmlBuilder();
$client = new InMotivClient(
    $endpointProvider,
    $xmlBuilder,
    111111,
    'rdc111111999',
    'xxxXXXxxx'
);
var_dump($client->isDriverLicenceValid('1111111111', 1990, 1, 1));

And result should be

bool(true)

See full example in example.php.

Debug mode

Request and response headers and bodies can be printed by forcing debug mode of the client. Notice the last optional argument:

$client = new InMotivClient(
    $endpointProvider,
    $xmlBuilder,
    111111,
    'rdc111111999',
    'xxxXXXxxx',
    true
);

Now lots of details became visible.

What is currently implemented

  • driver licence check
  • very basic vehicle details by numberplates

How to test

Since InMotiv does not have open sandbox account, you have to create .env file in the project root with your credentials. Also you need to provide a valid driver licence and numberplates details.

INMOTIV_CLIENT_NUMBER=111111
INMOTIV_USERNAME=rdc111111999
INMOTIV_PASSWORD=xxxXXXxxx

DRIVER_LICENCE_NUMBER=xxxxxxxxxx
BIRTHDAY_YEAR=2000
BIRTHDAY_MONTH=10
BIRTHDAY_DAY=10

NUMBERPLATES_CAR=22PBR4
NUMBERPLATES_MOTORCYCLE=05MMGG
NUMBERPLATES_MOTORCYCLE_ELECTRIC=81MGVP
NUMBERPLATES_MOTORCYCLE_WITHOUT_FIRST_REGISTRATION_DATE=07MJHJ

Then just run ./vendor/bin/phpunit. Everything should be green.

统计信息

  • 总下载量: 4.65k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 0
  • 点击次数: 2
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 1
  • Forks: 1
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2015-11-05

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固