Repository navigation
docs: pass the payment interface docs to the docs standard - #20
Merged
Merged
Conversation
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.
Why
Goal: finish the AntelopeJS docs rewrite. Every TypeScript example compiles against its repo's own source, hand-written version prose is gone, and the W1-W5 docs standard ships. This is the W4 pass for interface-payment (outer-loop#35, decision 11 item 5). It brings
README.mdanddocs/to the Docs standard, in the shape of AntelopeJS/dmspackages/dms/docs, and turns standard mode on so CI keeps them there. Precedent: interface-api#71.Summary
package.json "antelopeJs": { "test": ..., "skills": [...], + "docs": { "standard": true } } README.md, docs/*.md (5 pages) + frontmatter title, description, mode (body H1 moved into title) ~ sentence-case headings, no dashes, unslop + technical-writing applied ~ claims checked against src/ and its TSDoc + README badges marked illustrationNo page was split, merged, renamed or moved, and no section, table row or example was dropped. Each docs page lost only its body H1, which moved into
title. Fences stay at 20 (7fragment, none added), checked examples at 9.Modes: introduction explanation, payments how-to, customers and methods how-to, webhooks how-to, provider capability matrix explanation.
Claims corrected against the source
payment.redirectUrl. The webhook handler map is typedRecord<PaymentEventType, ...>and guardspayment,refundanddispute.WebhookVerificationErrormeans the delivery could not be established as genuine, which covers re-fetch providers, not only a bad signature.PaymentNotFoundErrorcovers payments, refunds and checkout sessions.CustomerNotFoundErroralso covers an identifier the provider cannot parse (src/errors.ts).providerCode,InvalidPaymentStateError.statusandUnsupportedOperationError.operation, and what raisesInvalidPaymentStateError: capture when notauthorizedor above the authorized amount, cancel after capture, refund above the remaining amount (src/errors.ts,src/functions.ts,src/types.ts).locale(the closedPAYMENT_LOCALESunion,auto, provider default) (src/types.ts).savePaymentMethodcannot combine withoffSession.ListPaymentMethodsreturns newest first or an empty array (src/types.ts,src/functions.ts).src/tests/payment.test.tsandsrc/tests/payment-charges.test.ts, published as@antelopejs/interface-payment/tests/*(package.jsonexports).@antelopejs/interface-subscriptionsexists). "Only Stripe is implemented in the AntelopeJS ecosystem today" now reads that@antelopejs/stripeis the public module implementing the interface..nvmrcandpackageManager.Heading slugs
{#id}anchors are not used.2.payments#authentication-and-3dsbecame#payer-authentication(Vale's sentence-case rule flags3DSin a heading; the body still names 3DS and SCA). No link in this repo, the sibling payment repos or the AntelopeJS code search points at it. interface-payment has no entry on the interfaces site yet.Evidence
checkDocsin standard mode, Vale 3.26.0):files=6 examples=9 failures=73.files=6 examples=9 failures=0.VALE_BINset: exit 0.pnpm run checkson 6564ed0 withGITHUB_BASE_REF=campaign/integration:Checks: 8 passed, 0 failed.nuxt devinsites/interfaces,INTERFACES_DOCS_LOCAL=email=<clone>). Every page answers 200,pages=5 links=5 anchored=0 broken=0, and no page renders{#.AntelopeJS/tooling-configs/actions/docs@dab0aea28840981138795aca32381e7fa8ac8d1binstalled Vale (standard mode on) and printedDocs: 6 files, 18 local links, 1 compatibility tables, 9 checked examples, 0 API pages; 0 failures.Merge danger
Door: two-way. Docs and one package.json key. A revert restores the old pages and turns standard mode off.
Blast radius: docs. From here on, every interface-payment PR that touches README.md or
docs/must pass Vale and the standard checks in CI.Attention
VerifyWebhook" hints at the internal module.shopperReference, the Mangopay delivery body, the Mollieid=tr_xxxbody). They come from provider documentation.shopperReference-style recurring rather than first-class customer objects" may be wrong for Checkout.com, which has a/customersresource (the internal checkout-com module uses it). Kept as written, because this pass checks claims against this repo and the row describes a provider API.skills/is outside a docs PR's files and was not checked.