Fields - Get
Returns a field in a work item type.
GET https://dev.azure.com/{organization}/_apis/work/processes/{processId}/workItemTypes/{witRefName}/fields/{fieldRefName}?api-version=7.1
GET https://dev.azure.com/{organization}/_apis/work/processes/{processId}/workItemTypes/{witRefName}/fields/{fieldRefName}?$expand={$expand}&api-version=7.1
URI Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
|
field
|
path | True |
string |
The reference name of the field. |
|
organization
|
path | True |
string |
The name of the Azure DevOps organization. |
|
process
|
path | True |
string (uuid) |
The ID of the process. |
|
wit
|
path | True |
string |
The reference name of the work item type. |
|
api-version
|
query | True |
string |
Version of the API to use. This should be set to '7.1' to use this version of the api. |
|
$expand
|
query |
Responses
| Name | Type | Description |
|---|---|---|
| 200 OK |
successful operation |
Security
oauth2
Type:
oauth2
Flow:
accessCode
Authorization URL:
https://app.vssps.visualstudio.com/oauth2/authorize&response_type=Assertion
Token URL:
https://app.vssps.visualstudio.com/oauth2/token?client_assertion_type=urn:ietf:params:oauth:client-assertion-type:jwt-bearer&grant_type=urn:ietf:params:oauth:grant-type:jwt-bearer
Scopes
| Name | Description |
|---|---|
| vso.work | Grants the ability to read work items, queries, boards, area and iterations paths, and other work item tracking related metadata. Also grants the ability to execute queries, search work items and to receive notifications about work item events via service hooks. |
Examples
Returns a field in a work item type
Sample request
GET https://dev.azure.com/{organization}/_apis/work/processes/{processId}/workItemTypes/{witRefName}/fields/{fieldRefName}?api-version=7.1
Sample response
{
"referenceName": "System.State",
"name": "State",
"type": "string",
"required": true,
"defaultValue": "New",
"url": "https://dev.azure.com/fabrikamm0652/_apis/work/processes/4bab314e-358e-4bf3-9508-806ba6ac0c30/behaviors",
"customization": "inherited"
}
Definitions
| Name | Description |
|---|---|
|
Customization |
Indicates the type of customization on this work item. System behaviors are inherited from parent process but not modified. Inherited behaviors are modified behaviors that were inherited from parent process. Custom behaviors are behaviors created by user in current process. |
|
Field |
|
|
Process |
Class that describes a field in a work item type and its properties. |
|
Process |
CustomizationType
Indicates the type of customization on this work item. System behaviors are inherited from parent process but not modified. Inherited behaviors are modified behaviors that were inherited from parent process. Custom behaviors are behaviors created by user in current process.
| Value | Description |
|---|---|
| system |
Customization-type is System if is system generated workitemtype. |
| inherited |
Customization-type is Inherited if the existing workitemtype of inherited process is customized. |
| custom |
Customization-type is Custom if the newly created workitemtype is customized. |
FieldType
| Value | Description |
|---|---|
| string |
String field type. |
| integer |
Integer field type. |
| dateTime |
DateTime field type. |
| plainText |
Plain text field type. |
| html |
HTML (Multiline) field type. |
| treePath |
Treepath field type. |
| history |
History field type. |
| double |
Double field type. |
| guid |
Guid field type. |
| boolean |
Boolean field type. |
| identity |
Identity field type. |
| picklistInteger |
Integer picklist field type. |
| picklistString |
String picklist field type. |
| picklistDouble |
Double picklist field type. |
ProcessWorkItemTypeField
Class that describes a field in a work item type and its properties.
| Name | Type | Description |
|---|---|---|
| allowGroups |
boolean |
Allow setting field value to a group identity. Only applies to identity fields. |
| allowedValues |
object[] |
The list of field allowed values. |
| customization |
Indicates the type of customization on this work item. |
|
| defaultValue |
object |
The default value of the field. |
| description |
string |
Description of the field. |
| isLocked |
boolean |
Information about field definition being locked for editing |
| name |
string |
Name of the field. |
| readOnly |
boolean |
If true the field cannot be edited. |
| referenceName |
string |
Reference name of the field. |
| required |
boolean |
If true the field cannot be empty. |
| type |
Type of the field. |
|
| url |
string |
Resource URL of the field. |
ProcessWorkItemTypeFieldsExpandLevel
| Value | Description |
|---|---|
| none |
Includes only basic properties of the field. |
| allowedValues |
Includes allowed values for the field. |
| all |
Includes allowed values and dependent fields of the field. |