-
Notifications
You must be signed in to change notification settings - Fork 7
docs: add SWIFT_ACCOUNT to documentation and Grid Visualizer #478
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||||
|---|---|---|---|---|---|---|---|---|
|
|
@@ -260,6 +260,16 @@ export const accountTypeSpecs: Record<string, AccountTypeSpec> = { | |||||||
| ], | ||||||||
| beneficiaryRequired: false, | ||||||||
| }, | ||||||||
| SWIFT_ACCOUNT: { | ||||||||
| accountType: 'SWIFT_ACCOUNT', | ||||||||
| fields: [ | ||||||||
| { name: 'swiftCode', example: 'DEUTDEFF' }, | ||||||||
| { name: 'bankName', example: 'Deutsche Bank' }, | ||||||||
| { name: 'country', example: 'NG', description: 'ISO 3166-1 alpha-2 code' }, | ||||||||
| { name: 'accountNumber', example: '1234567890', description: 'Or use iban for IBAN-only corridors' }, | ||||||||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
Prompt To Fix With AIThis is a comment left during a code review.
Path: components/grid-visualizer/src/data/account-types.ts
Line: 269
Comment:
The `iban` field is only mentioned in the `accountNumber` description text, so the Grid Visualizer has no way to generate IBAN-based SWIFT account creation requests. Since `external-accounts.mdx` provides a full IBAN curl example as a first-class alternative, the visualizer should expose `iban` as a field too. Without it, users in IBAN-only corridors (e.g., GB, BR) cannot use the visualizer to prototype their integration.
```suggestion
{ name: 'accountNumber', example: '1234567890', description: 'Use for most corridors; mutually exclusive with iban' },
{ name: 'iban', example: 'GB29NWBK60161331926819', description: 'Use instead of accountNumber for IBAN-only corridors (e.g. GB, BR)' },
```
How can I resolve this? If you propose a fix, please make it concise. |
||||||||
| ], | ||||||||
| beneficiaryRequired: true, | ||||||||
| }, | ||||||||
| AED_ACCOUNT: { | ||||||||
| accountType: 'AED_ACCOUNT', | ||||||||
| fields: [ | ||||||||
|
|
||||||||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The
swiftCodeexample is'DEUTDEFF', which is Deutsche Bank Frankfurt — a German bank (ISO country codeDE). Thecountryexample, however, is'NG'(Nigeria). A user copying from the Grid Visualizer would produce a request where the bank country and the SWIFT code point to different countries, which will likely be rejected by the API. The documentation inaccount-model.mdxcorrectly uses'DE'; the visualizer should match.Prompt To Fix With AI