Update
PUT/projects/{projectId}/task-source
Create or replace the project’s task source. Scenario calls the endpoint first and saves it only if the response holds tasks it can read with the mapping. The Authorization value is stored encrypted; null removes it. Enterprise only, team admins only.
Body ParametersJSON
url: string
https URL of the task source. It may contain the placeholders
{user.email}, {user.id} and {project.id}, replaced on each call.
Never put a credential in it: only authorization is stored as a secret.
maxLength4096
Update
curl https://api.cloud.scenario.com/v1/projects/$PROJECT_ID/task-source \
-X PUT \
-H 'Content-Type: application/json' \
-u "$SCENARIO_SDK_API_KEY:SCENARIO_SDK_API_SECRET" \
-d '{
"mapping": {
"id": "x",
"tasksPath": "tasksPath"
},
"method": "GET",
"url": "url"
}'{
"exchange": {
"request": {
"headers": {
"foo": "string"
},
"method": "GET",
"url": "url",
"body": "body"
},
"durationMs": 0,
"response": {
"body": "body",
"headers": {
"foo": "string"
},
"status": 0,
"isBodyTruncated": true
}
},
"tasks": [
{
"id": "id",
"name": "name",
"status": "status"
}
],
"taskSource": {
"hasAuthorization": true,
"mapping": {
"id": "x",
"tasksPath": "tasksPath",
"name": "x",
"status": "x"
},
"method": "GET",
"url": "url",
"body": "body",
"parameters": {
"foo": "string"
}
}
}Returns Examples
{
"exchange": {
"request": {
"headers": {
"foo": "string"
},
"method": "GET",
"url": "url",
"body": "body"
},
"durationMs": 0,
"response": {
"body": "body",
"headers": {
"foo": "string"
},
"status": 0,
"isBodyTruncated": true
}
},
"tasks": [
{
"id": "id",
"name": "name",
"status": "status"
}
],
"taskSource": {
"hasAuthorization": true,
"mapping": {
"id": "x",
"tasksPath": "tasksPath",
"name": "x",
"status": "x"
},
"method": "GET",
"url": "url",
"body": "body",
"parameters": {
"foo": "string"
}
}
}