Kubeshop Test Workflow With Executions API

The Test Workflow With Executions API from Kubeshop — 3 operation(s) for test workflow with executions.

OpenAPI Specification

kubeshop-test-workflow-with-executions-api-openapi.yml Raw ↑
openapi: 3.0.1
info:
  title: Testkube Standalone Agent api Test Workflow With Executions API
  description: API for Testkube Standalone Agent
  contact:
    email: info@testkube.io
  license:
    name: MIT
    url: https://opensource.org/licenses/MIT
  version: 1.0.0
servers:
- url: https://api.testkube.io
  description: Testkube Cloud Control Plane API Endpoint
- url: https://<your-testkube-api-host>
  description: Testkube On-Prem API Endpoint
tags:
- name: Test Workflow With Executions
paths:
  /test-workflow-with-executions:
    get:
      parameters:
      - $ref: '#/components/parameters/Selector'
      summary: List test workflows with latest execution
      description: List test workflows from the kubernetes cluster with latest execution
      operationId: listTestWorkflowWithExecutions
      responses:
        '200':
          description: successful list operation
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/TestWorkflowWithExecutionSummary'
            text/yaml:
              schema:
                type: string
        '400':
          description: problem with selector parsing - probably some bad input occurs
          content:
            application/problem+json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/Problem'
        '402':
          description: missing Pro subscription for a commercial feature
          content:
            application/problem+json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/Problem'
        '502':
          description: problem communicating with kubernetes cluster
          content:
            application/problem+json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/Problem'
      tags:
      - Test Workflow With Executions
  /test-workflow-with-executions/{id}:
    get:
      parameters:
      - $ref: '#/components/parameters/ID'
      summary: Get test workflow details with latest execution
      description: Get test workflow details from the kubernetes cluster with latest execution
      operationId: getTestWorkflowWithExecution
      responses:
        '200':
          description: successful operation
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TestWorkflowWithExecution'
            text/yaml:
              schema:
                type: string
        '402':
          description: missing Pro subscription for a commercial feature
          content:
            application/problem+json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/Problem'
        '404':
          description: the resource has not been found
          content:
            application/problem+json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/Problem'
        '502':
          description: problem communicating with kubernetes cluster
          content:
            application/problem+json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/Problem'
      tags:
      - Test Workflow With Executions
  /test-workflow-with-executions/{id}/tags:
    get:
      parameters:
      - $ref: '#/components/parameters/ID'
      summary: List test workflow execution tags
      description: List test workflow execution tags for all executed test workflows
      operationId: listTestWorkflowWithExecutionTags
      responses:
        '200':
          description: successful operation
          content:
            application/json:
              schema:
                type: object
                additionalProperties:
                  type: array
                  items:
                    type: string
                example:
                  app:
                  - backend
                  env:
                  - prod
                  toDelete:
                  - 'yes'
        '502':
          description: problem communicating with kubernetes cluster
          content:
            application/problem+json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/Problem'
      tags:
      - Test Workflow With Executions
components:
  schemas:
    PodDNSConfig:
      type: object
      properties:
        nameservers:
          type: array
          items:
            type: string
        searches:
          type: array
          items:
            type: string
        options:
          type: array
          items:
            $ref: '#/components/schemas/PodDNSConfigOption'
    PodResourceClaim:
      type: object
      properties:
        name:
          type: string
        source:
          $ref: '#/components/schemas/ClaimSource'
    TestWorkflowSummary:
      type: object
      properties:
        name:
          type: string
        namespace:
          type: string
        labels:
          type: object
          additionalProperties:
            type: string
        annotations:
          type: object
          additionalProperties:
            type: string
        health:
          $ref: '#/components/schemas/TestWorkflowExecutionHealth'
    ImagePullPolicy:
      type: string
      enum:
      - Always
      - Never
      - IfNotPresent
    TestWorkflowStatus:
      type: string
      enum:
      - queued
      - assigned
      - starting
      - scheduling
      - running
      - pausing
      - paused
      - resuming
      - passed
      - failed
      - stopping
      - aborted
      - canceled
    NodeSelector:
      type: object
      properties:
        nodeSelectorTerms:
          type: array
          items:
            $ref: '#/components/schemas/NodeSelectorTerm'
    ExecAction:
      type: object
      properties:
        command:
          type: array
          description: Command is the command line to execute inside the container, the working directory for the command is root ('/') in the container's filesystem. Exit status of 0 is treated as live/healthy and non-zero is unhealthy.
          items:
            type: string
    TestWorkflowCronJobConfig:
      type: object
      description: cron job configuration
      required:
      - cron
      properties:
        cron:
          type: string
          description: cron schedule to run a test workflow
          example: '* * * * *'
        labels:
          type: object
          description: labels to attach to the cron job
          additionalProperties:
            type: string
        annotations:
          type: object
          description: annotations to attach to the cron job
          additionalProperties:
            type: string
        config:
          $ref: '#/components/schemas/TestWorkflowConfigValue'
        target:
          $ref: '#/components/schemas/ExecutionTarget'
        timezone:
          $ref: '#/components/schemas/BoxedString'
          description: cron timezone
          example: America/New_York
    TestWorkflowPause:
      type: object
      properties:
        ref:
          type: string
          description: step at which it was paused
        pausedAt:
          type: string
          format: date-time
          description: when the pause has started
        resumedAt:
          type: string
          format: date-time
          description: when the pause has ended
      required:
      - ref
      - pausedAt
    ProjectedVolumeSource:
      type: object
      description: Represents a projected volume source
      properties:
        defaultMode:
          $ref: '#/components/schemas/BoxedInteger'
        sources:
          description: sources is the list of volume projections. Each entry in this list handles one source.
          items:
            description: Projection that may be projected along with other supported volume types. Exactly one of these fields must be set.
            properties:
              clusterTrustBundle:
                type: object
                description: ClusterTrustBundle allows a pod to access the `.spec.trustBundle` field of ClusterTrustBundle objects in an auto-updating file.
                properties:
                  labelSelector:
                    $ref: '#/components/schemas/LabelSelector'
                  name:
                    $ref: '#/components/schemas/BoxedString'
                  optional:
                    $ref: '#/components/schemas/BoxedBoolean'
                  path:
                    description: Relative path from the volume root to write the bundle.
                    type: string
                  signerName:
                    $ref: '#/components/schemas/BoxedString'
                required:
                - path
              configMap:
                type: object
                description: configMap information about the configMap data to project
                properties:
                  items:
                    description: items if unspecified, each key-value pair in the Data field of the referenced ConfigMap will be projected into the volume as a file whose name is the key and content is the value. If specified, the listed keys will be projected into the specified paths, and unlisted keys will not be present. If a key is specified which is not present in the ConfigMap, the volume setup will error unless it is marked optional. Paths must be relative and may not contain the '..' path or start with '..'.
                    items:
                      description: Maps a string key to a path within a volume.
                      properties:
                        key:
                          description: key is the key to project.
                          type: string
                        mode:
                          $ref: '#/components/schemas/BoxedInteger'
                        path:
                          description: path is the relative path of the file to map the key to. May not be an absolute path. May not contain the path element '..'. May not start with the string '..'.
                          type: string
                      required:
                      - key
                      - path
                      type: object
                    type: array
                  name:
                    description: 'Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names TODO: Add other useful fields. apiVersion, kind, uid?'
                    type: string
                  optional:
                    $ref: '#/components/schemas/BoxedBoolean'
              downwardAPI:
                type: object
                description: downwardAPI information about the downwardAPI data to project
                properties:
                  items:
                    description: Items is a list of DownwardAPIVolume file
                    items:
                      description: DownwardAPIVolumeFile represents information to create the file containing the pod field
                      properties:
                        fieldRef:
                          $ref: '#/components/schemas/FieldRef'
                        mode:
                          $ref: '#/components/schemas/BoxedInteger'
                        path:
                          description: path is the relative path of the file to map the key to. May not be an absolute path. May not contain the path element '..'. May not start with the string '..'.
                          type: string
                        resourceFieldRef:
                          $ref: '#/components/schemas/ResourceFieldRef'
                      required:
                      - path
                      type: object
                    type: array
              secret:
                type: object
                description: secret information about the secret data to project
                properties:
                  items:
                    description: items if unspecified, each key-value pair in the Data field of the referenced ConfigMap will be projected into the volume as a file whose name is the key and content is the value. If specified, the listed keys will be projected into the specified paths, and unlisted keys will not be present. If a key is specified which is not present in the ConfigMap, the volume setup will error unless it is marked optional. Paths must be relative and may not contain the '..' path or start with '..'.
                    items:
                      description: Maps a string key to a path within a volume.
                      properties:
                        key:
                          description: key is the key to project.
                          type: string
                        mode:
                          $ref: '#/components/schemas/BoxedInteger'
                        path:
                          description: path is the relative path of the file to map the key to. May not be an absolute path. May not contain the path element '..'. May not start with the string '..'.
                          type: string
                      required:
                      - key
                      - path
                      type: object
                    type: array
                  name:
                    description: 'Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names TODO: Add other useful fields. apiVersion, kind, uid?'
                    type: string
                  optional:
                    $ref: '#/components/schemas/BoxedBoolean'
              serviceAccountToken:
                type: object
                description: serviceAccountToken is information about the serviceAccountToken data to project
                properties:
                  audience:
                    description: audience is the intended audience of the token. A recipient of a token must identify itself with an identifier specified in the audience of the token, and otherwise should reject the token. The audience defaults to the identifier of the apiserver.
                    type: string
                  expirationSeconds:
                    $ref: '#/components/schemas/BoxedInteger'
                  path:
                    description: path is the path relative to the mount point of the file to project the token into.
                    type: string
                required:
                - path
            type: object
          type: array
    TestWorkflowStepParallelTransfer:
      type: object
      properties:
        from:
          type: string
          description: path to load the files from
        to:
          type: string
          description: path to save the files to
        files:
          $ref: '#/components/schemas/TestWorkflowTarballFilePattern'
        mount:
          $ref: '#/components/schemas/BoxedBoolean'
      required:
      - from
    SecretVolumeSource:
      description: 'secret represents a secret that should populate this volume. More info: https://kubernetes.io/docs/concepts/storage/volumes#secret'
      properties:
        defaultMode:
          $ref: '#/components/schemas/BoxedInteger'
        items:
          description: items If unspecified, each key-value pair in the Data field of the referenced Secret will be projected into the volume as a file whose name is the key and content is the value. If specified, the listed keys will be projected into the specified paths, and unlisted keys will not be present. If a key is specified which is not present in the Secret, the volume setup will error unless it is marked optional. Paths must be relative and may not contain the '..' path or start with '..'.
          items:
            description: Maps a string key to a path within a volume.
            properties:
              key:
                description: key is the key to project.
                type: string
              mode:
                $ref: '#/components/schemas/BoxedInteger'
              path:
                description: path is the relative path of the file to map the key to. May not be an absolute path. May not contain the path element '..'. May not start with the string '..'.
                type: string
            required:
            - key
            - path
            type: object
          type: array
        optional:
          description: optional field specify whether the Secret or its keys must be defined
          type: boolean
        secretName:
          description: 'secretName is the name of the secret in the pod''s namespace to use. More info: https://kubernetes.io/docs/concepts/storage/volumes#secret'
          type: string
      type: object
    TestWorkflowSpec:
      type: object
      properties:
        use:
          type: array
          items:
            $ref: '#/components/schemas/TestWorkflowTemplateRef'
        concurrency:
          $ref: '#/components/schemas/TestWorkflowConcurrencyPolicy'
        config:
          $ref: '#/components/schemas/TestWorkflowConfigSchema'
        system:
          $ref: '#/components/schemas/TestWorkflowSystem'
        content:
          $ref: '#/components/schemas/TestWorkflowContent'
        services:
          type: object
          additionalProperties:
            $ref: '#/components/schemas/TestWorkflowServiceSpec'
        container:
          $ref: '#/components/schemas/TestWorkflowContainerConfig'
        job:
          $ref: '#/components/schemas/TestWorkflowJobConfig'
        pod:
          $ref: '#/components/schemas/TestWorkflowPodConfig'
        setup:
          type: array
          items:
            $ref: '#/components/schemas/TestWorkflowStep'
        steps:
          type: array
          items:
            $ref: '#/components/schemas/TestWorkflowStep'
        after:
          type: array
          items:
            $ref: '#/components/schemas/TestWorkflowStep'
        events:
          type: array
          items:
            $ref: '#/components/schemas/TestWorkflowEvent'
        execution:
          $ref: '#/components/schemas/TestWorkflowExecutionSchema'
        timeouts:
          $ref: '#/components/schemas/TestWorkflowTimeouts'
        pvcs:
          type: object
          additionalProperties:
            $ref: '#/components/schemas/TestWorkflowPvcConfig'
    ExecutionTarget:
      type: object
      properties:
        match:
          type: object
          description: runner labels to match
          additionalProperties:
            type: array
            items:
              type: string
        not:
          type: object
          description: runner labels to NOT match
          additionalProperties:
            type: array
            items:
              type: string
        replicate:
          type: array
          description: list of runner labels to replicate the executions
          items:
            type: string
    TestWorkflowEvent:
      type: object
      properties:
        cronjob:
          $ref: '#/components/schemas/TestWorkflowCronJobConfig'
    AzureDiskVolumeSource:
      description: azureDisk represents an Azure Data Disk mount on the host and bind mount to the pod.
      properties:
        cachingMode:
          $ref: '#/components/schemas/BoxedString'
        diskName:
          description: diskName is the Name of the data disk in the blob storage
          type: string
        diskURI:
          description: diskURI is the URI of data disk in the blob storage
          type: string
        fsType:
          $ref: '#/components/schemas/BoxedString'
        kind:
          $ref: '#/components/schemas/BoxedString'
        readOnly:
          description: readOnly Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts.
          type: boolean
      required:
      - diskName
      - diskURI
      type: object
    GRPCAction:
      type: object
      properties:
        port:
          type: integer
        service:
          $ref: '#/components/schemas/BoxedString'
    PodAffinity:
      type: object
      properties:
        requiredDuringSchedulingIgnoredDuringExecution:
          type: array
          items:
            $ref: '#/components/schemas/PodAffinityTerm'
        preferredDuringSchedulingIgnoredDuringExecution:
          type: array
          items:
            $ref: '#/components/schemas/WeightedPodAffinityTerm'
    TestWorkflowReport:
      type: object
      properties:
        ref:
          type: string
          description: step reference
        kind:
          type: string
          enum:
          - junit
          description: report kind/type
          example: junit
        file:
          type: string
          description: file path to full report in artifact storage
        summary:
          $ref: '#/components/schemas/TestWorkflowReportSummary'
    TestWorkflowExecutionHealth:
      type: object
      properties:
        passRate:
          type: number
          format: float64
          description: 'Recency-weighted fraction of executions that passed (value between 0.0 and 1.0).

            '
        flipRate:
          type: number
          format: float64
          description: "Fraction of status changes among consecutive executions without recency weighting \n(value between 0.0 and 1.0).\n"
        overallHealth:
          type: number
          format: float64
          description: 'Combined health score, computed as passRate * (1 - flipRate)

            (value between 0.0 and 1.0).

            '
      required:
      - passRate
      - flipRate
      - overallHealth
    TestWorkflowServiceSpec:
      type: object
      allOf:
      - $ref: '#/components/schemas/TestWorkflowStepExecuteStrategy'
      - $ref: '#/components/schemas/TestWorkflowIndependentServiceSpec'
      - properties:
          use:
            type: array
            items:
              $ref: '#/components/schemas/TestWorkflowTemplateRef'
    SecurityContext:
      type: object
      properties:
        capabilities:
          $ref: '#/components/schemas/Capabilities'
        privileged:
          $ref: '#/components/schemas/BoxedBoolean'
        seLinuxOptions:
          $ref: '#/components/schemas/SELinuxOptions'
        windowsOptions:
          $ref: '#/components/schemas/WindowsSecurityContextOptions'
        runAsUser:
          $ref: '#/components/schemas/TemplatableBoxedInteger'
        runAsGroup:
          $ref: '#/components/schemas/TemplatableBoxedInteger'
        runAsNonRoot:
          $ref: '#/components/schemas/BoxedBoolean'
        readOnlyRootFilesystem:
          $ref: '#/components/schemas/BoxedBoolean'
        allowPrivilegeEscalation:
          $ref: '#/components/schemas/BoxedBoolean'
        procMount:
          $ref: '#/components/schemas/BoxedString'
        seccompProfile:
          $ref: '#/components/schemas/SeccompProfile'
        appArmorProfile:
          $ref: '#/components/schemas/AppArmorProfile'
    TestWorkflowConfigSchema:
      type: object
      description: configuration definition
      additionalProperties:
        $ref: '#/components/schemas/TestWorkflowParameterSchema'
    Problem:
      description: problem response in case of error
      type: object
      properties:
        type:
          type: string
          description: Type contains a URI that identifies the problem type.
          example: https://kubeshop.io/testkube/problems/invalidtestname
        title:
          type: string
          description: Title is a short, human-readable summary of the problem type. This title SHOULD NOT change from occurrence to occurrence of the problem, except for purposes of localization.
          example: Invalid test name
        status:
          type: integer
          description: HTTP status code for this occurrence of the problem.
          example: 500
        detail:
          type: string
          description: A human-readable explanation specific to this occurrence of the problem.
          example: Your test name can't contain forbidden characters like "}}}" passed
        instance:
          type: string
          description: A URI that identifies the specific occurrence of the problem. This URI may or may not yield further information if de-referenced.
          example: http://10.23.23.123:8088/tests
    NodeSelectorTerm:
      type: object
      properties:
        matchExpressions:
          type: array
          items:
            $ref: '#/components/schemas/NodeSelectorRequirement'
        matchFields:
          type: array
          items:
            $ref: '#/components/schemas/NodeSelectorRequirement'
    TestWorkflowExecutionConfigValue:
      type: object
      description: configuration values used in the test workflow execution
      properties:
        value:
          type: string
          description: configuration value
        emptyValue:
          type: boolean
          description: configuration value is empty
        defaultValue:
          type: string
          description: configuration value default
        emptyDefaultValue:
          type: boolean
          description: configuration value default is empty
        truncated:
          type: boolean
          description: indicates if the value is truncated
        sensitive:
          type: boolean
          description: marks value as sensitive
    PodDNSConfigOption:
      type: object
      properties:
        name:
          type: string
        value:
          $ref: '#/components/schemas/BoxedString'
    TestWorkflowExecutionSummary:
      type: object
      properties:
        id:
          type: string
          description: unique execution identifier
          format: bson objectId
          example: 62f395e004109209b50edfc1
        groupId:
          type: string
          description: identifier for group of correlated executions
          format: bson objectId
          example: 62f395e004109209b50edfc1
        runnerId:
          type: string
          description: identifier of the runner where it has been executed
        name:
          type: string
          description: execution name
          example: some-workflow-name-1
        number:
          type: integer
          description: sequence number for the execution
        scheduledAt:
          type: string
          format: date-time
          description: when the execution has been scheduled to run
        statusAt:
          type: string
          format: date-time
          description: when the execution result's status has changed last time (queued, passed, failed)
        result:
          $ref: '#/components/schemas/TestWorkflowResultSummary'
        workflow:
          $ref: '#/components/schemas/TestWorkflowSummary'
        tags:
          $ref: '#/components/schemas/TestWorkflowTagValue'
        runningContext:
          description: running context for the test workflow execution (Pro edition only)
          $ref: '#/components/schemas/TestWorkflowRunningContext'
        configParams:
          $ref: '#/components/schemas/TestWorkflowExecutionConfig'
        runtime:
          $ref: '#/components/schemas/TestWorkflowExecutionRuntime'
        reports:
          type: array
          description: generated reports from the steps, like junit
          items:
            $ref: '#/components/schemas/TestWorkflowReport'
        resourceAggregations:
          $ref: '#/components/schemas/TestWorkflowExecutionResourceAggregationsReport'
        silentMode:
          description: execution mode to determine which events to skip
          $ref: '#/components/schemas/SilentMode'
      required:
      - id
      - name
      - workflow
    EnvReference:
      description: Reference to env resource
      type: object
      required:
      - reference
      properties:
        reference:
          $ref: '#/components/schemas/LocalObjectReference'
        mount:
          type: boolean
          description: whether we shoud mount resource
          example: /etc/data
        mountPath:
          type: string
          description: where we shoud mount resource
        mapToVariables:
          type: boolean
          description: whether we shoud map to variables from resource
          default: false
    ResourceFieldRef:
      type: object
      required:
      - resource
      description: 'Selects a resource of the container: only resources limits and requests (limits.cpu, limits.memory, limits.ephemeral-storage, requests.cpu, requests.memory and requests.ephemeral-storage) are currently supported.'
      properties:
        containerName:
          description: 'Container name: required for volumes, optional for env vars'
          type: string
        divisor:
          type: string
          pattern: ^[0-9]+(m|[GMK]i)$
        resource:
          description: 'Required: resource to select'
          type: string
    EnvVarSource:
      type: object
      description: EnvVarSource represents a source for the value of an EnvVar.
      properties:
        configMapKeyRef:
          type: object
          required:
          - key
          description: Selects a key of a ConfigMap.
          properties:
            key:
              description: The key to select.
              type: string
            name:
              description: 'Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names TODO: Add other useful fields. apiVersion, kind, uid?'
              type: string
            optional:
              nullable: true
              description: Specify whether the ConfigMap or its key must be defined
              type: boolean
        fieldRef:
          $ref: '#/components/schemas/FieldRef'
        resourceFieldRef:
          $ref: '#/components/schemas/ResourceFieldRef'
        secretKeyRef:
          type: object
          required:
          - key
          description: Selects a key of a secret in the pod's namespace
          properties:
            key:
              description: The key of the secret to select from.  Must be a valid secret key.
              type: string
            name:
              description: 'Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names TODO: Add other useful fields. apiVersion, kind, uid?'
              type: string
            optional:
              nullable: true
              description: Specify whether the Secret or its key must be defined
              type: boolean
    TestWorkflowTemplateRef:
      type: object
      properties:
        name:
          type: string
          description: TestWorkflowTemplate name to include
        config:
          $ref: '#/components/schemas/TestWorkflowConfigValue'
      required:
      - name
    LabelSelector:
      type: object
      properties:
        matchLabels:
          type: object
          additionalProperties:
            type: string
        matchExpressions:
          type: array
          items:
            $ref: '#/components/schemas/LabelSelectorRequirement'
    VariableType:
      type: string
      enum:
      - basic
      - secret
    SilentMode:
      type: object
      description: controls what aspects of an execution should be silent (not tracked/processed)
      properties:
        webhooks:
          type: boolean
          description: disable webhooks for this execution
          default: false
        insights:
          type: boolean
          description: exclude from insights and analytics dashboards
          default: false
        health:
          type: boolean
          description: exclude from health and flakiness calculations
          default: false
        metrics:
          type: boolean
          description: exclude from prometheus metrics
          default: false
        cdevents:
          type: boolean
          description: disable CDEvents for this execution
          default: false
    AWSElasticBlockStoreVolumeSource:
      description: 'awsElasticBlockStore represents an AWS Disk resource that is attached to a kubelet''s host machine and then exposed to the pod. More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore'
      properties:
        fsType:
          description: 'fsType is the filesystem type of the volume that you want to mount. Tip: Ensure that the filesystem type

# --- truncated at 32 KB (103 KB total) ---
# Full source: https://raw.githubusercontent.com/api-evangelist/kubeshop/refs/heads/main/openapi/kubeshop-test-workflow-with-executions-api-openapi.yml