Please Note This forum exists for community support for the Mango product family and the Radix IoT Platform. Although Radix IoT employees participate in this forum from time to time, there is no guarantee of a response to anything posted here, nor can Radix IoT, LLC guarantee the accuracy of any information expressed or conveyed. Specific project questions from customers with active support contracts are asked to send requests to support@radixiot.com.
/data-sources API - Limits results to 100 items
-
When running the /data-sources GET via the API the total reports the actual number of data sources we have, but the items array is limited to 100 data sources.
Is there a "limit" parameter or paging option that I'm missing?
How can I get all of the data sources returned to me via the API?
Thanks,
Chad -
Yes, limit is set to 100 by default. Same goes for datapoints. Try limit=-1 as a parameter. I believe will tell it to pull all.
Use swagger to test your api calls.
Fox
-
Thanks once again, Fox, for the help!
It took us a little bit to figure out the syntax, but got it working: /rest/v2/data-sources?limit(1000)
We tried to use -1, but that created a 500 error.
Could not write JSON: PreparedStatementCallback; bad SQL grammar [select `ds`.`id`, `ds`.`xid`, `ds`.`name`, `ds`.`dataSourceType`, `ds`.`data`, `ds`.`editPermission` from dataSources AS ds limit ?]Not a big deal for our purposes though.
-
Bizarre, help docs used to mention using -1 as no limit. Glad you have got it sorted!
Fox
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login