xendit-node
xendit-node copied to clipboard
Type not specific enough for getPaymentsByPaymentMethodId
https://github.com/xendit/xendit-node/blob/85c741b9b94542a7c55b757d45c96b056c5d57f2/payment_method/apis/PaymentMethod.ts#L292-L299
Notice that the return type is object
. Was expecting a proper type. Here's a sample payload I got:
{
data: [
{
amount: 20.58,
business_id: '65758dd48ce3112f63c41f2c',
channel_code: 'QRPH',
country: 'PH',
created: '2024-06-05T10:24:47.265313Z',
currency: 'PHP',
id: 'pymt-12c3b34a-1343-4958-a2c0-011b4c61dc8f',
instrument_id: 'qrpy_b04be677-82f9-40a1-9967-bfa8d7e72779',
payment_detail: [Object],
payment_method: [Object],
payment_request_id: 'pr-dbede44c-25c3-4bd8-8188-2c8d2026928a',
reference_id: '7c624c78-523f-4a40-9aed-40ef842d4e7b',
status: 'SUCCEEDED',
type: 'QR_CODE',
updated: '2024-06-05T10:24:47.265313Z'
}
],
has_more: false,
links: [
{
href: '/v2/payment_methods/pm-9a4fa574-a6f3-419d-ba16-348077337456/payments?limit=10&payment_request_id=pr-dbede44c-25c3-4bd8-8188-2c8d2026928a',
method: 'GET',
rel: 'first'
}
]
}