# sypnosis2019/shopify-function-payment-hide architecture

> Architecture diagram of the GitHub repository sypnosis2019/shopify-function-payment-hide, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-16). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/sypnosis2019/shopify-function-payment-hide
- Repository: https://github.com/sypnosis2019/shopify-function-payment-hide

## Overview

This repository is an extension-only Shopify app template with a payment-method transform extension, not a server or admin UI. In the checkout workflow, the extension evaluates the cart total and available payment methods, then returns an operation to hide Cash on Delivery when the total reaches the configured threshold. The GraphQL input query and runtime function are present; the extension’s target wiring is not shown in the excerpts, so that connection is marked unverified.

Main entry points: [`extensions/payment-hide-non-subscription/src/cart_payment_methods_transform_run.js`](https://github.com/sypnosis2019/shopify-function-payment-hide/blob/main/extensions/payment-hide-non-subscription/src/cart_payment_methods_transform_run.js) (Payment transform), [`extensions/payment-hide-non-subscription/src/cart_payment_methods_transform_run.graphql`](https://github.com/sypnosis2019/shopify-function-payment-hide/blob/main/extensions/payment-hide-non-subscription/src/cart_payment_methods_transform_run.graphql) (Input query)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_checkout["Checkout integration"]
  node_checkout["Shopify checkout"]
end

subgraph group_input["Function input"]
  node_input_query["Input query"]
  node_api_schema["Function API schema<br/>[schema.graphql]"]
end

subgraph group_logic["Transform logic"]
  node_transform["Payment transform"]
end

node_shopper(("Shopper"))

node_shopper -.->|"uses checkout"| node_checkout
node_checkout -.->|"invokes function"| node_transform
node_input_query -.->|"supplies input"| node_transform
node_transform -->|"returns hide operation"| node_checkout

click node_input_query "https://github.com/sypnosis2019/shopify-function-payment-hide/blob/main/extensions/payment-hide-non-subscription/src/cart_payment_methods_transform_run.graphql"
click node_api_schema "https://github.com/sypnosis2019/shopify-function-payment-hide/blob/main/extensions/payment-hide-non-subscription/schema.graphql"
click node_transform "https://github.com/sypnosis2019/shopify-function-payment-hide/blob/main/extensions/payment-hide-non-subscription/src/cart_payment_methods_transform_run.js"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_checkout toneBlue
class node_input_query,node_api_schema toneAmber
class node_transform toneMint
class node_shopper toneIndigo
```

## Components

### Checkout integration

- **Shopify checkout**

### Function input

- [Input query](https://github.com/sypnosis2019/shopify-function-payment-hide/blob/main/extensions/payment-hide-non-subscription/src/cart_payment_methods_transform_run.graphql): `extensions/payment-hide-non-subscription/src/cart_payment_methods_transform_run.graphql`
- [Function API schema](https://github.com/sypnosis2019/shopify-function-payment-hide/blob/main/extensions/payment-hide-non-subscription/schema.graphql): `extensions/payment-hide-non-subscription/schema.graphql`

### Transform logic

- [Payment transform](https://github.com/sypnosis2019/shopify-function-payment-hide/blob/main/extensions/payment-hide-non-subscription/src/cart_payment_methods_transform_run.js): `extensions/payment-hide-non-subscription/src/cart_payment_methods_transform_run.js`

### Other components

- **Shopper**

## Connections

- Shopper → Shopify checkout: uses checkout
- Shopify checkout → Payment transform: invokes function
- Input query → Payment transform: supplies input
- Payment transform → Shopify checkout: returns hide operation (evidence: `extensions/payment-hide-non-subscription/src/cart_payment_methods_transform_run.js`)
