PHPackages                             ordersify/shopify-api-php - 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. ordersify/shopify-api-php

ActiveLibrary[API Development](/categories/api)

ordersify/shopify-api-php
=========================

Shopify API Client for PHP

v2.4.20(1y ago)01.7kMITPHPPHP &gt;=5.6.0

Since Nov 29Pushed 1y agoCompare

[ Source](https://github.com/ordersify/shopify-api-php)[ Packagist](https://packagist.org/packages/ordersify/shopify-api-php)[ RSS](/packages/ordersify-shopify-api-php/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (4)Dependencies (9)Versions (39)Used By (0)

 [![](https://camo.githubusercontent.com/5a8dc7b87ac10bf7daa31a55bfd296f938a320c516bfd33eb6cb764feea71cf5/68747470733a2f2f63646e2e73686f706966792e636f6d2f73686f706966792d6d61726b6574696e675f6173736574732f6275696c64732f31392e302e302f73686f706966792d66756c6c2d636f6c6f722d626c61636b2e737667)](https://camo.githubusercontent.com/5a8dc7b87ac10bf7daa31a55bfd296f938a320c516bfd33eb6cb764feea71cf5/68747470733a2f2f63646e2e73686f706966792e636f6d2f73686f706966792d6d61726b6574696e675f6173736574732f6275696c64732f31392e302e302f73686f706966792d66756c6c2d636f6c6f722d626c61636b2e737667)

🚀 PHP SDK for the Shopify API

 [ ![Software License](https://camo.githubusercontent.com/55c0218c8f8009f06ad4ddae837ddd05301481fcf0dff8e0ed9dadda8780713e/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f6c6963656e73652d4d49542d627269676874677265656e2e7376673f7374796c653d666c61742d737175617265) ](LICENSE) [ ![Build Status](https://camo.githubusercontent.com/8161514a5875f3bcd14e7a5f518b8d330e34654a650601b8187cd0a545b6fc62/68747470733a2f2f696d672e736869656c64732e696f2f7472617669732f736c696e63652f73686f706966792d6170692d7068702f6d61737465722e7376673f7374796c653d666c61742d737175617265) ](https://travis-ci.org/slince/shopify-api-php) [ ![Coverage Status](https://camo.githubusercontent.com/fb8496fe5356441460a603fd2843b60127259413d3fb554882856f487edbe6a2/68747470733a2f2f696d672e736869656c64732e696f2f636f6465636f762f632f6769746875622f736c696e63652f73686f706966792d6170692d7068702e7376673f7374796c653d666c61742d737175617265) ](https://codecov.io/github/slince/shopify-api-php) [ ![Latest Stable Version](https://camo.githubusercontent.com/eb74ca172bcdc5e7540bf02dcbef5b974328c4ea57c85b0b6aca275218d24d3b/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f736c696e63652f73686f706966792d6170692d7068702e7376673f7374796c653d666c61742d737175617265266c6162656c3d737461626c65) ](https://packagist.org/packages/slince/shopify-api-php) [ ![Scrutinizer](https://camo.githubusercontent.com/d35ef2293d6c508330dd366a8762f299b59f72726566c02cc114ecc29adbc865/68747470733a2f2f696d672e736869656c64732e696f2f7363727574696e697a65722f672f736c696e63652f73686f706966792d6170692d7068702e7376673f7374796c653d666c61742d737175617265) ](https://scrutinizer-ci.com/g/slince/shopify-api-php/?branch=master)

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

[](#installation)

Install via composer

```
$ composer require slince/shopify-api-php
```

Quick Start
-----------

[](#quick-start)

### Initialize the client

[](#initialize-the-client)

You first need to initialize the client. For that you need your Shop Name and AccessToken

```
require __DIR__ . '/vendor/autoload.php';

$credential = new Slince\Shopify\PublicAppCredential('Access Token');
// Or Private App
$credential = new Slince\Shopify\PrivateAppCredential('API KEY', 'PASSWORD', 'SHARED SECRET');

$client = new Slince\Shopify\Client($credential, 'your-store.myshopify.com', [
    'metaCacheDir' => './tmp' // Metadata cache dir, required
]);
```

### Use Manager to manipulate your data;

[](#use-manager-to-manipulate-your-data)

- Lists products

```
$products = $client->getProductManager()->findAll([
    // Filter your product
    'collection_id' => 841564295
    'page' => 2 // deprecated
]);
```

- Lists products by pagination

```
$pagination = $client->getProductManager()->paginate([
    // filter your product
    'limit' => 3,
    'created_at_min' => '2015-04-25T16:15:47-04:00'
]);
// $pagination is instance of `Slince\Shopify\Common\CursorBasedPagination`

$currentProducts = $pagination->current(); //current page

while ($pagination->hasNext()) {
    $nextProducts = $pagination->next();
}

# to persist across requests you can use next_page_info and previous_page_info
$nextPageInfo = $pagination->getNextPageInfo();
$prevPageInfo = $pagination->getPrevPageInfo();

$products = $pagination->current($nextPageInfo);
```

- Get the specified product

```
$product = $client->getProductManager()->find(12800);

// Update the given product
$product = $client->getProductManager()->update(12800, [
      "title" => "Burton Custom Freestyle 151",
      "body_html" => "Good snowboard!",
      "vendor"=> "Burton",
      "product_type" => "Snowboard",
]);
```

- Creates a new product

```
$product = $client->getProductManager()->create([
      "title" => "Burton Custom Freestyle 151",
      "body_html" => "Good snowboard!",
      "vendor"=> "Burton",
      "product_type" => "Snowboard",
]);
```

- Removes the product by its id

```
$client->getProductManager()->remove(12800);
```

The product is an instance of `Slince\Shopify\Manager\Product\Product`; You can access properties like following:

```
echo $product->getTitle();
echo $product->getCreatedAt(); // DateTime Object
//...
print_r($product->getVariants());
print_r($product->getImages());
```

Available managers:

- [Article](./src/Manager/Article/ArticleManagerInterface.php)
- [Asset](./src/Manager/Asset/AssetManagerInterface.php)
- [Blog](./src/Manager/Blog/BlogManagerInterface.php)
- [CarrierService](./src/Manager/CarrierService/CarrierServiceManagerInterface.php)
- [Collect](./src/Manager/Collect/CollectManagerInterface.php)
- [Comment](./src/Manager/Comment/CommentManagerInterface.php)
- [Country](./src/Manager/Country/CountryManagerInterface.php)
- [CustomCollection](./src/Manager/CustomCollection/CustomCollectionManagerInterface.php)
- [Customer](./src/Manager/Customer/CustomerManagerInterface.php)
- [CustomerAddress](./src/Manager/CustomerAddress/AddressManagerInterface.php)
- [CustomerSavedSearch](./src/Manager/CustomerSavedSearch/CustomerSavedSearchManagerInterface.php)
- [DiscountCode](./src/Manager/DiscountCode/DiscountCodeManagerInterface.php)
- [DraftOrder](./src/Manager/DraftOrder/DraftOrderManagerInterface.php)
- [Fulfillment](./src/Manager/Fulfillment/FulfillmentManagerInterface.php)
- [FulfillmentService](./src/Manager/FulfillmentService/FulfillmentServiceManagerInterface.php)
- [InventoryItem](./src/Manager/InventoryItem/InventoryItemManagerInterface.php)
- [InventoryLevel](./src/Manager/InventoryLevel/InventoryLevelManagerInterface.php)
- [Location](./src/Manager/Location/LocationManagerInterface.php)
- [Order](./src/Manager/Order/OrderManagerInterface.php)
- [OrderRisk](./src/Manager/OrderRisk/RiskManagerInterface.php)
- [Page](./src/Manager/Page/PageManagerInterface.php)
- [Policy](./src/Manager/Policy/PolicyManagerInterface.php)
- [PriceRule](./src/Manager/PriceRule/PriceRuleManagerInterface.php)
- [Product](./src/Manager/Product/ProductManagerInterface.php)
- [ProductImage](./src/Manager/ProductImage/ImageManagerInterface.php)
- [ProductVariant](./src/Manager/ProductVariant/VariantManagerInterface.php)
- [Province](./src/Manager/Province/ProvinceManagerInterface.php)
- [RecurringApplicationCharge](./src/Manager/RecurringApplicationCharge/RecurringApplicationChargeManagerInterface.php)
- [Redirect](./src/Manager/Redirect/RedirectManagerInterface.php)
- [Refund](./src/Manager/Refund/RefundManagerInterface.php)
- [ScriptTag](./src/Manager/ScriptTag/ScriptTagManagerInterface.php)
- [ShippingZone](./src/Manager/ShippingZone/ShippingZoneManagerInterface.php)
- [Shop](./src/Manager/Shop/ShopManagerInterface.php)
- [SmartCollection](./src/Manager/SmartCollection/SmartCollectionManagerInterface.php)
- [Theme](./src/Manager/Theme/ThemeManagerInterface.php)
- [Transaction](./src/Manager/Transaction/TransactionManagerInterface.php)
- [Webhook](./src/Manager/Webhook/WebhookManagerInterface.php)

You can access the manager like `$client->getProductManager()`, `$client->getOrderManager()`.

### Basic CURD

[](#basic-curd)

If you don't like to use managers, you can also manipulate data like this:

The returned value is just an array;

```
$products = $client->get('products', [
    // Filter your products
]);

$product = $client->get('products/12800');

$product = $client->post('products', [
    "product" => [
        "title" => "Burton Custom Freestyle 151",
        "body_html" => "Good snowboard!",
        "vendor"=> "Burton",
        "product_type" => "Snowboard",
        "images" => [
            [
                "attachment" => "R0lGODlhAQABAIAAAAAAAAAAACH5BAEAAAAALAAAAAABAAEAAAICRAEAOw==\n"
            ]
        ]
     ]
]);

$product = $client->put('products/12800', [
    "product" => [
        "title" => "Burton Custom Freestyle 151",
        "body_html" => "Good snowboard!",
        "vendor"=> "Burton",
        "product_type" => "Snowboard",
        "images" => [
            [
                "attachment" => "R0lGODlhAQABAIAAAAAAAAAAACH5BAEAAAAALAAAAAABAAEAAAICRAEAOw==\n"
            ]
        ]
     ]
]);

$client->delete('products/12800');
```

LICENSE
-------

[](#license)

The MIT license. See [MIT](https://opensource.org/licenses/MIT)

###  Health Score

39

—

LowBetter than 86% of packages

Maintenance47

Moderate activity, may be stable

Popularity16

Limited adoption so far

Community12

Small or concentrated contributor base

Maturity70

Established project with proven stability

 Bus Factor1

Top contributor holds 56.2% 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 ~77 days

Recently: every ~410 days

Total

36

Last Release

391d ago

Major Versions

1.0.0-beta2 → 2.0.0-beta12018-01-31

2.4.0 → 3.x-dev2020-03-15

2.4.18 → 4.x-dev2021-04-14

PHP version history (2 changes)1.0.0-beta1PHP &gt;=5.6.0

3.x-devPHP ^7.1.3

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/61607737?v=4)[Ordersify](/maintainers/ordersify)[@ordersify](https://github.com/ordersify)

---

Top Contributors

[![slince](https://avatars.githubusercontent.com/u/3785826?v=4)](https://github.com/slince "slince (86 commits)")[![maximzasorin](https://avatars.githubusercontent.com/u/13367689?v=4)](https://github.com/maximzasorin "maximzasorin (28 commits)")[![imandydoan](https://avatars.githubusercontent.com/u/62533868?v=4)](https://github.com/imandydoan "imandydoan (27 commits)")[![coreyee](https://avatars.githubusercontent.com/u/16696867?v=4)](https://github.com/coreyee "coreyee (5 commits)")[![jonathangreco](https://avatars.githubusercontent.com/u/1587180?v=4)](https://github.com/jonathangreco "jonathangreco (3 commits)")[![baorv](https://avatars.githubusercontent.com/u/9483946?v=4)](https://github.com/baorv "baorv (3 commits)")[![scrutinizer-auto-fixer](https://avatars.githubusercontent.com/u/6253494?v=4)](https://github.com/scrutinizer-auto-fixer "scrutinizer-auto-fixer (1 commits)")

---

Tags

restfulshopifyshopify-apishopify-sdkshopify-clientshopify-client-php

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/ordersify-shopify-api-php/health.svg)

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

###  Alternatives

[slince/shopify-api-php

Shopify API Client for PHP

131236.9k1](/packages/slince-shopify-api-php)[sylius/sylius

E-Commerce platform for PHP, based on Symfony framework.

8.4k5.6M651](/packages/sylius-sylius)[ec-cube/ec-cube

EC-CUBE EC open platform.

78527.0k1](/packages/ec-cube-ec-cube)[kyon147/laravel-shopify

Shopify package for Laravel to aide in app development

473252.9k](/packages/kyon147-laravel-shopify)

PHPackages © 2026

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