I am trying to activate a billing plan that is previously created and I get the malformed json error.
Activate endpoint:
"/v1/payments/billing-plans/{plan-id}"
Request body:
[
{
"path": "",
"value": {
"state": "ACTIVE"
},
"op": "replace"
}
]
In PHP:
$payLoad = json_encode(array(array(
'path' => "",
'value' => array(
'state' => 'ACTIVE'
),
'op' => 'replace'
)));
And the response I get:
{"name":"MALFORMED_REQUEST","message":"Incoming JSON request does not map to API request"....}
Edit: I have also tried path to have a value of "/"
"path": "\/",
but to no avail.