Set the estimations, the dates and the other values of the tasks of a task type from a CSV file. Each line gives one entity. The columns are Parent, Entity, Estimation, Drawings, Start date, Due date, Difficulty and the names of the task metadata descriptors of the task type. The route changes only the tasks of the episode. Use main for the entities without episode and all for every entity of the project. For an asset task type, Parent is the asset type and Entity is the asset, among the assets of the episode and the ones cast into it. For a shot task type, Parent is the sequence and Entity is the shot, among the shots of the episode. For a sequence or an edit task type, Entity is the sequence or the edit, among the ones of the episode. Parent is empty or the name of the episode. With main, Parent is empty. With all, Parent names the episode, or is empty to match any episode. For an episode task type, Entity is the episode, and the route ignores Parent and the episode of the route. When several entities match a line, the ones with the exact name win, then the ones that are not canceled, then the assets of the episode over the ones cast into it. If a line still matches several entities, the route refuses it. The route does not support concept task types. The Estimation column is in hours when the organisation shows durations in hours, in days otherwise. Dates use the YYYY-MM-DD format. If Due date is empty and Start date and Estimation are set, the route computes the due date from them. Send the CSV file in a multipart form. The route finds the separator of the file. Each line is imported in order. If a line is not valid, the import stops. You must be an administrator, a manager of the project, or a supervisor of the project. A supervisor must have no department, or the department of the task type must be one of their departments.
Path parameters
-
Unique identifier of the project
-
Unique identifier of the task type
-
Unique identifier of the episode, or main, or all. Another value gives a 400.
curl -X POST "http://api.example.com/import/csv/projects/a24a6ea4-ce75-4665-a070-57453082c25/episodes/c24a6ea4-ce75-4665-a070-57453082c25/task-types/b24a6ea4-ce75-4665-a070-57453082c25/estimations" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Accept: application/json"
import requests
url = "http://api.example.com/import/csv/projects/a24a6ea4-ce75-4665-a070-57453082c25/episodes/c24a6ea4-ce75-4665-a070-57453082c25/task-types/b24a6ea4-ce75-4665-a070-57453082c25/estimations"
headers = {
"Authorization": "Bearer YOUR_API_TOKEN",
"Accept": "application/json"
}
params = {}
payload = None
response = requests.post(
url,
headers=headers,
params=params,
json=payload
)
response.raise_for_status()
if response.content:
print(response.json())
[
{}
]
{
"error": true,
"message": "string",
"line_number": 42,
"imported_rows": 42
}