Make XGuard the universal Pay-All checkout for multi-merchant payments - #277
Draft
moelayyan90 wants to merge 28 commits into
Draft
Make XGuard the universal Pay-All checkout for multi-merchant payments#277moelayyan90 wants to merge 28 commits into
moelayyan90 wants to merge 28 commits into
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Primary product direction
XGuard becomes a universal multi-merchant payment cart rather than only a settlement-truth / retry layer.
User-facing invariant:
The payer can collect multiple independent Payment Claims from merchants, services, agents, invoices, or rails, review one combined checkout, authorize once, and receive one parent receipt with child settlement results.
New artifacts
docs/UNIVERSAL_MULTI_MERCHANT_CHECKOUT.mdspecs/batch-payment-intent.schema.jsonpackages/core/src/batch-payment.tspackages/core/src/index.tsnow exports the batch-payment contract.Execution modes
Atomicity policies are explicit:
ALL_OR_NOTHING,BEST_EFFORT, orGROUP_ATOMIC.Payment Claim
Each merchant/service exposes or has its platform translate an authenticated claim containing beneficiary, amount, currency/asset, destination rail, invoice/order/resource reference, expiry, and provider/merchant evidence.
The adoption loop is:
Existing safety primitives
Settlement Truth and retry protection remain supporting infrastructure for child-payment correctness and receipts, but they are no longer the primary product story.
Commercial model
Pricing remains rail-specific and may include a disclosed payer batch convenience fee, platform/rail usage fee, per-child settlement fee, volume tiers, or contractually supported revenue share. XGuard must not silently divert merchant proceeds.
Truthfulness / legal boundary
XGuard does not claim that unrelated independent card merchants can be collapsed into one native card-acquiring transaction without a licensed marketplace / merchant-of-record / payment platform that supports that model. Where that boundary is unavailable, XGuard either uses explicit coordinated child payments under a valid user mandate or does not support that combination.
Goal
Make XGuard the common Pay-All / batch-authorization layer between payable claims and heterogeneous payment rails.