workflowSource

Read the editable source behind one workflow before changing it; returns the workflow source document with its source text, edit mode and the reasons it can only be edited as source. Requires project.runs.read.

Arguments

  • projectReferenceString!required

  • workflowIdString!required

  • inputSourceReadSelectorInput

  • input.sourceTargetKindWriteTargetKind

    The source to read; default runtimeTargetKind, else project. One of project, preview_branch.

  • input.runtimeTargetKindRuntimeTargetKind

    Used as the source to read when sourceTargetKind is omitted. One of main_branch, environment, preview_branch.

  • input.targetBranchIdID

    Required with the kind preview_branch.

  • input.targetEnvironmentIdID

    Not supported for source reads; a non-null value is refused as invalid_input.

Responses

query WorkflowSource($projectReference: String!, $workflowId: String!) {  workflowSource(projectReference: $projectReference, workflowId: $workflowId) {    id    name    description    target    sourcePath    source    version    schedulable    editMode    sourceOnlyReasons  }}
{  "data": {    "workflowSource": {      "id": "string",      "name": "string",      "description": "string",      "target": "string",      "sourcePath": "string",      "source": "string",      "version": "string",      "schedulable": false,      "editMode": "structured",      "sourceOnlyReasons": [        "string"      ]    }  }}

The WorkflowSource! in data.workflowSource.