# Api (*api*) ## Overview Testkube API operations ### Available Operations * [abortExecution](#abortexecution) - Aborts execution * [abortTestExecutions](#aborttestexecutions) - Abort all executions of a test * [abortTestSuiteExecution](#aborttestsuiteexecution) - Aborts testsuite execution * [abortTestSuiteExecutionByID](#aborttestsuiteexecutionbyid) - Aborts testsuite execution * [abortTestSuiteExecutions](#aborttestsuiteexecutions) - Abort all executions of a test suite * [bulkUpdateTestTriggers](#bulkupdatetesttriggers) - Bulk update test triggers * [createExecutorJson](#createexecutorjson) - Create new executor * [createExecutorString](#createexecutorstring) - Create new executor * [createTestSourceJson](#createtestsourcejson) - Create new test source * [createTestSourceString](#createtestsourcestring) - Create new test source * [createTestSuiteJson](#createtestsuitejson) - Create new test suite * [createTestSuiteString](#createtestsuitestring) - Create new test suite * [createTestTriggerJson](#createtesttriggerjson) - Create new test trigger * [createTestTriggerString](#createtesttriggerstring) - Create new test trigger * [createTestJson](#createtestjson) - Create new test * [createTestString](#createteststring) - Create new test * [createWebhookJson](#createwebhookjson) - Create new webhook * [createWebhookString](#createwebhookstring) - Create new webhook * [deleteExecutor](#deleteexecutor) - Delete executor * [deleteExecutors](#deleteexecutors) - Delete executors * [deleteTest](#deletetest) - Delete test * [deleteTestSource](#deletetestsource) - Delete test source * [deleteTestSources](#deletetestsources) - Delete test sources * [deleteTestSuite](#deletetestsuite) - Delete test suite * [deleteTestSuites](#deletetestsuites) - Delete test suites * [deleteTestTrigger](#deletetesttrigger) - Delete test trigger * [deleteTestTriggers](#deletetesttriggers) - Delete test triggers * [deleteTests](#deletetests) - Delete tests * [deleteWebhook](#deletewebhook) - Delete webhook * [deleteWebhooks](#deletewebhooks) - Delete webhooks * [downloadArchive](#downloadarchive) - Download artifact archive * [downloadFile](#downloadfile) - Download artifact * [executeTest](#executetest) - Starts new test execution * [executeTestSuite](#executetestsuite) - Starts new test suite execution * [executeTestSuites](#executetestsuites) - Starts new test suite executions * [executeTests](#executetests) - Starts new test executions * [getConfig](#getconfig) - Get config * [getDebugInfo](#getdebuginfo) - Get debug information * [getExecutionArtifacts](#getexecutionartifacts) - Get execution's artifacts by ID * [getExecutionByID](#getexecutionbyid) - Get test execution by ID * [getExecutionLogs](#getexecutionlogs) - Get execution's logs by ID * [getExecutor](#getexecutor) - Get executor details * [getKeyMap](#getkeymap) - Test triggers keymap * [getTest](#gettest) - Get test * [getTestExecution](#gettestexecution) - Get test execution * [getTestMetrics](#gettestmetrics) - Get test metrics * [getTestSource](#gettestsource) - Get test source data * [getTestSuiteByID](#gettestsuitebyid) - Get test suite by ID * [getTestSuiteByIDWithExecution](#gettestsuitebyidwithexecution) - Get test suite by ID with execution * [getTestSuiteExecution](#gettestsuiteexecution) - Get test suite execution * [getTestSuiteExecutionArtifacts](#gettestsuiteexecutionartifacts) - Get test suite execution artifacts * [getTestSuiteExecutionArtifactsByTestsuite](#gettestsuiteexecutionartifactsbytestsuite) - Get test suite execution artifacts * [getTestSuiteExecutionByID](#gettestsuiteexecutionbyid) - Get test suite execution by ID * [getTestSuiteMetrics](#gettestsuitemetrics) - Get test suite metrics * [getTestTriggerByID](#gettesttriggerbyid) - Get test trigger by ID * [getTestWithExecution](#gettestwithexecution) - Get test with execution * [getWebhook](#getwebhook) - Get webhook details * [listAllTestSuiteExecutions](#listalltestsuiteexecutions) - Get all test suite executions * [listExecutions](#listexecutions) - Get all test executions * [listExecutors](#listexecutors) - List executors * [listTestExecutions](#listtestexecutions) - Get all test executions * [listTestSources](#listtestsources) - List test sources * [listTestSuiteExecutions](#listtestsuiteexecutions) - Get all test suite executions * [listTestSuiteTests](#listtestsuitetests) - List tests for test suite * [listTestSuiteWithExecutions](#listtestsuitewithexecutions) - Get all test suite with executions * [listTestSuites](#listtestsuites) - Get all test suites * [listTestTriggers](#listtesttriggers) - List test triggers * [listTestWithExecutions](#listtestwithexecutions) - List test with executions * [listTests](#listtests) - List tests * [listWebhooks](#listwebhooks) - List webhooks * [processTestSourceBatch](#processtestsourcebatch) - Process test source batch (create, update, delete) * [updateConfigKey](#updateconfigkey) - Update config * [updateExecutorJson](#updateexecutorjson) - Update executor * [updateExecutorString](#updateexecutorstring) - Update executor * [updateTestSourceJson](#updatetestsourcejson) - Update test source * [updateTestSourceString](#updatetestsourcestring) - Update test source * [updateTestSuiteJson](#updatetestsuitejson) - Update test suite * [updateTestSuiteString](#updatetestsuitestring) - Update test suite * [updateTestTriggerJson](#updatetesttriggerjson) - Update test trigger * [updateTestTriggerString](#updatetesttriggerstring) - Update test trigger * [updateTestJson](#updatetestjson) - Update test * [updateTestString](#updateteststring) - Update test * [uploads](#uploads) - Upload file * [validateRepository](#validaterepository) - Validate new repository ## abortExecution Aborts execution with given executionID ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.abortExecution({ executionID: "", id: "", }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ---------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------- | | `request` | [operations.AbortExecutionRequest](../../sdk/models/operations/abortexecutionrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.AbortExecutionResponse](../../sdk/models/operations/abortexecutionresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## abortTestExecutions Abort all test executions ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.abortTestExecutions({ id: "", }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | -------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------- | | `request` | [operations.AbortTestExecutionsRequest](../../sdk/models/operations/aborttestexecutionsrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.AbortTestExecutionsResponse](../../sdk/models/operations/aborttestexecutionsresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## abortTestSuiteExecution Aborts testsuite execution with given executionID ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.abortTestSuiteExecution({ executionID: "", id: "", }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ---------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------- | | `request` | [operations.AbortTestSuiteExecutionRequest](../../sdk/models/operations/aborttestsuiteexecutionrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.AbortTestSuiteExecutionResponse](../../sdk/models/operations/aborttestsuiteexecutionresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## abortTestSuiteExecutionByID Aborts testsuite execution with given executionID ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.abortTestSuiteExecutionByID({ executionID: "", }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------ | | `request` | [operations.AbortTestSuiteExecutionByIDRequest](../../sdk/models/operations/aborttestsuiteexecutionbyidrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.AbortTestSuiteExecutionByIDResponse](../../sdk/models/operations/aborttestsuiteexecutionbyidresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## abortTestSuiteExecutions Abort all test executions of a test suite ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.abortTestSuiteExecutions({ id: "", }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------ | | `request` | [operations.AbortTestSuiteExecutionsRequest](../../sdk/models/operations/aborttestsuiteexecutionsrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.AbortTestSuiteExecutionsResponse](../../sdk/models/operations/aborttestsuiteexecutionsresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## bulkUpdateTestTriggers Updates test triggers provided as an array in the request body ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; import { TestTriggerActions, TestTriggerConditionStatuses, TestTriggerExecutions, TestTriggerResources, } from "testkube-sdk/dist/sdk/models/shared"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.bulkUpdateTestTriggers([ { action: TestTriggerActions.Run, conditionSpec: { conditions: [ { reason: "NewReplicaSetAvailable", status: TestTriggerConditionStatuses.Unknown, ttl: 1, type: "Progressing", }, ], delay: 1, timeout: 1, }, event: "modified", execution: TestTriggerExecutions.Testsuite, labels: { "env": "prod", "app": "backend", }, name: "name", namespace: "testkube", probeSpec: { delay: 1, probes: [ { headers: { "Content-Type": "application/xml", }, host: "testkube-api-server", path: "/", port: 80, scheme: "http", }, ], timeout: 1, }, resource: TestTriggerResources.Deployment, resourceSelector: { name: "nginx", namespace: "testkube", }, testSelector: { name: "nginx", namespace: "testkube", }, }, ]); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ------------------------------------------------------------ | ------------------------------------------------------------ | ------------------------------------------------------------ | ------------------------------------------------------------ | | `request` | [shared.TestTriggerUpsertRequest[]](../../models/.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.BulkUpdateTestTriggersResponse](../../sdk/models/operations/bulkupdatetesttriggersresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## createExecutorJson Create new executor based on variables passed in request ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; import { ExecutorUpsertRequestFeatures } from "testkube-sdk/dist/sdk/models/shared"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.createExecutorJson({ args: [ "--repeats", "5", "--insecure", ], command: [ "curl", ], contentTypes: [ "", ], features: [ ExecutorUpsertRequestFeatures.JunitReport, ], imagePullSecrets: [ {}, ], labels: { "env": "prod", "app": "backend", }, meta: { docsURI: "https://docs.testkube.io/test-types/executor-k6", iconURI: "/assets/k6.jpg", tooltips: { "general": "please provide k6 test script for execution", }, }, name: "name", namespace: "testkube", types: [ "", ], }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | -------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- | | `request` | [shared.ExecutorUpsertRequest](../../sdk/models/shared/executorupsertrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.CreateExecutorJsonResponse](../../sdk/models/operations/createexecutorjsonresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## createExecutorString Create new executor based on variables passed in request ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.createExecutorString(""); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ------------------------------------------------------------ | ------------------------------------------------------------ | ------------------------------------------------------------ | ------------------------------------------------------------ | | `request` | [string](../../models/.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.CreateExecutorStringResponse](../../sdk/models/operations/createexecutorstringresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## createTestSourceJson Create new test source based on variables passed in request ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; import { AuthType, RepositoryType, TestSourceUpsertRequestType } from "testkube-sdk/dist/sdk/models/shared"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.createTestSourceJson({ labels: { "key": "", }, name: "testsource1", namespace: "testkube", repository: { branch: "main", commit: "b928cbb7186944ab9275937ec1ac3d3738ca2e1d", path: "test/perf", tokenSecret: { key: "", name: "", }, type: RepositoryType.Git, uri: "https://github.com/kubeshop/testkube", usernameSecret: { key: "", name: "", }, workingDir: "/", }, uri: "https://github.com/kubeshop/testkube", }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | | `request` | [shared.TestSourceUpsertRequest](../../sdk/models/shared/testsourceupsertrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.CreateTestSourceJsonResponse](../../sdk/models/operations/createtestsourcejsonresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## createTestSourceString Create new test source based on variables passed in request ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.createTestSourceString(""); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ------------------------------------------------------------ | ------------------------------------------------------------ | ------------------------------------------------------------ | ------------------------------------------------------------ | | `request` | [string](../../models/.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.CreateTestSourceStringResponse](../../sdk/models/operations/createtestsourcestringresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## createTestSuiteJson Create new test suite action ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; import { RunningContextType, TestSuiteExecutionStatus, VariableType } from "testkube-sdk/dist/sdk/models/shared"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.createTestSuiteJson({ after: [ { execute: [ { delay: "1s", test: "example-test", }, ], stopOnFailure: true, }, ], before: [ { execute: [ { delay: "1s", test: "example-test", }, ], stopOnFailure: true, }, ], description: "collection of tests", executionRequest: { concurrencyLevel: 10, contentRequest: { repository: { branch: "main", commit: "b928cbb7186944ab9275937ec1ac3d3738ca2e1d", path: "test/perf", workingDir: "/", }, }, executionLabels: { "users": "3", "prefix": "some-", }, httpProxy: "user:pass@my.proxy.server:8080", httpsProxy: "user:pass@my.proxy.server:8081", labels: { "users": "3", "prefix": "some-", }, name: "testing with 1000 users", namespace: "testkube", number: 1, runningContext: { type: RunningContextType.Testsuite, }, timeout: 1, variables: { "var1": { configMapRef: { key: "", name: "", }, name: "var1", secretRef: { key: "", name: "", }, type: VariableType.Basic, value: "value1", }, "secret1": { configMapRef: { key: "", name: "", }, name: "secret1", secretRef: { key: "", name: "", }, type: VariableType.Secret, value: "secretvalue1", }, }, }, labels: { "env": "prod", "app": "backend", }, name: "name", namespace: "testkube", repeats: 1, schedule: "* * * * *", status: { latestExecution: { id: "62f395e004109209b50edfc4", }, }, steps: [ { execute: [ { delay: "1s", test: "example-test", }, ], stopOnFailure: true, }, ], }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | | `request` | [shared.TestSuiteUpsertRequest](../../sdk/models/shared/testsuiteupsertrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.CreateTestSuiteJsonResponse](../../sdk/models/operations/createtestsuitejsonresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## createTestSuiteString Create new test suite action ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.createTestSuiteString(""); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ------------------------------------------------------------ | ------------------------------------------------------------ | ------------------------------------------------------------ | ------------------------------------------------------------ | | `request` | [string](../../models/.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.CreateTestSuiteStringResponse](../../sdk/models/operations/createtestsuitestringresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## createTestTriggerJson Create new test trigger CRD inside a Kubernetes cluster ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; import { TestTriggerActions, TestTriggerConditionStatuses, TestTriggerExecutions, TestTriggerResources, } from "testkube-sdk/dist/sdk/models/shared"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.createTestTriggerJson({ action: TestTriggerActions.Run, conditionSpec: { conditions: [ { reason: "NewReplicaSetAvailable", status: TestTriggerConditionStatuses.Unknown, ttl: 1, type: "Progressing", }, ], delay: 1, timeout: 1, }, event: "modified", execution: TestTriggerExecutions.Test, labels: { "env": "prod", "app": "backend", }, name: "name", namespace: "testkube", probeSpec: { delay: 1, probes: [ { headers: { "Content-Type": "application/xml", }, host: "testkube-api-server", path: "/", port: 80, scheme: "http", }, ], timeout: 1, }, resource: TestTriggerResources.Pod, resourceSelector: { name: "nginx", namespace: "testkube", }, testSelector: { name: "nginx", namespace: "testkube", }, }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | -------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- | | `request` | [shared.TestTriggerUpsertRequest](../../sdk/models/shared/testtriggerupsertrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.CreateTestTriggerJsonResponse](../../sdk/models/operations/createtesttriggerjsonresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## createTestTriggerString Create new test trigger CRD inside a Kubernetes cluster ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.createTestTriggerString(""); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ------------------------------------------------------------ | ------------------------------------------------------------ | ------------------------------------------------------------ | ------------------------------------------------------------ | | `request` | [string](../../models/.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.CreateTestTriggerStringResponse](../../sdk/models/operations/createtesttriggerstringresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## createTestJson Create new test based on file content, uri or git based data ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; import { AuthType, ExecutionRequestArgsMode, ExecutionStatus, RepositoryType, RunningContextType, TestContentType, VariableType, } from "testkube-sdk/dist/sdk/models/shared"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.createTestJson({ content: { repository: { branch: "main", commit: "b928cbb7186944ab9275937ec1ac3d3738ca2e1d", path: "test/perf", tokenSecret: { key: "", name: "", }, type: RepositoryType.Git, uri: "https://github.com/kubeshop/testkube", usernameSecret: { key: "", name: "", }, workingDir: "/", }, uri: "https://github.com/kubeshop/testkube", }, created: new Date("2022-07-30T06:54:15Z"), executionRequest: { activeDeadlineSeconds: 1, args: [ "--repeats", "5", "--insecure", ], artifactRequest: { dirs: [ "", ], storageClassName: "artifact-volume-local", }, bucketName: "execution-c01d7cf6-ec3f-47f0-9556-a5d6e9009a43", command: [ "curl", ], contentRequest: { repository: { branch: "main", commit: "b928cbb7186944ab9275937ec1ac3d3738ca2e1d", path: "test/perf", workingDir: "/", }, }, envConfigMaps: [ { mount: true, reference: {}, }, ], envSecrets: [ { mount: true, reference: {}, }, ], envs: { "record": "true", "prefix": "some-", }, executionLabels: { "users": "3", "prefix": "some-", }, httpProxy: "user:pass@my.proxy.server:8080", httpsProxy: "user:pass@my.proxy.server:8081", id: "62f395e004109209b50edfc1", image: "kubeshop/testkube-executor-custom:1.10.11-dev-0a9c91", imagePullSecrets: [ {}, ], isNegativeTestChangedOnRun: false, isVariablesFileUploaded: false, name: "testing with 1000 users", namespace: "testkube", negativeTest: false, postRunScript: "sleep 30", preRunScript: "echo -n '$SECRET_ENV' > ./secret_file", runningContext: { type: RunningContextType.UserUI, }, secretEnvs: { "secret_key_name1": "secret-name", "secret_Key_name2": "secret-name", }, testSuiteName: "test-suite1", uploads: [ "settings/config.txt", ], variables: { "var1": { configMapRef: { key: "", name: "", }, name: "var1", secretRef: { key: "", name: "", }, type: VariableType.Basic, value: "value1", }, "secret1": { configMapRef: { key: "", name: "", }, name: "secret1", secretRef: { key: "", name: "", }, type: VariableType.Secret, value: "secretvalue1", }, }, }, labels: { "env": "prod", "app": "backend", }, name: "test1", namespace: "testkube", schedule: "* * * * *", source: "my-private-repository-test", status: { latestExecution: { id: "62f395e004109209b50edfc4", number: 1, }, }, type: "postman/collection", uploads: [ "settings/config.txt", ], }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ------------------------------------------------------------------------ | ------------------------------------------------------------------------ | ------------------------------------------------------------------------ | ------------------------------------------------------------------------ | | `request` | [shared.TestUpsertRequest](../../sdk/models/shared/testupsertrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.CreateTestJsonResponse](../../sdk/models/operations/createtestjsonresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## createTestString Create new test based on file content, uri or git based data ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.createTestString(""); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ------------------------------------------------------------ | ------------------------------------------------------------ | ------------------------------------------------------------ | ------------------------------------------------------------ | | `request` | [string](../../models/.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.CreateTestStringResponse](../../sdk/models/operations/createteststringresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## createWebhookJson Create new webhook based on variables passed in request ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; import { EventType } from "testkube-sdk/dist/sdk/models/shared"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.createWebhookJson({ events: [ EventType.EndTestTimeout, ], headers: { "Content-Type": "application/xml", }, labels: { "env": "prod", "app": "backend", }, name: "webhook1", namespace: "testkube", uri: "https://hooks.app.com/services/1", }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ------------------------------------------------------------------------------ | ------------------------------------------------------------------------------ | ------------------------------------------------------------------------------ | ------------------------------------------------------------------------------ | | `request` | [shared.WebhookCreateRequest](../../sdk/models/shared/webhookcreaterequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.CreateWebhookJsonResponse](../../sdk/models/operations/createwebhookjsonresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## createWebhookString Create new webhook based on variables passed in request ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.createWebhookString(""); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ------------------------------------------------------------ | ------------------------------------------------------------ | ------------------------------------------------------------ | ------------------------------------------------------------ | | `request` | [string](../../models/.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.CreateWebhookStringResponse](../../sdk/models/operations/createwebhookstringresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## deleteExecutor Deletes executor by its name ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.deleteExecutor({ id: "", }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ---------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------- | | `request` | [operations.DeleteExecutorRequest](../../sdk/models/operations/deleteexecutorrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.DeleteExecutorResponse](../../sdk/models/operations/deleteexecutorresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## deleteExecutors Deletes labeled executors ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.deleteExecutors({}); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------ | | `request` | [operations.DeleteExecutorsRequest](../../sdk/models/operations/deleteexecutorsrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.DeleteExecutorsResponse](../../sdk/models/operations/deleteexecutorsresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## deleteTest Deletes a test ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.deleteTest({ id: "", }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | -------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- | | `request` | [operations.DeleteTestRequest](../../sdk/models/operations/deletetestrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.DeleteTestResponse](../../sdk/models/operations/deletetestresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## deleteTestSource Deletes test source by its name ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.deleteTestSource({ id: "", }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | -------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------- | | `request` | [operations.DeleteTestSourceRequest](../../sdk/models/operations/deletetestsourcerequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.DeleteTestSourceResponse](../../sdk/models/operations/deletetestsourceresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## deleteTestSources Deletes labeled test sources ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.deleteTestSources({}); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ---------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------- | | `request` | [operations.DeleteTestSourcesRequest](../../sdk/models/operations/deletetestsourcesrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.DeleteTestSourcesResponse](../../sdk/models/operations/deletetestsourcesresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## deleteTestSuite Deletes a test suite ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.deleteTestSuite({ id: "", }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------ | | `request` | [operations.DeleteTestSuiteRequest](../../sdk/models/operations/deletetestsuiterequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.DeleteTestSuiteResponse](../../sdk/models/operations/deletetestsuiteresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## deleteTestSuites Deletes all or labeled test suites ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.deleteTestSuites({}); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | -------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------- | | `request` | [operations.DeleteTestSuitesRequest](../../sdk/models/operations/deletetestsuitesrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.DeleteTestSuitesResponse](../../sdk/models/operations/deletetestsuitesresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## deleteTestTrigger Deletes a test trigger ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.deleteTestTrigger({ id: "", }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ---------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------- | | `request` | [operations.DeleteTestTriggerRequest](../../sdk/models/operations/deletetesttriggerrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.DeleteTestTriggerResponse](../../sdk/models/operations/deletetesttriggerresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## deleteTestTriggers Deletes all or labeled test triggers ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.deleteTestTriggers({}); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------ | | `request` | [operations.DeleteTestTriggersRequest](../../sdk/models/operations/deletetesttriggersrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.DeleteTestTriggersResponse](../../sdk/models/operations/deletetesttriggersresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## deleteTests Deletes all or labeled tests ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.deleteTests({}); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | | `request` | [operations.DeleteTestsRequest](../../sdk/models/operations/deletetestsrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.DeleteTestsResponse](../../sdk/models/operations/deletetestsresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## deleteWebhook Deletes webhook by its name ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.deleteWebhook({ id: "", }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | -------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- | | `request` | [operations.DeleteWebhookRequest](../../sdk/models/operations/deletewebhookrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.DeleteWebhookResponse](../../sdk/models/operations/deletewebhookresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## deleteWebhooks Deletes labeled webhooks ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.deleteWebhooks({}); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ---------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------- | | `request` | [operations.DeleteWebhooksRequest](../../sdk/models/operations/deletewebhooksrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.DeleteWebhooksResponse](../../sdk/models/operations/deletewebhooksresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## downloadArchive Download the artifact archive from the given execution ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.downloadArchive({ id: "", }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------ | | `request` | [operations.DownloadArchiveRequest](../../sdk/models/operations/downloadarchiverequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.DownloadArchiveResponse](../../sdk/models/operations/downloadarchiveresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## downloadFile Download the artifact file from the given execution ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.downloadFile({ filename: "maserati_bronze_audi.mp2a", id: "", }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | | `request` | [operations.DownloadFileRequest](../../sdk/models/operations/downloadfilerequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.DownloadFileResponse](../../sdk/models/operations/downloadfileresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## executeTest New test execution returns new execution details on successful execution start ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; import { ExecutionRequestArgsMode, RunningContextType, VariableType } from "testkube-sdk/dist/sdk/models/shared"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.executeTest({ executionRequest: { activeDeadlineSeconds: 1, args: [ "--repeats", "5", "--insecure", ], artifactRequest: { dirs: [ "", ], storageClassName: "artifact-volume-local", }, bucketName: "execution-c01d7cf6-ec3f-47f0-9556-a5d6e9009a43", command: [ "curl", ], contentRequest: { repository: { branch: "main", commit: "b928cbb7186944ab9275937ec1ac3d3738ca2e1d", path: "test/perf", workingDir: "/", }, }, envConfigMaps: [ { mount: true, reference: {}, }, ], envSecrets: [ { mount: true, reference: {}, }, ], envs: { "record": "true", "prefix": "some-", }, executionLabels: { "users": "3", "prefix": "some-", }, httpProxy: "user:pass@my.proxy.server:8080", httpsProxy: "user:pass@my.proxy.server:8081", id: "62f395e004109209b50edfc1", image: "kubeshop/testkube-executor-custom:1.10.11-dev-0a9c91", imagePullSecrets: [ {}, ], isNegativeTestChangedOnRun: false, isVariablesFileUploaded: false, name: "testing with 1000 users", namespace: "testkube", negativeTest: false, postRunScript: "sleep 30", preRunScript: "echo -n '$SECRET_ENV' > ./secret_file", runningContext: { type: RunningContextType.Testsuite, }, secretEnvs: { "secret_key_name1": "secret-name", "secret_Key_name2": "secret-name", }, testSuiteName: "test-suite1", uploads: [ "settings/config.txt", ], variables: { "var1": { configMapRef: { key: "", name: "", }, name: "var1", secretRef: { key: "", name: "", }, type: VariableType.Basic, value: "value1", }, "secret1": { configMapRef: { key: "", name: "", }, name: "secret1", secretRef: { key: "", name: "", }, type: VariableType.Secret, value: "secretvalue1", }, }, }, id: "", }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | | `request` | [operations.ExecuteTestRequest](../../sdk/models/operations/executetestrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.ExecuteTestResponse](../../sdk/models/operations/executetestresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## executeTestSuite New test suite execution returns new execution details on successful execution start ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; import { RunningContextType, VariableType } from "testkube-sdk/dist/sdk/models/shared"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.executeTestSuite({ testSuiteExecutionRequest: { concurrencyLevel: 10, contentRequest: { repository: { branch: "main", commit: "b928cbb7186944ab9275937ec1ac3d3738ca2e1d", path: "test/perf", workingDir: "/", }, }, executionLabels: { "users": "3", "prefix": "some-", }, httpProxy: "user:pass@my.proxy.server:8080", httpsProxy: "user:pass@my.proxy.server:8081", labels: { "users": "3", "prefix": "some-", }, name: "testing with 1000 users", namespace: "testkube", number: 1, runningContext: { type: RunningContextType.Testtrigger, }, timeout: 1, variables: { "var1": { configMapRef: { key: "", name: "", }, name: "var1", secretRef: { key: "", name: "", }, type: VariableType.Basic, value: "value1", }, "secret1": { configMapRef: { key: "", name: "", }, name: "secret1", secretRef: { key: "", name: "", }, type: VariableType.Secret, value: "secretvalue1", }, }, }, id: "", }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | -------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------- | | `request` | [operations.ExecuteTestSuiteRequest](../../sdk/models/operations/executetestsuiterequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.ExecuteTestSuiteResponse](../../sdk/models/operations/executetestsuiteresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## executeTestSuites New test suite executions returns new executions details on successful executions start ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; import { RunningContextType, VariableType } from "testkube-sdk/dist/sdk/models/shared"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.executeTestSuites({ testSuiteExecutionRequest: { concurrencyLevel: 10, contentRequest: { repository: { branch: "main", commit: "b928cbb7186944ab9275937ec1ac3d3738ca2e1d", path: "test/perf", workingDir: "/", }, }, executionLabels: { "users": "3", "prefix": "some-", }, httpProxy: "user:pass@my.proxy.server:8080", httpsProxy: "user:pass@my.proxy.server:8081", labels: { "users": "3", "prefix": "some-", }, name: "testing with 1000 users", namespace: "testkube", number: 1, runningContext: { type: RunningContextType.UserUI, }, timeout: 1, variables: { "var1": { configMapRef: { key: "", name: "", }, name: "var1", secretRef: { key: "", name: "", }, type: VariableType.Basic, value: "value1", }, "secret1": { configMapRef: { key: "", name: "", }, name: "secret1", secretRef: { key: "", name: "", }, type: VariableType.Secret, value: "secretvalue1", }, }, }, }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ---------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------- | | `request` | [operations.ExecuteTestSuitesRequest](../../sdk/models/operations/executetestsuitesrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.ExecuteTestSuitesResponse](../../sdk/models/operations/executetestsuitesresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## executeTests New test executions returns new executions details on successful executions start ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; import { ExecutionRequestArgsMode, RunningContextType, VariableType } from "testkube-sdk/dist/sdk/models/shared"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.executeTests({ executionRequest: { activeDeadlineSeconds: 1, args: [ "--repeats", "5", "--insecure", ], artifactRequest: { dirs: [ "", ], storageClassName: "artifact-volume-local", }, bucketName: "execution-c01d7cf6-ec3f-47f0-9556-a5d6e9009a43", command: [ "curl", ], contentRequest: { repository: { branch: "main", commit: "b928cbb7186944ab9275937ec1ac3d3738ca2e1d", path: "test/perf", workingDir: "/", }, }, envConfigMaps: [ { mount: true, reference: {}, }, ], envSecrets: [ { mount: true, reference: {}, }, ], envs: { "record": "true", "prefix": "some-", }, executionLabels: { "users": "3", "prefix": "some-", }, httpProxy: "user:pass@my.proxy.server:8080", httpsProxy: "user:pass@my.proxy.server:8081", id: "62f395e004109209b50edfc1", image: "kubeshop/testkube-executor-custom:1.10.11-dev-0a9c91", imagePullSecrets: [ {}, ], isNegativeTestChangedOnRun: false, isVariablesFileUploaded: false, name: "testing with 1000 users", namespace: "testkube", negativeTest: false, postRunScript: "sleep 30", preRunScript: "echo -n '$SECRET_ENV' > ./secret_file", runningContext: { type: RunningContextType.Scheduler, }, secretEnvs: { "secret_key_name1": "secret-name", "secret_Key_name2": "secret-name", }, testSuiteName: "test-suite1", uploads: [ "settings/config.txt", ], variables: { "var1": { configMapRef: { key: "", name: "", }, name: "var1", secretRef: { key: "", name: "", }, type: VariableType.Basic, value: "value1", }, "secret1": { configMapRef: { key: "", name: "", }, name: "secret1", secretRef: { key: "", name: "", }, type: VariableType.Secret, value: "secretvalue1", }, }, }, }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | | `request` | [operations.ExecuteTestsRequest](../../sdk/models/operations/executetestsrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.ExecuteTestsResponse](../../sdk/models/operations/executetestsresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## getConfig Get config from cluster storage state ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.getConfig(); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ------------------------------------------------------------ | ------------------------------------------------------------ | ------------------------------------------------------------ | ------------------------------------------------------------ | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.GetConfigResponse](../../sdk/models/operations/getconfigresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## getDebugInfo Gets information that is needed for debugging and opening Testkube bug reports ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.getDebugInfo(); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ------------------------------------------------------------ | ------------------------------------------------------------ | ------------------------------------------------------------ | ------------------------------------------------------------ | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.GetDebugInfoResponse](../../sdk/models/operations/getdebuginforesponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## getExecutionArtifacts Returns artifacts of the given executionID ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.getExecutionArtifacts({ id: "", }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------ | | `request` | [operations.GetExecutionArtifactsRequest](../../sdk/models/operations/getexecutionartifactsrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.GetExecutionArtifactsResponse](../../sdk/models/operations/getexecutionartifactsresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## getExecutionByID Returns execution with given executionID ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.getExecutionByID({ executionID: "", }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | -------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------- | | `request` | [operations.GetExecutionByIDRequest](../../sdk/models/operations/getexecutionbyidrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.GetExecutionByIDResponse](../../sdk/models/operations/getexecutionbyidresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## getExecutionLogs Returns logs of the given executionID ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.getExecutionLogs({ id: "", }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | -------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------- | | `request` | [operations.GetExecutionLogsRequest](../../sdk/models/operations/getexecutionlogsrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.GetExecutionLogsResponse](../../sdk/models/operations/getexecutionlogsresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## getExecutor Returns executors data with executions passed to executor ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.getExecutor({ id: "", }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | | `request` | [operations.GetExecutorRequest](../../sdk/models/operations/getexecutorrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.GetExecutorResponse](../../sdk/models/operations/getexecutorresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## getKeyMap Returns a keymap (supported/allowed fields) for the test trigger UI screen ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.getKeyMap(); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ------------------------------------------------------------ | ------------------------------------------------------------ | ------------------------------------------------------------ | ------------------------------------------------------------ | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.GetKeyMapResponse](../../sdk/models/operations/getkeymapresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## getTest Gets the specified test ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.getTest({ id: "", }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | -------------------------------------------------------------------------- | -------------------------------------------------------------------------- | -------------------------------------------------------------------------- | -------------------------------------------------------------------------- | | `request` | [operations.GetTestRequest](../../sdk/models/operations/gettestrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.GetTestResponse](../../sdk/models/operations/gettestresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## getTestExecution Returns execution with given executionID ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.getTestExecution({ executionID: "", id: "", }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | -------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------- | | `request` | [operations.GetTestExecutionRequest](../../sdk/models/operations/gettestexecutionrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.GetTestExecutionResponse](../../sdk/models/operations/gettestexecutionresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## getTestMetrics Gets test metrics for given tests executions, with particular execution status and timings ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.getTestMetrics({ id: "", }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ---------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------- | | `request` | [operations.GetTestMetricsRequest](../../sdk/models/operations/gettestmetricsrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.GetTestMetricsResponse](../../sdk/models/operations/gettestmetricsresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## getTestSource Returns test sources data ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.getTestSource({ id: "", }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | -------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- | | `request` | [operations.GetTestSourceRequest](../../sdk/models/operations/gettestsourcerequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.GetTestSourceResponse](../../sdk/models/operations/gettestsourceresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## getTestSuiteByID Returns test suite with given name ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.getTestSuiteByID({ id: "", }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | -------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------- | | `request` | [operations.GetTestSuiteByIDRequest](../../sdk/models/operations/gettestsuitebyidrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.GetTestSuiteByIDResponse](../../sdk/models/operations/gettestsuitebyidresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## getTestSuiteByIDWithExecution Returns test suite with given name with execution ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.getTestSuiteByIDWithExecution({ id: "", }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ---------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------- | | `request` | [operations.GetTestSuiteByIDWithExecutionRequest](../../sdk/models/operations/gettestsuitebyidwithexecutionrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.GetTestSuiteByIDWithExecutionResponse](../../sdk/models/operations/gettestsuitebyidwithexecutionresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## getTestSuiteExecution Returns test suite execution with given executionID ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.getTestSuiteExecution({ executionID: "", id: "", }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------ | | `request` | [operations.GetTestSuiteExecutionRequest](../../sdk/models/operations/gettestsuiteexecutionrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.GetTestSuiteExecutionResponse](../../sdk/models/operations/gettestsuiteexecutionresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## getTestSuiteExecutionArtifacts Returns test suite execution artifacts with given executionID ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.getTestSuiteExecutionArtifacts({ executionID: "", }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------ | | `request` | [operations.GetTestSuiteExecutionArtifactsRequest](../../sdk/models/operations/gettestsuiteexecutionartifactsrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.GetTestSuiteExecutionArtifactsResponse](../../sdk/models/operations/gettestsuiteexecutionartifactsresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## getTestSuiteExecutionArtifactsByTestsuite Returns test suite execution artifacts with given executionID ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.getTestSuiteExecutionArtifactsByTestsuite({ executionID: "", id: "", }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ---------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------- | | `request` | [operations.GetTestSuiteExecutionArtifactsByTestsuiteRequest](../../sdk/models/operations/gettestsuiteexecutionartifactsbytestsuiterequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.GetTestSuiteExecutionArtifactsByTestsuiteResponse](../../sdk/models/operations/gettestsuiteexecutionartifactsbytestsuiteresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## getTestSuiteExecutionByID Returns test suite execution with given executionID ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.getTestSuiteExecutionByID({ executionID: "", }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | -------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------- | | `request` | [operations.GetTestSuiteExecutionByIDRequest](../../sdk/models/operations/gettestsuiteexecutionbyidrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.GetTestSuiteExecutionByIDResponse](../../sdk/models/operations/gettestsuiteexecutionbyidresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## getTestSuiteMetrics Gets test suite metrics for given tests executions, with particular execution status and timings ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.getTestSuiteMetrics({ id: "", }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | -------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------- | | `request` | [operations.GetTestSuiteMetricsRequest](../../sdk/models/operations/gettestsuitemetricsrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.GetTestSuiteMetricsResponse](../../sdk/models/operations/gettestsuitemetricsresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## getTestTriggerByID Get test trigger by ID from CRD in kubernetes cluster ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.getTestTriggerByID({ id: "", }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------ | | `request` | [operations.GetTestTriggerByIDRequest](../../sdk/models/operations/gettesttriggerbyidrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.GetTestTriggerByIDResponse](../../sdk/models/operations/gettesttriggerbyidresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## getTestWithExecution Gets the specified test with execution ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.getTestWithExecution({ id: "", }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ---------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------- | | `request` | [operations.GetTestWithExecutionRequest](../../sdk/models/operations/gettestwithexecutionrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.GetTestWithExecutionResponse](../../sdk/models/operations/gettestwithexecutionresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## getWebhook Returns webhook ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.getWebhook({ id: "", }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | -------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- | | `request` | [operations.GetWebhookRequest](../../sdk/models/operations/getwebhookrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.GetWebhookResponse](../../sdk/models/operations/getwebhookresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## listAllTestSuiteExecutions Returns array of test suite executions ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; import { TestSuiteExecutionStatus } from "testkube-sdk/dist/sdk/models/shared"; import { RFCDate } from "testkube-sdk/dist/sdk/types"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.listAllTestSuiteExecutions({}); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ---------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------- | | `request` | [operations.ListAllTestSuiteExecutionsRequest](../../sdk/models/operations/listalltestsuiteexecutionsrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.ListAllTestSuiteExecutionsResponse](../../sdk/models/operations/listalltestsuiteexecutionsresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## listExecutions Returns array of test executions ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; import { ExecutionStatus } from "testkube-sdk/dist/sdk/models/shared"; import { RFCDate } from "testkube-sdk/dist/sdk/types"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.listExecutions({}); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ---------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------- | | `request` | [operations.ListExecutionsRequest](../../sdk/models/operations/listexecutionsrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.ListExecutionsResponse](../../sdk/models/operations/listexecutionsresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## listExecutors List executors available in cluster ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.listExecutors({}); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | -------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- | | `request` | [operations.ListExecutorsRequest](../../sdk/models/operations/listexecutorsrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.ListExecutorsResponse](../../sdk/models/operations/listexecutorsresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## listTestExecutions Returns array of all available test executions ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; import { ExecutionStatus } from "testkube-sdk/dist/sdk/models/shared"; import { RFCDate } from "testkube-sdk/dist/sdk/types"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.listTestExecutions({ id: "", }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------ | | `request` | [operations.ListTestExecutionsRequest](../../sdk/models/operations/listtestexecutionsrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.ListTestExecutionsResponse](../../sdk/models/operations/listtestexecutionsresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## listTestSources List test sources available in cluster ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.listTestSources({}); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------ | | `request` | [operations.ListTestSourcesRequest](../../sdk/models/operations/listtestsourcesrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.ListTestSourcesResponse](../../sdk/models/operations/listtestsourcesresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## listTestSuiteExecutions Returns array of all available test suite executions ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; import { TestSuiteExecutionStatus } from "testkube-sdk/dist/sdk/models/shared"; import { RFCDate } from "testkube-sdk/dist/sdk/types"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.listTestSuiteExecutions({ id: "", }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ---------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------- | | `request` | [operations.ListTestSuiteExecutionsRequest](../../sdk/models/operations/listtestsuiteexecutionsrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.ListTestSuiteExecutionsResponse](../../sdk/models/operations/listtestsuiteexecutionsresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## listTestSuiteTests List available tests for test suite ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.listTestSuiteTests({ id: "", }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------ | | `request` | [operations.ListTestSuiteTestsRequest](../../sdk/models/operations/listtestsuitetestsrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.ListTestSuiteTestsResponse](../../sdk/models/operations/listtestsuitetestsresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## listTestSuiteWithExecutions Returns array of test suite with executions ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; import { TestSuiteExecutionStatus } from "testkube-sdk/dist/sdk/models/shared"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.listTestSuiteWithExecutions({}); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------ | | `request` | [operations.ListTestSuiteWithExecutionsRequest](../../sdk/models/operations/listtestsuitewithexecutionsrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.ListTestSuiteWithExecutionsResponse](../../sdk/models/operations/listtestsuitewithexecutionsresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## listTestSuites Returns array of test suites ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.listTestSuites({}); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ---------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------- | | `request` | [operations.ListTestSuitesRequest](../../sdk/models/operations/listtestsuitesrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.ListTestSuitesResponse](../../sdk/models/operations/listtestsuitesresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## listTestTriggers List test triggers from the kubernetes cluster ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.listTestTriggers({}); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | -------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------- | | `request` | [operations.ListTestTriggersRequest](../../sdk/models/operations/listtesttriggersrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.ListTestTriggersResponse](../../sdk/models/operations/listtesttriggersresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## listTestWithExecutions List available test with executions ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; import { ExecutionStatus } from "testkube-sdk/dist/sdk/models/shared"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.listTestWithExecutions({}); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | -------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------- | | `request` | [operations.ListTestWithExecutionsRequest](../../sdk/models/operations/listtestwithexecutionsrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.ListTestWithExecutionsResponse](../../sdk/models/operations/listtestwithexecutionsresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## listTests List available tests ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.listTests({}); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ------------------------------------------------------------------------------ | ------------------------------------------------------------------------------ | ------------------------------------------------------------------------------ | ------------------------------------------------------------------------------ | | `request` | [operations.ListTestsRequest](../../sdk/models/operations/listtestsrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.ListTestsResponse](../../sdk/models/operations/listtestsresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## listWebhooks List webhooks available in cluster ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.listWebhooks({}); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | | `request` | [operations.ListWebhooksRequest](../../sdk/models/operations/listwebhooksrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.ListWebhooksResponse](../../sdk/models/operations/listwebhooksresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## processTestSourceBatch Process test source batch based on variables passed in request ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; import { AuthType, RepositoryType, TestSourceUpsertRequestType } from "testkube-sdk/dist/sdk/models/shared"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.processTestSourceBatch({ batch: [ { labels: { "key": "", }, name: "testsource1", namespace: "testkube", repository: { branch: "main", commit: "b928cbb7186944ab9275937ec1ac3d3738ca2e1d", path: "test/perf", tokenSecret: { key: "", name: "", }, type: RepositoryType.Git, uri: "https://github.com/kubeshop/testkube", usernameSecret: { key: "", name: "", }, workingDir: "/", }, uri: "https://github.com/kubeshop/testkube", }, ], }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | | `request` | [shared.TestSourceBatchRequest](../../sdk/models/shared/testsourcebatchrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.ProcessTestSourceBatchResponse](../../sdk/models/operations/processtestsourcebatchresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## updateConfigKey Updates config in cluster storage state ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.updateConfigKey({ clusterId: "", enableTelemetry: false, id: "", }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ------------------------------------------------------------ | ------------------------------------------------------------ | ------------------------------------------------------------ | ------------------------------------------------------------ | | `request` | [shared.Config](../../sdk/models/shared/config.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.UpdateConfigKeyResponse](../../sdk/models/operations/updateconfigkeyresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## updateExecutorJson Update new executor based on variables passed in request ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; import { ExecutorUpdateRequestFeatures } from "testkube-sdk/dist/sdk/models/shared"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.updateExecutorJson({ executorUpdateRequest: { args: [ "--repeats", "5", "--insecure", ], command: [ "curl", ], contentTypes: [ "", ], features: [ ExecutorUpdateRequestFeatures.Artifacts, ], imagePullSecrets: [ {}, ], labels: { "env": "prod", "app": "backend", }, meta: { docsURI: "https://docs.testkube.io/test-types/executor-k6", iconURI: "/assets/k6.jpg", tooltips: { "general": "please provide k6 test script for execution", }, }, name: "name", namespace: "testkube", types: [ "", ], }, id: "", }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------ | | `request` | [operations.UpdateExecutorJsonRequest](../../sdk/models/operations/updateexecutorjsonrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.UpdateExecutorJsonResponse](../../sdk/models/operations/updateexecutorjsonresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## updateExecutorString Update new executor based on variables passed in request ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.updateExecutorString({ requestBody: "", id: "", }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ---------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------- | | `request` | [operations.UpdateExecutorStringRequest](../../sdk/models/operations/updateexecutorstringrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.UpdateExecutorStringResponse](../../sdk/models/operations/updateexecutorstringresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## updateTestSourceJson Update test source based on test content or git based data ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; import { AuthType, RepositoryType, TestSourceUpdateRequestType } from "testkube-sdk/dist/sdk/models/shared"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.updateTestSourceJson({ testSourceUpdateRequest: { labels: { "key": "", }, name: "testsource1", namespace: "testkube", repository: { branch: "main", commit: "b928cbb7186944ab9275937ec1ac3d3738ca2e1d", path: "test/perf", tokenSecret: { key: "", name: "", }, type: RepositoryType.Git, uri: "https://github.com/kubeshop/testkube", usernameSecret: { key: "", name: "", }, workingDir: "/", }, uri: "https://github.com/kubeshop/testkube", }, id: "", }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ---------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------- | | `request` | [operations.UpdateTestSourceJsonRequest](../../sdk/models/operations/updatetestsourcejsonrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.UpdateTestSourceJsonResponse](../../sdk/models/operations/updatetestsourcejsonresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## updateTestSourceString Update test source based on test content or git based data ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.updateTestSourceString({ requestBody: "", id: "", }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | -------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------- | | `request` | [operations.UpdateTestSourceStringRequest](../../sdk/models/operations/updatetestsourcestringrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.UpdateTestSourceStringResponse](../../sdk/models/operations/updatetestsourcestringresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## updateTestSuiteJson Update test based on test suite content or git based data ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; import { RunningContextType, TestSuiteExecutionStatus, VariableType } from "testkube-sdk/dist/sdk/models/shared"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.updateTestSuiteJson({ testSuiteUpdateRequest: { after: [ { execute: [ { delay: "1s", test: "example-test", }, ], stopOnFailure: true, }, ], before: [ { execute: [ { delay: "1s", test: "example-test", }, ], stopOnFailure: true, }, ], description: "collection of tests", executionRequest: { concurrencyLevel: 10, contentRequest: { repository: { branch: "main", commit: "b928cbb7186944ab9275937ec1ac3d3738ca2e1d", path: "test/perf", workingDir: "/", }, }, executionLabels: { "users": "3", "prefix": "some-", }, httpProxy: "user:pass@my.proxy.server:8080", httpsProxy: "user:pass@my.proxy.server:8081", labels: { "users": "3", "prefix": "some-", }, name: "testing with 1000 users", namespace: "testkube", number: 1, runningContext: { type: RunningContextType.UserCLI, }, timeout: 1, variables: { "var1": { configMapRef: { key: "", name: "", }, name: "var1", secretRef: { key: "", name: "", }, type: VariableType.Basic, value: "value1", }, "secret1": { configMapRef: { key: "", name: "", }, name: "secret1", secretRef: { key: "", name: "", }, type: VariableType.Secret, value: "secretvalue1", }, }, }, labels: { "env": "prod", "app": "backend", }, name: "name", namespace: "testkube", repeats: 1, schedule: "* * * * *", status: { latestExecution: { id: "62f395e004109209b50edfc4", }, }, steps: [ { execute: [ { delay: "1s", test: "example-test", }, ], stopOnFailure: true, }, ], }, id: "", }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | -------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------- | | `request` | [operations.UpdateTestSuiteJsonRequest](../../sdk/models/operations/updatetestsuitejsonrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.UpdateTestSuiteJsonResponse](../../sdk/models/operations/updatetestsuitejsonresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## updateTestSuiteString Update test based on test suite content or git based data ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.updateTestSuiteString({ requestBody: "", id: "", }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------ | | `request` | [operations.UpdateTestSuiteStringRequest](../../sdk/models/operations/updatetestsuitestringrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.UpdateTestSuiteStringResponse](../../sdk/models/operations/updatetestsuitestringresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## updateTestTriggerJson Update test trigger ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; import { TestTriggerActions, TestTriggerConditionStatuses, TestTriggerExecutions, TestTriggerResources, } from "testkube-sdk/dist/sdk/models/shared"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.updateTestTriggerJson({ testTriggerUpsertRequest: { action: TestTriggerActions.Run, conditionSpec: { conditions: [ { reason: "NewReplicaSetAvailable", status: TestTriggerConditionStatuses.False, ttl: 1, type: "Progressing", }, ], delay: 1, timeout: 1, }, event: "modified", execution: TestTriggerExecutions.Testsuite, labels: { "env": "prod", "app": "backend", }, name: "name", namespace: "testkube", probeSpec: { delay: 1, probes: [ { headers: { "Content-Type": "application/xml", }, host: "testkube-api-server", path: "/", port: 80, scheme: "http", }, ], timeout: 1, }, resource: TestTriggerResources.Configmap, resourceSelector: { name: "nginx", namespace: "testkube", }, testSelector: { name: "nginx", namespace: "testkube", }, }, id: "", }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------ | | `request` | [operations.UpdateTestTriggerJsonRequest](../../sdk/models/operations/updatetesttriggerjsonrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.UpdateTestTriggerJsonResponse](../../sdk/models/operations/updatetesttriggerjsonresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## updateTestTriggerString Update test trigger ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.updateTestTriggerString({ requestBody: "", id: "", }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ---------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------- | | `request` | [operations.UpdateTestTriggerStringRequest](../../sdk/models/operations/updatetesttriggerstringrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.UpdateTestTriggerStringResponse](../../sdk/models/operations/updatetesttriggerstringresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## updateTestJson Update test based on test content or git based data ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; import { AuthType, ExecutionRequestArgsMode, ExecutionStatus, RepositoryType, RunningContextType, TestContentType, VariableType, } from "testkube-sdk/dist/sdk/models/shared"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.updateTestJson({ testUpdateRequest: { content: { repository: { branch: "main", commit: "b928cbb7186944ab9275937ec1ac3d3738ca2e1d", path: "test/perf", tokenSecret: { key: "", name: "", }, type: RepositoryType.Git, uri: "https://github.com/kubeshop/testkube", usernameSecret: { key: "", name: "", }, workingDir: "/", }, uri: "https://github.com/kubeshop/testkube", }, created: new Date("2022-07-30T06:54:15Z"), executionRequest: { activeDeadlineSeconds: 1, args: [ "--repeats", "5", "--insecure", ], artifactRequest: { dirs: [ "", ], storageClassName: "artifact-volume-local", }, bucketName: "execution-c01d7cf6-ec3f-47f0-9556-a5d6e9009a43", command: [ "curl", ], contentRequest: { repository: { branch: "main", commit: "b928cbb7186944ab9275937ec1ac3d3738ca2e1d", path: "test/perf", workingDir: "/", }, }, envConfigMaps: [ { mount: true, reference: {}, }, ], envSecrets: [ { mount: true, reference: {}, }, ], envs: { "record": "true", "prefix": "some-", }, executionLabels: { "users": "3", "prefix": "some-", }, httpProxy: "user:pass@my.proxy.server:8080", httpsProxy: "user:pass@my.proxy.server:8081", id: "62f395e004109209b50edfc1", image: "kubeshop/testkube-executor-custom:1.10.11-dev-0a9c91", imagePullSecrets: [ {}, ], isNegativeTestChangedOnRun: false, isVariablesFileUploaded: false, name: "testing with 1000 users", namespace: "testkube", negativeTest: false, postRunScript: "sleep 30", preRunScript: "echo -n '$SECRET_ENV' > ./secret_file", runningContext: { type: RunningContextType.UserCLI, }, secretEnvs: { "secret_key_name1": "secret-name", "secret_Key_name2": "secret-name", }, testSuiteName: "test-suite1", uploads: [ "settings/config.txt", ], variables: { "var1": { configMapRef: { key: "", name: "", }, name: "var1", secretRef: { key: "", name: "", }, type: VariableType.Basic, value: "value1", }, "secret1": { configMapRef: { key: "", name: "", }, name: "secret1", secretRef: { key: "", name: "", }, type: VariableType.Secret, value: "secretvalue1", }, }, }, labels: { "env": "prod", "app": "backend", }, name: "test1", namespace: "testkube", schedule: "* * * * *", source: "my-private-repository-test", status: { latestExecution: { id: "62f395e004109209b50edfc4", number: 1, }, }, type: "postman/collection", uploads: [ "settings/config.txt", ], }, id: "", }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ---------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------- | | `request` | [operations.UpdateTestJsonRequest](../../sdk/models/operations/updatetestjsonrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.UpdateTestJsonResponse](../../sdk/models/operations/updatetestjsonresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## updateTestString Update test based on test content or git based data ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.updateTestString({ requestBody: "", id: "", }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | -------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------- | | `request` | [operations.UpdateTestStringRequest](../../sdk/models/operations/updateteststringrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.UpdateTestStringResponse](../../sdk/models/operations/updateteststringresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## uploads Upload file to be used in executions and tests ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; import { ParentType } from "testkube-sdk/dist/sdk/models/shared"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.uploads({ filePath: "folder/file.txt", parentName: "test-1", }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ------------------------------------------------------------ | ------------------------------------------------------------ | ------------------------------------------------------------ | ------------------------------------------------------------ | | `request` | [shared.UploadsBody](../../sdk/models/shared/uploadsbody.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.UploadsResponse](../../sdk/models/operations/uploadsresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* | ## validateRepository Validate new repository based on variables passed in request ### Example Usage ```typescript import { TestkubeSDK } from "testkube-sdk"; import { AuthType, RepositoryType } from "testkube-sdk/dist/sdk/models/shared"; async function run() { const sdk = new TestkubeSDK(); const res = await sdk.api.validateRepository({ branch: "main", commit: "b928cbb7186944ab9275937ec1ac3d3738ca2e1d", path: "test/perf", tokenSecret: { key: "", name: "", }, type: RepositoryType.Git, uri: "https://github.com/kubeshop/testkube", usernameSecret: { key: "", name: "", }, workingDir: "/", }); if (res.statusCode == 200) { // handle response } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ------------------------------------------------------------ | ------------------------------------------------------------ | ------------------------------------------------------------ | ------------------------------------------------------------ | | `request` | [shared.Repository](../../sdk/models/shared/repository.md) | :heavy_check_mark: | The request object to use for the request. | | `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. | ### Response **Promise<[operations.ValidateRepositoryResponse](../../sdk/models/operations/validaterepositoryresponse.md)>** ### Errors | Error Object | Status Code | Content Type | | --------------- | --------------- | --------------- | | errors.SDKError | 4xx-5xx | */* |