I am having difficulty calling both update and query functions via HTTPS requests to my canister. I am sure it is some kind of json format error, but without logs it is proving to be very difficult to debug. As a result, could someone please provide me a sample request whose pattern I can follow?
Here is a request I am trying to make to call an update function pass_on, which has no arguments:
What am I doing wrong here? Also, I have a function insert_me, which has arguments – considering that DFINITY syntax does not allow single quotes e.g “args” = “(‘a’, ‘b’, ‘c’)” and considering that json does not allow single quotes, how can I pass arguments into the function?
It looks like you are trying to send a json encoded object from python. That will not work, the interaction with the canisters is a bit more involved than that. You will most likely need to use an agent to interact with the IC from your apps. I believe there’s a WIP agent for python, but I haven’t checked on their progress recently. Try searching the forum using “python agent” and see if anything pops up.
If you want to get deeper into the IC and want to learn more, you should give the Interface Specification a thorough read. It details how the IC works, and the HTTP Interface will be of particular interest to your needs.