Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/ScreenStaring/shopify-dev-tools

Command-line program to assist with the development and/or maintenance of Shopify apps and stores
https://github.com/ScreenStaring/shopify-dev-tools

golang metafields scripttags shopify shopify-admin shopify-admin-graphql shopify-apps shopify-developers shopify-development shopify-partners webhooks

Last synced: about 1 month ago
JSON representation

Command-line program to assist with the development and/or maintenance of Shopify apps and stores

Awesome Lists containing this project

README

        

# Shopify Development Tools

Command-line program to assist with the development and/or maintenance of Shopify apps and stores.

## Installation

Download the version for your platform on the [releases page](https://github.com/ScreenStaring/shopify_dev_tools/releases).
Windows, macOS/OS X, and GNU/Linux are supported.

## Usage

NAME:
sdt - Shopify Development Tools

USAGE:
sdt command [command options] [arguments...]

VERSION:
0.0.5

COMMANDS:
admin, a Open admin pages
charges, c, ch Do things with charges
metafield, m, meta Metafield utilities
orders, o Information about orders
products, p Do things with products
graphql, gql Run a GraphQL query against the Admin API
shop, s Information about the given shop
scripttags ScriptTag utilities
themes, theme, t Theme utilities
webhook, webhooks, hooks, w Webhook utilities
help, h Shows a list of commands or help for one command

GLOBAL OPTIONS:
--help, -h show help (default: false)
--version, -v print the version (default: false)

### Credentials

You'll need access to the Shopify store you want to execute commands against. Also see [Environment Variables](#environment-variables).

#### Access Token

If the store has your app installed you can use the credentials generated when the shop installed your app:
```
sdt COMMAND --shop shopname --access-token value
```

In this scenario you will likely need to execute the command against many shops, and having to lookup the token every
time you need it can become annoying. To simplify this process you can [specify an Access Token Command](#access-token-command).

#### Key & Password

If you have access to the store via the Shopify Admin you can authenticate by
[generating private app API credentials](https://shopify.dev/tutorials/generate-api-credentials). Once obtained they can be specified as follows:
```
sdt COMMAND --shop shopname --api-key thekey --api-password thepassword
```

#### Access Token Command

Instead of specifying an access token per store you can provide a custom command that can lookup the token for the given `shop`.
For example:

```
sdt COMMAND --shop shopname --access-token ' ARGV[0]).token" "$shop"'
```

Furthermore, you can use the [`SHOPIFY_ACCESS_TOKEN` environment variable](#environment-variables) to reduce the required options to
just `shop`:

```
export SHOPIFY_ACCESS_TOKEN='