How to change subscribers address

etherkye
Contributor
Contributor

Looking at the horribly inadequate documentation for the subscriptions API the best I can find is this: https://developer.paypal.com/docs/subscriptions/full-integration/subscription-management/#update-sub...

 

However trying to path the address isn't working, here's the var_dumps. Any ideas would be most appreciated. I think it's the patch path, but as I copied it from the guides, I don't know what else it can be.

 

array(1) { [0]=> array(3) { ["op"]=> string(7) "replace" ["path"]=> string(28) "/subscriber/shipping_address" ["value"]=> array(1) { ["shipping_address"]=> array(6) { ["address_line_1"]=> string(18) "12 XXXXXXXXXX" ["address_line_2"]=> string(0) "" ["admin_area_2"]=> string(14) "Greater London" ["admin_area_1"]=> string(7) "England" ["postal_code"]=> string(7) "XXX XXX" ["country_code"]=> string(2) "GB" } } } }

 

 

array(5) { ["name"]=> string(15) "INVALID_REQUEST" ["message"]=> string(72) "Request is not well-formed, syntactically incorrect, or violates schema." ["debug_id"]=> string(13) "950047bbbd901" ["details"]=> array(1) { [0]=> array(5) { ["field"]=> string(7) "/0/path" ["value"]=> string(28) "/subscriber/shipping_address" ["location"]=> string(4) "body" ["issue"]=> string(18) "INVALID_PATCH_PATH" ["description"]=> string(33) "Specified field cannot be patched" } } ["links"]=> array(1) { [0]=> array(3) { ["href"]=> string(78) "https://developer.paypal.com/docs/api/v1/billing/subscriptions#INVALID_REQUEST" ["rel"]=> string(16) "information_link" ["method"]=> string(3) "GET" } } }

 

Login to Me Too
0 REPLIES 0

Haven't Found your Answer?

It happens. Hit the "Login to Ask the community" button to create a question for the PayPal community.