How to build a custom payment app for processing FSA/HSA eligible transactions?

Topic summary

Goal: build a custom offsite payment app to process FSA/HSA (health spending) eligible purchases by redirecting checkout to a hosted payment page. The hosted page expects a redirect URL containing base64-encoded Order ID and Merchant Key.

Planned integration: use Shopify’s Offsite Payment Extension. Configure a Session Payment URL to receive an HTTP POST with order, payment, billing, and shipping data, then construct a payload for a createOrder API that returns the redirect URL to the hosted page.

Blockers: on the Session Payment URL, the team cannot access the Merchant Key or line‑item metadata (e.g., GTIN/EAN) needed to build the payload. Guidance is requested on how to obtain item details and the merchant key at this stage.

Attempted approach: create a custom payment option via REST API (POST /admin/api/2023-01/payment_gateways.json) with API Key/Secret in settings. Although the call returns 200 and an installation URL, redirecting to it shows a Shopify “temporarily unavailable” error. They ask if this is the correct path and how to fix it.

Community updates: another developer reports similar uncertainty due to high-level docs; a third asks if a resolution was found. Status: unresolved; key questions remain open.

Summarized with AI on December 21. AI used: gpt-5.

I’m tying to create a similar app, mine is a bit simpler but still I’ve not found a clear path to develop this custom payment app for shopify.

I don’t understand why the documentation is very general on this topic.

1 Like