hakimrazalan/chip-php-sdk

PHP framework agnostic to work with CHIP Asia API

Installs: 168

Dependents: 0

Suggesters: 0

Security: 0

Stars: 0

Watchers: 1

Forks: 0

Open Issues: 3

pkg:composer/hakimrazalan/chip-php-sdk

1.3 2026-02-11 06:54 UTC

This package is auto-updated.

Last update: 2026-02-11 07:13:57 UTC


README

Installation

Composer

To install through composer by using the following command:

composer require php-http/guzzle7-adapter hakimrazalan/chip-php-sdk

HTTP Adapter

Refer PHP-HTTP Clients & Adapters for other supported clients and adapters.

Get Started

Creating client

To create CHIP client, you need to know which service you want to use - Collect / Send. Use the following codes:

use Chip\Client;

// To use Collect
$collect = Client::makeCollect("myApiKey");

// To use Send
$send = Client::makeSend("myApiKey", "secretKey");

You can also use a config object to make the client easier to extend:

use Chip\Client;
use Chip\Config;

$collect = Client::makeCollect(
    Config::collect("myApiKey")->withVersion("v1")
);

$send = Client::makeSend(
    Config::send("myApiKey", "secretKey")
        ->withSandbox(true)
);

Alternatively, you could configure Http\Client\Common\HttpMethodsClient manually

use Chip\Client;

// To use Collect
$http = Laravie\Codex\Discovery::client();
$collect = Client::makeCollect("myApiKey", $http);

// To use Send
$send = Client::makeSend("myApiKey", "secretKey", $http);

Use Sandbox

Sandbox options is only supported for Send API. To use sandbox environment:

$send->useSandbox();

Usages

For Collect → Here

For Send → Here