Skip to content

Instantly share code, notes, and snippets.

@fgalan
Created February 13, 2015 17:32
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save fgalan/b74b057399e6f8e2ed98 to your computer and use it in GitHub Desktop.
Save fgalan/b74b057399e6f8e2ed98 to your computer and use it in GitHub Desktop.
fermin@oriondeb:~/src/fiware-orion$ mongo orion
MongoDB shell version: 2.4.9
connecting to: orion
> db.dropDatabase()
{ "dropped" : "orion", "ok" : 1 }
> ^C
bye
fermin@oriondeb:~/src/fiware-orion$ (curl localhost:1026/ngsi10/contextEntities/cie_test_1/attributes/test_1 -s -S --header 'Content-Type: application/json' --header 'Accept: application/json' -d @- ) <<EOF
{"value":"10"}
EOF
"statusCode" : {
"code" : "200",
"reasonPhrase" : "OK"
}
fermin@oriondeb:~/src/fiware-orion$ curl http://localhost:1026/ngsi10/contextEntities/cie_test_1 --header 'Accept: application/json'
{
"contextElement" : {
"type" : "",
"isPattern" : "false",
"id" : "cie_test_1",
"attributes" : [
{
"name" : "test_1",
"type" : "",
"value" : "10"
}
]
},
"statusCode" : {
"code" : "200",
"reasonPhrase" : "OK"
}
}
fermin@oriondeb:~/src/fiware-orion$ (curl localhost:1026/ngsi10/contextEntities/cie_test_1/attributes/test_1 -s -S --header 'Content-Type: application/json' --header 'Accept: application/json' -d @- ) <<EOF
{"value":"50"}
EOF
"statusCode" : {
"code" : "200",
"reasonPhrase" : "OK"
}
fermin@oriondeb:~/src/fiware-orion$ curl http://localhost:1026/ngsi10/contextEntities/cie_test_1 --header 'Accept: application/json' {
"contextElement" : {
"type" : "",
"isPattern" : "false",
"id" : "cie_test_1",
"attributes" : [
{
"name" : "test_1",
"type" : "",
"value" : "50"
}
]
},
"statusCode" : {
"code" : "200",
"reasonPhrase" : "OK"
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment