Julien Brdy
Julien Brdy

Reputation: 103

Copy range of historical datapoints between xively channels

I have a legacy Xivey (from Cosm) feed with old channels. I will create new feed and I want to migrate some old data to some new channels. How can I do that efficiently ? Thanks !

Else, I will work with scripts like this...

curl --request GET "http://api.xively.com/v2/feeds/#oldFeed#/datastreams/#oldChannel#.csv?key=#key#&start=2013-12-02&duration=24hours&interval=900&limit=100&interval_type=discrete" > tmp.csv

curl --request PUT --data-binary @tmp.csv --header "X-ApiKey: #key#" --verbose https://api.xively.com/v2/feeds/#newFeed#/datastreams/#newChannel#.csv

Upvotes: 2

Views: 185

Answers (1)

calumb
calumb

Reputation: 1061

There is no supported way to do feed transfer. However, your method looks good to me.

However, you may want to add in some slight delays to avoid going over your rate limit and spamming Xively too hard.

Upvotes: 1

Related Questions