Skip to content

Get a dataset row

GET
/datasets/{datasetId}/rows/{rowId}
curl --request GET \
--url 'https://api.modeldesk.io/datasets/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0/rows/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0?draft=false&baseState=false' \
--header 'Authorization: Bearer <token>'

One row of the dataset, at the state at, ref or draft names, or at the default branch. A row your draft removed is 404 there, whatever the branch still holds. JSON unless the request accepts text/turtle, application/ld+json, application/n-triples or application/rdf+xml by name; then the entry as RDF, under the IRI the same state’s export gives it, at a release or a branch head only (a draft read is a 400).

datasetId
required
string format: uuid
rowId
required
string format: uuid
at
string
ref
string
draft
boolean

Read at your own draft rather than at a release or a branch.

baseState
boolean

For a dataset made from a base, give the row’s baseState.

OK

A row as a state holds it: what it carries, and how it stands against the dataset’s data schema. The verdict is the state’s rather than the row’s — a repin re-judges a branch’s rows, and a release keeps the verdict it froze.

object
rowId
required

The row’s stable identity, minted once and surviving every edit.

string format: uuid
values

Value-property source element id to the terms the row holds for it.

object
key
additional properties
Array
refs

Reference-property source element id to the rows it points at.

object
key
additional properties
Array<object>

A pointer to a row, in this dataset or in one this dataset declares a dependency on.

object
datasetId
required
string format: uuid
rowId
required
string format: uuid
platformRefs

Reference-property source element id to the models, model elements and datasets it points at, for a property whose target type is represented by things the platform holds. Such a property holds these and never row references. Absent when the row holds none.

object
key
additional properties
Array<object>

A pointer to a thing the platform holds: a model, an element of a model, or a dataset. A model or element is read at the state the dataset pins the model at; a dataset as it stands.

object
kind
required
string
Allowed values: MODEL ELEMENT DATASET
resourceId
required

The model, for a model or an element; the dataset, for a dataset.

string format: uuid
elementId

The element of the model; present exactly for an ELEMENT.

string format: uuid
parts

Containment-property source element id to the parts the row holds inside itself, for a property whose target type has no identity of its own (a contact point, a period). Such a property holds parts and never row references. Absent when the row holds none. A write that leaves parts out keeps the parts the row holds, as a client that knows nothing of parts writes every row; one that sends it, empty included, leaves the row holding what it sent.

object
key
additional properties
Array<object>

One part a row holds inside itself: an occurrence of a containment property whose target type has no identity of its own. Its maps are keyed as a row’s are, and it holds parts of its own to whatever depth the model nests them.

object
partId

The part’s identity inside its row, so a change to one part is told from a change to another. Send it back unchanged on every write of the row; a part written without one gets a new one, and two parts of one row under one id are a 400.

string format: uuid
values

Value-property source element id to the terms the part holds for it.

object
key
additional properties
Array
refs

Reference-property source element id to the rows it points at.

object
key
additional properties
Array<object>

A pointer to a row, in this dataset or in one this dataset declares a dependency on.

object
datasetId
required
string format: uuid
rowId
required
string format: uuid
platformRefs

Reference-property source element id to the models, model elements and datasets the part points at, for a property whose target type is represented by things the platform holds. A part is written whole, so a part sent without them holds none. Absent when the part holds none.

object
key
additional properties
Array<object>

A pointer to a thing the platform holds: a model, an element of a model, or a dataset. A model or element is read at the state the dataset pins the model at; a dataset as it stands.

object
kind
required
string
Allowed values: MODEL ELEMENT DATASET
resourceId
required

The model, for a model or an element; the dataset, for a dataset.

string format: uuid
elementId

The element of the model; present exactly for an ELEMENT.

string format: uuid
parts

Containment-property source element id to the parts this part holds.

object
key
additional properties
Array<object> recursive
basedOn

The base concept the row was made from; absent on a row the dataset added itself.

object
elementId
required
string format: uuid
iri
string
reasons

Why the row differs from its base, keyed by a column’s source element id or row for the row as a whole. Never a column: not judged as data.

object
key
additional properties
string
<= 1000 characters
selectable

Whether a value may point at the row, overriding the dataset’s levels; absent to follow them.

boolean
validation

Absent when nothing has judged the row, which is not the same as judged clean.

object
valid

Whether no violation is an error. A row whose violations are all warnings is valid and still carries them.

boolean
violations

Absent when nothing is wrong with the row.

Array<object>

One way in which a row does not conform.

object
code
required
string
Allowed values: TOO_FEW_VALUES TOO_MANY_VALUES VALUE_NOT_IN_TYPE PROPERTY_NOT_DECLARED REFERENCE_TARGET_MISSING REFERENCE_DATASET_NOT_DECLARED REFERENCE_MODEL_NOT_DECLARED REFERENCE_TARGET_WRONG_TYPE REFERENCE_TARGET_NOT_SELECTABLE OTHER
propertyId

The schema property’s source element id — the same key the row’s own maps use, so a caller marks the offending cell without a lookup. Absent for a violation about the row itself. For a violation inside a part, the row’s column that holds the part, with path leading from there to the field.

string format: uuid
valueIndex

Which value of the property; absent when the violation is the property’s as a whole. For a violation inside a part, which value of the field path ends at.

integer
path

For a violation inside a part, the way from propertyId down to the field, outermost part first: contactpunt[2].email is one step, the part at index 1 and its property email. Absent for a violation of one of the row’s own fields.

Array<object>

One step of a violation’s way into a part: the part at a position among the parts of the property reached so far, and the property of that part the way goes on to.

object
index
required

The part’s position among that property’s parts, from 0.

integer
partId
required
string format: uuid
propertyId

The part’s property the way goes on to; absent where the violation is about the part.

string format: uuid
message
required
string
severity

How much the violation weighs; the row is kept and flagged either way. A value outside a code list is a WARNING unless the list is marked strict; everything else is an ERROR.

string
Allowed values: WARNING ERROR
inPlatformRefs

For a reference property, which of its lists the violation is about: true for its references to models, model elements and datasets (platformRefs), which valueIndex then counts in; false for its references to rows (refs) where that needs saying beside the other. Absent for its references to rows, as every violation from before the other list existed reads. Inside a part as at the row: beside path, it says which list of the field path ends at.

boolean
baseState

Present only when the read asked for it, on a dataset made from a base.

object
state
required
string
Allowed values: AS_IN_BASE CHANGED_HERE ADDED_HERE
changedColumns
Array<string>
baseValues
object
key
additional properties
Array
baseRefs
object
key
additional properties
Array<object>

A pointer to a row, in this dataset or in one this dataset declares a dependency on.

object
datasetId
required
string format: uuid
rowId
required
string format: uuid

Example

{
"platformRefs": {
"additionalProperty": [
{
"kind": "MODEL"
}
]
},
"parts": {
"additionalProperty": [
{
"platformRefs": {
"additionalProperty": [
{
"kind": "MODEL"
}
]
}
}
]
},
"validation": {
"violations": [
{
"code": "TOO_FEW_VALUES",
"severity": "WARNING"
}
]
},
"baseState": {
"state": "AS_IN_BASE"
}
}

Dataset, release, branch or row not found

Media typeapplication/problem+json

An RFC 9457 problem document, always sent as application/problem+json.

object
type

Present only on a typed refusal, whose own schema requires it and fixes its value. An untyped problem omits it, which RFC 9457 defines as about:blank: the status and title are all there is to branch on.

string format: uri
title
required
string
status
required
integer
detail
required
string
instance

The path of the request that was refused. Absent when the request was refused before it reached the application’s handlers: a 401 for a missing or unusable access token, and a 403 for a service account whose scopes do not reach the route.

string
violations

Present on a 400 raised by request-body validation, and on a 422 that refuses named fields (a malformed slug or namespace prefix). Each entry names the rejected property, so a client can attach the message to the field that caused it rather than showing one error for the whole form.

Array<object>
object
property
required
string
message
required
string

Example generated

{
"type": "https://example.com",
"title": "example",
"status": 1,
"detail": "example",
"instance": "example",
"violations": [
{
"property": "example",
"message": "example"
}
]
}

Error

Media typeapplication/problem+json

An RFC 9457 problem document, always sent as application/problem+json.

object
type

Present only on a typed refusal, whose own schema requires it and fixes its value. An untyped problem omits it, which RFC 9457 defines as about:blank: the status and title are all there is to branch on.

string format: uri
title
required
string
status
required
integer
detail
required
string
instance

The path of the request that was refused. Absent when the request was refused before it reached the application’s handlers: a 401 for a missing or unusable access token, and a 403 for a service account whose scopes do not reach the route.

string
violations

Present on a 400 raised by request-body validation, and on a 422 that refuses named fields (a malformed slug or namespace prefix). Each entry names the rejected property, so a client can attach the message to the field that caused it rather than showing one error for the whole form.

Array<object>
object
property
required
string
message
required
string

Example generated

{
"type": "https://example.com",
"title": "example",
"status": 1,
"detail": "example",
"instance": "example",
"violations": [
{
"property": "example",
"message": "example"
}
]
}