Skip to content
Get started

Get the processing status of a dataset

datasets.get_status(strdataset_id) -> DatasetGetStatusResponse
GET/api/v1/datasets/{dataset_id}/status

Get the processing status of a dataset

ParametersExpand Collapse
dataset_id: str
ReturnsExpand Collapse
class DatasetGetStatusResponse:
dataset_id: str

Dataset ID

error: Optional[Error]

Error details if the dataset failed. Null otherwise.

message: str

Error message

progress: Optional[Progress]

Processing progress. Null when no run is active.

percent: Optional[int]

Progress percentage (0-100)

processed_rows: Optional[int]

Number of rows processed so far

total_rows: Optional[int]

Total rows to process (samples_to_process or row_count)

row_count: Optional[int]

Number of rows in the dataset

status: Literal["pending", "running", "succeeded", "failed"]

Current processing status

One of the following:
"pending"
"running"
"succeeded"
"failed"

Get the processing status of a dataset

import os
from adaption import Adaption

client = Adaption(
    api_key=os.environ.get("ADAPTION_API_KEY"),  # This is the default and can be omitted
)
response = client.datasets.get_status(
    "dataset_id",
)
print(response.dataset_id)
{
  "dataset_id": "dataset_id",
  "error": {
    "message": "message"
  },
  "progress": {
    "percent": 0,
    "processed_rows": 0,
    "total_rows": 0
  },
  "row_count": 0,
  "status": "pending"
}
Returns Examples
{
  "dataset_id": "dataset_id",
  "error": {
    "message": "message"
  },
  "progress": {
    "percent": 0,
    "processed_rows": 0,
    "total_rows": 0
  },
  "row_count": 0,
  "status": "pending"
}