#Andsis
1 messages · Page 1 of 1 (latest)
FYI my code is:
try {
const paymentIntent = await stripe.paymentIntents.retrieve(body.paymentIntentId);
console.log("got the payment intent", paymentIntent);
const terminal = await stripe.terminal.readers.retrieve(
body.terminalId
);
console.log("got the terminal",terminal);
const result = await terminal.collectRefundPaymentMethod(
paymentIntent.latest_charge,
body.amount,
"cad"
);
HI 👋 I don't think that function has been built into our libraries just yet.
The last reference I see of refund_payment in the release notes for that library is related to a beta version:
https://github.com/stripe/stripe-node/releases/tag/v10.3.0-beta.1
#1511 API Updates for beta branch
Updated stable APIs to the latest version
Add refund_payment method to Terminal resource
See the changelog for more details.
yes I see I need to add terminal_interac_refunds_beta=v1 to the header
Okay so don't use the SDK for that call then
Yeah, that would be my suggestion for now.
Okay great thanks thats good to know! thank you!
Happy to help!