V4.1 API call not working (params not "received")

I’m pretty sure SSL is required, unless you set in the parameters HTTP is allowed.

Where is this parameter you speak of? Reminder that I’m running via the Bitnami SuiteCRM container.

 curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, false);
        curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);

Otherwise connection will fail without SSL on both sides.

I appreciate your continued help, but note that I’m connecting via HTTP, not HTTPS. I have added code to disable SSL as you suggest but I get the same output.

Luckily, I’ve found the problem. I’m not sure why it seems that only I have this issue, but I added more logging in the SuiteCRM code and found that the JSON rest_data payload is ending up encoded. I’ve tried sending it as plain text ({"field": "value"}) and as URL-encoded ({&field&: &value&}). In the end the value received in SugarRestJSON->serve() is:

{"user_auth":{"user_name":"admin","password":"dd995564b1fa70241364c5926aa27997"},"application_name":"My SuiteCRM REST Client","name_value_list":[]}

PHP’s json_decode does not decode these HTML entities, so the resulting JSON object ended up being empty.

I’ve worked around this by adding html_entity_decode() around the code that pulls the rest_data.

I’ve submitted a PR for this: decode HTML entities in REST/JSON service by JoshMcCullough · Pull Request #558 · salesagility/SuiteCRM-Core · GitHub