Download the PHP
package pspark/sdk without Composer
On this page you can find all versions of the php package
pspark/sdk. It is possible to download/install
these versions without Composer. Possible dependencies are resolved
automatically.
Vendor pspark Package sdk Short Description PHP SDK for merchant REST API License
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.
You should have jwt-key and api-key keys to be able to use our API via this SDK.
jwt-key is a CSR file.
Generating a CSR file
A Certificate Signing Request (.csr) file is required to authenticate an API user and to get your API-Key.
The .csr file contains your API public key that will be used to validate the request signature.
To generate your RSA 4096 private key (stored in pspakr_secret.key) for signing requests, use the following command
line:
Make sure you keep the API secret key (pspark_secret.key) safe and secure. Do not share your API secret key with
anyone.
To get your API-key you should upload your pspark_public_key in
the cabinet.pspark.io.
You can easily configure SDK by using your framework's DI (service provider e.t.c.) or create your own simple factory.
Validation errors
The API doesn't implement all RESTFull API requirements and has its own response structure.
All HTTP responses from the server will have 200 status code. So, if your request will have some validation errors,
the code, and it's description will be presented in the response body as shown bellow.
Response Example
Each time when the server's response will have some validation errors, the SDK will throw ResponseValidationException
exception. All types of validation errors can be find in the API Doc.
Requiresext-curl Version
* ext-json Version
* php Version
>=8.1 firebase/php-jwt Version
^6.3
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 pspark/sdk contains the following files
Loading the files please wait ....
Loading please wait ...
Before you can download the PHP files, the dependencies should be resolved. This can take some minutes. Please be patient.