Internal
Create a new instance of the service.
Adds issue types to a custom field context, appending the issue types to the issue types list.
A custom field context without any issue types applies to all issue types. Adding issue types to such a custom field context would result in it applying to only the listed issue types.
If any of the issue types exists in the custom field context, the operation fails and no issue types are added.
Permissions required: Administer Jira global permission.
The ID of the context.
The ID of the custom field.
Returned if operation is successful.
Assigns a custom field context to projects.
If any project in the request is assigned to any context of the custom field, the operation fails.
Permissions required: Administer Jira global permission.
The ID of the context.
The ID of the custom field.
Returned if operation is successful.
Creates a custom field context.
If projectIds
is empty, a global context is created. A global context is one
that applies to all project. If issueTypeIds
is empty, the context applies to
all issue types.
Permissions required: Administer Jira global permission.
The ID of the custom field.
Returned if the custom field context is created.
example:
{
"id": "10025",
"name": "Bug fields context",
"description": "A context used to define the custom field options for bugs.",
"projectIds": [],
"issueTypeIds": [
"10010"
]
}
Deletes a custom field context.
Permissions required: Administer Jira global permission.
The ID of the context.
The ID of the custom field.
Returned if the context is deleted.
Returns a paginated list of contexts for a custom field. Contexts can be returned as follows:
id
only, all contexts from the list of IDs.isAnyIssueType
, limit the list of contexts returned to either
those that apply to all issue types (true) or those that apply to only a subset
of issue types (false)isGlobalContext
, limit the list of contexts return to either
those that apply to all projects (global contexts) (true) or those that apply
to only a subset of projects (false).Permissions required: Administer Jira global permission.
Optional
contextThe list of context IDs. To include multiple contexts, separate IDs with
ampersand: contextId=10000&contextId=10001
.
The ID of the custom field.
Optional
isWhether to return contexts that apply to all issue types.
Optional
isWhether to return contexts that apply to all projects.
Optional
maxThe maximum number of items to return per page.
Optional
startThe index of the first item to return in a page of results (page offset).
Returned if the request is successful.
example:
{
"isLast": true,
"maxResults": 100,
"startAt": 0,
"total": 2,
"values": [
{
"id": "10025",
"name": "Bug fields context",
"description": "A context used to define the custom field options for bugs.",
"isGlobalContext": true,
"isAnyIssueType": false
},
{
"id": "10026",
"name": "Task fields context",
"description": "A context used to define the custom field options for tasks.",
"isGlobalContext": false,
"isAnyIssueType": false
}
]
}
Returns a paginated list of project and issue type mappings and, for each mapping, the ID of a custom field context that applies to the project and issue type.
If there is no custom field context assigned to the project then, if present,
the custom field context that applies to all projects is returned if it also
applies to the issue type or all issue types. If a custom field context is not
found, the returned custom field context ID is null
.
Duplicate project and issue type mappings cannot be provided in the request.
The order of the returned values is the same as provided in the request.
Permissions required: Administer Jira global permission.
The ID of the custom field.
Optional
maxThe maximum number of items to return per page.
The list of project and issue type mappings.
Optional
startThe index of the first item to return in a page of results (page offset).
Returned if the request is successful.
example:
{
"isLast": true,
"maxResults": 50,
"startAt": 0,
"total": 3,
"values": [
{
"projectId": "10000",
"issueTypeId": "10000",
"contextId": "10000"
},
{
"projectId": "10000",
"issueTypeId": "10001",
"contextId": null
},
{
"projectId": "10001",
"issueTypeId": "10002",
"contextId": "10003"
}
]
}
Returns a paginated list of defaults for a custom field. The
results can be filtered by contextId
, otherwise all values are returned. If
no defaults are set for a context, nothing is returned.
The returned object depends on type of the custom field:
CustomFieldContextDefaultValueDate
(type datepicker
) for date fields.CustomFieldContextDefaultValueDateTime
(type datetimepicker
) for
date-time fields.CustomFieldContextDefaultValueSingleOption
(type option.single
) for
single choice select lists and radio buttons.CustomFieldContextDefaultValueMultipleOption
(type option.multiple
) for
multiple choice select lists and checkboxes.CustomFieldContextDefaultValueCascadingOption
(type option.cascading
)
for cascading select lists.CustomFieldContextSingleUserPickerDefaults
(type single.user.select
)
for single users.CustomFieldContextDefaultValueMultiUserPicker
(type multi.user.select
)
for user lists.CustomFieldContextDefaultValueSingleGroupPicker
(type
grouppicker.single
) for single choice group pickers.CustomFieldContextDefaultValueMultipleGroupPicker
(type
grouppicker.multiple
) for multiple choice group pickers.CustomFieldContextDefaultValueURL
(type url
) for URLs.CustomFieldContextDefaultValueProject
(type project
) for project
pickers.CustomFieldContextDefaultValueFloat
(type float
) for floats
(floating-point numbers).CustomFieldContextDefaultValueLabels
(type labels
) for labels.CustomFieldContextDefaultValueTextField
(type textfield
) for text
fields.CustomFieldContextDefaultValueTextArea
(type textarea
) for text area
fields.CustomFieldContextDefaultValueReadOnly
(type readonly
) for read only
(text) fields.CustomFieldContextDefaultValueMultipleVersion
(type version.multiple
)
for single choice version pickers.CustomFieldContextDefaultValueSingleVersion
(type version.single
) for
multiple choice version pickers.Forge custom fields types are also supported, returning:
CustomFieldContextDefaultValueForgeStringFieldBean
(type forge.string
)
for Forge string fields.CustomFieldContextDefaultValueForgeMultiStringFieldBean
(type
forge.string.list
) for Forge string collection fields.CustomFieldContextDefaultValueForgeObjectFieldBean
(type forge.object
)
for Forge object fields.CustomFieldContextDefaultValueForgeDateTimeFieldBean
(type
forge.datetime
) for Forge date-time fields.CustomFieldContextDefaultValueForgeGroupFieldBean
(type forge.group
)
for Forge group fields.CustomFieldContextDefaultValueForgeMultiGroupFieldBean
(type
forge.group.list
) for Forge group collection fields.CustomFieldContextDefaultValueForgeNumberFieldBean
(type forge.number
)
for Forge number fields.CustomFieldContextDefaultValueForgeUserFieldBean
(type forge.user
) for
Forge user fields.CustomFieldContextDefaultValueForgeMultiUserFieldBean
(type
forge.user.list
) for Forge user collection fields.Permissions required: Administer Jira global permission.
Optional
contextThe IDs of the contexts.
The ID of the custom field, for example customfield\_10000
.
Optional
maxThe maximum number of items to return per page.
Optional
startThe index of the first item to return in a page of results (page offset).
Returned if the request is successful.
example:
{
"isLast": true,
"maxResults": 50,
"startAt": 0,
"total": 3,
"values": [
{
"contextId": "10100",
"optionId": "10001"
},
{
"contextId": "10101",
"optionId": "10003"
},
{
"contextId": "10103"
}
]
}
Returns a paginated list of context to issue type mappings for a custom field. Mappings are returned for all contexts or a list of contexts. Mappings are ordered first by context ID and then by issue type ID.
Permissions required: Administer Jira global permission.
Optional
contextThe ID of the context. To include multiple contexts, provide an
ampersand-separated list. For example, contextId=10001&contextId=10002
.
The ID of the custom field.
Optional
maxThe maximum number of items to return per page.
Optional
startThe index of the first item to return in a page of results (page offset).
Returned if operation is successful.
example:
{
"isLast": true,
"maxResults": 100,
"startAt": 0,
"total": 3,
"values": [
{
"contextId": "10001",
"issueTypeId": "10010"
},
{
"contextId": "10001",
"issueTypeId": "10011"
},
{
"contextId": "10002",
"isAnyIssueType": true
}
]
}
Returns a paginated list of context to project mappings for a
custom field. The result can be filtered by contextId
. Otherwise, all
mappings are returned. Invalid IDs are ignored.
Permissions required: Administer Jira global permission.
Optional
contextThe list of context IDs. To include multiple context, separate IDs with
ampersand: contextId=10000&contextId=10001
.
The ID of the custom field, for example customfield\_10000
.
Optional
maxThe maximum number of items to return per page.
Optional
startThe index of the first item to return in a page of results (page offset).
Returned if the request is successful.
example:
{
"isLast": true,
"maxResults": 100,
"startAt": 0,
"total": 2,
"values": [
{
"contextId": "10025",
"projectId": "10001"
},
{
"contextId": "10026",
"isGlobalContext": true
}
]
}
Removes a custom field context from projects.
A custom field context without any projects applies to all projects. Removing all projects from a custom field context would result in it applying to all projects.
If any project in the request is not assigned to the context, or the operation would result in two global contexts for the field, the operation fails.
Permissions required: Administer Jira global permission.
The ID of the context.
The ID of the custom field.
Returned if the custom field context is removed from the projects.
Removes issue types from a custom field context.
A custom field context without any issue types applies to all issue types.
Permissions required: Administer Jira global permission.
The ID of the context.
The ID of the custom field.
Returned if operation is successful.
Sets default for contexts of a custom field. Default are defined using these objects:
CustomFieldContextDefaultValueDate
(type datepicker
) for date fields.CustomFieldContextDefaultValueDateTime
(type datetimepicker
) for
date-time fields.CustomFieldContextDefaultValueSingleOption
(type option.single
) for
single choice select lists and radio buttons.CustomFieldContextDefaultValueMultipleOption
(type option.multiple
) for
multiple choice select lists and checkboxes.CustomFieldContextDefaultValueCascadingOption
(type option.cascading
)
for cascading select lists.CustomFieldContextSingleUserPickerDefaults
(type single.user.select
)
for single users.CustomFieldContextDefaultValueMultiUserPicker
(type multi.user.select
)
for user lists.CustomFieldContextDefaultValueSingleGroupPicker
(type
grouppicker.single
) for single choice group pickers.CustomFieldContextDefaultValueMultipleGroupPicker
(type
grouppicker.multiple
) for multiple choice group pickers.CustomFieldContextDefaultValueURL
(type url
) for URLs.CustomFieldContextDefaultValueProject
(type project
) for project
pickers.CustomFieldContextDefaultValueFloat
(type float
) for floats
(floating-point numbers).CustomFieldContextDefaultValueLabels
(type labels
) for labels.CustomFieldContextDefaultValueTextField
(type textfield
) for text
fields.CustomFieldContextDefaultValueTextArea
(type textarea
) for text area
fields.CustomFieldContextDefaultValueReadOnly
(type readonly
) for read only
(text) fields.CustomFieldContextDefaultValueMultipleVersion
(type version.multiple
)
for single choice version pickers.CustomFieldContextDefaultValueSingleVersion
(type version.single
) for
multiple choice version pickers.Forge custom fields types are also supported, returning:
CustomFieldContextDefaultValueForgeStringFieldBean
(type forge.string
)
for Forge string fields.CustomFieldContextDefaultValueForgeMultiStringFieldBean
(type
forge.string.list
) for Forge string collection fields.CustomFieldContextDefaultValueForgeObjectFieldBean
(type forge.object
)
for Forge object fields.CustomFieldContextDefaultValueForgeDateTimeFieldBean
(type
forge.datetime
) for Forge date-time fields.CustomFieldContextDefaultValueForgeGroupFieldBean
(type forge.group
)
for Forge group fields.CustomFieldContextDefaultValueForgeMultiGroupFieldBean
(type
forge.group.list
) for Forge group collection fields.CustomFieldContextDefaultValueForgeNumberFieldBean
(type forge.number
)
for Forge number fields.CustomFieldContextDefaultValueForgeUserFieldBean
(type forge.user
) for
Forge user fields.CustomFieldContextDefaultValueForgeMultiUserFieldBean
(type
forge.user.list
) for Forge user collection fields.Only one type of default object can be included in a request. To remove a
default for a context, set the default parameter to null
.
Permissions required: Administer Jira global permission.
The ID of the custom field.
Returned if operation is successful.
Updates a custom field context.
Permissions required: Administer Jira global permission.
The ID of the context.
The ID of the custom field.
Returned if the context is updated.
Protected
Static
initialize
This resource represents issue custom field contexts. Use it to:
See
https://developer.atlassian.com/cloud/jira/platform/rest/v3/api-group-issue-custom-field-contexts