Well, we can use "URL & split" to get/parse https/http responses. Does any block can be used to handle RESTful APIs?
File -> Libraries... -> Web services access (https) -> Import
Thanks.
What the heck is a restful?
Sending requests to servers to get information
[EDIT: "no utube"]
no utube
RESTful = REST. More info: What is a REST API?
json of list
(same block as length of list
)
I think you put the json in the send
(internally called payload
) parameter.
Well, restful server prints: "I (8813) http: Light control: a List [3 elements]", actually "a List [3 elements]", so it seems NOT a json string. Any way to convert list to json object?
List in Snap seems OK, kind of a table.
Really weird , why set channel5 to 1500 is a string???? not int?
Is there any way to convert it to int?
A way to convert a string to number is by using any math block in place of the value. I personally would not do it in snap, but instead have the server convert the string to a number. That way you don't have to rely on snap sending the correct data type.
Yeah, HTTP server has added type check.
This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.