Download the PHP package zaver/sdk without Composer

On this page you can find all versions of the php package zaver/sdk. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package sdk

Zaver PHP SDK

This is the officially supported PHP SDK for Zaver Checkout, developed as a Composer package by Krokedil.

Requirements

Installation

Usage

All classes and methods are properly type-hinted with complementary PHPDoc - please see the API documentation for further details.

Examples

Initialize payment

Receive payment callback

Do a refund

Receive refund callback (e.g. after refund approval)

List the available payment methods

getPaymentMethods() returns the methods Zaver offers the merchant for a market, optionally narrowed down by amount and currency. Merchants with several variants of a method (for example PAY_LATER in 14, 30 or 90 days) get one entry per variant, identified by paymentMethodVariant; other merchants get one entry per method without a variant:

Show a credit method as its title and description, a divider, the credit warning and the representative example. getPaymentMethod() and getPaymentMethodVariant() on a PaymentStatusResponse tell which method (and variant) the payer chose; both are null until the payer has made a choice.

Price an amount (credit pricing)

getCreditPricing() tells which consumer credit options you may show for an amount before any payment exists: single invoices (PAY_LATER, with the payment plan the unpaid balance converts to on the due date), installments and monthly invoices, each with the representative example in the requested language. Shops use it for "from X per month" badges and loan calculators on product pages:

getPayLaterOptions() and getInstallmentOptions() filter the options by method. An empty getOptions() means Zaver offers no credit for the amount, for instance below the merchant's minimum; it is not an error.

Identify your integration

Every request carries a User-Agent header with the SDK and PHP versions. Add your platform and plugin so Zaver can see which versions a merchant runs when you ask for support:

The same parameter exists on Refund and Manage. Without it, the header is zaver-php-sdk/<version> PHP/<version>.

Handle API errors

All API and transport failures throw Zaver\SDK\Utils\Error:


All versions of sdk with dependencies

PHP Build Version
Package Version
Requires php Version >=7.4.0
ext-json Version *
guzzlehttp/guzzle Version ^7.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package zaver/sdk contains the following files

Loading the files please wait ...