Get Multiple Tasks
Authentication
Authentication
Every request sent to Scale’s API requires authentication. In short, your API Key is the Bearer token. See the Authentication section for more details.
Pagination
Pagination
The API returns a maximum of 100 tasks per request (or less if you specify a limit
).
If your request returns more tasks than your specified limit
, API response will also contain a next_token
until you reach to the last page.
You can set the next_token
in your next request to continue downloading tasks from the next page.
Required query parameters
You are expected to provide one of the following to start downloading tasks:
- Project (
project_id
orproject_name
) - Batch (
batch_id
orbatch_name
)
Example Code
Download All Completed Tasks From a Batch as JSONL
Download All Completed Tasks From a Batch as JSONL
Authorizations
Your API Key is the Bearer token. See the Authentication section to learn how to access your key.
Query Parameters
Scale's unique identifier for the project.
"project_abc123"
The name of the project.
"My Scale Project"
Scale's unique identifier for the batch.
"batch_abc123"
The name of the batch.
"My Scale Batch"
The current status of the task, indicating whether it is pending, completed, error, or canceled.
pending
, completed
, canceled
, error
Tasks with a completed_at
after the given date will be returned. A timestamp formatted as an ISO 8601 date-time string.
Tasks with a completed_at
before the given date will be returned. A timestamp formatted as an ISO 8601 date-time string.
Limit the number of entities returned.
1 <= x <= 100
A token used to retrieve the next page of results if there are more. You can find the next_token
in your last request.
List of properties to include in the task response.
Response
List of completed tasks.
The response is of type object
.