Skip to main content
GET
Read task source

Authorizations

Authorization
string
header
required

Use a JWT bearer token or a Veryfront API key in the Authorization header.

Path Parameters

project_reference
string
required

Project slug, UUID, or domain that identifies the project.

task_id
string
required

Task identifier

Query Parameters

source_target_kind
string

Source to read: project or preview_branch. Defaults to runtime_target_kind, then project.

target_branch_id
string<uuid> | null

Preview branch to use when the target kind is preview_branch.

runtime_target_kind
enum<string> | null

Used as the source target kind when source_target_kind is omitted.

Available options:
main_branch,
environment,
preview_branch,
null
target_environment_id
string<uuid> | null

Not supported for source reads; a non-null value is rejected.

Response

Task document

Task definition including editable source content.

id
string
required

Task identifier.

name
string
required

Human-readable task name.

description
string | null
required

Short description of what the task does.

target
string
required

Execution target that implements the task.

source_path
string
required

Source file path where the task definition lives.

source
string
required

Task source code or structured document content.

schedulable
boolean
required

Whether the task can be used from schedulers.

edit_mode
enum<string>
required

Editing mode supported for the task definition.

Available options:
structured,
source_only
source_only_reasons
string[]
required

Reasons why the task can only be edited as raw source, when applicable.