You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/api.md
+51-1Lines changed: 51 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -34,6 +34,16 @@ Here major and breaking changes to the API are listed by version.
34
34
35
35
### ODK Central v2023.1
36
36
37
+
**Added**:
38
+
39
+
- New endpoint [GET /projects/:id/datasets/:name](#reference/datasets/datasets/dataset-metadata) to get the metadata of a Dataset
40
+
41
+
**Changed**:
42
+
43
+
-[GET /projects/:id/datasets](#reference/datasets/datasets/datasets) now supports `X-Extended-Metadata` header to retrieve number of Entities in the Dataset and timestamp of the last Entity
44
+
-`$select` in OData now supports selecting complex type(groups)
45
+
-[Creating a form](#reference/forms/forms/creating-a-new-form) can now return workflow warnings
46
+
37
47
**Removed**:
38
48
39
49
- Scheduled backups to Google Drive are no longer supported. As a result, backups are no longer configurable. It is no longer possible to get or terminate a backups configuration or to use a backups configuration to GET a Direct Backup. For more information about these changes, please see [this topic](https://forum.getodk.org/t/backups-to-google-drive-from-central-will-stop-working-after-jan-31st/38895) in the ODK Forum.
@@ -1193,6 +1203,11 @@ By default, any XLSForm conversion Warnings will fail this request and return th
1193
1203
1194
1204
The API will currently check the XML's structure in order to extract the information we need about it, but ODK Central does _not_ run comprehensive validation on the full contents of the XML to ensure compliance with the ODK specification. Future versions will likely do this, but in the meantime you will have to use a tool like [ODK Validate](https://getodk.org/use/validate/) to be sure your Forms are correct.
1195
1205
1206
+
You will get following workflow warnings while creating a new form or uploading a new version of an existing form:
1207
+
1208
+
- Structural Change: Returned when the uploaded definition of the form removes, renames or moves a field to a different group/repeat. [Learn more](https://docs.getodk.org/central-forms/#central-forms-updates)
1209
+
- Deleted Form: Returned when there is a form with the same ID in the Trash. [Learn more](https://docs.getodk.org/central-forms/#deleting-a-form)
1210
+
1196
1211
### Creating Datasets with Forms
1197
1212
1198
1213
Starting from Version 2022.3, a Form can also create a Dataset by defining a Dataset schema in the Form definition (XForms XML or XLSForm). When a Form with a Dataset schema is uploaded, a Dataset and its Properties are created and a `dataset.create` event is logged in the Audit logs. The state of the Dataset is dependent on the state of the Form; you will need to publish the Form to publish the Dataset. Datasets in the Draft state are not returned in [Dataset APIs](#reference/datasets), however the [Related Datasets](#reference/forms/related-datasets/draft-form-dataset-diff) API for the Form can be called to get the Dataset and its Properties.
@@ -2957,6 +2972,25 @@ The Dataset listing endpoint returns all published Datasets in a Project. If a D
Returns the metadata of a Dataset including properties and forms that create and consume the Dataset.
2986
+
2987
+
+ Parameters
2988
+
+ projectId: `16` (number, required) - The numeric ID of the Project
2989
+
+ name: `people` (string, required) - Name of the Dataset
2990
+
2991
+
+ Response 200 (application/json)
2992
+
+ Attributes (DatasetMetadata)
2993
+
2960
2994
+ Response 403 (application/json)
2961
2995
+ Attributes (Error 403)
2962
2996
@@ -3541,7 +3575,6 @@ The _nonstandard_ `$wkt` querystring parameter may be set to `true` to request t
3541
3575
As of ODK Central v2022.3, the [`$select` query parameter](http://docs.oasis-open.org/odata/odata/v4.01/odata-v4.01-part1-protocol.html#_Toc31358942) is supported with some limitations:
3542
3576
+`$select` and `$expand` can't be used together.
3543
3577
+ Child properties of repeats can't be requested using `$select`
3544
-
+ Requesting complex types (groups) to get all fields of that type is only supported for `__system`
3545
3578
3546
3579
As the vast majority of clients only support the JSON OData format, that is the only format ODK Central offers.
3547
3580
@@ -4245,6 +4278,18 @@ These are in alphabetic order, with the exception that the `Extended` versions o
4245
4278
+ createdAt: `2018-01-19T23:58:03.395Z` (string, required) - ISO date format.
4246
4279
+ projectId: `1` (number, required) - The numerical ID of the Project that the Dataset belongs to.
4247
4280
4281
+
## Extended Dataset (Dataset)
4282
+
+ lastEntity: `2018-04-18T03:04:51.695Z` (string, optional) - ISO date format. The timestamp of the most recent entity, if any.
4283
+
+ entities: `10` (number, required) - The number of Entities in the Dataset.
4284
+
4285
+
## DatasetMetadata (Dataset)
4286
+
+ linkedForms: (array[Form KeyValue]) - Forms that consume data from the Dataset
4287
+
+ properties: (array[Property Detailed]) - All properties of the Dataset
4288
+
4289
+
## Form KeyValue (object)
4290
+
+ xmlFormId: `simple` (string, required) - The `id` of this form as given in its XForms XML definition
4291
+
+ name: `Simple` (string, required) - The friendly name of this form. It is given by the `<title>` in the XForms XML definition. Returns `xmlFormId` if there is no title in the form definition.
4292
+
4248
4293
## Patch Attachment (object)
4249
4294
+ dataset: `true` (boolean, required) - true for linking Dataset and false for unlinking Dataset.
4250
4295
@@ -4265,3 +4310,8 @@ These are in alphabetic order, with the exception that the `Extended` versions o
4265
4310
+ name: `first_name` (string, required) - The name of the Property.
4266
4311
+ inForm: `true` (boolean, required) - Whether or not this Property is affected by the form.
4267
4312
+ isNew: `true` (boolean, required) - Whether or not this Property is new (will be created by publishing the Draft Form).
4313
+
4314
+
## Property Detailed (object)
4315
+
+ name: `first_name` (string, required) - The name of the Property.
4316
+
+ publishedAt: `2018-01-21T00:04:11.153Z` (string, required) - Publishing timestamp of the form that defined this property for the first time.
4317
+
+ forms: (array[Form KeyValue]) - List of forms that create the property
0 commit comments