Download the PHP package apruvd/php_sdk_v4 without Composer

On this page you can find all versions of the php package apruvd/php_sdk_v4. 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 php_sdk_v4

apruvd-v4-php

Lightweight PHP SDK for integrating with the Apruvd API v4

Services

APIService

The main primary service containing 1:1 method mapping on available API endpoints.

APIAsyncResponseService

The optional service to grab/transform $_POST JSON data into the appropriate response model. The

Authentication

There are 2 viable authentication patterns for the v4 API, API Keys and OAuth 2.0

API Keys

Consisting of a key/secret pairthat is generated in the application settings page. Used as a basic authentication scheme. All calls can be made using this key key set - using the OAuth 2.0 flow is completely option

OAuth 2.0

This method uses two tokens, an access token and a refresh token. Using your API Key, you can get a refresh token. You can then use that token to create an access token, which should then be used during requests to authenticate. Note that access tokens expire more quickly than refresh tokens, but both will expire in time.

Using your API Key you can programatically request a refresh token using the following method:

A token set will be returned and automatically binded to the service class. When new tokens are generated an optional anonymous callback function can be passed to the API service as an event handler.

If a refresh token has been binded via service constructor, subsequent API calls will automatically request a new access token on missing or failed attempts. This process can additionally be handled via direct call.

It's recommended that the onAccessTokenUpdate method be used with your prefered storage routine and that the refresh and access tokens can be recalled and passed via service constructor.

Models

Transaction and Cart Contents

For model details please refer to the codebase and the API docs. All model types can take object/array property sets for constructor hydration.

Responses

All responses are well formed and documented. The following properties of the APIModel class are available to all responses, with each response binding it's own additional properties.

API Methods and Endpoints

readMerchants(String $id) : ReadMerchantsResponse

Submits to as GET

createMerchantAccessToken() : CreateMerchantAccessTokenResponse

Submits to as POST

createMerchantRefreshToken() : CreateMerchantRefeshTokenResponse

Submits to as POST

listWebhookAPIKeys(int $page, int $page_size) : ListWebhookAPIKeysResponse

Submits to as GET

createWebhookAPIKey(WebhookAPIKey $webhook_api_key) : UpsertWebhookAPIKeyResponse

Submits to as POST

readWebhookAPIKey(String $id) : ReadWebhookAPIKeyResponse

Submits to as GET

updateWebhookAPIKey(String $id, WebhookAPIKey $webhook_api_key) : UpsertWebhookAPIKeyResponse

Submits to as PUT

partialUpdateWebhookAPIKey(String $id, WebhookAPIKey $webhook_api_key) : UpsertWebhookAPIKeyResponse

Submits to as PATCH

deleteWebhookAPIKey(String $id) : APIResponse

Submits to as DELETE

listWebhooks(int $page, int $page_size) : ListWebhooksResponse

Submits to as GET

createWebhook(Webhook $webhook) : UpsertWebhookResponse

Submits to as POST

readWebhook(String $id) : ReadWebhookResponse

Submits to as GET

updateWebhook(String $id, Webhook $webhook) : UpsertWebhookResponse

Submits to as PUT

partialUpdateWebhook(String $id, Webhook $webhook) : UpsertWebhookResponse

Submits to as PATCH

deleteWebhook(String $id) : APIResponse

Submits to as DELETE

createTransaction(Transaction $transaction) : UpsertTransactionResponse

Submits to as POST

readOrderByID(String $id) : ReadTransactionResponse

Submits to as GET

updateOrderByID(String $id, Transaction $transaction) : UpsertTransactionResponse

Submits to as PUT

partialUpdateOrderByID(String $id, Transaction $transaction) : UpsertTransactionResponse

Submits to as PATCH

createSession(Session $session) : CreateSessionResponse

Submits to as POST

updateSession(String $id, Session $session) : UpsertSessionResponse

Submits to as PUT

partialUpdateSession(String $id, Session $session) : UpsertSessionResponse

Submits to as PATCH

Helper Methods

onAccessTokenUpdate(Closure $callback)

Registers the single event handler for Token Update events. This maps to a single property, only one callback per event cycle.

setToken(String $token)
getToken() : String
setRefreshToken(String $token)
getRefreshToken() : String

All versions of php_sdk_v4 with dependencies

PHP Build Version
Package Version
Requires nategood/httpful Version ^0.2.20
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 apruvd/php_sdk_v4 contains the following files

Loading the files please wait ....