Skip to content
developers
Open TestCollab

Get test datasets linked to a test cae

GET/testdatasets/getLatest

Get test datasets linked to a test cae

Use resource IDs from your own project. Keep the API token in your server or CI environment.

example.ts
import { createConfiguration, TestDatasetsApi } from '@testcollab/sdk';
const config = createConfiguration(process.env.TESTCOLLAB_TOKEN!);
const api = new TestDatasetsApi(config);
const result = await api.getTestCaseDatasets({
"project": 123,
"testcase": 123
});
console.log(result);
Name Location Type Required Description
project query number Yes Project ID
testcase query number Yes —

200 — test datasets

Field Type Required Description
[].id number Yes —
[].name string Yes —
[].description string No —
[].parameters Array of Test Dataset Parameter Yes —
[].datarows string Yes JSON stringified
[].created_at string No —
[].updated_at string No —
[].created_by User Minified No —
[].created_by.id number Yes —
[].created_by.username string No —
[].created_by.name string Yes —
[].created_by.avatar Upload No —
[].created_by.avatar.id number Yes —
[].created_by.avatar.name string Yes —
[].created_by.avatar.hash string Yes —
[].created_by.avatar.ext string Yes —
[].created_by.avatar.mime string Yes —
[].created_by.avatar.size string Yes —
[].created_by.avatar.url string Yes —
[].created_by.avatar.created_by number No —
[].created_by.avatar.created_at string Yes —
[].created_by.avatar.updated_at string Yes —
[].created_by.is_guest number No —
[].archived number No —
[].is_bdd_managed boolean No True when a BDD sync (tc sync) made the dataset from the Examples: tables of a Scenario Outline in a .feature file in Git. The repository owns it, so it cannot be changed or deleted by hand (PUT and DELETE answer 422); only tc sync changes it. Each of its data rows also holds bdd_example_index, the Examples row as Cucumber numbers it in a report (., for example “2.1”), and bdd_example_name, the name of its Examples table. They are not parameters.
Illustrative response
[]
Status Meaning
401 Unauthorized
403 Forbidden
404 Not found
500 Internal server error