Edit an automation run

This call renames an automation run.

Request

https://api.sbgenomics.com/v2/automation/runs/{run-id}
https://eu-api.sbgenomics.com/v2/automation/runs/{run-id}

Example request

PATCH /v2/automation/runs/383b8953-5b9f-47d2-94c4-0cdddf393e9f HTTP/1.1
Host: api.sbgenomics.com
X-SBG-Auth-Token: 697195687ad14d65bb74d5d5c4f536d3b
X-SBG-Advance-Access: advance
Content-Type: application/json

{
    "name": "New name"
}
curl --location --request PATCH 'https://api.sbgenomics.com/v2/automation/runs/383b89543-5b9f-47d2-94c4-0cdddf393e9f' \
--header 'X-SBG-Auth-Token: 697195687ab14d5bb74d5d5c4f536d3b' \
--header 'X-SBG-Advance-Access: advance' \
--header 'Content-Type: application/json' \
--data-raw '{
    "name": "New name"
}'
from sevenbridges import Api

api = Api(url='https://api.sbgenomics.com/v2',
          token='3259c50e1ac5426ea8f1273259740f74',
          advance_access=True)

run = api.automation_runs.get(id='383b8953-5b9f-47d2-94c4-0cdddf393e9f')

# edit an automation run
run.name = 'New name'

# send PATCH request to SB API
run.save()

print(run.name)

Header Fields

Name

Description

X-SBG-Auth-Token
required

Your Seven Bridges Platform authentication token.

Content-Type
required

application/json

X-SBG-Advance-Access
required

advance

Request body

Name

Data type

Description

name
required

string

The new name for the automation run.

Path parameters

Name

Description

run_id

The ID of the automation you are editing.

Response

See a list of Seven Bridges Platform-specific response codes that may be contained in the body of the response.

Example response body

{
    "id": "e5ed2ee7-8f3c-44e9-bc78-4cabd2ee441f",
    "href": "https://api.sbgenomics.com/v2/automation/runs/e5ed2ee7-8f3c-44e9-bc78-4cabd2ee441f",
    "automation": {
        "id": "40a284d9-c0da-441c-8799-3de8d85bbd8d",
        "href": "https://api.sbgenomics.com/v2/automation/automations/40a284d9-c0da-441c-8799-3de8d85bbd8d",
        "name": "Automation 1",
        "description": "This is the description for the Automation 1",
        "owner": "rfranklin",
        "created_by": "rfranklin",
        "created_on": "2018-08-27T18:12:13.000+02:00",
        "modified_on": "2018-08-27T16:12:13.000000",
        "modified_by": "rfranklin"

    },
    "inputs": {
        "x": 1,
        "y": 2,
        "z": 3
    },
    "settings": null,
    "status": "ABORTED",
    "message": "Automation \"state.json\" and/or \"automation.log\" not found.",
    "package": {
        "id": "c291f294-f46b-4a9e-a702-e9fb2fbf751f",
        "automation": "40a284d9-c0da-441c-8799-3de8d85bbd8d",
        "version": "1.0.0",
        "location": "5b84276ee4b0e7481db7d94d",
        "created_by": "fcrick",
        "created_on": "2018-08-27T16:32:23.072Z"
    },
    "created_on": "2018-08-30T16:10:33.203Z",
    "start_time": "2018-08-30T16:10:36.247Z",
    "end_time": "2018-08-30T16:10:44.181Z",
    "resumed_from": null,
    "created_by": "rfranklin",
    "execution_details": null
}
}