Is there any reason JSON API can't run and be developed on a Mivatest dev store? Is there a misconfiguration in the dev store?
I'm seeing complaints in the response about an invalid date and the endpoint in the response is a cloudflare url, not what I submitted. The content type is also not what is submitted.
Works on my own store (not a dev store, no cloudflare). I've verified the access tokens are correct and privileges' are set correctly per the store.
Payload should have nothing to do with the call, but here's the JSON API payload:
If it helps, here's the first line of the response.
I'm wondering if it's a firewall rule in Cloudflare?
I'm seeing complaints in the response about an invalid date and the endpoint in the response is a cloudflare url, not what I submitted. The content type is also not what is submitted.
Code:
<mvt:call action="g.endpoint" method="'RAW'" headers="g.headers" content-type="'application/json'" fields="'g.json_data'"> <mvt:eval expr="s.callreturnheader1" /><br><br> <mvt:assign name="g.cr" value="g.cr $ s.callreturnheader1 $ '|'" /> <mvt:assign name="g.cr" value="g.cr $ s.callreturnheader2 $ '|'" /> <mvt:assign name="g.cr" value="g.cr $ s.callreturnheader3 $ '|'" /> <mvt:assign name="g.cr" value="g.cr $ s.callreturnheader4 $ '|'" /> <mvt:assign name="g.cr" value="g.cr $ s.callreturnheader5 $ '|'" /> <mvt:assign name="g.cr" value="g.cr $ s.callreturnheader6 $ '|'" /> <mvt:assign name="g.cr" value="g.cr $ s.callreturnheader7 $ '|'" /> <mvt:assign name="g.cr" value="g.cr $ s.callreturnheader8 $ '|'" /> <mvt:assign name="g.cr" value="g.cr $ s.callreturnheader9 $ '|'" /> <mvt:assign name="g.response" value="g.response $ s.callvalue" /> </mvt:call> Order Load Response: <br> &mvt:global:cr;<br /> <textarea rows="20" cols="200"> &mvt:global:response; </textarea> <br>
Payload should have nothing to do with the call, but here's the JSON API payload:
Code:
{ "Miva_Request_Timestamp": "1683050694", "Store_Code": "STOREIDHERE", "Function": "Product_Update", "Iterations": [ { "Edit_Product": "PRODCODE1", "CustomField_Values": { "baskinv": { "total_inv": 1 } } }, { "Edit_Product": "PRODCODE2", "CustomField_Values": { "baskinv": { "total_inv": 2 } } } ] }
Order Load Response:
HTTP/1.1 401 Unauthorized|Date: Tue, 02 May 2023 19:08:22 GMT|Content-Type: text/html; charset=iso-8859-1|Content-Length: 457|Connection: close|www-authenticate: Basic realm="Protected_Dev_Site"|CF-Cache-Status: DYNAMIC|Report-To: {"endpoints":[{"url":"https:\/\/a.nel.cloudflare.com\/report\/v3?
HTTP/1.1 401 Unauthorized|Date: Tue, 02 May 2023 19:08:22 GMT|Content-Type: text/html; charset=iso-8859-1|Content-Length: 457|Connection: close|www-authenticate: Basic realm="Protected_Dev_Site"|CF-Cache-Status: DYNAMIC|Report-To: {"endpoints":[{"url":"https:\/\/a.nel.cloudflare.com\/report\/v3?
Comment