Skip to content

feat(backend): add memory invoice public id helper (#275) - #351

Draft
s6pa1rta3n-lab wants to merge 1 commit into
Quittance-Labs:mainfrom
s6pa1rta3n-lab:fix-issue-275
Draft

feat(backend): add memory invoice public id helper (#275)#351
s6pa1rta3n-lab wants to merge 1 commit into
Quittance-Labs:mainfrom
s6pa1rta3n-lab:fix-issue-275

Conversation

@s6pa1rta3n-lab

Copy link
Copy Markdown

Summary

Implements generatePublicInvoiceId() in backend/src/utils/memory-public-id.ts for MVP/in-memory invoice creation and wires it into InvoiceMemoryService.

Changes

  • backend/src/utils/memory-public-id.ts: Implemented generatePublicInvoiceId(), isValidPublicInvoiceId(), and normalizePublicInvoiceId().
  • backend/tests/fixtures/memory-public-id.fixture.ts: Added fixture cases for format verification, validation, normalization, and uniqueness properties.
  • backend/tests/memory-public-id.test.ts: Added unit test suite covering format, property cases, validation rejection, normalization, uniqueness, and edge cases.
  • backend/src/services/invoice-memory.service.ts: Imported generatePublicInvoiceId() and assigned explicit public id upon invoice creation.

Closes #275

Payout Routing

  • EVM (Base/Arbitrum/Polygon/ETH): 0xF46C9F6d70C50BF81ef3588AB523a90a594a2F89
  • Stellar: GCL6OXAMLD75BMTINA6EMRUDWK5THQUSHMYNLSNBCJAPZJHNYJTUNIBC

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat(backend): add memory invoice public id helper

1 participant