Testkube Agent /executors operations
Testkube API (1.0.0)
Download OpenAPI specification:Download
Testkube provides a Kubernetes-native framework for test definition, execution and results
List executors
List executors available in cluster
query Parameters
| selector | string  Labels to filter by  | 
Responses
Response samples
- 200
 - 400
 - 502
 
[- {
- "executorType": "string",
 - "image": "string",
 - "slaves": {
- "image": "kubeshop/ex-slaves-image:latest"
 
}, - "imagePullSecrets": [
- {
- "name": "string"
 
} 
], - "command": [
- "curl"
 
], - "args": [
- "--repeats",
 - "5",
 - "--insecure"
 
], - "types": [
- "string"
 
], - "uri": "string",
 - "contentTypes": [
- "string"
 
], - "jobTemplate": "string",
 - "jobTemplateReference": "string",
 - "labels": {
- "env": "prod",
 - "app": "backend"
 
}, - "features": [
- "artifacts"
 
], - "meta": {
- "iconURI": "/assets/k6.jpg",
 - "tooltips": {
- "general": "please provide k6 test script for execution"
 
} 
}, - "useDataDirAsWorkingDir": true
 
} 
]Create new executor
Create new executor based on variables passed in request
Request Body schema: required
executor request body data
| executorType | string  ExecutorType one of "rest" for rest openapi based executors or "job" which will be default runners for testkube soon  | 
| image | string  Image for kube-job  | 
object (SlavesMeta)   Slave data for executing tests in distributed environment  | |
Array of objects (LocalObjectReference)   container image pull secrets  | |
| command | Array of strings  executor image command  | 
| args | Array of strings  additional executor binary argument  | 
| types required  | Array of strings  Types defines what types can be handled by executor e.g. "postman/collection", ":curl/command" etc  | 
| uri | string  URI for rest based executors  | 
| contentTypes | Array of strings  list of handled content types  | 
| jobTemplate | string  Job template to launch executor  | 
| jobTemplateReference | string  name of the template resource  | 
object  executor labels  | |
| features | Array of strings Items Enum: "artifacts" "junit-report"   Available executor features  | 
object (ExecutorMeta)   Executor meta data  | |
| useDataDirAsWorkingDir | boolean  use data dir as working dir for executor  | 
| namespace required  | string  object kubernetes namespace  | 
| name required  | string  object name  | 
Responses
Request samples
- Payload
 
{- "executorType": "string",
 - "image": "string",
 - "slaves": {
- "image": "kubeshop/ex-slaves-image:latest"
 
}, - "imagePullSecrets": [
- {
- "name": "string"
 
} 
], - "command": [
- "curl"
 
], - "args": [
- "--repeats",
 - "5",
 - "--insecure"
 
], - "types": [
- "string"
 
], - "uri": "string",
 - "contentTypes": [
- "string"
 
], - "jobTemplate": "string",
 - "jobTemplateReference": "string",
 - "labels": {
- "env": "prod",
 - "app": "backend"
 
}, - "features": [
- "artifacts"
 
], - "meta": {
- "iconURI": "/assets/k6.jpg",
 - "tooltips": {
- "general": "please provide k6 test script for execution"
 
} 
}, - "useDataDirAsWorkingDir": true,
 - "namespace": "testkube",
 - "name": "name"
 
}Response samples
- 201
 - 400
 - 502
 
{- "name": "string",
 - "executor": {
- "executorType": "string",
 - "image": "string",
 - "slaves": {
- "image": "kubeshop/ex-slaves-image:latest"
 
}, - "imagePullSecrets": [
- {
- "name": "string"
 
} 
], - "command": [
- "curl"
 
], - "args": [
- "--repeats",
 - "5",
 - "--insecure"
 
], - "types": [
- "string"
 
], - "uri": "string",
 - "contentTypes": [
- "string"
 
], - "jobTemplate": "string",
 - "jobTemplateReference": "string",
 - "labels": {
- "env": "prod",
 - "app": "backend"
 
}, - "features": [
- "artifacts"
 
], - "meta": {
- "iconURI": "/assets/k6.jpg",
 - "tooltips": {
- "general": "please provide k6 test script for execution"
 
} 
}, - "useDataDirAsWorkingDir": true
 
}, - "executions": {
- "totals": {
- "results": 0,
 - "passed": 0,
 - "failed": 0,
 - "queued": 0,
 - "running": 0
 
}, - "filtered": {
- "results": 0,
 - "passed": 0,
 - "failed": 0,
 - "queued": 0,
 - "running": 0
 
}, - "results": [
- {
- "id": "62f395e004109209b50edfc4",
 - "name": "test-suite1-test1",
 - "number": 1,
 - "testName": "test1",
 - "testNamespace": "testkube",
 - "testType": "postman/collection",
 - "status": "queued",
 - "startTime": "2019-08-24T14:15:22Z",
 - "endTime": "2019-08-24T14:15:22Z",
 - "duration": "00:00:13",
 - "durationMs": 10000,
 - "labels": {
- "env": "prod",
 - "app": "backend"
 
}, - "runningContext": {
- "type": "userCLI",
 - "context": "string"
 
} 
} 
] 
} 
}Get executor details
Returns executors data with executions passed to executor
path Parameters
| id required  | string  unique id of the object  | 
Responses
Response samples
- 200
 - 400
 - 500
 - 502
 
{- "name": "string",
 - "executor": {
- "executorType": "string",
 - "image": "string",
 - "slaves": {
- "image": "kubeshop/ex-slaves-image:latest"
 
}, - "imagePullSecrets": [
- {
- "name": "string"
 
} 
], - "command": [
- "curl"
 
], - "args": [
- "--repeats",
 - "5",
 - "--insecure"
 
], - "types": [
- "string"
 
], - "uri": "string",
 - "contentTypes": [
- "string"
 
], - "jobTemplate": "string",
 - "jobTemplateReference": "string",
 - "labels": {
- "env": "prod",
 - "app": "backend"
 
}, - "features": [
- "artifacts"
 
], - "meta": {
- "iconURI": "/assets/k6.jpg",
 - "tooltips": {
- "general": "please provide k6 test script for execution"
 
} 
}, - "useDataDirAsWorkingDir": true
 
}, - "executions": {
- "totals": {
- "results": 0,
 - "passed": 0,
 - "failed": 0,
 - "queued": 0,
 - "running": 0
 
}, - "filtered": {
- "results": 0,
 - "passed": 0,
 - "failed": 0,
 - "queued": 0,
 - "running": 0
 
}, - "results": [
- {
- "id": "62f395e004109209b50edfc4",
 - "name": "test-suite1-test1",
 - "number": 1,
 - "testName": "test1",
 - "testNamespace": "testkube",
 - "testType": "postman/collection",
 - "status": "queued",
 - "startTime": "2019-08-24T14:15:22Z",
 - "endTime": "2019-08-24T14:15:22Z",
 - "duration": "00:00:13",
 - "durationMs": 10000,
 - "labels": {
- "env": "prod",
 - "app": "backend"
 
}, - "runningContext": {
- "type": "userCLI",
 - "context": "string"
 
} 
} 
] 
} 
}Update executor
Update new executor based on variables passed in request
path Parameters
| id required  | string  unique id of the object  | 
Request Body schema: required
executor request body data
| executorType | string  ExecutorType one of "rest" for rest openapi based executors or "job" which will be default runners for testkube soon  | 
| image | string  Image for kube-job  | 
object (SlavesMeta)   Slave data for executing tests in distributed environment  | |
Array of objects (LocalObjectReference)   container image pull secrets  | |
| command | Array of strings  executor image command  | 
| args | Array of strings  additional executor binary argument  | 
| types | Array of strings  Types defines what types can be handled by executor e.g. "postman/collection", ":curl/command" etc  | 
| uri | string  URI for rest based executors  | 
| contentTypes | Array of strings  list of handled content types  | 
| jobTemplate | string  Job template to launch executor  | 
| jobTemplateReference | string  name of the template resource  | 
object  executor labels  | |
| features | Array of strings Items Enum: "artifacts" "junit-report"   Available executor features  | 
object (ExecutorMeta)   Executor meta data  | |
| useDataDirAsWorkingDir | boolean  use data dir as working dir for executor  | 
| namespace | string  object kubernetes namespace  | 
| name required  | string  object name  | 
Responses
Request samples
- Payload
 
{- "executorType": "string",
 - "image": "string",
 - "slaves": {
- "image": "kubeshop/ex-slaves-image:latest"
 
}, - "imagePullSecrets": [
- {
- "name": "string"
 
} 
], - "command": [
- "curl"
 
], - "args": [
- "--repeats",
 - "5",
 - "--insecure"
 
], - "types": [
- "string"
 
], - "uri": "string",
 - "contentTypes": [
- "string"
 
], - "jobTemplate": "string",
 - "jobTemplateReference": "string",
 - "labels": {
- "env": "prod",
 - "app": "backend"
 
}, - "features": [
- "artifacts"
 
], - "meta": {
- "iconURI": "/assets/k6.jpg",
 - "tooltips": {
- "general": "please provide k6 test script for execution"
 
} 
}, - "useDataDirAsWorkingDir": true,
 - "namespace": "testkube",
 - "name": "name"
 
}Response samples
- 200
 - 400
 - 404
 - 502
 
{- "name": "string",
 - "executor": {
- "executorType": "string",
 - "image": "string",
 - "slaves": {
- "image": "kubeshop/ex-slaves-image:latest"
 
}, - "imagePullSecrets": [
- {
- "name": "string"
 
} 
], - "command": [
- "curl"
 
], - "args": [
- "--repeats",
 - "5",
 - "--insecure"
 
], - "types": [
- "string"
 
], - "uri": "string",
 - "contentTypes": [
- "string"
 
], - "jobTemplate": "string",
 - "jobTemplateReference": "string",
 - "labels": {
- "env": "prod",
 - "app": "backend"
 
}, - "features": [
- "artifacts"
 
], - "meta": {
- "iconURI": "/assets/k6.jpg",
 - "tooltips": {
- "general": "please provide k6 test script for execution"
 
} 
}, - "useDataDirAsWorkingDir": true
 
}, - "executions": {
- "totals": {
- "results": 0,
 - "passed": 0,
 - "failed": 0,
 - "queued": 0,
 - "running": 0
 
}, - "filtered": {
- "results": 0,
 - "passed": 0,
 - "failed": 0,
 - "queued": 0,
 - "running": 0
 
}, - "results": [
- {
- "id": "62f395e004109209b50edfc4",
 - "name": "test-suite1-test1",
 - "number": 1,
 - "testName": "test1",
 - "testNamespace": "testkube",
 - "testType": "postman/collection",
 - "status": "queued",
 - "startTime": "2019-08-24T14:15:22Z",
 - "endTime": "2019-08-24T14:15:22Z",
 - "duration": "00:00:13",
 - "durationMs": 10000,
 - "labels": {
- "env": "prod",
 - "app": "backend"
 
}, - "runningContext": {
- "type": "userCLI",
 - "context": "string"
 
} 
} 
] 
} 
}