Single object data retrieval

Retrieve the data for a single row from a data set.

GET https://ip-or-hostname/io/api/1/dataset/:id/:row
curl \
	-G \
	-d 'key=:apiKey' \
	https://ip-or-hostname/io/api/1/dataset/:id/:row

Get the data for a specified data set where:

  • :apiKey is the API key to use for access (see below)
  • :id is the data set id (a UUID), per the /datasets API. The data set ID can also be found in the Data set inspector of the Data tab for the data set.
  • :row is the row id (an integer) for the object to get.

Query parameters

  • clientId string
    A unique id for the client accessing the table on your system. While this is optional it is a recommended parameter as it is useful for tracking requests in CloudTables' analytics.
  • clientName string
    A label that can help identify a user - e.g. a name or e-mail address. Typically the clientId will be an integer or UUID which mean you'd need to look up the user to understand who made what changes. Note that while the clientId should be unique per client and not change - the clientName can change and will be updated to reflect the latest value given (e.g. if a user modifies their name in your own system).
  • conditions array/object
    Conditions to apply to the accessed data. Only data meeting the requirements will be returned. Please see the conditional data access documentation for full details.
  • key string Required Header
    The API key which will allow access (and thus assign the roles that can be used for access). Note that this option can be also be provided as an HTTP header (also with the name key).
  • role string
    The name of the role that should be used for access (if assigned to the API key - if the role is not available for the API key no access will be granted). If not provided then all roles available to the API key will be used.
  • roles string[]
    Similar to role but allows multiple roles to be specified.

Body parameters

  • N/A

Result

The returned JSON will be an object which contains a single data object. This object will contain the data for the row requested, where the exact structure of which will depend upon how your data set is configured and any any data sets which are linked to it. The properties in the row object are named based upon their data point ids. The prefix for the id can help identify what type it is:

  • dp- - regular data point
  • c- - computed values
  • l- - link (which will be an array of objects, in a similar structure, based upon the link).

The row object will also have the following information:

  • id - The identifier for that row
  • dv - The data version of the row. Each edit will increment this value by one.

The API will return the value of all data points that the role(s) have access to, regardless of the visibility of the data points in the table CloudTables creates.

To understand the structure of the JSON representation for each row, please use the /api/1/dataset/:id/schema endpoint.

{
    "data": {
        "id": number,
        "dv": number,
        // ... data values
    }
}

Example

The following shows the return from an example data set for flight information which contains dp-11 the flight number, l-5 a link to an airports data set for the departure airport and l-6 for the link to the arrivals airport. Inside these two lines dp-8 is the airport name.

{
	"data": {
		"id": 13,
		"dv": 1,
		"dp-11": "AA123",
		"l-5": [{
			"id": 2,
			"dp-8": "Edinburgh"
		}],
		"l-6": [{
			"id": 3,
			"dp-8": "Bristol"
		}]
	},
	"success": true
}