Hide and Show payment method based on cart attribute (payment-method-customization)

Topic summary

A developer is building a custom Shopify app extension to conditionally hide payment methods based on cart attributes but has encountered a critical issue: the cart attribute values are not being passed through to the extension.

Technical Setup:

  • The extension uses a payment method customization function
  • Implementation includes run.graphql and run.js files
  • Cart attributes are being set in Liquid templates

Current Problem:

  • Console logs show that attribute values are not appearing in the extension’s context
  • Screenshots demonstrate the code structure across GraphQL queries, JavaScript logic, console output, and Liquid implementation
  • The attribute data pipeline from storefront to app extension appears broken

Status: The issue remains unresolved with no responses yet. The developer has provided detailed visual documentation of their implementation to help diagnose where the data flow is failing.

Summarized with AI on October 27. AI used: claude-sonnet-4-5-20250929.

Hi, I am developing a custom app extension to hide certain payment method based on cart attribute.

I have setup the app and I am facing an issue which the attribute value is not coming through.

Run.Graphql

Run.js

Console.log

Liquid