Repository navigation
fix: let Airwallex customer, payment intent and refund lists page - #212
Merged
Merged
Conversation
`Customer.list`, `PaymentIntent.list` and `Refund.list` now read `startingAfter` as a previous page's `nextCursor`, request that 0-based `page_num`, and return the next page's cursor while Airwallex has more. An item id, a cursor for another `limit`, and the `email` / `charge` filters this provider cannot apply (ignored until now) fail with `PaymentInvalidRequestError`. Closes #202 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01SwiB327vtGxPf5T8PzcC25
thomasfosterau
force-pushed
the
claude/issue-202-airwallex
branch
from
October 22, 2026 10:56
d3d3353 to
3e0fc88
Compare
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
This is the Airwallex half of #202, built to the owner's decision there: option A, an opaque cursor (comment). The PayPal half, #211, has merged. It brought the shared core and Stripe commit (
Page.nextCursor, Stripe setting it to the last item's id, and the core./internalpageNumberedList), so after a rebase ontotrunkthis PR is the Airwallex change alone:Customer.list,PaymentIntent.listandRefund.listgo throughpageNumberedList, requesting the 0-basedpage_numthe cursor names. The first page sends nopage_num, so the wire is unchanged for it. Each page carries the next page's cursor while Airwallex reportshas_more.pageNumberedListrefuses an item id, a malformed cursor, or a cursor for anotherlimitwithPaymentInvalidRequestError(param: "startingAfter") before anything is sent.PaymentInvalidRequestErrorinstead of being ignored:Customer.list'semail, andRefund.list'scharge, since Airwallex has no charges.Closes #202
Verification
Run in a worktree after
pnpm install --frozen-lockfile, rebased ontrunkat9f1fb99(after #211):vp check: pass (0 errors; 119 warnings, the same set as ontrunk)vp run check: passvp run -r test:unit: pass (core 152, Airwallex 127, PayPal 167, Stripe 1369)vp run -r build: passvp run docgen: pass ("docgen: every example compiled and ran")vp run test:coverage: pass, thenfallow audit --base origin/trunk: pass ("No issues in 4 changed files")Before #211 merged, I ran
fallow dupeson a scratch branch combining both PRs. It reported no new clone group.Changeset
.changeset/airwallex-list-paging.md: Airwallex patch (paging, and the refusedemailandchargefilters).Notes
www.airwallex.com), sopage_num(0-based, next topage_size) is Airwallex's documented list paging as I know it, not checked against the live reference. If Airwallex uses a different parameter for these three endpoints, the fix is one query key inAirwallexPayments.ts. The first page doesn't depend on it.emailfilter: I couldn't confirm against the docs whether Airwallex's customer list can filter by email, so refusing is the safe reading of the core invariant. Honouring a verified parameter later would be a follow-up.🤖 Generated with Claude Code
https://claude.ai/code/session_01SwiB327vtGxPf5T8PzcC25