Skip to content

Feat(developer-sdk): Meld Subdivision Ramp Option - #178

Merged
thewuhxyz merged 7 commits into
mainfrom
wuh/meld-subdivision
Jul 23, 2026
Merged

Feat(developer-sdk): Meld Subdivision Ramp Option#178
thewuhxyz merged 7 commits into
mainfrom
wuh/meld-subdivision

Conversation

@thewuhxyz

Copy link
Copy Markdown
Collaborator
  • Adds typed ramp country/subdivision options to the developer SDK.
  • Normalizes backend countries[].subdivisions[] responses into the SDK’s camelCase public shape.
  • Preserves compatibility with older countryCodes-only ramp options responses.

@thewuhxyz
thewuhxyz requested a review from edo-chan July 3, 2026 15:42
@thewuhxyz
thewuhxyz force-pushed the wuh/meld-subdivision branch from 382b8ac to e2f3650 Compare July 22, 2026 15:54

@edo-chan edo-chan left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Requesting changes on three blockers:

  1. The required Developer SDK Python check is failing because Ruff would reformat packages/developer-sdk/python/src/swig_developer_sdk/ramp.py and packages/developer-sdk/python/tests/test_resource_clients.py. Please apply Ruff formatting and rerun the required check.

  2. The country and subdivision normalizers at packages/developer-sdk/typescript/src/ramp/client.ts:121-175 and packages/developer-sdk/python/src/swig_developer_sdk/ramp.py:385-452 silently discard entries missing codes, synthesize missing names, and default missing subdivision arrays. This hides malformed successful responses, and the TypeScript and Python clients disagree when a present non-empty countries array contains only invalid entries. Keep the legacy fallback when top-level countries is absent or empty, but reject malformed entries once the array is present. Please add missing-field and cross-SDK parity tests.

  3. serviceProviderCode is required, but the readers used at packages/developer-sdk/typescript/src/ramp/client.ts:325-371 and packages/developer-sdk/python/src/swig_developer_sdk/ramp.py:559-562 accept an empty string and coerce numbers or booleans into identifiers. Please require a non-empty actual string in both SDKs and add empty and wrong-type tests.

The snake-case and camel-case handling, public exports, and legacy country-code fallback otherwise match the merged backend contract.

@edo-chan edo-chan left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approving overall. The previously noted response-boundary items are non-blocking follow-ups; the required Python formatting check should still pass before merge.

@thewuhxyz
thewuhxyz merged commit 6fc9e22 into main Jul 23, 2026
5 checks 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.

2 participants