WorkItemTrackingHttpClientBase.GetWorkItemsAsync Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Overloads
GetWorkItemsAsync(IEnumerable<Int32>, IEnumerable<String>, Nullable<DateTime>, Nullable<WorkItemExpand>, Nullable<WorkItemErrorPolicy>, Object, CancellationToken) |
[Preview API] Returns a list of work items (Maximum 200) |
GetWorkItemsAsync(Guid, IEnumerable<Int32>, IEnumerable<String>, Nullable<DateTime>, Nullable<WorkItemExpand>, Nullable<WorkItemErrorPolicy>, Object, CancellationToken) |
[Preview API] Returns a list of work items (Maximum 200) |
GetWorkItemsAsync(String, IEnumerable<Int32>, IEnumerable<String>, Nullable<DateTime>, Nullable<WorkItemExpand>, Nullable<WorkItemErrorPolicy>, Object, CancellationToken) |
[Preview API] Returns a list of work items (Maximum 200) |
GetWorkItemsAsync(IEnumerable<Int32>, IEnumerable<String>, Nullable<DateTime>, Nullable<WorkItemExpand>, Nullable<WorkItemErrorPolicy>, Object, CancellationToken)
[Preview API] Returns a list of work items (Maximum 200)
public virtual System.Threading.Tasks.Task<System.Collections.Generic.List<Microsoft.TeamFoundation.WorkItemTracking.WebApi.Models.WorkItem>> GetWorkItemsAsync (System.Collections.Generic.IEnumerable<int> ids, System.Collections.Generic.IEnumerable<string> fields = null, Nullable<DateTime> asOf = null, Nullable<Microsoft.TeamFoundation.WorkItemTracking.WebApi.Models.WorkItemExpand> expand = null, Nullable<Microsoft.TeamFoundation.WorkItemTracking.WebApi.Models.WorkItemErrorPolicy> errorPolicy = null, object userState = null, System.Threading.CancellationToken cancellationToken = null);
abstract member GetWorkItemsAsync : seq<int> * seq<string> * Nullable<DateTime> * Nullable<Microsoft.TeamFoundation.WorkItemTracking.WebApi.Models.WorkItemExpand> * Nullable<Microsoft.TeamFoundation.WorkItemTracking.WebApi.Models.WorkItemErrorPolicy> * obj * System.Threading.CancellationToken -> System.Threading.Tasks.Task<System.Collections.Generic.List<Microsoft.TeamFoundation.WorkItemTracking.WebApi.Models.WorkItem>>
override this.GetWorkItemsAsync : seq<int> * seq<string> * Nullable<DateTime> * Nullable<Microsoft.TeamFoundation.WorkItemTracking.WebApi.Models.WorkItemExpand> * Nullable<Microsoft.TeamFoundation.WorkItemTracking.WebApi.Models.WorkItemErrorPolicy> * obj * System.Threading.CancellationToken -> System.Threading.Tasks.Task<System.Collections.Generic.List<Microsoft.TeamFoundation.WorkItemTracking.WebApi.Models.WorkItem>>
Parameters
- ids
- IEnumerable<Int32>
The comma-separated list of requested work item ids. (Maximum 200 ids allowed).
- fields
- IEnumerable<String>
Comma-separated list of requested fields
- expand
- Nullable<WorkItemExpand>
The expand parameters for work item attributes. Possible options are { None, Relations, Fields, Links, All }.
- errorPolicy
- Nullable<WorkItemErrorPolicy>
The flag to control error policy in a bulk get work items request. Possible options are {Fail, Omit}.
- userState
- Object
- cancellationToken
- CancellationToken
The cancellation token to cancel operation.
Returns
Applies to
GetWorkItemsAsync(Guid, IEnumerable<Int32>, IEnumerable<String>, Nullable<DateTime>, Nullable<WorkItemExpand>, Nullable<WorkItemErrorPolicy>, Object, CancellationToken)
[Preview API] Returns a list of work items (Maximum 200)
public virtual System.Threading.Tasks.Task<System.Collections.Generic.List<Microsoft.TeamFoundation.WorkItemTracking.WebApi.Models.WorkItem>> GetWorkItemsAsync (Guid project, System.Collections.Generic.IEnumerable<int> ids, System.Collections.Generic.IEnumerable<string> fields = null, Nullable<DateTime> asOf = null, Nullable<Microsoft.TeamFoundation.WorkItemTracking.WebApi.Models.WorkItemExpand> expand = null, Nullable<Microsoft.TeamFoundation.WorkItemTracking.WebApi.Models.WorkItemErrorPolicy> errorPolicy = null, object userState = null, System.Threading.CancellationToken cancellationToken = null);
abstract member GetWorkItemsAsync : Guid * seq<int> * seq<string> * Nullable<DateTime> * Nullable<Microsoft.TeamFoundation.WorkItemTracking.WebApi.Models.WorkItemExpand> * Nullable<Microsoft.TeamFoundation.WorkItemTracking.WebApi.Models.WorkItemErrorPolicy> * obj * System.Threading.CancellationToken -> System.Threading.Tasks.Task<System.Collections.Generic.List<Microsoft.TeamFoundation.WorkItemTracking.WebApi.Models.WorkItem>>
override this.GetWorkItemsAsync : Guid * seq<int> * seq<string> * Nullable<DateTime> * Nullable<Microsoft.TeamFoundation.WorkItemTracking.WebApi.Models.WorkItemExpand> * Nullable<Microsoft.TeamFoundation.WorkItemTracking.WebApi.Models.WorkItemErrorPolicy> * obj * System.Threading.CancellationToken -> System.Threading.Tasks.Task<System.Collections.Generic.List<Microsoft.TeamFoundation.WorkItemTracking.WebApi.Models.WorkItem>>
Parameters
- project
- Guid
Project ID
- ids
- IEnumerable<Int32>
The comma-separated list of requested work item ids. (Maximum 200 ids allowed).
- fields
- IEnumerable<String>
Comma-separated list of requested fields
- expand
- Nullable<WorkItemExpand>
The expand parameters for work item attributes. Possible options are { None, Relations, Fields, Links, All }.
- errorPolicy
- Nullable<WorkItemErrorPolicy>
The flag to control error policy in a bulk get work items request. Possible options are {Fail, Omit}.
- userState
- Object
- cancellationToken
- CancellationToken
The cancellation token to cancel operation.
Returns
Applies to
GetWorkItemsAsync(String, IEnumerable<Int32>, IEnumerable<String>, Nullable<DateTime>, Nullable<WorkItemExpand>, Nullable<WorkItemErrorPolicy>, Object, CancellationToken)
[Preview API] Returns a list of work items (Maximum 200)
public virtual System.Threading.Tasks.Task<System.Collections.Generic.List<Microsoft.TeamFoundation.WorkItemTracking.WebApi.Models.WorkItem>> GetWorkItemsAsync (string project, System.Collections.Generic.IEnumerable<int> ids, System.Collections.Generic.IEnumerable<string> fields = null, Nullable<DateTime> asOf = null, Nullable<Microsoft.TeamFoundation.WorkItemTracking.WebApi.Models.WorkItemExpand> expand = null, Nullable<Microsoft.TeamFoundation.WorkItemTracking.WebApi.Models.WorkItemErrorPolicy> errorPolicy = null, object userState = null, System.Threading.CancellationToken cancellationToken = null);
abstract member GetWorkItemsAsync : string * seq<int> * seq<string> * Nullable<DateTime> * Nullable<Microsoft.TeamFoundation.WorkItemTracking.WebApi.Models.WorkItemExpand> * Nullable<Microsoft.TeamFoundation.WorkItemTracking.WebApi.Models.WorkItemErrorPolicy> * obj * System.Threading.CancellationToken -> System.Threading.Tasks.Task<System.Collections.Generic.List<Microsoft.TeamFoundation.WorkItemTracking.WebApi.Models.WorkItem>>
override this.GetWorkItemsAsync : string * seq<int> * seq<string> * Nullable<DateTime> * Nullable<Microsoft.TeamFoundation.WorkItemTracking.WebApi.Models.WorkItemExpand> * Nullable<Microsoft.TeamFoundation.WorkItemTracking.WebApi.Models.WorkItemErrorPolicy> * obj * System.Threading.CancellationToken -> System.Threading.Tasks.Task<System.Collections.Generic.List<Microsoft.TeamFoundation.WorkItemTracking.WebApi.Models.WorkItem>>
Parameters
- project
- String
Project ID or project name
- ids
- IEnumerable<Int32>
The comma-separated list of requested work item ids. (Maximum 200 ids allowed).
- fields
- IEnumerable<String>
Comma-separated list of requested fields
- expand
- Nullable<WorkItemExpand>
The expand parameters for work item attributes. Possible options are { None, Relations, Fields, Links, All }.
- errorPolicy
- Nullable<WorkItemErrorPolicy>
The flag to control error policy in a bulk get work items request. Possible options are {Fail, Omit}.
- userState
- Object
- cancellationToken
- CancellationToken
The cancellation token to cancel operation.
Returns
Applies to
Feedback
https://aka.ms/ContentUserFeedback.
Coming soon: Throughout 2024 we will be phasing out GitHub Issues as the feedback mechanism for content and replacing it with a new feedback system. For more information see:Submit and view feedback for