Table of contents
Schedules
Download API definition:
This API is a Technical Preview and is available for testing purposes only. Do not use in production.
GET https://dev-api.bentley.com/schedules/{scheduleId}/tasks/{taskId}

Gets the details of a Task.

Authentication

Requires Authorization header with valid Bearer token for scope itwin-platform.

For more documentation on authorization and how to get access token visit OAUTH2 Authorization page.

Task Constraint Types

Each Task has a constraint type. Task Constraints determine the rules under which a Task can be started and rescheduled.

  • NoConstraint: The Task can be set to start at any date/time you choose.
  • CannotReschedule: The Task cannot have its start or finish date changed.
  • StartAsap: The Task will automatically spring back to start as soon as possible (ASAP), i.e to its Early Start Date.
  • StartAlap: The Task will automatically spring forward to start as late as possible (ALAP), i.e to its Late Start Date.
  • StartOn: Tasks Dependencies have a greater priority than the specified Start Date such that the Task may actually start at ANY time.
  • StartAfter: Tasks Dependencies have a greater priority than the specified Start Date such that the Task may actually start On or After the specified Start Date.
  • StartBefore: Tasks Dependencies have a greater priority than the specified Start Date such that the Task may actually start On or Before the specified Start Date.
  • StartBetween: Tasks Dependencies have a greater priority than the specified Start Date such that the Task may actually start at between the Late Start Date and the Early Start Date.
  • FinishOn: Tasks Dependencies have a greater priority than the specified Finish Date such that the Task may actually finish at ANY time.
  • FinishAfter: Tasks Dependencies have a greater priority than the specified Finish Date such that the Task may actually finish On or After the specified Finish Date.
  • FinishBefore: Tasks Dependencies have a greater priority than the specified Finish Date such that the Task may actually finish On or Before the specified Finish Date.
  • FinishBetween: Tasks Dependencies have a greater priority than the specified Finish Date such that the Task may actually finish between the Late Finish Date and the Early Finish Date.
  • MandatoryStart: The defined Start Date has a greater priority than any Task dependency to ensure that the Task starts on the specified date.
  • MandatoryFinish: The defined Finish Date has a greater priority than any Task dependency to ensure that the Task finishes on the specified date.
  • WorkBetween: Tasks Dependencies have a greater priority than the specified Start and Finish Dates such that the Task may actually start On or After the specified Start Date and finish On or Before the specified Finish Date.
  • WorkOut: Tasks Dependencies have a greater priority than the specified Start and Finish Dates such that the Task may actually start On or Before the specified Start Date and finish On or After the specified Finish Date.

Task Progress Types

Each Task has a progress type, which specifies how progress is determined.

  • Automatic: Percent Complete is tied to duration and calculated automatically based on Task dates, and current time. Changing the Percent Complete value leads to creation of a delay or advance report.
  • Manual: Percent Complete should be set manually. Changing the Percent Complete has no effect on other parameters.
  • Duration: Percent Complete is tied to duration, calculated based on planned and remaining duration. Changing the Percent Complete leads to recalculation of remaining duration.
  • Physical: Percent Complete is tied to Physical Quantity, calculated as Actual Physical Quantity / (Actual Physical Quanitity + Remaining Physical Quantity). Changing the Percent Complete leads to recalculation of actual Physical Quantity.
  • Unit: Percent Complete is tied to units of assigned equipment and human resources, calculated based on actual and remaining units of assigned equipment and human resources (material and location resources are not taken into account). Changing the Percent Complete leads to recalculation of actual units.

Task Duration Types

Each Task has a duration type, which specifies how Task Duration is determined.

  • Fixed: User enters Task Duration manually.
  • PhysicalQuantityDependent: Task Duration is calculated based on user-entered Physical Quantity (eg. square feet of wall to paint, cubic metres of concrete to pour) and assigned production rate Rule.
  • ResourceUnitDependent: Task Duration is calculated based on required man or machine-hours and Utilisation Percentage for a selected Driving Resource.

Task Types

Tasks can be of differing types. The following Task types have different behaviors:

  • Work: The default Task type. Work represents an expenditure of effort and resources achieving the Task. Work type Tasks have a Start, Finish and a Duration.
  • StartKeyDate: A Project Milestone - setting a Task as a Key Date will also change its representation in the Gantt Chart to a diamond, and give the Task a zero duration. Start Key Dates have no Finish Date or Duration.
  • FinishKeyDate: A Project Milestone - setting a Task as a Key Date will also change its representation in the Gantt Chart to a diamond, and give the Task a zero duration. Finish Key Dates have no Start Date or Duration.
  • ShortHammock: Spans the shortest duration between all its predecessor and successor Tasks. The Start, Finish, and Duration of the Short Hammock is derived from its predecessor and successor Tasks and cannot be edited directly.
  • LongHammock: Spans the longest duration between all its predecessor and successor Tasks. The Start, Finish, and Duration of the Long Hammock is derived from its predecessor and successor Tasks and cannot be edited directly

The remaining Task Types behave the same as the Work type and can be used to help label Tasks.

Rate limits

All iTwin Platform API operations have a rate limit. For more documentation on that visit Rate limits and quotas page.

Request parameters

Name
Required?
Description
taskId
Yes

The unique identifier of the Task.

scheduleId
Yes

The unique identifier of the Schedule.

Request headers

Name
Required?
Description
If-None-Match
No

A header that makes the request conditional. If the ETag of the requested resource or resource collection matches the provided value, a 304 (Not Modified) response is returned. For more information see the official documentation.

Authorization
Yes

OAuth access token with itwin-platform scope

Accept
Yes

Setting to application/vnd.bentley.itwin-platform.v1+json is recommended.

Response 200 OK

OK

json
{
    "task": {
        "actualDuration": 230400,
        "actualFinish": "2019-11-15T12:00:00Z",
        "actualPhysicalQuantity": 0,
        "actualStart": "2019-11-04T12:00:00Z",
        "constraintEarlyDate": "2019-11-04T08:00:00Z",
        "constraintLateDate": null,
        "constraintType": "StartAfter",
        "durationType": "Fixed",
        "estimatedRate": 0,
        "expectedFinish": null,
        "id": "fc3673d9-e385-4031-abbe-663535a329f5",
        "isWbs": false,
        "name": "Demolish Old Building",
        "parentId": "e3e4f597-8b58-4c0a-8931-1f3f55a7b34b",
        "percentComplete": 100,
        "physicalQuantity": 0,
        "physicalQuantityUnit": "Unknown",
        "plannedDuration": 144000,
        "plannedFinish": "2019-12-06T05:00:00Z",
        "plannedStart": "2019-12-02T08:00:00Z",
        "progressType": "Duration",
        "remainingDuration": null,
        "remainingPhysicalQuantity": 0,
        "status": "Finished",
        "statusId": "20cf6c69-b9df-422a-a509-a164c59d668b",
        "type": "Work",
        "url": "",
        "userDefinedId": "D256"
    }
}

Response headers

Name
Description
ETag

A header that identifies a specific version of a resource or resource collection. For more information see the official documentation.

Response 401 Unauthorized

This response indicates that request lacks valid authentication credentials. Access token might not been provided, issued by the wrong issuer, does not have required scopes or request headers were malformed.

json
{
    "error": {
        "code": "HeaderNotFound",
        "message": "Header Authorization was not found in the request. Access denied."
    }
}

Response 404 Not Found

This response indicates that the provided Task or Schedule is not available.

json
{
    "error": {
        "code": "ScheduleNotFound",
        "message": "Requested Schedule is not available.",
        "target": "scheduleId"
    }
}

Response 429 Too many requests

This response indicates that the client sent more requests than allowed by this API for the current tier of the client.

json
{
    "error": {
        "code": "RateLimitExceeded",
        "message": "The client sent more requests than allowed by this API for the current tier of the client."
    }
}

Response headers

Name
Description
retry-after

Number of seconds to wait until client is allowed to make more requests.

Resource Unit Type

The possible unit types for resources.

Name
Type
Description
CubicFeet
String
CubicMeter
String
Liter
String
Millimeter
String
Meter
String
Feet
String
Each
String
Pair
String
Dozen
String
Gross
String
SqFoot
String
SqYard
String
SqMeter
String
Pound
String
Gram
String
Kilo
String
Bag
String
Box
String
Bucket
String
Bundle
String
Card
String
Carton
String
Coil
String
Pack
String
Pegs
String
Length
String
Outer
String
Pallet
String
Roll
String
Sachet
String
Set
String
Sheet
String
Ton
String
Person
String
Item
String
CubicYard
String
MetricTon
String
Hour
String
LinearMeter
String
Unknown
String

Task

Representation of a Task.

Name
Type
Description
actualDuration
Int32, null

The amount of time actually consumed in performing the activity. The value is a timestamp of seconds.

actualFinish
Date-time, null

The date on which the activity actually finished.

actualPhysicalQuantity
Double

The physical quantity completed to date.

actualStart
Date-time, null

The date on which the activity is actually started.

comment
String, null

The comment of the Task.

constraintEarlyDate
Date-time, null

Early date in the date range for Task Constraint Types: StartBetween, FinishBetween, WorkBetween, WorkOut.

constraintLateDate
Date-time, null

Late date in the date range for Task Constraint Types: StartBetween, FinishBetween, WorkBetween, WorkOut.

constraintType

Task Constraints determine the rules under which a Task can be started and rescheduled.

durationType

The Duration Type of a Task specifies how the Task duration will be calculated.

estimatedRate
Double

The estimated production rate to accomplish the given Physical Quantity in the given Duration (when Duration Type is Fixed).

expectedFinish
Date-time, null

The expected Task End Date, based upon the Actual Start plus the Percent Complete and Remaining Duration.

id
String

The unique identifier of the Task.

isWbs
Boolean

Is Task a Work Breakdown Structure (WBS).

name
String

The name of the Task.

parentId
String, null

The unique identifier of the parent Task.

percentComplete
Int32

The due level of progress for the Task as a percentage of its overall duration. Depends on the Progress Type selected.

physicalQuantity
Double

The total quantity required by the Task, used to calculate the duration of a Physical Quantity Dependent Task.

physicalQuantityUnit

The unit used to measure the Physical Quantity assigned to the Task.

plannedDuration
Int32

The time allotted to complete a Task. It can only change for Tasks with Planned Status. The value is a timestamp of seconds.

plannedFinish
Date-time

The Finish Date according to the current project schedule. It can only change for Tasks with Planned Status.

plannedStart
Date-time

The Start Date according to the current project schedule. It can only change for Tasks with Planned Status.

progressType

This value specifies way that Progress is determined.

remainingDuration
Int32, null

The amount of work time required to complete the Task. It is automatically calculated from the Percent Complete or can be entered manually once a Task has been Started. The value is a timestamp of seconds.

remainingPhysicalQuantity
Double

The physical quantity required to complete the Task.

status

The current Task status.

statusId
String

The unique identifier of the Task Status.

type

Task Type provides a categorization (or classification) of project Tasks.

url
String

A URL associated with the Task.

userDefinedId
String

A unique Task Id defined by the user.

Task Constraint Type

Task Constraints determine the rules under which a Task can be started and rescheduled. See the Task Constraint Types section for details.

Name
Type
Description
NoConstraint
String
CannotReschedule
String
StartAsap
String
StartAlap
String
StartOn
String
StartAfter
String
StartBefore
String
StartBetween
String
FinishOn
String
FinishAfter
String
FinishBefore
String
FinishBetween
String
MandatoryStart
String
MandatoryFinish
String
WorkBetween
String
WorkOut
String
Unknown
String

Task Duration Type

The Task duration type value specifies way that Task Duration is determined. See the Task Duration Types section for details.

Name
Type
Description
Fixed
String
PhysicalQuantityDependent
String
ResourceUnitsDependent
String
Unknown
String

Task Progress Type

The Task progress type value specifies way that Task Progress is determined. See the Task Progress Types section for details.

Name
Type
Description
Automatic
String
Manual
String
Duration
String
Physical
String
Unit
String
Unknown
String

Task Response

Container for Task object.

Name
Type
Description
task

Task Properties.

Task Status Type

Task status type specifies the current status of the Task.

Name
Type
Description
Planned
String
Started
String
Finished
String
Unknown
String

Task Type

Task Type provides a categorization (or classification) of project Tasks. See the Task Types section for details.

Name
Type
Description
Work
String
StartKeyDate
String
FinishKeyDate
String
ShortHammock
String
LongHammock
String
Rfi
String
ChangeOrder
String
Testing
String
Delivery
String
Meeting
String
Rework
String
Design
String
Maintenance
String
Manufacture
String
Storage
String
Purchase
String
Receive
String
Delay
String
WeatherDelay
String
Unknown
String

Error

Contains error information.

Name
Type
Description
code
String

One of a server-defined set of error codes.

message
String

A human-readable representation of the error.

target
String, null

The target of the error.

Error Response

Gives details for an error that occurred while handling the request. Note that clients MUST NOT assume that every failed request will produce an object of this schema, or that all of the properties in the response will be non-null, as the error may have prevented this response from being constructed.

Name
Type
Description
error

Error information.

Was this page helpful?