Next: Copying, Previous: Adapter HTTP Behaviour, Up: STCA Parameters Plugin [Contents]
examples/parameters.stca.xml configures the adapter on
127.0.0.1:8080 and the plugin HTTP API on
127.0.0.1:8081, with a relative db-path of
./params.db and two sample parameters (setpoint,
offset).
$ curl http://127.0.0.1:8080/data
$ curl http://127.0.0.1:8081/params
$ curl -X PUT http://127.0.0.1:8081/params/setpoint \
-H 'Content-Type: application/json' \
-d '{ "value": 22.5 }'
# Adapter write is rejected:
$ curl -X PUT http://127.0.0.1:8080/data/setpoint \
-H 'Content-Type: application/json' \
-d '23'