Skip to content

fix(types): allow string fail_existing for customers.create#467

Open
Sayansh2004 wants to merge 1 commit intorazorpay:masterfrom
Sayansh2004:fix/customers-fail-existing-types
Open

fix(types): allow string fail_existing for customers.create#467
Sayansh2004 wants to merge 1 commit intorazorpay:masterfrom
Sayansh2004:fix/customers-fail-existing-types

Conversation

@Sayansh2004
Copy link
Copy Markdown

Summary

Updates the TypeScript type for fail_existing on customer create so callers can use string '0' / '1' in addition to boolean and numeric 0 / 1, which matches what the Customers API accepts (see #463).

Changes

  • lib/types/customers.d.ts: widen fail_existing and clarify JSDoc.
  • dist/types/customers.d.ts: synced from lib after build.
  • CHANGELOG.md: Unreleased note under the same style as previous entries.

Testing

  • Ran npm test locally (build + mocha + nyc); all tests passed.
  • Confirmed in TypeScript that customers.create({ ..., fail_existing: '0' }) and fail_existing: '1' type-check without errors.

Fixes #463

@Sayansh2004
Copy link
Copy Markdown
Author

Summary

Updates the TypeScript type for fail_existing on customer create so callers can use string '0' / '1' in addition to boolean and numeric 0 / 1, which matches what the Customers API accepts (see #463).

Changes

  • lib/types/customers.d.ts: widen fail_existing and clarify JSDoc.
  • dist/types/customers.d.ts: synced from lib after build.
  • CHANGELOG.md: Unreleased note under the same style as previous entries.

Testing

  • Ran npm test locally (build + mocha + nyc); all tests passed.
  • Confirmed in TypeScript that customers.create({ ..., fail_existing: '0' }) and fail_existing: '1' type-check without errors.

Fixes #463

Hi — the BVT check asks for the Tested (with test doc) or TestingNotRequired label. This PR only updates TypeScript types and CHANGELOG for #463. Could a maintainer please add TestingNotRequired, and approve the pending workflows if needed? Thanks.

@Sayansh2004
Copy link
Copy Markdown
Author

Hi — the BVT check asks for the Tested (with test doc) or TestingNotRequired label. This PR only updates TypeScript types and CHANGELOG for #463. Could a maintainer please add TestingNotRequired, and approve the pending workflows if needed? Thanks.

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.

Incorrect TypeScript Typings for fail_existing in customers.create (should allow '0' | '1' strings)

1 participant