Skip to content

Commit

Permalink
docs: update Shopify backend documentation (#87)
Browse files Browse the repository at this point in the history
* docs: update Shopify backend documentation
* docs: update documentation with django and shopify app clarification
* docs: remove notice about shopify api setting
  • Loading branch information
agconti committed Jun 22, 2021
1 parent 0aacbaf commit 7ea233b
Showing 1 changed file with 22 additions and 10 deletions.
32 changes: 22 additions & 10 deletions docs/backends/shopify.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,23 @@ Shopify

Shopify uses OAuth 2 for authentication.

To use this backend, you must install the package ``shopify`` from the `GitHub
project`_. Currently supports v2+

- Register a new application at `Shopify Partners`_, and

- Set the Auth Type to OAuth2 in the application settings

- Set the Application URL to http://[your domain]/login/shopify/

To use this backend, you must:

- Install the `Shopify python library`_::
pip install --upgrade ShopifyAPI

- Register a new application at `Shopify Partners`_
- Configure your Shopify app to use the application URL of `https://[your domain]/login/shopify/`
- Configure your Shopify app to use the callback URL of `https://[your domain]/complete/shopify/`
- If you're using Django, add the backend to your AUTHENTICATION_BACKENDS configuration::
AUTHENTICATION_BACKENDS = (
...,
'social_core.backends.shopify.ShopifyOAuth2',
...,
)
- fill ``API Key`` and ``Shared Secret`` values in your django settings::

SOCIAL_AUTH_SHOPIFY_KEY = ''
Expand All @@ -24,6 +32,10 @@ project`_. Currently supports v2+
'write_customers',
'read_products']

- If you'd like to, you can set your desired Shopify API version in your settings::
SOCIAL_AUTH_SHOPIFY_API_VERSION = '2020-10'
`ShopifyAPI 5.0.0`_ introduced a non backward compatible change in order to
support Shopify API versioning. The backend will default to value `2019-04` but
it's possible to override the default with the following setting::
Expand All @@ -32,5 +44,5 @@ it's possible to override the default with the following setting::

.. _Shopify Partners: http://www.shopify.com/partners
.. _Shopify API: http://api.shopify.com/authentication.html#scopes
.. _GitHub project: https://github.com/Shopify/shopify_python_api
.. _Shopify python library: https://github.com/Shopify/shopify_python_api
.. _ShopifyAPI 5.0.0: https://github.com/Shopify/shopify_python_api#-breaking-change-notice-for-version-500-

0 comments on commit 7ea233b

Please sign in to comment.