Skip to content

Instantly share code, notes, and snippets.

@otfrom
Created September 12, 2014 12:51
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 otfrom/e180ebaa7118d9121808 to your computer and use it in GitHub Desktop.
Save otfrom/e180ebaa7118d9121808 to your computer and use it in GitHub Desktop.
----------- DATASETS -------------
-- Divide--
curl -v -H 'Content-Type: application/json' -u <username>:<password> -X POST --data "{\"entity_id\":\"9ac7f5635832d843dda594f58525239263ffdd37\",\"operation\":\"divide\", \"name\": \"systemEfficiencyOverall\", \"members\": [\"interpolatedHeatConsumption-b4f0c7e2b15ba9636f3fb08379cc4b3798a226bb\", \"interpolatedElectricityConsumption-268e93a5249c24482ac1519b77f6a45f36a6231d\"]}" http://www.getembed.com/4/entities/9ac7f5635832d843dda594f58525239263ffdd37/datasets/
-- Subtract --
curl -v -H 'Content-Type: application/json' -u <username>:<password> -X POST --data "{\"entity_id\":\"9ac7f5635832d843dda594f58525239263ffdd37\",\"operation\":\"subtract\", \"name\": \"cop-subtraction\", \"members\": [\"interpolatedElectricityConsumption-268e93a5249c24482ac1519b77f6a45f36a6231d\", \"interpolatedElectricityConsumption-3aae0fe7ddaa5e400a2cf9580a5e548d9255c70a\", \"interpolatedElectricityConsumption-122b4bf8dfa66cbf8f321f2d03c4d73f924bb719\"]}" http://www.getembed.com/4/entities/9ac7f5635832d843dda594f58525239263ffdd37/datasets/
-- Divide (CoP)
curl -v -H 'Content-Type: application/json' -u <username>:<password> -X POST --data "{\"entity_id\":\"9ac7f5635832d843dda594f58525239263ffdd37\",\"operation\":\"divide\", \"name\": \"cop-overall\", \"members\": [\"interpolatedHeatConsumption-b4f0c7e2b15ba9636f3fb08379cc4b3798a226bb\", \"interpolatedElectricityConsumption-268e93a5249c24482ac1519b77f6a45f36a6231d\", \"interpolatedElectricityConsumption-3aae0fe7ddaa5e400a2cf9580a5e548d9255c70a\", \"interpolatedElectricityConsumption-122b4bf8dfa66cbf8f321f2d03c4d73f924bb719\"]}" http://www.getembed.com/4/entities/9ac7f5635832d843dda594f58525239263ffdd37/datasets/
-- Add (Total kWh) --
curl -v -H 'Content-Type: application/json' -u <username>:<password> -X POST --data "{\"entity_id\":\"9ac7f5635832d843dda594f58525239263ffdd37\",\"operation\":\"sum\", \"name\": \"total-kwh\", \"members\": [\"gasConsumption_kwh-fe5ab5bf19a7265276ffe90e4c0050037de923e2\", \"electricityConsumption-fe5ab5bf19a7265276ffe90e4c0050037de923e2\"]}" http://www.getembed.com/4/entities/9ac7f5635832d843dda594f58525239263ffdd37/datasets/
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment