There is an error with one of our subscriptions which has now been removed from sale. We need to refund the customers who have already purchased it. Is it possible to do that, and if so, how?
Is it possible to refund subscriptions
I would recommend checking out the https://developer.apple.com/documentation/appstoreserverapi/extending_the_renewal_date_for_auto-renewable_subscriptions endpoint.
"If your service experiences a temporary outage, canceled event, or interruption to a live streamed event, you may choose to compensate your customers by extending the renewal date of their paid, active subscription."