Download the PHP package pingencom/pingen2-sdk-php without Composer
On this page you can find all versions of the php package pingencom/pingen2-sdk-php. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download pingencom/pingen2-sdk-php
More information about pingencom/pingen2-sdk-php
Files in pingencom/pingen2-sdk-php
Package pingen2-sdk-php
Short Description Official PHP Pingen SDK for API V2
License BSD-3-Clause
Informations about the package pingen2-sdk-php
Requirements
You need to have an account in Pingen and obtain OAuth credentials for your desired grant type (usually client_credentials).
How to obtain these, are described here: https://api.pingen.com/documentation#section/Authentication/How-to-obtain-a-Client-ID
Installation
Require the package via composer (Get composer here: https://getcomposer.org/download/)
composer require pingencom/pingen2-sdk-php
Environments
We have two Environments available: Production and Staging (see https://api.pingen.com/documentation#section/Basics/Environments)
This SDK supports staging as well. When initiating the provider (see Usage), the optional 'staging' attribute should be set, as well as when creating an endpoint object.
Usage
The simplest way to integrate is using the client credentials grant (see https://api.pingen.com/documentation#section/Authentication/Which-grant-type-should-i-use)
Examples & Docs
The integration tests, available in this repository, give you many examples and flows, which can provide a solid starting ground to use the SDK.
For detailed research, documentation and examples, our API Docs are here: https://api.pingen.com/documentation
On the right-hand side of every endpoint you can see request samples for all languages and SDKs, which you can copy and paste into your application.
Bugreport & Contribution
If you find a bug, please either create a ticket in GitHub, or initiate a pull request.
Versioning
We adhere to semantic (major.minor.patch) versioning (https://semver.org/). This means that:
- Patch (x.x.patch) versions fix bugs
- Minor (x.minor.x) versions introduce new, backwards compatible features or improve existing code.
- Major (major.x.x) versions introduce radical changes which are not backwards compatible.
In your automation or procedure you can always safely update patch & minor versions without the risk of your application failing.
Testing
There are two test suites in phpunit.xml:
- default – Fast, Offline unit tests (HTTP is mocked). This is what CI runs on every change and it does not require credentials.
- integration – talks to the real Pingen Staging API. Is excluded from running in CI and every test is tagged
#[Group('integration')].
Prepare the docker image and composer:
Running the unit tests (Http Mocked)
Running the integration tests (Live calls against Pingen Staging API, Credentials required in .env)
Integration test Credentials
Credentials come from a .env file in the repository root (copy .env.example and replace with your values)
Without PINGEN2_CLIENT_ID / PINGEN2_CLIENT_SECRET the whole integration suite is skipped (not failed).
Static analysis and style
Testing without Docker
We highly recommend to use our prepared docker image for running tests to ensure all necessary packages and versions are available. However if you prefer you can always install anything necessary locally and run all commands without the docker-compose run --rm php prefix
All versions of pingen2-sdk-php with dependencies
ext-json Version *
league/oauth2-client Version ^2.6
illuminate/support Version ^10.0|^11.0|^12.0|^13.0
illuminate/http Version ^10.0|^11.0|^12.0|^13.0