Skip to content
OpenSmartRoute
Skillv1.0.0

shopify-enterprise-rbac

Implement Shopify Plus access control patterns with staff permissions, multi-location management, and Shopify Organization features. Use when building apps for Shopify Plus merchants, implementing per

by jeremylongshore(0) 0 installs
Free
Sign in to install

Free account. Installing gives you the manifest plus copy-paste snippets.

See reviews

About

Imported from jeremylongshore/tons-of-skills-marketplace (plugins/saas-packs/shopify-pack/skills/shopify-enterprise-rbac/SKILL.md). Install upstream with npx skills add jeremylongshore/tons-of-skills-marketplace --skill shopify-enterprise-rbac. Copyright stays with the author (MIT).

Shopify Enterprise RBAC

Overview

Implement role-based access control for Shopify Plus apps using Shopify's staff member permissions, multi-location features, and Organization-level access.

Prerequisites

  • Shopify Plus store (for Organization features)
  • Understanding of Shopify's staff permission model
  • read_users scope for querying staff permissions

Instructions

Step 1: Query Staff Permissions and Map to App Roles

Query staff members via GraphQL to get their access scopes, then map those scopes to app-level roles (admin, manager, fulfillment, viewer). Staff permissions mirror app scopes like read_products, write_orders, etc.

See Staff Query and Role Mapping for the complete GraphQL query, role definitions, and matching logic.

Step 2: Permission Middleware and Multi-Location Access

In embedded apps, use online access tokens to get per-staff permissions from session.onlineAccessInfo. For Shopify Plus stores with multiple locations, restrict fulfillment and inventory operations to authorized locations per user.

See Permission Middleware and Location Access for Remix loader examples and location access control.

Step 3: Organization API and Audit Trail

Shopify Plus Organization API enables multi-store management with organization-level, store-level admin, and store-level staff roles. Log all access decisions (allowed and denied) for compliance auditing.

See Organization API and Audit Trail for the Organization query and audit implementation.

Output

  • Staff permissions queried and mapped to app roles
  • Permission middleware protecting embedded app routes
  • Multi-location access control for Shopify Plus
  • Audit trail for all access decisions

Error Handling

Issue Cause Solution
No onlineAccessInfo Using offline token Use online access tokens for per-user permissions
Staff can't access feature Merchant restricted their permissions Staff must request access from store owner
Organization API 403 Not on Shopify Plus Organization features require Plus plan
Location not found Location deactivated Query active locations before operations

Examples

Quick Permission Check in Remix

// Remix action with permission guard
export async function action({ request }: ActionFunctionArgs) {
  const { admin, session } = await authenticate.admin(request);

  const role = determineRole(
    session.onlineAccessInfo?.associated_user_scope?.split(",") || []
  );

  if (!canPerformAction(role, "manage_products")) {
    return json({ error: "Insufficient permissions" }, { status: 403 });
  }

  // ... perform the action
}

Resources

Use it

Copy one of these into your project. Installing also returns the manifest and these snippets.

yaml
targets:
  - https://api.opensmartroute.ai/api/v1/registry/jeremylongshore-tons-of-skills-marketplace-shopify-enter-707112/manifest   # or paste the manifest below

Manifest

An Open Capability Manifest: the router reads it to know what this does, what it costs and when to pick it.

jeremylongshore-tons-of-skills-marketplace-shopify-enter-707112.ocm.jsonjson
{
  "ocm": "1",
  "id": "jeremylongshore-tons-of-skills-marketplace-shopify-enter-707112",
  "kind": "skill",
  "name": "shopify-enterprise-rbac",
  "description": "Implement Shopify Plus access control patterns with staff permissions, multi-location management, and Shopify Organization features. Use when building apps for Shopify Plus merchants, implementing per-staff permissions, or managing multi-store organizations. Trigger with phrases like \"shopify permissions\", \"shopify staff\", \"shopify Plus organization\", \"shopify roles\", \"shopify multi-location\".",
  "publisher": "jeremylongshore",
  "version": "1.0.0",
  "capabilities": {
    "domains": [
      "general"
    ],
    "tags": [
      "skill-md",
      "saas",
      "ecommerce",
      "shopify",
      "skills-sh"
    ],
    "languages": [
      "en"
    ]
  },
  "quality_prior": 0.6,
  "examples": [
    "Implement Shopify Plus access control patterns with staff permissions, multi-location management, and Shopify Organization features. Use when building apps for Shopify Plus merchants, implementing per-staff permissions, or managing multi-store organizations. Trigger with phrases like \"shopify permissions\", \"shopify staff\", \"shopify Plus organization\", \"shopify roles\", \"shopify multi-location\"."
  ],
  "primary": false,
  "metadata": {
    "source": {
      "provider": "skills.sh",
      "repository": "https://github.com/jeremylongshore/tons-of-skills-marketplace",
      "path": "plugins/saas-packs/shopify-pack/skills/shopify-enterprise-rbac/SKILL.md",
      "ref": "HEAD",
      "url": "https://github.com/jeremylongshore/tons-of-skills-marketplace/blob/HEAD/plugins/saas-packs/shopify-pack/skills/shopify-enterprise-rbac/SKILL.md",
      "key": "jeremylongshore/tons-of-skills-marketplace/plugins/saas-packs/shopify-pack/skills/shopify-enterprise-rbac/SKILL.md"
    },
    "compatibility": "Designed for Claude Code",
    "allowed_tools": [
      "Read,",
      "Write,",
      "Edit"
    ],
    "license": "MIT"
  },
  "instructions": "# Shopify Enterprise RBAC\n\n## Overview\n\nImplement role-based access control for Shopify Plus apps using Shopify's staff member permissions, multi-location features, and Organization-level access.\n\n## Prerequisites\n\n- Shopify Plus store (for Organization features)\n- Understanding of Shopify's staff permission model\n- `read_users` scope for querying staff permissions\n\n## Instructions\n\n### Step 1: Query Staff Permissions and Map to App Roles\n\nQuery staff members via GraphQL to get their access scopes, then map those scopes to app-level roles (admin, manager, fulfillment, viewer). Staff permission",
  "cost": {
    "context_tokens": 820
  }
}

Fetch it by URL: GET /api/v1/registry/jeremylongshore-tons-of-skills-marketplace-shopify-enter-707112/manifest?version=1.0.0

Reviews

Star ratings from people who tried it. One review per account; edit yours any time.

No reviews yet. Install it, try it, and be the first to rate it.