Skip to content

Feat/one off charge#12

Merged
BenKalsky merged 2 commits into
mainfrom
feat/one-off-charge
May 1, 2026
Merged

Feat/one off charge#12
BenKalsky merged 2 commits into
mainfrom
feat/one-off-charge

Conversation

@BenKalsky
Copy link
Copy Markdown
Member

No description provided.

BenKalsky and others added 2 commits May 2, 2026 01:05
Adds a builder for `POST /billing/payments/charge/` (one-off charge)
alongside the existing recurring builder. Items omit the recurring-only
`Duration_Months` and `Recurrence` fields; everything else (Credentials,
Customer envelope, SingleUseToken, VATIncluded, OnlyDocument,
AuthoriseOnly) is shared via a small `baseChargeEnvelope` helper.

Response normalization is unchanged — the existing logic already
handles both shapes since one-off and recurring responses share the
`Payment.*` envelope. Exposed as `normalizeChargeResponse` to make the
one-off use case discoverable; `normalizeRecurringChargeResponse` stays
as an alias for back-compat.

Updated README, CLAUDE.md, and API reference. All 16 tests pass.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Additive release: new buildOneOffChargePayload + normalizeChargeResponse
alias. No breaking changes.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@BenKalsky BenKalsky merged commit f36d363 into main May 1, 2026
1 check passed
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.

1 participant