Implement authorization code grant manually

All Shopify apps, other than apps created in the Shopify admin, need to obtain authorization using the OAuth 2.0 specification to use Shopify’s API resources.

This tutorial shows you how to authorize your app using authorization code grant, either using a Shopify Admin API library, or from scratch. Using a Shopify Admin API library helps you to keep your app secure and reduce implementation time. Shopify recommends that you use a library where possible.

All Shopify app templates already have OAuth implemented. If you're using one of these templates, then you don't need to follow this tutorial. To save time and keep your app secure, Shopify recommends using an app template if possible.