Hierarchy (View Summary)

Implements

Constructors

Properties

Methods

addComment createAcceptHeader createAttachment createCommentReaction createField createOrUpdateClassificationNode createQuery createRequestOptions createTemplate createWorkItem deleteClassificationNode deleteComment deleteCommentReaction deleteField deleteQuery deleteTag deleteTemplate deleteWorkItem destroyWorkItem exportWorkItemTypeDefinition formatResponse getAccountMyWorkData getAttachmentContent getAttachmentZip getClassificationNode getClassificationNodes getComment getCommentReactions getComments getCommentsBatch getCommentVersion getCommentVersions getDeletedWorkItem getDeletedWorkItems getDeletedWorkItemShallowReferences getEngagedUsers getField getFields getQueries getQueriesBatch getQuery getRecentActivityData getRecentMentions getRelationType getRelationTypes getReportingLinksByLinkType getRevision getRevisions getRootNodes getTag getTags getTemplate getTemplates getUpdate getUpdates getWorkArtifactLinkTypes getWorkItem getWorkItemIconJson getWorkItemIcons getWorkItemIconSvg getWorkItemIconXaml getWorkItemNextStatesOnCheckinAction getWorkItems getWorkItemsBatch getWorkItemStateColors getWorkItemTemplate getWorkItemType getWorkItemTypeCategories getWorkItemTypeCategory getWorkItemTypeColorAndIcons getWorkItemTypeColors getWorkItemTypeFieldsWithReferences getWorkItemTypeFieldWithReferences getWorkItemTypes getWorkItemTypeStates migrateProjectsProcess queryById queryByWiql queryWorkItemsForArtifactUris readReportingDiscussions readReportingRevisionsGet readReportingRevisionsPost replaceTemplate restoreWorkItem searchQueries sendMail updateClassificationNode updateComment updateField updateQuery updateTag updateWorkItem updateWorkItemTypeDefinition

Constructors

Properties

baseUrl: string
http: HttpClient
rest: RestClient
userAgent: string
vsoClient: VsoClient
RESOURCE_AREA_ID: "5264459e-e5e0-4bd8-b118-0985e68a4ec5"

Methods

  • Uploads an attachment.

    Parameters

    • customHeaders: any
    • contentStream: ReadableStream

      Content to upload

    • OptionalfileName: string

      The name of the file

    • OptionaluploadType: string

      Attachment upload type: Simple or Chunked

    • Optionalproject: string

      Project ID or project name

    • OptionalareaPath: string

      Target project Area Path

    Returns Promise<AttachmentReference>

  • Creates a single work item.

    Parameters

    • customHeaders: any
    • document: JsonPatchDocument

      The JSON Patch document representing the work item

    • project: string

      Project ID or project name

    • type: string

      The work item type of the work item to create

    • OptionalvalidateOnly: boolean

      Indicate if you only want to validate the changes without saving the work item

    • OptionalbypassRules: boolean

      Do not enforce the work item type rules on this update

    • OptionalsuppressNotifications: boolean

      Do not fire any notifications for this change

    • Optionalexpand: WorkItemExpand

      The expand parameters for work item attributes. Possible options are { None, Relations, Fields, Links, All }.

    Returns Promise<WorkItem>

  • Delete a query or a folder. This deletes any permission change on the deleted query or folder and any of its descendants if it is a folder. It is important to note that the deleted permission changes cannot be recovered upon undeleting the query or folder.

    Parameters

    • project: string

      Project ID or project name

    • query: string

      ID or path of the query or folder to delete.

    Returns Promise<void>

  • Deletes the specified work item and sends it to the Recycle Bin, so that it can be restored back, if required. Optionally, if the destroy parameter has been set to true, it destroys the work item permanently. WARNING: If the destroy parameter is set to true, work items deleted by this command will NOT go to recycle-bin and there is no way to restore/recover them after deletion. It is recommended NOT to use this parameter. If you do, please use this parameter with extreme caution.

    Parameters

    • id: number

      ID of the work item to be deleted

    • Optionalproject: string

      Project ID or project name

    • Optionaldestroy: boolean

      Optional parameter, if set to true, the work item is deleted permanently. Please note: the destroy action is PERMANENT and cannot be undone.

    Returns Promise<WorkItemDelete>

  • Downloads an attachment.

    Parameters

    • id: string

      Attachment ID

    • OptionalfileName: string

      Name of the file

    • Optionalproject: string

      Project ID or project name

    • Optionaldownload: boolean

      If set to true always download attachment

    Returns Promise<ReadableStream>

  • Downloads an attachment.

    Parameters

    • id: string

      Attachment ID

    • OptionalfileName: string

      Name of the file

    • Optionalproject: string

      Project ID or project name

    • Optionaldownload: boolean

      If set to true always download attachment

    Returns Promise<ReadableStream>

  • Returns a list of work item comments, pageable.

    Parameters

    • project: string

      Project ID or project name

    • workItemId: number

      Id of a work item to get comments for.

    • Optionaltop: number

      Max number of comments to return.

    • OptionalcontinuationToken: string

      Used to query for the next page of comments.

    • OptionalincludeDeleted: boolean

      Specify if the deleted comments should be retrieved.

    • Optionalexpand: CommentExpandOptions

      Specifies the additional data retrieval options for work item comments.

    • Optionalorder: CommentSortOrder

      Order in which the comments should be returned.

    Returns Promise<CommentList>

  • Retrieves an individual query and its children

    Parameters

    • project: string

      Project ID or project name

    • query: string

      ID or path of the query.

    • Optionalexpand: QueryExpand

      Include the query string (wiql), clauses, query result columns, and sort options in the results.

    • Optionaldepth: number

      In the folder of queries, return child queries and folders to this depth.

    • OptionalincludeDeleted: boolean

      Include deleted queries and folders

    • OptionaluseIsoDateFormat: boolean

      DateTime query clauses will be formatted using a ISO 8601 compliant format

    Returns Promise<QueryHierarchyItem>

  • Get a batch of work item links

    Parameters

    • Optionalproject: string

      Project ID or project name

    • OptionallinkTypes: string[]

      A list of types to filter the results to specific link types. Omit this parameter to get work item links of all link types.

    • Optionaltypes: string[]

      A list of types to filter the results to specific work item types. Omit this parameter to get work item links of all work item types.

    • OptionalcontinuationToken: string

      Specifies the continuationToken to start the batch from. Omit this parameter to get the first batch of links.

    • OptionalstartDateTime: Date

      Date/time to use as a starting point for link changes. Only link changes that occurred after that date/time will be returned. Cannot be used in conjunction with 'watermark' parameter.

    Returns Promise<ReportingWorkItemLinksBatch>

  • Get a work item icon given the friendly name and icon color.

    Parameters

    • icon: string

      The name of the icon

    • Optionalcolor: string

      The 6-digit hex color for the icon

    • Optionalv: number

      The version of the icon (used only for cache invalidation)

    Returns Promise<ReadableStream>

  • Get a work item icon given the friendly name and icon color.

    Parameters

    • icon: string

      The name of the icon

    • Optionalcolor: string

      The 6-digit hex color for the icon

    • Optionalv: number

      The version of the icon (used only for cache invalidation)

    Returns Promise<ReadableStream>

  • Returns a list of work items (Maximum 200)

    Parameters

    • ids: number[]

      The comma-separated list of requested work item ids. (Maximum 200 ids allowed).

    • Optionalfields: string[]

      Comma-separated list of requested fields

    • OptionalasOf: Date

      AsOf UTC date time string

    • Optionalexpand: WorkItemExpand

      The expand parameters for work item attributes. Possible options are { None, Relations, Fields, Links, All }.

    • OptionalerrorPolicy: WorkItemErrorPolicy

      The flag to control error policy in a bulk get work items request. Possible options are {Fail, Omit}.

    • Optionalproject: string

      Project ID or project name

    Returns Promise<WorkItem[]>

  • Get a batch of work item revisions with the option of including deleted items

    Parameters

    • Optionalproject: string

      Project ID or project name

    • Optionalfields: string[]

      A list of fields to return in work item revisions. Omit this parameter to get all reportable fields.

    • Optionaltypes: string[]

      A list of types to filter the results to specific work item types. Omit this parameter to get work item revisions of all work item types.

    • OptionalcontinuationToken: string

      Specifies the watermark to start the batch from. Omit this parameter to get the first batch of revisions.

    • OptionalstartDateTime: Date

      Date/time to use as a starting point for revisions, all revisions will occur after this date/time. Cannot be used in conjunction with 'watermark' parameter.

    • OptionalincludeIdentityRef: boolean

      Return an identity reference instead of a string value for identity fields.

    • OptionalincludeDeleted: boolean

      Specify if the deleted item should be returned.

    • OptionalincludeTagRef: boolean

      Specify if the tag objects should be returned for System.Tags field.

    • OptionalincludeLatestOnly: boolean

      Return only the latest revisions of work items, skipping all historical revisions

    • Optionalexpand: ReportingRevisionsExpand

      Return all the fields in work item revisions, including long text fields which are not returned by default

    • OptionalincludeDiscussionChangesOnly: boolean

      Return only the those revisions of work items, where only history field was changed

    • OptionalmaxPageSize: number

      The maximum number of results to return in this batch

    Returns Promise<ReportingWorkItemRevisionsBatch>

  • Updates a single work item.

    Parameters

    • customHeaders: any
    • document: JsonPatchDocument

      The JSON Patch document representing the update

    • id: number

      The id of the work item to update

    • Optionalproject: string

      Project ID or project name

    • OptionalvalidateOnly: boolean

      Indicate if you only want to validate the changes without saving the work item

    • OptionalbypassRules: boolean

      Do not enforce the work item type rules on this update

    • OptionalsuppressNotifications: boolean

      Do not fire any notifications for this change

    • Optionalexpand: WorkItemExpand

      The expand parameters for work item attributes. Possible options are { None, Relations, Fields, Links, All }.

    Returns Promise<WorkItem>