feat: handle duplicate notification setting error from api-specifications#2423 - #234
Merged
Merged
Conversation
Co-authored-by: Jed Patterson <jed.patterson@paddle.com>
Co-authored-by: Jed Patterson <jed.patterson@paddle.com>
Keep the duplicate notification setting error coverage without bumping the published package version. Co-authored-by: Jed Patterson <jed.patterson@paddle.com>
Keep both Unreleased Added entries from main and this branch. Co-authored-by: Jed Patterson <jed.patterson@paddle.com>
jedpattersonpaddle
approved these changes
Aug 6, 2026
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
Adds explicit regression coverage for the public
notification_setting_cannot_be_duplicaterequest error introduced by api-specifications#2423 and tracked in DX-1082. The package version is bumped from 3.8.0 to 3.9.0 for the additive API contract.Spec-to-SDK mapping
request_errorfor duplicate notification settingssrc/__tests__/mocks/resources/notification-settings.mock.tsadds the exact error fixture;src/__tests__/resources/notification-settings.test.tsverifies bothcreate()andupdate()preserve the exact code and detail inApiErrorCHANGELOG.md;package.jsonIntentionally excluded
No production resource, response type, entity, enum, notification mirror, event class, or webhook mock changed.
ErrorDetail.codeandErrorDetail.detailalready accept arbitrary strings,ApiErroralready preserves them, and both notification-setting methods already route errors throughBaseResource.handleResponse(). The payment-attemptErrorCodeunion is unrelated to top-level API request errors.The fixture uses the established generated URL convention:
https://developer.paddle.com/errors/notifications/notification_setting_cannot_be_duplicate. The page is not published yet, so a human should confirm the generated documentation URL when the API docs deploy.Validation
pnpm install --frozen-lockfile— passedpnpm build— passedpnpm typecheck:tests— passedpnpm test --runInBand— 34 suites, 277 tests passedpnpm test --runInBand src/__tests__/resources/notification-settings.test.ts— 1 suite, 7 tests passedpnpm prettier— passedpnpm lint— passedCreated by an automated spec-sync agent.