Blocks Area

Requests

πŸ“¨ Requests – Your Miniaturized “Web Browser

What it is: Blocks for making web requests (HTTP).

What it does: Communicates with websites and online services.

Example: Asking a website for the time or weather.

πŸ‘‰ It’s the robot’s web browser.

Β 

🧩 Fun Guide to HTTP Requests Blocks (Clu-blocks Pro)

🌍 Important! Request blocks let your robot send and receive data from the internet β€” like asking a website for weather info, sending sensor data to a server, or chatting with an online app!


🌐 Sending Requests

#BlockWhat it doesDropdown optionsWhat the options mean
1response value towards "http://Clu-Bots.com" Conduct get Request and get resultSends a GET request to a websiteget, head, deleteget: asks for data
head: gets headers only
delete: removes data
2response value towards "http://Clu-Bots.com" Conduct post Request RequestContent "application/json" and get resultSends a POST request with contentpost, put, patchpost: sends new data
put: updates data
patch: edits part of it
3RequestContentSets the content to sendβ€”Usually JSON, text, or form data β€” like { "temp": 22 }

πŸ“₯ Handling Responses

#BlockWhat it doesDropdown optionsWhat the options mean
4get Response content from responseReads the reply from the serverResponse content, JSON deserialization, Status Code, Bin content, encodeResponse content: plain text
JSON deserialization: turns reply into usable data
Status Code: shows success/failure
Bin content: raw bytes
encode: encoding type

🧠 Quick Tips for Students

  • Use GET to ask for info β€” like weather, jokes, or sensor data.
  • Use POST to send info β€” like scores, logs, or commands.
  • Use JSON format for smart data β€” it’s like sending a mini-dictionary.
  • Use Status Code to check if it worked β€” 200 = success, 404 = not found.
  • Use Response content to show results β€” great for printing or displaying on LCD/OLED.
On this page