Commit f88e8bda authored by Cédric Crettaz's avatar Cédric Crettaz 🖥

Upload New File

parent 2ffeac03
#!/usr/bin/env bash
[[ -z "$ORION_HOST" ]] && echo "Please set ORION_HOST env var. E.g. export ORION_HOST=127.0.0.1" && exit
echo "Querying context broker at: ${ORION_HOST}"
# API NOTES:
# "condition": { "attrs": [] } -> means monitor all the attributes in the entity
curl --location --request POST \
"http://$ORION_HOST:1026/v2/subscriptions/" \
--header "Fiware-Service: braila" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data '{
"description": "Notify QuantumLeap, the historic API, of all Device changes",
"subject": {
"entities": [
{
"idPattern": ".*",
"type": "Device"
}
],
"condition": {
"attrs": []
}
},
"notification": {
"http": {
"url": "http://172.18.1.7:8668/v2/notify"
},
"attrs": [],
"metadata": ["dateCreated", "dateModified"]
}
}'
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment