httpPost() not sending content in 7.9.17

I'm using 7.9.17 and am trying to post to a URL using httpPost() - system.net.httpPost - Ignition User Manual 7.9 - Ignition Documentation

val = system.net.httpPost("http://localhost:5000/available_tasks", {"status":"ready"})

However in my server, I get the following message as traceback:

b'' "
raise JSONDecodeError("Expecting value", s, err.value) from None
json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)

I think it is trying to tell me that the contents of the message is empty.
What is the mistake I am making?

you are passing URL params, is it possible your server is expecting post data instead?

Try adding keyword args and providing data explicitly:

val = system.net.httpPost(url="http://localhost:5000/available_tasks", postData={"status":"ready"})

Thanks!
There was a bit more that was needed to solve this.
Solution:

json_str = system.util.jsonEncode({"status":"ready"})
val = system.net.httpPost(url="http://localhost:5000/available_tasks", postData=json_str, contentType="application/json")