Skip to content

Add fake payment sending API#30

Open
jynbil1 wants to merge 3 commits into
tscircuit:mainfrom
jynbil1:codex-payment-api-1778654139
Open

Add fake payment sending API#30
jynbil1 wants to merge 3 commits into
tscircuit:mainfrom
jynbil1:codex-payment-api-1778654139

Conversation

@jynbil1
Copy link
Copy Markdown

@jynbil1 jynbil1 commented May 13, 2026

Adds a fake payment API for #1.

What changed:

  • Adds payment persistence to the in-memory db schema/client.
  • Adds POST /payments/send with currency normalization and idempotency-key deduplication.
  • Adds GET /payments/list and GET /payments/get.
  • Adds POST /payments/update-status for payment lifecycle updates.
  • Documents the payment endpoints in the README.
  • Adds route tests for send, list, get, idempotent resend, and status update behavior.

Verification:

  • bun test tests/routes/payments/send.test.ts
  • winterspec bundle -o dist/bundle.js
  • tsc --noEmit
  • biome check README.md lib/db/schema.ts lib/db/db-client.ts routes/payments/update-status.ts tests/routes/payments/send.test.ts

/claim #1

Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 8d2039faa6

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread routes/payments/send.ts Outdated
@jynbil1
Copy link
Copy Markdown
Author

jynbil1 commented May 13, 2026

Fixed the default currency issue from the automated review and added a regression test for requests that omit currency. Re-ran Winterspec bundling and tsc --noEmit successfully.

@jynbil1
Copy link
Copy Markdown
Author

jynbil1 commented May 13, 2026

Added /claim #1 to the PR body so this PR is explicitly tied to the bounty issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant