Skip to content

feat: add payment.failed webhook handling - #2280

Merged
dragosp1011 merged 1 commit into
v1from
dragos/int-657-payment-failed-webhook
Nov 2, 2026
Merged

dragosp1011 merged 1 commit into
v1from
dragos/int-657-payment-failed-webhook

Conversation

@dragosp1011

@dragosp1011 dragosp1011 commented Nov 2, 2026 •

Copy link
Copy Markdown
Contributor

Context

  • fixes #

Changes

  • Handle the Rhyza payment.failed webhook:
    • Nothing sent (sentAmount is 0): mark the transaction FAILED with value 0
    • Partially sent: move sentAmount from the sender's GateHub wallet to the settlement wallet, then mark the transaction COMPLETED with the sent amount
  • Add a shared settleToSettlementWallet helper, now used by both payment.completed and payment.failed
  • Add payment.failed to webhook validation, types and mocks

@github-actions github-actions Bot added package: wallet/backend Wallet backend implementations type: test Improvements or additions to tests type: source Source changes labels Nov 2, 2026
@dragosp1011
dragosp1011 marked this pull request as ready for review November 2, 2026 12:59
@dragosp1011
dragosp1011 merged commit da273dc into v1 Nov 2, 2026
17 checks passed
@dragosp1011
dragosp1011 deleted the dragos/int-657-payment-failed-webhook branch November 2, 2026 15:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

package: wallet/backend Wallet backend implementations type: source Source changes type: test Improvements or additions to tests

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants