feat: adding purpose of payment to quote#214
Conversation
9800c97 to
1e1e9d2
Compare
✱ Stainless preview buildsThis PR will update the kotlin openapi python typescript ✅ grid-typescript studio · code
✅ grid-python studio · code
This comment is auto-generated by GitHub Actions and is automatically kept up to date as you push. |
Greptile SummaryAdds
Issues found:
Confidence Score: 3/5
|
| Filename | Overview |
|---|---|
| openapi/components/schemas/quotes/PurposeOfPayment.yaml | New schema defining purpose of payment enum with 12 values for quote requests |
| openapi/components/schemas/quotes/QuoteRequest.yaml | Added purposeOfPayment field to quote request schema, creating potential dual paths with senderCustomerInfo |
| mintlify/snippets/sending/cross-currency.mdx | Updated documentation to use new purposeOfPayment field instead of senderCustomerInfo.PURPOSE_OF_PAYMENT |
Flowchart
%%{init: {'theme': 'neutral'}}%%
flowchart TD
A[Client creates quote request] --> B{Payment corridor requires<br/>purpose of payment?}
B -->|Yes<br/>e.g., India| C[Include purposeOfPayment field<br/>GIFT, SELF, GOODS_OR_SERVICES, etc.]
B -->|No| D[Optional: Include purposeOfPayment]
C --> E[POST /quotes]
D --> E
E --> F[Quote created with locked rate]
F --> G[Execute quote]
G --> H[Payment processed]
Last reviewed commit: 93ac62f
1e1e9d2 to
93ac62f
Compare
| enum: | ||
| - GIFT | ||
| - SELF | ||
| - GOODS_OR_SERVICES | ||
| - EDUCATION | ||
| - HEALTH_OR_MEDICAL | ||
| - REAL_ESTATE_PURCHASE | ||
| - TAX_PAYMENT | ||
| - LOAN_PAYMENT | ||
| - UTILITY_BILL | ||
| - DONATION | ||
| - TRAVEL | ||
| - OTHER |
There was a problem hiding this comment.
Inconsistent with existing purposeOfPayment enum in NgnAccountExternalAccountInfo.yaml. The NGN schema has different order (LOAN_PAYMENT before TAX_PAYMENT) and is missing TRAVEL and OTHER values. Consider unifying these enums or using a $ref to share the same definition.
Prompt To Fix With AI
This is a comment left during a code review.
Path: openapi/components/schemas/quotes/PurposeOfPayment.yaml
Line: 5-17
Comment:
Inconsistent with existing `purposeOfPayment` enum in `NgnAccountExternalAccountInfo.yaml`. The NGN schema has different order (`LOAN_PAYMENT` before `TAX_PAYMENT`) and is missing `TRAVEL` and `OTHER` values. Consider unifying these enums or using a `$ref` to share the same definition.
How can I resolve this? If you propose a fix, please make it concise.| purposeOfPayment: | ||
| $ref: ./PurposeOfPayment.yaml |
There was a problem hiding this comment.
The CLI (cli/src/commands/quotes.ts:180) still uses the old pattern senderCustomerInfo.PURPOSE_OF_PAYMENT instead of this new top-level purposeOfPayment field. Update the CLI to use the new field.
Prompt To Fix With AI
This is a comment left during a code review.
Path: openapi/components/schemas/quotes/QuoteRequest.yaml
Line: 47-48
Comment:
The CLI (`cli/src/commands/quotes.ts:180`) still uses the old pattern `senderCustomerInfo.PURPOSE_OF_PAYMENT` instead of this new top-level `purposeOfPayment` field. Update the CLI to use the new field.
How can I resolve this? If you propose a fix, please make it concise.
Adding purpose of payment to quotes