import basem = require('./ClientApiBases'); import VsoBaseInterfaces = require('./interfaces/common/VsoBaseInterfaces'); import WorkItemTrackingProcessDefinitionsInterfaces = require("./interfaces/WorkItemTrackingProcessDefinitionsInterfaces"); export interface IWorkItemTrackingProcessDefinitionsApi extends basem.ClientApiBase { createBehavior(behavior: WorkItemTrackingProcessDefinitionsInterfaces.BehaviorCreateModel, processId: string): Promise; deleteBehavior(processId: string, behaviorId: string): Promise; getBehavior(processId: string, behaviorId: string): Promise; getBehaviors(processId: string): Promise; replaceBehavior(behaviorData: WorkItemTrackingProcessDefinitionsInterfaces.BehaviorReplaceModel, processId: string, behaviorId: string): Promise; addControlToGroup(control: WorkItemTrackingProcessDefinitionsInterfaces.Control, processId: string, witRefName: string, groupId: string): Promise; editControl(control: WorkItemTrackingProcessDefinitionsInterfaces.Control, processId: string, witRefName: string, groupId: string, controlId: string): Promise; removeControlFromGroup(processId: string, witRefName: string, groupId: string, controlId: string): Promise; setControlInGroup(control: WorkItemTrackingProcessDefinitionsInterfaces.Control, processId: string, witRefName: string, groupId: string, controlId: string, removeFromGroupId?: string): Promise; createField(field: WorkItemTrackingProcessDefinitionsInterfaces.FieldModel, processId: string): Promise; updateField(field: WorkItemTrackingProcessDefinitionsInterfaces.FieldUpdate, processId: string): Promise; addGroup(group: WorkItemTrackingProcessDefinitionsInterfaces.Group, processId: string, witRefName: string, pageId: string, sectionId: string): Promise; editGroup(group: WorkItemTrackingProcessDefinitionsInterfaces.Group, processId: string, witRefName: string, pageId: string, sectionId: string, groupId: string): Promise; removeGroup(processId: string, witRefName: string, pageId: string, sectionId: string, groupId: string): Promise; setGroupInPage(group: WorkItemTrackingProcessDefinitionsInterfaces.Group, processId: string, witRefName: string, pageId: string, sectionId: string, groupId: string, removeFromPageId: string, removeFromSectionId: string): Promise; setGroupInSection(group: WorkItemTrackingProcessDefinitionsInterfaces.Group, processId: string, witRefName: string, pageId: string, sectionId: string, groupId: string, removeFromSectionId: string): Promise; getFormLayout(processId: string, witRefName: string): Promise; getListsMetadata(): Promise; createList(picklist: WorkItemTrackingProcessDefinitionsInterfaces.PickListModel): Promise; deleteList(listId: string): Promise; getList(listId: string): Promise; updateList(picklist: WorkItemTrackingProcessDefinitionsInterfaces.PickListModel, listId: string): Promise; addPage(page: WorkItemTrackingProcessDefinitionsInterfaces.Page, processId: string, witRefName: string): Promise; editPage(page: WorkItemTrackingProcessDefinitionsInterfaces.Page, processId: string, witRefName: string): Promise; removePage(processId: string, witRefName: string, pageId: string): Promise; createStateDefinition(stateModel: WorkItemTrackingProcessDefinitionsInterfaces.WorkItemStateInputModel, processId: string, witRefName: string): Promise; deleteStateDefinition(processId: string, witRefName: string, stateId: string): Promise; getStateDefinition(processId: string, witRefName: string, stateId: string): Promise; getStateDefinitions(processId: string, witRefName: string): Promise; hideStateDefinition(hideStateModel: WorkItemTrackingProcessDefinitionsInterfaces.HideStateModel, processId: string, witRefName: string, stateId: string): Promise; updateStateDefinition(stateModel: WorkItemTrackingProcessDefinitionsInterfaces.WorkItemStateInputModel, processId: string, witRefName: string, stateId: string): Promise; addBehaviorToWorkItemType(behavior: WorkItemTrackingProcessDefinitionsInterfaces.WorkItemTypeBehavior, processId: string, witRefNameForBehaviors: string): Promise; getBehaviorForWorkItemType(processId: string, witRefNameForBehaviors: string, behaviorRefName: string): Promise; getBehaviorsForWorkItemType(processId: string, witRefNameForBehaviors: string): Promise; removeBehaviorFromWorkItemType(processId: string, witRefNameForBehaviors: string, behaviorRefName: string): Promise; updateBehaviorToWorkItemType(behavior: WorkItemTrackingProcessDefinitionsInterfaces.WorkItemTypeBehavior, processId: string, witRefNameForBehaviors: string): Promise; createWorkItemType(workItemType: WorkItemTrackingProcessDefinitionsInterfaces.WorkItemTypeModel, processId: string): Promise; deleteWorkItemType(processId: string, witRefName: string): Promise; getWorkItemType(processId: string, witRefName: string, expand?: WorkItemTrackingProcessDefinitionsInterfaces.GetWorkItemTypeExpand): Promise; getWorkItemTypes(processId: string, expand?: WorkItemTrackingProcessDefinitionsInterfaces.GetWorkItemTypeExpand): Promise; updateWorkItemType(workItemTypeUpdate: WorkItemTrackingProcessDefinitionsInterfaces.WorkItemTypeUpdateModel, processId: string, witRefName: string): Promise; addFieldToWorkItemType(field: WorkItemTrackingProcessDefinitionsInterfaces.WorkItemTypeFieldModel2, processId: string, witRefNameForFields: string): Promise; getWorkItemTypeField(processId: string, witRefNameForFields: string, fieldRefName: string): Promise; getWorkItemTypeFields(processId: string, witRefNameForFields: string): Promise; removeFieldFromWorkItemType(processId: string, witRefNameForFields: string, fieldRefName: string): Promise; } export declare class WorkItemTrackingProcessDefinitionsApi extends basem.ClientApiBase implements IWorkItemTrackingProcessDefinitionsApi { constructor(baseUrl: string, handlers: VsoBaseInterfaces.IRequestHandler[], options?: VsoBaseInterfaces.IRequestOptions); static readonly RESOURCE_AREA_ID: string; /** * Creates a single behavior in the given process. * * @param {WorkItemTrackingProcessDefinitionsInterfaces.BehaviorCreateModel} behavior * @param {string} processId - The ID of the process */ createBehavior(behavior: WorkItemTrackingProcessDefinitionsInterfaces.BehaviorCreateModel, processId: string): Promise; /** * Removes a behavior in the process. * * @param {string} processId - The ID of the process * @param {string} behaviorId - The ID of the behavior */ deleteBehavior(processId: string, behaviorId: string): Promise; /** * Returns a single behavior in the process. * * @param {string} processId - The ID of the process * @param {string} behaviorId - The ID of the behavior */ getBehavior(processId: string, behaviorId: string): Promise; /** * Returns a list of all behaviors in the process. * * @param {string} processId - The ID of the process */ getBehaviors(processId: string): Promise; /** * Replaces a behavior in the process. * * @param {WorkItemTrackingProcessDefinitionsInterfaces.BehaviorReplaceModel} behaviorData * @param {string} processId - The ID of the process * @param {string} behaviorId - The ID of the behavior */ replaceBehavior(behaviorData: WorkItemTrackingProcessDefinitionsInterfaces.BehaviorReplaceModel, processId: string, behaviorId: string): Promise; /** * Creates a control in a group * * @param {WorkItemTrackingProcessDefinitionsInterfaces.Control} control - The control * @param {string} processId - The ID of the process * @param {string} witRefName - The reference name of the work item type * @param {string} groupId - The ID of the group to add the control to */ addControlToGroup(control: WorkItemTrackingProcessDefinitionsInterfaces.Control, processId: string, witRefName: string, groupId: string): Promise; /** * Updates a control on the work item form * * @param {WorkItemTrackingProcessDefinitionsInterfaces.Control} control - The updated control * @param {string} processId - The ID of the process * @param {string} witRefName - The reference name of the work item type * @param {string} groupId - The ID of the group * @param {string} controlId - The ID of the control */ editControl(control: WorkItemTrackingProcessDefinitionsInterfaces.Control, processId: string, witRefName: string, groupId: string, controlId: string): Promise; /** * Removes a control from the work item form * * @param {string} processId - The ID of the process * @param {string} witRefName - The reference name of the work item type * @param {string} groupId - The ID of the group * @param {string} controlId - The ID of the control to remove */ removeControlFromGroup(processId: string, witRefName: string, groupId: string, controlId: string): Promise; /** * Moves a control to a new group * * @param {WorkItemTrackingProcessDefinitionsInterfaces.Control} control - The control * @param {string} processId - The ID of the process * @param {string} witRefName - The reference name of the work item type * @param {string} groupId - The ID of the group to move the control to * @param {string} controlId - The id of the control * @param {string} removeFromGroupId - The group to remove the control from */ setControlInGroup(control: WorkItemTrackingProcessDefinitionsInterfaces.Control, processId: string, witRefName: string, groupId: string, controlId: string, removeFromGroupId?: string): Promise; /** * Creates a single field in the process. * * @param {WorkItemTrackingProcessDefinitionsInterfaces.FieldModel} field * @param {string} processId - The ID of the process */ createField(field: WorkItemTrackingProcessDefinitionsInterfaces.FieldModel, processId: string): Promise; /** * Updates a given field in the process. * * @param {WorkItemTrackingProcessDefinitionsInterfaces.FieldUpdate} field * @param {string} processId - The ID of the process */ updateField(field: WorkItemTrackingProcessDefinitionsInterfaces.FieldUpdate, processId: string): Promise; /** * Adds a group to the work item form * * @param {WorkItemTrackingProcessDefinitionsInterfaces.Group} group - The group * @param {string} processId - The ID of the process * @param {string} witRefName - The reference name of the work item type * @param {string} pageId - The ID of the page to add the group to * @param {string} sectionId - The ID of the section to add the group to */ addGroup(group: WorkItemTrackingProcessDefinitionsInterfaces.Group, processId: string, witRefName: string, pageId: string, sectionId: string): Promise; /** * Updates a group in the work item form * * @param {WorkItemTrackingProcessDefinitionsInterfaces.Group} group - The updated group * @param {string} processId - The ID of the process * @param {string} witRefName - The reference name of the work item type * @param {string} pageId - The ID of the page the group is in * @param {string} sectionId - The ID of the section the group is in * @param {string} groupId - The ID of the group */ editGroup(group: WorkItemTrackingProcessDefinitionsInterfaces.Group, processId: string, witRefName: string, pageId: string, sectionId: string, groupId: string): Promise; /** * Removes a group from the work item form * * @param {string} processId - The ID of the process * @param {string} witRefName - The reference name of the work item type * @param {string} pageId - The ID of the page the group is in * @param {string} sectionId - The ID of the section to the group is in * @param {string} groupId - The ID of the group */ removeGroup(processId: string, witRefName: string, pageId: string, sectionId: string, groupId: string): Promise; /** * Moves a group to a different page and section * * @param {WorkItemTrackingProcessDefinitionsInterfaces.Group} group - The updated group * @param {string} processId - The ID of the process * @param {string} witRefName - The reference name of the work item type * @param {string} pageId - The ID of the page the group is in * @param {string} sectionId - The ID of the section the group is in * @param {string} groupId - The ID of the group * @param {string} removeFromPageId - ID of the page to remove the group from * @param {string} removeFromSectionId - ID of the section to remove the group from */ setGroupInPage(group: WorkItemTrackingProcessDefinitionsInterfaces.Group, processId: string, witRefName: string, pageId: string, sectionId: string, groupId: string, removeFromPageId: string, removeFromSectionId: string): Promise; /** * Moves a group to a different section * * @param {WorkItemTrackingProcessDefinitionsInterfaces.Group} group - The updated group * @param {string} processId - The ID of the process * @param {string} witRefName - The reference name of the work item type * @param {string} pageId - The ID of the page the group is in * @param {string} sectionId - The ID of the section the group is in * @param {string} groupId - The ID of the group * @param {string} removeFromSectionId - ID of the section to remove the group from */ setGroupInSection(group: WorkItemTrackingProcessDefinitionsInterfaces.Group, processId: string, witRefName: string, pageId: string, sectionId: string, groupId: string, removeFromSectionId: string): Promise; /** * Gets the form layout * * @param {string} processId - The ID of the process * @param {string} witRefName - The reference name of the work item type */ getFormLayout(processId: string, witRefName: string): Promise; /** * Returns meta data of the picklist. * */ getListsMetadata(): Promise; /** * Creates a picklist. * * @param {WorkItemTrackingProcessDefinitionsInterfaces.PickListModel} picklist */ createList(picklist: WorkItemTrackingProcessDefinitionsInterfaces.PickListModel): Promise; /** * Removes a picklist. * * @param {string} listId - The ID of the list */ deleteList(listId: string): Promise; /** * Returns a picklist. * * @param {string} listId - The ID of the list */ getList(listId: string): Promise; /** * Updates a list. * * @param {WorkItemTrackingProcessDefinitionsInterfaces.PickListModel} picklist * @param {string} listId - The ID of the list */ updateList(picklist: WorkItemTrackingProcessDefinitionsInterfaces.PickListModel, listId: string): Promise; /** * Adds a page to the work item form * * @param {WorkItemTrackingProcessDefinitionsInterfaces.Page} page - The page * @param {string} processId - The ID of the process * @param {string} witRefName - The reference name of the work item type */ addPage(page: WorkItemTrackingProcessDefinitionsInterfaces.Page, processId: string, witRefName: string): Promise; /** * Updates a page on the work item form * * @param {WorkItemTrackingProcessDefinitionsInterfaces.Page} page - The page * @param {string} processId - The ID of the process * @param {string} witRefName - The reference name of the work item type */ editPage(page: WorkItemTrackingProcessDefinitionsInterfaces.Page, processId: string, witRefName: string): Promise; /** * Removes a page from the work item form * * @param {string} processId - The ID of the process * @param {string} witRefName - The reference name of the work item type * @param {string} pageId - The ID of the page */ removePage(processId: string, witRefName: string, pageId: string): Promise; /** * Creates a state definition in the work item type of the process. * * @param {WorkItemTrackingProcessDefinitionsInterfaces.WorkItemStateInputModel} stateModel * @param {string} processId - The ID of the process * @param {string} witRefName - The reference name of the work item type */ createStateDefinition(stateModel: WorkItemTrackingProcessDefinitionsInterfaces.WorkItemStateInputModel, processId: string, witRefName: string): Promise; /** * Removes a state definition in the work item type of the process. * * @param {string} processId - ID of the process * @param {string} witRefName - The reference name of the work item type * @param {string} stateId - ID of the state */ deleteStateDefinition(processId: string, witRefName: string, stateId: string): Promise; /** * Returns a state definition in the work item type of the process. * * @param {string} processId - The ID of the process * @param {string} witRefName - The reference name of the work item type * @param {string} stateId - The ID of the state */ getStateDefinition(processId: string, witRefName: string, stateId: string): Promise; /** * Returns a list of all state definitions in the work item type of the process. * * @param {string} processId - The ID of the process * @param {string} witRefName - The reference name of the work item type */ getStateDefinitions(processId: string, witRefName: string): Promise; /** * Hides a state definition in the work item type of the process. * * @param {WorkItemTrackingProcessDefinitionsInterfaces.HideStateModel} hideStateModel * @param {string} processId - The ID of the process * @param {string} witRefName - The reference name of the work item type * @param {string} stateId - The ID of the state */ hideStateDefinition(hideStateModel: WorkItemTrackingProcessDefinitionsInterfaces.HideStateModel, processId: string, witRefName: string, stateId: string): Promise; /** * Updates a given state definition in the work item type of the process. * * @param {WorkItemTrackingProcessDefinitionsInterfaces.WorkItemStateInputModel} stateModel * @param {string} processId - ID of the process * @param {string} witRefName - The reference name of the work item type * @param {string} stateId - ID of the state */ updateStateDefinition(stateModel: WorkItemTrackingProcessDefinitionsInterfaces.WorkItemStateInputModel, processId: string, witRefName: string, stateId: string): Promise; /** * Adds a behavior to the work item type of the process. * * @param {WorkItemTrackingProcessDefinitionsInterfaces.WorkItemTypeBehavior} behavior * @param {string} processId - The ID of the process * @param {string} witRefNameForBehaviors - Work item type reference name for the behavior */ addBehaviorToWorkItemType(behavior: WorkItemTrackingProcessDefinitionsInterfaces.WorkItemTypeBehavior, processId: string, witRefNameForBehaviors: string): Promise; /** * Returns a behavior for the work item type of the process. * * @param {string} processId - The ID of the process * @param {string} witRefNameForBehaviors - Work item type reference name for the behavior * @param {string} behaviorRefName - The reference name of the behavior */ getBehaviorForWorkItemType(processId: string, witRefNameForBehaviors: string, behaviorRefName: string): Promise; /** * Returns a list of all behaviors for the work item type of the process. * * @param {string} processId - The ID of the process * @param {string} witRefNameForBehaviors - Work item type reference name for the behavior */ getBehaviorsForWorkItemType(processId: string, witRefNameForBehaviors: string): Promise; /** * Removes a behavior for the work item type of the process. * * @param {string} processId - The ID of the process * @param {string} witRefNameForBehaviors - Work item type reference name for the behavior * @param {string} behaviorRefName - The reference name of the behavior */ removeBehaviorFromWorkItemType(processId: string, witRefNameForBehaviors: string, behaviorRefName: string): Promise; /** * Updates default work item type for the behavior of the process. * * @param {WorkItemTrackingProcessDefinitionsInterfaces.WorkItemTypeBehavior} behavior * @param {string} processId - The ID of the process * @param {string} witRefNameForBehaviors - Work item type reference name for the behavior */ updateBehaviorToWorkItemType(behavior: WorkItemTrackingProcessDefinitionsInterfaces.WorkItemTypeBehavior, processId: string, witRefNameForBehaviors: string): Promise; /** * Creates a work item type in the process. * * @param {WorkItemTrackingProcessDefinitionsInterfaces.WorkItemTypeModel} workItemType * @param {string} processId - The ID of the process */ createWorkItemType(workItemType: WorkItemTrackingProcessDefinitionsInterfaces.WorkItemTypeModel, processId: string): Promise; /** * Removes a work itewm type in the process. * * @param {string} processId - The ID of the process * @param {string} witRefName - The reference name of the work item type */ deleteWorkItemType(processId: string, witRefName: string): Promise; /** * Returns a work item type of the process. * * @param {string} processId - The ID of the process * @param {string} witRefName - The reference name of the work item type * @param {WorkItemTrackingProcessDefinitionsInterfaces.GetWorkItemTypeExpand} expand */ getWorkItemType(processId: string, witRefName: string, expand?: WorkItemTrackingProcessDefinitionsInterfaces.GetWorkItemTypeExpand): Promise; /** * Returns a list of all work item types in the process. * * @param {string} processId - The ID of the process * @param {WorkItemTrackingProcessDefinitionsInterfaces.GetWorkItemTypeExpand} expand */ getWorkItemTypes(processId: string, expand?: WorkItemTrackingProcessDefinitionsInterfaces.GetWorkItemTypeExpand): Promise; /** * Updates a work item type of the process. * * @param {WorkItemTrackingProcessDefinitionsInterfaces.WorkItemTypeUpdateModel} workItemTypeUpdate * @param {string} processId - The ID of the process * @param {string} witRefName - The reference name of the work item type */ updateWorkItemType(workItemTypeUpdate: WorkItemTrackingProcessDefinitionsInterfaces.WorkItemTypeUpdateModel, processId: string, witRefName: string): Promise; /** * Adds a field to the work item type in the process. * * @param {WorkItemTrackingProcessDefinitionsInterfaces.WorkItemTypeFieldModel2} field * @param {string} processId - The ID of the process * @param {string} witRefNameForFields - Work item type reference name for the field */ addFieldToWorkItemType(field: WorkItemTrackingProcessDefinitionsInterfaces.WorkItemTypeFieldModel2, processId: string, witRefNameForFields: string): Promise; /** * Returns a single field in the work item type of the process. * * @param {string} processId - The ID of the process * @param {string} witRefNameForFields - Work item type reference name for fields * @param {string} fieldRefName - The reference name of the field */ getWorkItemTypeField(processId: string, witRefNameForFields: string, fieldRefName: string): Promise; /** * Returns a list of all fields in the work item type of the process. * * @param {string} processId - The ID of the process * @param {string} witRefNameForFields - Work item type reference name for fields */ getWorkItemTypeFields(processId: string, witRefNameForFields: string): Promise; /** * Removes a field in the work item type of the process. * * @param {string} processId - The ID of the process * @param {string} witRefNameForFields - Work item type reference name for fields * @param {string} fieldRefName - The reference name of the field */ removeFieldFromWorkItemType(processId: string, witRefNameForFields: string, fieldRefName: string): Promise; }