2017 © Pedro Peláez
 

library bunq-api

An API client that talks to bunq

image

verschoof/bunq-api

An API client that talks to bunq

  • Thursday, June 8, 2017
  • by verschoof
  • Repository
  • 1 Watchers
  • 1 Stars
  • 23 Installations
  • PHP
  • 1 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 4 Versions
  • 0 % Grown

The README.md

Build Status, (*1)

Build Status, (*2)

Symfony

If you use Symfony see https://github.com/verschoof/bunq-api-bundle, (*3)

Installation

Require the package, (*4)

composer require verschoof/bunq-api

Now setup the classes in your DI (example https://github.com/verschoof/bunq-api-bundle/blob/master/src/Resources/config/services.yml)., (*5)

<?php

use Bunq\Certificate\Storage\FileCertificateStorage;
use Bunq\HttpClientFactory;
use Bunq\Service\DefaultInstallationService;
use Bunq\Service\DefaultTokenService;
use Bunq\Token\Storage\FileTokenStorage;

include __DIR__ . '/vendor/autoload.php';

$bunqCertificateStorage = new FileCertificateStorage('var/data/bunq');

$bunqHttpInstalltionClient = HttpClientFactory::createInstallationClient(
    'https://sandbox.public.api.bunq.com/v1',
        $bunqCertificateStorage
);

$bunqInstallationService = new DefaultInstallationService(
    $bunqHttpInstalltionClient,
    $bunqCertificateStorage,
    'apiKey',
    ['10.0.0.1']
);

$bunqTokenStorage       = new FileTokenStorage('var/data/bunq');
$bunqTokenService       = new DefaultTokenService($bunqInstallationService, $bunqTokenStorage, $bunqCertificateStorage);

$bunqHttpClient = HttpClientFactory::create($bunqCertificateStorage, $bunqTokenService, $bunqCertificateStorage);

$bunqClient = new \Bunq\Client($bunqHttpClient);

Usage

For example to get all users from bunq, (*6)

$userResource = new \Bunq\Resource\UserResource($bunqClient);
$userResource->listUsers();

Thats about it., (*7)

Todo

  • [ ] Implement Money object https://github.com/moneyphp/money

The Versions

08/06 2017

dev-master

9999999-dev

An API client that talks to bunq

  Sources   Download

GNU GENERAL PUBLIC LICENSE

The Requires

 

The Development Requires

08/06 2017

v2.0.0

2.0.0.0

An API client that talks to bunq

  Sources   Download

GNU GENERAL PUBLIC LICENSE

The Requires

 

The Development Requires

21/05 2017

v1.0.1

1.0.1.0

An API client that talks to bunq

  Sources   Download

GNU GENERAL PUBLIC LICENSE

The Requires

 

The Development Requires

20/05 2017

v1.0.0

1.0.0.0

An API client that talks to bunq

  Sources   Download

GNU GENERAL PUBLIC LICENSE

The Requires

 

The Development Requires