docs(webhook): restructure PaymentInstructionEvent status payload#24
Open
diegopereira90 wants to merge 2 commits intomainfrom
Open
docs(webhook): restructure PaymentInstructionEvent status payload#24diegopereira90 wants to merge 2 commits intomainfrom
diegopereira90 wants to merge 2 commits intomainfrom
Conversation
Match the SNS payload now emitted by fx-payment (PR #79) and align with the State<T> wrapper already used by OperationEvent and TransactionEvent — `currentState.status` plus `currentState.reason` (populated on REJECTED) and `currentState.createdAt`. The PaymentInstructionEventStatus enum is preserved as PaymentInstructionState.status — no enum value changes.
|
Preview deployment for your docs. Learn more about Mintlify Previews.
💡 Tip: Enable Workflows to automatically generate PRs for you. |
…tionStatus The `Event` suffix was an artifact of when this enum lived directly on `PaymentInstructionEvent.status`. Now that it sits inside `PaymentInstructionState.status`, the suffix no longer reflects the schema's role. Rename to match the surrounding `PaymentInstructionEvent` / `PaymentInstructionState` family. Companion to the same rename in fx-payment. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
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.
Summary
Lock-step companion to fx-payment#79. Two changes to the SNS payload for
BENEFICIARY_PAYMENT_INSTRUCTION_*:currentStateto matchOperationEvent/TransactionEventand surface the rejectionreason.PaymentInstructionEventStatus→PaymentInstructionStatus. TheEventsuffix was an artifact of when the enum sat directly onPaymentInstructionEvent.status; now that it lives insidePaymentInstructionState.status, the suffix no longer reflects its role. The new name is consistent withOperationStatus/TransactionStatusand with the surroundingPaymentInstructionEvent/PaymentInstructionStatefamily.PaymentInstructionEvent: properties: id: ... asset: ... - status: - $ref: '#/components/schemas/PaymentInstructionEventStatus' + currentState: + $ref: '#/components/schemas/PaymentInstructionState' address: ... + +PaymentInstructionState: + properties: + status: # PaymentInstructionStatus enum (renamed) + reason: # populated on REJECTED, null otherwise + createdAt: # when the instruction entered this statusEnum values (
PENDING_REVIEW,APPROVED,REJECTED) and JSON field paths are unchanged. Webhook event-type prose forBENEFICIARY_PAYMENT_INSTRUCTION_APPROVED/_REJECTEDupdated to referencecurrentState.status(andcurrentState.reasonon rejection).Test plan
redocly lintshows no new error categories —PaymentInstructionState.reasonfollows the sameallOf + nullablepattern as the existingOperationState.reason/TransactionState.reason🤖 Generated with Claude Code