Update a PaymentPlan

I need to update details of an orders payment plan (FirstPayAmt, InitDate, StartDate) using the API. Could someone advise how to do that with either the REST or XML API. I’ve tried updating the tables but the fields seems to be read-only.

There’s a documented method " Replace an Order Pay Plan" of the REST API but I can’t see to figure out how I’d use that from the PHP SDK?

Any one able to help?

Mark