# testcollab-sdk

> OpenAPI client for testcollab-sdk

Latest version **3.5.0** (published 2025-11-24) · 0 weekly downloads

## Install

```sh
npm install testcollab-sdk
pnpm add testcollab-sdk
yarn add testcollab-sdk
bun add testcollab-sdk
```

## Health

**Score 60/100 (C)** — status: stable.

Positive: has types; esm support; no vulnerabilities; high maintenance score.

Warnings: low downloads; large bundle.

## Facts

| | |
|---|---|
| Version | 3.5.0 |
| Published | 2025-11-24 |
| First published | 2019-09-13 |
| Weekly downloads | 0 |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Dependencies | 0 |
| Unpacked size | 10.4 MB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 3 |
| Author | Test Collab Software LLC. |
| Maintainers | gigapro |

## Links

- npm: https://www.npmjs.com/package/testcollab-sdk
- Repository: https://github.com/TCSoftInc/testcollab-sdk
- Homepage: https://github.com/TCSoftInc/testcollab-sdk#readme
- Issues: https://github.com/TCSoftInc/testcollab-sdk/issues
- npm.io page: https://npm.io/package/testcollab-sdk

## Recent versions

- 3.5.0 (latest) — 2025-11-24
- 3.4.0 — 2025-11-24
- 3.3.0 — 2025-11-23
- 3.2.0 — 2025-11-22
- 3.1.1-SNAPSHOT.202511221358 — 2025-11-22
- 2.1.1-SNAPSHOT.202509242236 — 2025-09-24
- 2.1.1-SNAPSHOT.202509242229 — 2025-09-24
- 2.1.1-SNAPSHOT.202508220856 — 2025-08-22
- 2.1.1-SNAPSHOT.202508110839 — 2025-08-11
- 2.1.1-SNAPSHOT.202507190520 — 2025-07-19
- 2.1.1-SNAPSHOT.202507030530 — 2025-07-03
- 2.1.1-SNAPSHOT.202412041305 — 2024-12-04
- 2.1.1-SNAPSHOT.202410090543 — 2024-10-09
- 2.1.1-SNAPSHOT.202408290727 — 2024-08-29
- 2.1.1-SNAPSHOT.202407230657 — 2024-07-23
- … 122 more at https://npm.io/package/testcollab-sdk/versions

## README

# testcollab-sdk

This SDK allows [Test Collab](https://testcollab.com/) clients to call API easily, build custom workflows, reports, and integrations with CI/CD pipelines and more.

## Installation

To install the library, use npm:

```sh
npm install testcollab-sdk
```

## Usage Example

You'll need to authenticate the client before you can use any methods.

There are 2 possible authentication methods:

a) API key: To generate API key: login to your TestCollab account and go to 'My Profile Settings' and switch to API Token tab. Click on "Generate new API token".

b) Access token: This requires logging into API programmatically with this SDK using login method which will provide a auth token. 

For the purpose of this documentation, we'll stick to the API key based authorization.


### Authentication

API Key method:

```javascript
import { createConfiguration, TestPlansApi, TestPlanTestCasesApi, TestPlansAssignmentApi } from 'testcollab-sdk';

const apiKey = '123456-abc';
const config = createConfiguration(apiKey);
const testPlansApi = new TestPlansApi(config);
```

If you need to override URL (for self-hosted setup or EU server residency), you can pass basePath as the second argument:

```javascript
const config = createConfiguration(apiKey, {
    basePath: 'https://api-eu.testcollab.io'
});
```


### Test Plan Add

```javascript
        const response = await testPlansApi.addTestPlan({
            testPlanPayload: {
                project: 1234,
                title: 'From SDK',
                description: 'This is a test plan is created using the Node.js SDK',
                status: 1,
                priority: 1,
                testPlanFolder: null,
                customFields: []

            }
        });

        // get the test plan id
        const testPlanId = response.id;
        console.log('Test Plan ID: ' + testPlanId)
```

### Add New Test Cases to Test Plan

```javascript
        const testPlanCases = new TestPlanTestCasesApi(config);

        const res2 = await testPlanCases.bulkAddTestPlanTestCases({
            testPlanTestCaseBulkAddPayload:
            {
                testplan: testPlanId,
                "testCaseCollection": {
                    testCases: [1, 2, 3],
                    selector: []
                }
            }
        });
        //console.log(res2)
```

### Assign test cases to a tester in test plan

```javascript
        const testPlanAssignment = new TestPlansAssignmentApi(config);
        const res3 = await testPlanAssignment.assignTestPlan({
            project: 1234,
            testplan: testPlanId,
            testPlanAssignmentPayload: {
                "executor": "me",
                "assignmentCriteria": "testCase",
                "assignmentMethod": "automatic",
                "assignment": {
                    "user": [2],
                    "testCases": {
                        "testCases": [],
                        "selector": []
                    },
                    "configuration": null
                },
                "project": 1234,
                "testplan": testPlanId
            }
        })
        console.log(res3)
```

## API Documentation

Detailed API documentation is available at [Test Collab OpenAPI specs](https://developers.testcollab.com/).

## Author

Test Collab Software LLC

## Contact Information

For support, please contact us at [support@testcollab.com](mailto:support@testcollab.com).

---
_Source: https://npm.io/package/testcollab-sdk · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
