PHPackages                             merch-one/php-api-sdk - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [API Development](/categories/api)
4. /
5. merch-one/php-api-sdk

ActiveLibrary[API Development](/categories/api)

merch-one/php-api-sdk
=====================

SDK for MerchOne API integration

1.0.4(3y ago)01411MITPHPPHP &gt;=7.4

Since Apr 4Pushed 3y ago1 watchersCompare

[ Source](https://github.com/merch-one/php-api-sdk)[ Packagist](https://packagist.org/packages/merch-one/php-api-sdk)[ RSS](/packages/merch-one-php-api-sdk/feed)WikiDiscussions master Synced 3w ago

READMEChangelog (5)Dependencies (3)Versions (6)Used By (1)

 PHP SDK for MerchOne API integration
--------------------------------------

[](#----php-sdk-for-merchone-api-integration)

 [![Packagist Version](https://camo.githubusercontent.com/0360788c1a50140f93c3527368b904f6b6830b6ba426693e31ccea3c616ef184/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f6d657263682d6f6e652f7068702d6170692d73646b3f636f6c6f723d6f72616e6765267374796c653d666c61742d737175617265)](https://packagist.org/packages/merch-one/php-api-sdk) [![License](https://camo.githubusercontent.com/e3425aaa58626d44e8eaf43da3d16de7e500060325c67e015bb46749f81bb816/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f6c2f6d657263682d6f6e652f7068702d6170692d73646b3f636f6c6f723d627269676874677265656e267374796c653d666c61742d737175617265)](https://packagist.org/packages/merch-one/php-api-sdk) [![Minimum PHP version](https://camo.githubusercontent.com/a2c9629ef5cf6fe83cb4b03d7eda470a05f8e9f3b716975688cc5189bb0e9c65/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f646570656e64656e63792d762f6d657263682d6f6e652f7068702d6170692d73646b2f7068703f7374796c653d666c61742d737175617265)](https://packagist.org/packages/merch-one/php-api-sdk) [![GitHub last commit](https://camo.githubusercontent.com/12d8a1a8de52fee37f11c76012d5b5859806c3bee1b8f6c34ed1fc20be4e6624/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f6c6173742d636f6d6d69742f6d657263682d6f6e652f7068702d6170692d73646b3f636f6c6f723d626c7565267374796c653d666c61742d737175617265)](https://packagist.org/packages/merch-one/php-api-sdk)

This package provide a set of tools that allow developers to easily integrate with MerchOne API.

Installation
------------

[](#installation)

```
composer require merch-one/php-api-sdk
```

Overview
--------

[](#overview)

- [Introduction](#introduction)
- [Basic Usage](#basic-usage)
- [Helpers](#helpers)
- [Exceptions](#exceptions)

---

### Introduction

[](#introduction)

**Client provide 3 different API's to interact with.**

- Catalog API
- Orders API
- Shipping API

**To get the list of available endpoints, please check [MerchOne API Documentation](https://docs.merchone.com/api-reference)**

---

### Basic Usage

[](#basic-usage)

**Create an instance of `MerchOne\PhpApiSdk\Http\Client`**

```
use MerchOne\PhpApiSdk\Http\Client;

class MyService
 {
    private Client $httpClient;

    public function __construct()
    {
        $this->httpClient = new Client();
    }

    public function doSomething(): void
     {
        // authenticate client using credentials
        $this->httpClient->auth(
            'your-store-user',
            'your-store-key'
        );

        // or authenticate client using base64 encoded credentials
        $this->httpClient->basicAuth(
            base64_encode('your-store-user:your-store-key'),
        );

        /* Interact with Catalog API */
        /** @var \MerchOne\PhpApiSdk\Contracts\Clients\CatalogApi $catalogApi */
        $catalogApi = $this->httpClient->catalog();

        /* Interact with Orders API */
        /** @var \MerchOne\PhpApiSdk\Contracts\Clients\OrdersApi $ordersApi */
        $ordersApi = $this->httpClient->orders();

        /* Interact with Shipping API */
        /** @var \MerchOne\PhpApiSdk\Contracts\Clients\ShippingApi $shippingApi */
        $shippingApi = $this->httpClient->shipping();

        // switch API version you interact with
        $this->httpClient->setVersion($version);

        // get current API version
        $this->httpClient->getVersion();
    }
}
```

- The `Client` class accepts two parameters:
    - `$version` - API version to interact with. Default value is `beta`.
        - See [Helpers](#helpers) for available versions.
    - `$clientOptions` - Custom options to use with request.
        - See [Guzzle Documentation](https://docs.guzzlephp.org/en/stable/request-options.html) for available options.
        - The `User-Agent`, `Accept` and `Content-Type` headers, as well as `http_error` properties **CAN NOT** be overwritten !

---

### Helpers

[](#helpers)

```
use MerchOne\PhpApiSdk\Util\MerchOneApi;

// get the list of all available API versions
MerchOneApi::getVersions();
```

- Class `MerchOne\PhpSdk\Util\OrderStatus` provides a full list of Order statuses.

Check more in [MerchOne API Documentation](https://docs.merchone.com/api-reference/orders#order-status)

---

### Exceptions

[](#exceptions)

The package can throw the following exceptions:

ExceptionReason*MerchOneApiClientException*Request is not correct or validation did not pass.*MerchOneApiServerException*A server error occurred.*InvalidApiVersionException*An invalid API version was provided to the Client.*InvalidCredentialsException*Invalid API credentials was provided to the Client.### Tests

[](#tests)

Package comes with a set of tests to ensure that everything works as expected. To run tests, execute the following command:

```
./vendor/bin/phpunit
```

###  Health Score

24

—

LowBetter than 31% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity10

Limited adoption so far

Community11

Small or concentrated contributor base

Maturity49

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 62.5% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~2 days

Total

5

Last Release

1166d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/093aed183e47a051d6e7392472d60f13ac0cfaf98cc56d2ab2ce2842fa880103?d=identicon)[merch-one](/maintainers/merch-one)

---

Top Contributors

[![allanvb](https://avatars.githubusercontent.com/u/53047487?v=4)](https://github.com/allanvb "allanvb (5 commits)")[![merch-one](https://avatars.githubusercontent.com/u/110233410?v=4)](https://github.com/merch-one "merch-one (3 commits)")

---

Tags

apiapi-clientapi-client-phpapi-librarymerchonemerchone-apiphpprintondemandsdksdk-phpapisdkintegrationprint on demandmerch-onethe customization group

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/merch-one-php-api-sdk/health.svg)

```
[![Health](https://phpackages.com/badges/merch-one-php-api-sdk/health.svg)](https://phpackages.com/packages/merch-one-php-api-sdk)
```

###  Alternatives

[hubspot/api-client

Hubspot API client

24015.5M18](/packages/hubspot-api-client)[resend/resend-php

Resend PHP library.

596.2M35](/packages/resend-resend-php)[checkout/checkout-sdk-php

Checkout.com SDK for PHP

563.5M10](/packages/checkout-checkout-sdk-php)[mozex/anthropic-laravel

Laravel integration for the Anthropic API: facade, config publishing, install command, testing fakes, messages, streaming, tool use, thinking, and batches.

72287.1k1](/packages/mozex-anthropic-laravel)[clicksend/clicksend-php

301.6M11](/packages/clicksend-clicksend-php)[files.com/files-php-sdk

Files.com PHP SDK

2478.1k](/packages/filescom-files-php-sdk)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
