PHPackages                             vincenth520/shopify - 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. vincenth520/shopify

ActiveLibrary

vincenth520/shopify
===================

Shopify PHP SDK to interact with the Shopify API

v1.0(8y ago)012MITPHPPHP &gt;=5.5.0

Since Dec 11Pushed 8y ago1 watchersCompare

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

READMEChangelog (1)Dependencies (1)Versions (2)Used By (0)

Shopify
=======

[](#shopify)

Setup/Installation
------------------

[](#setupinstallation)

You can install it on packgist

`composer require vincenth520/shopify`

You must first setup a public app. View documentation. You need an authorization URL.

```
require 'vendor/autoload.php';
session_start();
$APP_API_KEY = ''; //api key
$APP_SECRET = ''; //app secret

$client = new Shopify\Shopify($_GET['shop'], $APP_API_KEY, $APP_SECRET);
$_SESSION['client_id'] = time();
$random_state = $_SESSION['client_id'];

$rediect_url = 'http://localhost/shopify/shopify/redirect.php';  //this is your redirect url

$client->authorizeUser($rediect_url, [
  'read_products',
  'write_products',
], $random_state);
```

At this point, the user is taken to their store to authorize the application to use their information. If the user accepts, they are taken to the redirect URL.

```
session_start();
require 'vendor/autoload.php';
$APP_API_KEY = ''; //api key
$APP_SECRET = ''; //app secret

$client = new Shopify\Shopify($_GET['shop'], $APP_API_KEY, $APP_SECRET);
$client->setState($_SESSION['client_id']);
if ($token = $client->getAccessToken()) {
  $_SESSION['shopify_access_token'] = $token;
  $_SESSION['shopify_shop_domain'] = $_GET['shop'];
}
else {
  die('invalid token');
}
```

### Method

[](#method)

- get shop info

```
$client = new Shopify\Shopify($_SESSION['shopify_shop_domain'], $APP_API_KEY, $APP_SECRET);
$client->getShopInfo();
```

- get webhook

```
$client = new Shopify\Shopify($_SESSION['shopify_shop_domain'], $APP_API_KEY, $APP_SECRET);
$client->getWebhooks();
```

- add webhook

```
$client = new Shopify\Shopify($_SESSION['shopify_shop_domain'], $APP_API_KEY, $APP_SECRET);
$type = 'collections/create'; //topics  [see:https://help.shopify.com/api/reference/webhook]
$address = 'https://baidu.com'; //address URIs
$format = 'json'; //json or xml
$client->addWebhook($type,$address,$format);
```

###  Health Score

25

—

LowBetter than 37% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity5

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity58

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% 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

Unknown

Total

1

Last Release

3072d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/42fa43596d7601bfb3754787ed10af15ca800c3484db20d0919fe9905b0546c6?d=identicon)[vincenth520](/maintainers/vincenth520)

---

Top Contributors

[![vincenth520](https://avatars.githubusercontent.com/u/12945328?v=4)](https://github.com/vincenth520 "vincenth520 (7 commits)")

---

Tags

shopify

### Embed Badge

![Health badge](/badges/vincenth520-shopify/health.svg)

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

###  Alternatives

[neuron-core/neuron-ai

The PHP Agentic Framework.

1.8k245.3k20](/packages/neuron-core-neuron-ai)[tencentcloud/tencentcloud-sdk-php

TencentCloudApi php sdk

3731.2M42](/packages/tencentcloud-tencentcloud-sdk-php)[aedart/athenaeum

Athenaeum is a mono repository; a collection of various PHP packages

255.2k](/packages/aedart-athenaeum)

PHPackages © 2026

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