Skip to content
Get started

Task Source

Delete
projects.task_source.delete(strproject_id) -> TaskSourceDeleteResponse
DELETE/projects/{projectId}/task-source
Retrieve
projects.task_source.retrieve(strproject_id) -> TaskSourceRetrieveResponse
GET/projects/{projectId}/task-source
Test
projects.task_source.test(strproject_id, TaskSourceTestParams**kwargs) -> TaskSourceTestResponse
POST/projects/{projectId}/task-source/test
Update
projects.task_source.update(strproject_id, TaskSourceUpdateParams**kwargs) -> TaskSourceUpdateResponse
PUT/projects/{projectId}/task-source
ModelsExpand Collapse
class TaskSourceDeleteResponse: …
deleted: bool

Whether a task source was configured and is now deleted

class TaskSourceRetrieveResponse: …
task_source: TaskSource

A project’s task source. The Authorization header value is never returned.

has_authorization: bool

Whether an Authorization header value is stored

mapping: TaskSourceMapping

Where the tasks sit in the response, and which fields to read

id: str

Field of each task that holds its id (example: “code”). The id must be 1 to 256 printable ASCII characters; a number is converted to a string.

maxLength256
minLength1
tasks_path: str

Dot-separated path to the array of tasks in the response (example: “data.items”). An empty string means the response is the array itself.

maxLength256
name: Optional[str]

Field of each task that holds its name (example: “title”)

maxLength256
minLength1
status: Optional[str]

Field of each task that holds its status (example: “state”)

maxLength256
minLength1
method: Literal["GET", "POST"]

HTTP method used to call the task source

One of the following:
"GET"
"POST"
url: str

https URL of the task source

body: Optional[str]

JSON body sent with POST

parameters: Optional[Dict[str, str]]

Query string parameters sent to the task source

class TaskSourceTestResponse: …
candidates: List[Candidate]

The arrays of objects in the response, to build the mapping. A 400 from a mapping that does not fit carries them as details.candidates.

count: float

Number of entries in the array

fields: List[CandidateField]

String and number fields of the entries

is_id_candidate: bool

Whether every entry holds a distinct, valid task id at this path

path: str

Dot-separated path in an entry, for mapping.id, name or status

sample: str

The value of the first entry that has one

tasks_path: str

Value for mapping.tasksPath; empty when the response is the array itself

exchange: Exchange

The test call. A 400 from a failed call carries it as details.exchange.

request: ExchangeRequest

The request Scenario sent to the task source, placeholders filled

headers: Dict[str, str]

Headers set by Scenario; the Authorization value is masked

method: Literal["GET", "POST"]

HTTP method Scenario uses to call a task source.

One of the following:
"GET"
"POST"
url: str

Full URL, query string included

body: Optional[str]

Body sent with POST

duration_ms: Optional[float]

Time from sending the request to reading the whole response

response: Optional[ExchangeResponse]

Absent when no response came back (DNS, TLS, timeout): the error explains why

body: str

Raw response body, truncated at 65,536 characters

headers: Dict[str, str]

Response headers; a Set-Cookie value is masked

status: float
is_body_truncated: Optional[bool]

Whether body was truncated

tasks: List[Task]

The first tasks read with the mapping; empty without a mapping

id: str

The task id, to send in the X-Scenario-Task-Id header

name: Optional[str]

The task name

status: Optional[str]

The task status

class TaskSourceUpdateResponse: …
exchange: Exchange

The validation call. A 400 from a failed call carries it as details.exchange.

request: ExchangeRequest

The request Scenario sent to the task source, placeholders filled

headers: Dict[str, str]

Headers set by Scenario; the Authorization value is masked

method: Literal["GET", "POST"]

HTTP method Scenario uses to call a task source.

One of the following:
"GET"
"POST"
url: str

Full URL, query string included

body: Optional[str]

Body sent with POST

duration_ms: Optional[float]

Time from sending the request to reading the whole response

response: Optional[ExchangeResponse]

Absent when no response came back (DNS, TLS, timeout): the error explains why

body: str

Raw response body, truncated at 65,536 characters

headers: Dict[str, str]

Response headers; a Set-Cookie value is masked

status: float
is_body_truncated: Optional[bool]

Whether body was truncated

tasks: List[Task]

The first tasks the task source returned during the validation call

id: str

The task id, to send in the X-Scenario-Task-Id header

name: Optional[str]

The task name

status: Optional[str]

The task status

task_source: TaskSource

A project’s task source. The Authorization header value is never returned.

has_authorization: bool

Whether an Authorization header value is stored

mapping: TaskSourceMapping

Where the tasks sit in the response, and which fields to read

id: str

Field of each task that holds its id (example: “code”). The id must be 1 to 256 printable ASCII characters; a number is converted to a string.

maxLength256
minLength1
tasks_path: str

Dot-separated path to the array of tasks in the response (example: “data.items”). An empty string means the response is the array itself.

maxLength256
name: Optional[str]

Field of each task that holds its name (example: “title”)

maxLength256
minLength1
status: Optional[str]

Field of each task that holds its status (example: “state”)

maxLength256
minLength1
method: Literal["GET", "POST"]

HTTP method used to call the task source

One of the following:
"GET"
"POST"
url: str

https URL of the task source

body: Optional[str]

JSON body sent with POST

parameters: Optional[Dict[str, str]]

Query string parameters sent to the task source