PATCH
/
apiKey
/
v2
/
test-targets
/
{testTargetId}
/
test-cases
/
{testCaseId}
Update a test case
curl --request PATCH \
  --url https://app.octomind.dev/api/apiKey/v2/test-targets/{testTargetId}/test-cases/{testCaseId} \
  --header 'Content-Type: application/json' \
  --header 'X-API-Key: <api-key>' \
  --data '{
  "elements": [
    {
      "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
      "index": 123,
      "interaction": {
        "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
        "action": "EXTRACT",
        "calledWith": "<string>",
        "testCaseElementId": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
      },
      "assertion": {
        "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
        "expectation": "VISIBLE",
        "calledWith": "<string>",
        "testCaseElementId": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
      },
      "selectors": [
        {
          "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
          "index": 123,
          "selector": "<string>",
          "selectorType": "TEXT",
          "options": {},
          "testCaseElementId": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
        }
      ],
      "testCaseId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
      "ignoreFailure": true
    }
  ],
  "description": "<string>",
  "entryPointUrlPath": "<string>",
  "status": "ENABLED",
  "runStatus": "ON",
  "folderName": "<string>",
  "interactionStatus": "NEW",
  "createBackendDiscoveryPrompt": "<string>",
  "assignedTagNames": [
    "<string>"
  ],
  "externalId": "<string>"
}'
{
  "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "testTargetId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "description": "<string>",
  "status": "ENABLED",
  "runStatus": "ON",
  "createdAt": "2023-11-07T05:31:56Z",
  "updatedAt": "2023-11-07T05:31:56Z",
  "entryPointUrlPath": "<string>",
  "elements": [
    {}
  ],
  "folderId": "<string>",
  "externalId": "<string>",
  "tags": [
    "<string>"
  ]
}

Authorizations

X-API-Key
string
header
required

Path Parameters

testTargetId
string<uuid>
required

The ID of the test target

testCaseId
string<uuid>
required

The ID of the test case to update

Body

application/json
elements
object[]
description
string
entryPointUrlPath
string | null
status
enum<string>
Available options:
ENABLED,
DISABLED,
DRAFT,
OUTDATED,
PROVISIONAL
runStatus
enum<string>
Available options:
ON,
OFF
folderName
string | null
interactionStatus
enum<string>
Available options:
NEW,
EDITED,
APPROVED,
REJECTED
createBackendDiscoveryPrompt
string
assignedTagNames
string[]
externalId
string | null

Response

Updated test case

id
string<uuid>
testTargetId
string<uuid>
description
string
status
enum<string>
Available options:
ENABLED,
DISABLED,
DRAFT,
OUTDATED,
PROVISIONAL
runStatus
enum<string>
Available options:
ON,
OFF
createdAt
string<date-time>
updatedAt
string<date-time>
entryPointUrlPath
string | null
elements
object[]
folderId
string | null
externalId
string | null
tags
string[]