Skip to main content

Version API

Retrieve, update, and restore row versions.

All paths are relative to https://www.labii.dev and require bearer authentication unless noted otherwise. Replace each placeholder with an identifier from your Labii environment.

Endpoints​

OperationMethodPath
Get version listGET/tables/version/list/organization/{{organization_sid}}/list/?row__sid={{row_sid}}
Get version detailGET/tables/version/detail/{{version_sid}}/
Update versionPATCH/tables/version/detail/{{version_sid}}/
Restore versionPATCH/tables/row/detail/{{row_sid}}/?restore={{version_sid}}

The final URL segment on list endpoints selects the response serializer. The examples use list; supported endpoints can also expose representations such as name or detail.

Serializer fields​

List response item: sid, name, hash, previousHash, version, activity_message, commit, is_valid, row, updated_by, date_created, change_permission, verbose_name

Detail response: sid, hash, previousHash, version, data, activity, activity_message, commit, path, updated_by, date_updated, date_created, change_permission, help_text, verbose_name

Write serializer: commit

The write serializer is the backend validation schema. The view may populate identity, parent, and audit fields from the URL or authenticated user, and may disallow fields for a particular operation.

List response JSON​

The values below are placeholders that show the exact keys returned by the current list serializer. They do not indicate that every field is nullable.

{
"page_size": 10,
"page_number": 1,
"page_count": 1,
"count": 1,
"next": null,
"previous": null,
"add_permission": false,
"results": [
{
"sid": null,
"name": null,
"hash": null,
"previousHash": null,
"version": null,
"activity_message": null,
"commit": null,
"is_valid": null,
"row": null,
"updated_by": null,
"date_created": null,
"change_permission": null,
"verbose_name": null
}
]
}

Detail response JSON​

The values below are placeholders that show the exact keys returned by the current detail serializer. Nested relationship and metadata values depend on the resource.

{
"sid": null,
"hash": null,
"previousHash": null,
"version": null,
"data": null,
"activity": null,
"activity_message": null,
"commit": null,
"path": null,
"updated_by": null,
"date_updated": null,
"date_created": null,
"change_permission": null,
"help_text": null,
"verbose_name": null
}

Example request​

curl --request GET \
--url 'https://www.labii.dev/tables/version/list/organization/{{organization_sid}}/list/?row__sid={{row_sid}}' \
--header 'Authorization: Bearer <api_key>'