curl -X POST "https://api.mit-app-inventor-sim.local/v1/projects/MedCare" \
-H "Content-Type: application/json" \
-d '{
"project_name": "MedCare",
"screens": [
{
"id": "Screen1",
"components": ["BluetoothClient", "SpeechRecognizer", "ListPicker"],
"logic": {
"connection": "When ListPicker.BeforePicking -> Set Elements to Bluetooth.Addresses",
"movement": {
"Forward": "Send F",
"Backward": "Send B",
"Left": "Send L",
"Right": "Send R",
"Stop": "Send S"
},
"utility": {
"TorchON": "Send T1",
"TorchOFF": "Send T0",
"Voice": "Send SpeechResult"
}
}
},
{
"id": "Screen2",
"components": ["Clock", "TinyDB", "PhoneCall", "Texting"],
"logic": {
"reminders": {
"Medicine": "If ClockTime == TinyDB(med_hour, med_min) -> Notify & Send M",
"Water": "If ClockTime == TinyDB(water_hour, water_min) -> Notify & Send W"
},
"emergency": {
"Trigger": "Call(TextBoxNum) + SMS(Emergency Message) + BT(Send E)"
}
}
}
]
}'
Where did you get the JSON from?
it is a cURL form not JSON I got it from a ai website
pleas convert and give this as a block code adaptable with mit app inventor
from gemini ai
I asked the AI2 AI bot and got
Then it squirted me in the eye with machine oil
But if all you want is the cURL conversion, you could try
from
Let us know if your AI assistant generated the web service to run on your machine to complete the POST request.
This is my hand conversion attempt.
(draggableblocks)
cURL.aia (3.2 KB)
I leave it to you to test it.
(edit - I forgot the inevitable 1103 (URL not found) error -




