Lists maintenance tasks of the current table by task type, returned from newest to oldest by creation time, with marker-based pagination.
Permission notes
|
API |
Action |
Description |
|
ListLanceTasks |
oss:GetTableMaintenanceJobStatus |
Lists maintenance tasks. |
Request syntax
GET /lance/oss/v1/table/{id}/tasks?task_type=lance_compact&max_results=100 HTTP/1.1
Host: {tableBucketHost}
Date: GMT Date
Authorization: SignatureValue
# Next page:
# GET /lance/oss/v1/table/{id}/tasks?task_type=lance_compact&max_results=100&marker={next_marker} HTTP/1.1
Request parameters
For the common conventions of this interface (access address, table identifier, request and response headers, permissions, async submission and quota, task status, error codes), see Lance table maintenance.
|
Parameter |
Location |
Data type |
Required |
Description |
|
id |
path |
string |
Yes |
Current table identifier. |
|
task_type |
query |
string |
Yes |
Must be one of the five complete types listed below. |
|
max_results |
query |
int32 |
No |
Default value 100. Maximum number of tasks returned per page, range [1, 1000]. |
|
marker |
query |
string |
No |
Not sent by default. Opaque pagination token; use the next_marker from the previous response verbatim, and encode it correctly as a Query parameter. |
|
delimiter |
query |
string |
No |
Default value $. Table identifier delimiter. |
Allowed task_type values and constraints
lance_compact
lance_scalar_index
lance_vector_index
lance_optimize_indices
lance_cleanup
Path action names such as compact and create_scalar_index are not valid task_type values. A single request lists only one type. The mode and status Query parameters are not supported; as soon as either parameter appears, 400 / InvalidInput / 13 is returned, including for empty values. Status filtering should be performed by the client on the returned results.
Response
HTTP/1.1 200 OK
Content-Type: application/json
x-oss-table-id: {table_id}
{
"tasks": [
{
"task_id": "123xxxxxxxxxxxxxxx",
"task_type": "lance_compact",
"params": {
"target_rows_per_fragment": 1048576,
"materialize_deletions": true,
"materialize_deletions_threshold": 0.1,
"max_rows_per_group": 1024,
"max_bytes_per_file": 0,
"compaction_mode": "reencode"
},
"status": "submitted",
"created_at": "2026-09-18T04:00:00.000000+00:00",
"started_at": "",
"completed_at": "",
"result": {},
"error": null
}
],
"next_marker": "",
"is_truncated": false
}
|
Response parameter |
Type |
Description |
|
tasks |
object[] |
Task list for the current page. Elements use the task object directly, without an additional task_info wrapper. See the table below for element fields. |
|
next_marker |
string |
Pagination token returned when there are more valid tasks; an empty string on the last page. |
|
is_truncated |
boolean |
true indicates there is another page of valid tasks. |
The fields contained in tasks are as follows:
|
Field |
Type |
Description |
|
task_id |
string |
Task ID. |
|
task_type |
string |
One of the five lance_ prefixed types. |
|
params |
object |
The actually saved task parameters, including server-filled default values. |
|
status |
string |
Current task status. |
|
created_at |
string |
Task creation time. |
|
started_at |
string |
Task start time; an empty string when not started. |
|
completed_at |
string |
Time when the task entered a terminal state; an empty string for non-terminal states. |
|
result |
object |
Task execution result, initially {}; may contain nested objects and arrays. The result structure varies by task type. |
|
error |
object or null |
Contains an error object when the known status is failed; null for other known statuses. |
When there are no tasks, {"tasks":[],"next_marker":"","is_truncated":false} is returned. The first page should omit marker. An explicitly empty marker, an illegal token, or using a token across tables or across task_type values all return 400 / InvalidContinuationToken /13. Do not use an internal index path as marker.
The server skips orphan indexes missing task records, malformed indexes, and duplicate indexes with old timestamps, and only sets is_truncated=true after confirming that a next valid task exists. A corrupted task body may cause an internal error. Pagination is not a fixed point-in-time snapshot; under concurrent submissions or deletions, the client must not assume the task set is completely unchanged.
Error codes
This interface uses the Lance unified JSON error format. For common error codes and the error response structure, see Lance table maintenance in the common conventions.