mcarrowsmith-packages / oauth2-shopify
v1.0
2022-09-17 16:12 UTC
Requires
- php: ^7.4 || ^8.0
- league/oauth2-client: ^2.6
Requires (Dev)
- friendsofphp/php-cs-fixer: ^3.11
- phpspec/phpspec: ^7.2
- phpstan/phpstan: ^1.8
- vlucas/phpdotenv: ^5.4
README
OAuth2 Shopify
PHP OAuth 2.0 provider for Shopify extending PHP League's OAuth Client.
Installation
You can install the package via composer:
composer require mcarrowsmith/oauth2-shopify
Usage
Make sure you have configured and app via your Shopify Partner account.
$provider = new \McArrowsmithPackages\Oauth2Shopify\ShopifyProvider([ 'shop' => '{example-shopify-store}.myshopify.com', 'clientId' => '{shopify-add-id}', 'clientSecret' => '{shopify-app-secret}', 'redirectUri' => 'https://{example-ngrok-subdomain}.ngrok.io/login' ]);
See web/login/index.php for full workflow example.
Testing
composer test
Changelog
Please see CHANGELOG for more information on what has changed recently.
Contributing
Please see CONTRIBUTING for details.