{"id":19443456,"url":"https://github.com/tbeseda/shopify-webhook-commander","last_synced_at":"2025-04-25T00:32:32.994Z","repository":{"id":57358694,"uuid":"383725572","full_name":"tbeseda/shopify-webhook-commander","owner":"tbeseda","description":"Set up Shopify webhook subscriptions from the command line","archived":false,"fork":false,"pushed_at":"2021-07-10T21:25:10.000Z","size":664,"stargazers_count":6,"open_issues_count":0,"forks_count":0,"subscribers_count":3,"default_branch":"main","last_synced_at":"2024-10-31T19:48:36.646Z","etag":null,"topics":["cli","graphql","shopify","webhook"],"latest_commit_sha":null,"homepage":"https://www.npmjs.com/package/shopify-webhook-commander","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/tbeseda.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2021-07-07T08:20:05.000Z","updated_at":"2024-05-21T08:41:02.000Z","dependencies_parsed_at":"2022-09-06T21:41:20.516Z","dependency_job_id":null,"html_url":"https://github.com/tbeseda/shopify-webhook-commander","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tbeseda%2Fshopify-webhook-commander","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tbeseda%2Fshopify-webhook-commander/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tbeseda%2Fshopify-webhook-commander/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tbeseda%2Fshopify-webhook-commander/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/tbeseda","download_url":"https://codeload.github.com/tbeseda/shopify-webhook-commander/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":223975428,"owners_count":17234737,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["cli","graphql","shopify","webhook"],"created_at":"2024-11-10T15:43:11.214Z","updated_at":"2024-11-10T15:43:11.995Z","avatar_url":"https://github.com/tbeseda.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Shopify Webhook Commander\n\n\u003cimg width=\"100%\" src=\"media/demo.gif\" alt=\"shopify-webhook-commander demo gif\"\u003e\n\n## Installation\n\n🚫 This package is under active development; installer beware.\n\n```sh-session\n$ npm i -g shopify-webhook-commander\n```\n\n## Example\n\n```sh-session\n$ shopify-webhook-commander config:set\n  \u003e Shop (with .myshopify.com): tbeseda.myshopify.com\n  \u003e Password: ****************\n\n$ shopify-webhook-commander webhook:create\n  \u003e Webhook topic: ORDERS_CREATE\n  \u003e Callback URL: https://ingest.my-app.com/\n  Created gid://shopify/WebhookSubscription/1021513859211 for \"tbeseda\"\n\n$ shopify-webhook-commander webhook:list\n  Webhooks for \"tbeseda\"\n    Topic          Endpoint                   ID\n    ────────────── ────────────────────────── ───────────────────────────────────────────────\n    SHOP_UPDATE    https://ingest.my-app.com/ gid://shopify/WebhookSubscription/1021513859211\n\n$ shopify-webhook-commander webhook:delete\n  \u003e Webhook id to delete: gid://shopify/WebhookSubscription/1021513859211\n  Deleted gid://shopify/WebhookSubscription/1021513859211 from \"tbeseda\"\n```\n\n## Shopify Webhook Topics\n\nThis tool uses the Shopify Admin GraphQL API. Webhook subscription topics should be of type [WebhookSubscriptionTopic](https://shopify.dev/api/admin/graphql/reference/events/webhooksubscriptiontopic)\n\n## Note about auth tokens\n\nThis tool uses a single token to authenticate; this is easiest with a Shopify \"Private\" Admin App. Set the config secret to the private app password. _There is no OAuth flow to help with \"Custom\" Partner apps._\nIn theory, you can instead provide an `accessToken` acquired from a Custom app's authentication flow. I haven't tested this.\n`shopify-webhook-commander` doesn't really help for \"Public\" apps that typically manage webhooks for each shop install programatically.\n\n## Roadmap\n\n1. tests 😬\n1. replace Apollo client with a slimmer GQL lib\n1. integrate `@shopify/shopify-api` types -- gotta get rid of those `any` types\n1. `webhooks:update` command\n1. autocomplete webhook topics\n1. auth loop for custom apps\n\n---\n\n# `oclif` Generated Docs:\n\nThe section below is auto-generated by `oclif` upon package release.\n\n## shopify-webhook-commander\n\nSet up Shopify webhook subscriptions from the command line\n\n[![oclif](https://img.shields.io/badge/cli-oclif-brightgreen.svg)](https://oclif.io)\n[![Version](https://img.shields.io/npm/v/shopify-webhook-commander.svg)](https://npmjs.org/package/shopify-webhook-commander)\n[![Downloads/week](https://img.shields.io/npm/dw/shopify-webhook-commander.svg)](https://npmjs.org/package/shopify-webhook-commander)\n[![License](https://img.shields.io/npm/l/shopify-webhook-commander.svg)](https://github.com/tbeseda/shopify-webhook-commander/blob/master/package.json)\n\n\u003c!-- toc --\u003e\n* [Shopify Webhook Commander](#shopify-webhook-commander)\n* [`oclif` Generated Docs:](#oclif-generated-docs)\n* [Usage](#usage)\n* [Commands](#commands)\n\u003c!-- tocstop --\u003e\n\n# Usage\n\n\u003c!-- usage --\u003e\n```sh-session\n$ npm install -g shopify-webhook-commander\n$ shopify-webhook-commander COMMAND\nrunning command...\n$ shopify-webhook-commander (-v|--version|version)\nshopify-webhook-commander/0.2.1 darwin-arm64 node-v16.4.1\n$ shopify-webhook-commander --help [COMMAND]\nUSAGE\n  $ shopify-webhook-commander COMMAND\n...\n```\n\u003c!-- usagestop --\u003e\n\n# Commands\n\n\u003c!-- commands --\u003e\n* [`shopify-webhook-commander config:reveal`](#shopify-webhook-commander-configreveal)\n* [`shopify-webhook-commander config:set`](#shopify-webhook-commander-configset)\n* [`shopify-webhook-commander config:unset`](#shopify-webhook-commander-configunset)\n* [`shopify-webhook-commander help [COMMAND]`](#shopify-webhook-commander-help-command)\n* [`shopify-webhook-commander webhooks:create`](#shopify-webhook-commander-webhookscreate)\n* [`shopify-webhook-commander webhooks:delete`](#shopify-webhook-commander-webhooksdelete)\n* [`shopify-webhook-commander webhooks:list`](#shopify-webhook-commander-webhookslist)\n\n## `shopify-webhook-commander config:reveal`\n\nprint current Shopify config\n\n```\nUSAGE\n  $ shopify-webhook-commander config:reveal\n\nOPTIONS\n  -h, --help  show CLI help\n  -y, --yes   agree to reveal\n```\n\n_See code: [src/commands/config/reveal.ts](https://github.com/tbeseda/shopify-webhook-commander/blob/v0.2.1/src/commands/config/reveal.ts)_\n\n## `shopify-webhook-commander config:set`\n\nset Shopify credentials config\n\n```\nUSAGE\n  $ shopify-webhook-commander config:set\n\nOPTIONS\n  -h, --help       show CLI help\n  --secret=secret\n  --shop=shop\n```\n\n_See code: [src/commands/config/set.ts](https://github.com/tbeseda/shopify-webhook-commander/blob/v0.2.1/src/commands/config/set.ts)_\n\n## `shopify-webhook-commander config:unset`\n\nremove Shopify config\n\n```\nUSAGE\n  $ shopify-webhook-commander config:unset\n\nOPTIONS\n  -h, --help  show CLI help\n```\n\n_See code: [src/commands/config/unset.ts](https://github.com/tbeseda/shopify-webhook-commander/blob/v0.2.1/src/commands/config/unset.ts)_\n\n## `shopify-webhook-commander help [COMMAND]`\n\ndisplay help for shopify-webhook-commander\n\n```\nUSAGE\n  $ shopify-webhook-commander help [COMMAND]\n\nARGUMENTS\n  COMMAND  command to show help for\n\nOPTIONS\n  --all  see all commands in CLI\n```\n\n_See code: [@oclif/plugin-help](https://github.com/oclif/plugin-help/blob/v3.2.2/src/commands/help.ts)_\n\n## `shopify-webhook-commander webhooks:create`\n\ncreate a webhook subscription\n\n```\nUSAGE\n  $ shopify-webhook-commander webhooks:create\n\nOPTIONS\n  -h, --help                 show CLI help\n  --callbackUrl=callbackUrl\n  --topic=topic\n```\n\n_See code: [src/commands/webhooks/create.ts](https://github.com/tbeseda/shopify-webhook-commander/blob/v0.2.1/src/commands/webhooks/create.ts)_\n\n## `shopify-webhook-commander webhooks:delete`\n\ndelete a webhook given a resource id\n\n```\nUSAGE\n  $ shopify-webhook-commander webhooks:delete\n\nOPTIONS\n  -h, --help  show CLI help\n  --id=id\n```\n\n_See code: [src/commands/webhooks/delete.ts](https://github.com/tbeseda/shopify-webhook-commander/blob/v0.2.1/src/commands/webhooks/delete.ts)_\n\n## `shopify-webhook-commander webhooks:list`\n\nlist existing shop webhook subscriptions\n\n```\nUSAGE\n  $ shopify-webhook-commander webhooks:list\n\nOPTIONS\n  -h, --help  show CLI help\n```\n\n_See code: [src/commands/webhooks/list.ts](https://github.com/tbeseda/shopify-webhook-commander/blob/v0.2.1/src/commands/webhooks/list.ts)_\n\u003c!-- commandsstop --\u003e\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftbeseda%2Fshopify-webhook-commander","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftbeseda%2Fshopify-webhook-commander","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftbeseda%2Fshopify-webhook-commander/lists"}