This resource represents project components. Use it to get, create, update, and delete project components. Also get components for project and get a count of issues by component.

Hierarchy

  • CommonHttpService
    • ProjectComponentsService

Constructors

  • Internal

    Create a new instance of the service.

    Parameters

    • getClientInstance: (() => CommonHttpClient)
        • (): CommonHttpClient
        • Returns CommonHttpClient

    Returns ProjectComponentsService

Methods

  • Creates a component. Use components to provide containers for issues within a project. Use components to provide containers for issues within a project.

    This operation can be accessed anonymously.

    Permissions required: Administer projects project permission for the project in which the component is created or Administer Jira global permission.

    Parameters

    Returns Promise<ProjectComponent>

    Returned if the request is successful.

    example:

    {
    "ari": "ari:cloud:compass:fdb3fdec-4e70-be56-11ee-0242ac120002:component/fdb3fdec-4e70-11ee-be56-0242ac120002/fdb3fdec-11ee-4e70-be56-0242ac120002",
    "assignee": {
    "accountId": "5b10a2844c20165700ede21g",
    "accountType": "atlassian",
    "active": false,
    "avatarUrls": {
    "16x16": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=16&s=16",
    "24x24": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=24&s=24",
    "32x32": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=32&s=32",
    "48x48": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=48&s=48"
    },
    "displayName": "Mia Krystof",
    "key": "",
    "name": "",
    "self": "https://your-domain.atlassian.net/rest/api/3/user?accountId=5b10a2844c20165700ede21g"
    },
    "assigneeType": "PROJECT_LEAD",
    "description": "This is a Jira component",
    "id": "10000",
    "isAssigneeTypeValid": false,
    "lead": {
    "accountId": "5b10a2844c20165700ede21g",
    "accountType": "atlassian",
    "active": false,
    "avatarUrls": {
    "16x16": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=16&s=16",
    "24x24": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=24&s=24",
    "32x32": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=32&s=32",
    "48x48": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=48&s=48"
    },
    "displayName": "Mia Krystof",
    "key": "",
    "name": "",
    "self": "https://your-domain.atlassian.net/rest/api/3/user?accountId=5b10a2844c20165700ede21g"
    },
    "metadata": {
    "icon": "https://www.example.com/icon.png"
    },
    "name": "Component 1",
    "project": "HSP",
    "projectId": 10000,
    "realAssignee": {
    "accountId": "5b10a2844c20165700ede21g",
    "accountType": "atlassian",
    "active": false,
    "avatarUrls": {
    "16x16": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=16&s=16",
    "24x24": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=24&s=24",
    "32x32": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=32&s=32",
    "48x48": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=48&s=48"
    },
    "displayName": "Mia Krystof",
    "key": "",
    "name": "",
    "self": "https://your-domain.atlassian.net/rest/api/3/user?accountId=5b10a2844c20165700ede21g"
    },
    "realAssigneeType": "PROJECT_LEAD",
    "self": "https://your-domain.atlassian.net/rest/api/3/component/10000"
    }

    POST /rest/api/3/component @scopes-current manage:jira-project @scopes-beta read:project:jira, read:user:jira, write:project.component:jira, read:application-role:jira, read:avatar:jira, read:group:jira, read:project.component:jira

  • Returns a paginated list of all components in a project, including global (Compass) components when applicable.

    This operation can be accessed anonymously.

    Permissions required: Browse Projects project permission for the project.

    Parameters

    • params: {
          maxResults?: number;
          orderBy?:
              | "name"
              | "description"
              | "-description"
              | "+description"
              | "-name"
              | "+name";
          projectIdsOrKeys?: string[];
          query?: string;
          startAt?: number;
      } = {}
      • OptionalmaxResults?: number

        The maximum number of items to return per page.

      • OptionalorderBy?:
            | "name"
            | "description"
            | "-description"
            | "+description"
            | "-name"
            | "+name"

        Order the results by a field:

        • description Sorts by the component description.
        • name Sorts by component name.
      • OptionalprojectIdsOrKeys?: string[]

        The project IDs and/or project keys (case sensitive).

      • Optionalquery?: string

        Filter the results using a literal string. Components with a matching name or description are returned (case insensitive).

      • OptionalstartAt?: number

        The index of the first item to return in a page of results (page offset).

    Returns Promise<PageBean2ComponentJsonBean>

    Returned if the request is successful.

    example:

    {
    "isLast": false,
    "maxResults": 2,
    "startAt": 0,
    "total": 2,
    "values": [
    {
    "description": "This is a component",
    "id": "10000",
    "name": "Component1",
    "self": "http://www.example.com/jira/rest/api/2/component/10000"
    },
    {
    "ari": "ari:cloud:jira::global/component/10001",
    "description": "This is a global component",
    "id": "10001",
    "metadata": {
    "key1": "value1",
    "key2": "value2"
    },
    "name": "Component2",
    "self": "http://www.example.com/jira/rest/api/2/component/10001"
    }
    ]
    }

    GET /rest/api/3/component @scopes-current read:jira-work @scopes-beta read:project:jira, read:project.component:jira, read:user:jira, read:application-role:jira, read:avatar:jira, read:group:jira

  • Returns a component.

    This operation can be accessed anonymously.

    Permissions required: Browse projects project permission for project containing the component.

    Parameters

    • params: {
          id: string;
      }
      • id: string

        The ID of the component.

    Returns Promise<ProjectComponent>

    Returned if the request is successful.

    example:

    {
    "ari": "ari:cloud:compass:fdb3fdec-4e70-be56-11ee-0242ac120002:component/fdb3fdec-4e70-11ee-be56-0242ac120002/fdb3fdec-11ee-4e70-be56-0242ac120002",
    "assignee": {
    "accountId": "5b10a2844c20165700ede21g",
    "accountType": "atlassian",
    "active": false,
    "avatarUrls": {
    "16x16": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=16&s=16",
    "24x24": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=24&s=24",
    "32x32": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=32&s=32",
    "48x48": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=48&s=48"
    },
    "displayName": "Mia Krystof",
    "key": "",
    "name": "",
    "self": "https://your-domain.atlassian.net/rest/api/3/user?accountId=5b10a2844c20165700ede21g"
    },
    "assigneeType": "PROJECT_LEAD",
    "description": "This is a Jira component",
    "id": "10000",
    "isAssigneeTypeValid": false,
    "lead": {
    "accountId": "5b10a2844c20165700ede21g",
    "accountType": "atlassian",
    "active": false,
    "avatarUrls": {
    "16x16": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=16&s=16",
    "24x24": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=24&s=24",
    "32x32": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=32&s=32",
    "48x48": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=48&s=48"
    },
    "displayName": "Mia Krystof",
    "key": "",
    "name": "",
    "self": "https://your-domain.atlassian.net/rest/api/3/user?accountId=5b10a2844c20165700ede21g"
    },
    "metadata": {
    "icon": "https://www.example.com/icon.png"
    },
    "name": "Component 1",
    "project": "HSP",
    "projectId": 10000,
    "realAssignee": {
    "accountId": "5b10a2844c20165700ede21g",
    "accountType": "atlassian",
    "active": false,
    "avatarUrls": {
    "16x16": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=16&s=16",
    "24x24": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=24&s=24",
    "32x32": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=32&s=32",
    "48x48": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=48&s=48"
    },
    "displayName": "Mia Krystof",
    "key": "",
    "name": "",
    "self": "https://your-domain.atlassian.net/rest/api/3/user?accountId=5b10a2844c20165700ede21g"
    },
    "realAssigneeType": "PROJECT_LEAD",
    "self": "https://your-domain.atlassian.net/rest/api/3/component/10000"
    }

    GET /rest/api/3/component/{id} @scopes-current read:jira-work @scopes-beta read:project:jira, read:project.component:jira, read:user:jira, read:application-role:jira, read:avatar:jira, read:group:jira

  • Returns all components in a project. See the Get project components paginated resource if you want to get a full list of components with pagination.

    If your project uses Compass components, this API will return a paginated list of Compass components that are linked to issues in that project.

    This operation can be accessed anonymously.

    Permissions required: Browse Projects project permission for the project.

    Parameters

    • params: {
          componentSource?: "auto" | "jira" | "compass";
          projectIdOrKey: string;
      }
      • OptionalcomponentSource?: "auto" | "jira" | "compass"

        The source of the components to return. Can be jira (default), compass or auto. When auto is specified, the API will return connected Compass components if the project is opted into Compass, otherwise it will return Jira components. Defaults to jira.

      • projectIdOrKey: string

        The project ID or project key (case sensitive).

    Returns Promise<ProjectComponent[]>

    Returned if the request is successful.

    example:

    [
    {
    "ari": "ari:cloud:compass:fdb3fdec-4e70-be56-11ee-0242ac120002:component/fdb3fdec-4e70-11ee-be56-0242ac120002/fdb3fdec-11ee-4e70-be56-0242ac120002",
    "assignee": {
    "accountId": "5b10a2844c20165700ede21g",
    "accountType": "atlassian",
    "active": false,
    "avatarUrls": {
    "16x16": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=16&s=16",
    "24x24": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=24&s=24",
    "32x32": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=32&s=32",
    "48x48": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=48&s=48"
    },
    "displayName": "Mia Krystof",
    "key": "",
    "name": "",
    "self": "https://your-domain.atlassian.net/rest/api/3/user?accountId=5b10a2844c20165700ede21g"
    },
    "assigneeType": "PROJECT_LEAD",
    "description": "This is a Jira component",
    "id": "10000",
    "isAssigneeTypeValid": false,
    "lead": {
    "accountId": "5b10a2844c20165700ede21g",
    "accountType": "atlassian",
    "active": false,
    "avatarUrls": {
    "16x16": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=16&s=16",
    "24x24": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=24&s=24",
    "32x32": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=32&s=32",
    "48x48": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=48&s=48"
    },
    "displayName": "Mia Krystof",
    "key": "",
    "name": "",
    "self": "https://your-domain.atlassian.net/rest/api/3/user?accountId=5b10a2844c20165700ede21g"
    },
    "metadata": {
    "icon": "https://www.example.com/icon.png"
    },
    "name": "Component 1",
    "project": "HSP",
    "projectId": 10000,
    "realAssignee": {
    "accountId": "5b10a2844c20165700ede21g",
    "accountType": "atlassian",
    "active": false,
    "avatarUrls": {
    "16x16": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=16&s=16",
    "24x24": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=24&s=24",
    "32x32": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=32&s=32",
    "48x48": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=48&s=48"
    },
    "displayName": "Mia Krystof",
    "key": "",
    "name": "",
    "self": "https://your-domain.atlassian.net/rest/api/3/user?accountId=5b10a2844c20165700ede21g"
    },
    "realAssigneeType": "PROJECT_LEAD",
    "self": "https://your-domain.atlassian.net/rest/api/3/component/10000"
    },
    {
    "ari": "ari:cloud:compass:fdb3fdec-4e70-be56-11ee-0242ac120002:component/fdb3fdec-11ee-4e70-be56-0242ac120002/fdb3fdec-4e70-11ee-be56-0242ac120002",
    "assignee": {
    "accountId": "5b10a2844c20165700ede21g",
    "accountType": "atlassian",
    "active": false,
    "avatarUrls": {
    "16x16": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=16&s=16",
    "24x24": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=24&s=24",
    "32x32": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=32&s=32",
    "48x48": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=48&s=48"
    },
    "displayName": "Mia Krystof",
    "key": "",
    "name": "",
    "self": "https://your-domain.atlassian.net/rest/api/3/user?accountId=5b10a2844c20165700ede21g"
    },
    "assigneeType": "PROJECT_LEAD",
    "description": "This is a another Jira component",
    "id": "10050",
    "isAssigneeTypeValid": false,
    "lead": {
    "accountId": "5b10a2844c20165700ede21g",
    "accountType": "atlassian",
    "active": false,
    "avatarUrls": {
    "16x16": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=16&s=16",
    "24x24": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=24&s=24",
    "32x32": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=32&s=32",
    "48x48": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=48&s=48"
    },
    "displayName": "Mia Krystof",
    "key": "",
    "name": "",
    "self": "https://your-domain.atlassian.net/rest/api/3/user?accountId=5b10a2844c20165700ede21g"
    },
    "metadata": {
    "icon": "https://www.example.com/icon.png"
    },
    "name": "PXA",
    "project": "PROJECTKEY",
    "projectId": 10000,
    "realAssignee": {
    "accountId": "5b10a2844c20165700ede21g",
    "accountType": "atlassian",
    "active": false,
    "avatarUrls": {
    "16x16": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=16&s=16",
    "24x24": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=24&s=24",
    "32x32": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=32&s=32",
    "48x48": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=48&s=48"
    },
    "displayName": "Mia Krystof",
    "key": "",
    "name": "",
    "self": "https://your-domain.atlassian.net/rest/api/3/user?accountId=5b10a2844c20165700ede21g"
    },
    "realAssigneeType": "PROJECT_LEAD",
    "self": "https://your-domain.atlassian.net/rest/api/3/component/10000"
    }
    ]

    GET /rest/api/3/project/{projectIdOrKey}/components @scopes-current read:jira-work @scopes-beta read:project:jira, read:project.component:jira, read:user:jira, read:application-role:jira, read:avatar:jira, read:group:jira

  • Returns a paginated list of all components in a project. See the Get project components resource if you want to get a full list of versions without pagination.

    If your project uses Compass components, this API will return a list of Compass components that are linked to issues in that project.

    This operation can be accessed anonymously.

    Permissions required: Browse Projects project permission for the project.

    Parameters

    • params: {
          componentSource?: "auto" | "jira" | "compass";
          maxResults?: number;
          orderBy?:
              | "name"
              | "description"
              | "lead"
              | "issueCount"
              | "-description"
              | "+description"
              | "-name"
              | "+name"
              | "-issueCount"
              | "+issueCount"
              | "-lead"
              | "+lead";
          projectIdOrKey: string;
          query?: string;
          startAt?: number;
      }
      • OptionalcomponentSource?: "auto" | "jira" | "compass"

        The source of the components to return. Can be jira (default), compass or auto. When auto is specified, the API will return connected Compass components if the project is opted into Compass, otherwise it will return Jira components. Defaults to jira.

      • OptionalmaxResults?: number

        The maximum number of items to return per page.

      • OptionalorderBy?:
            | "name"
            | "description"
            | "lead"
            | "issueCount"
            | "-description"
            | "+description"
            | "-name"
            | "+name"
            | "-issueCount"
            | "+issueCount"
            | "-lead"
            | "+lead"

        Order the results by a field:

        • description Sorts by the component description.
        • issueCount Sorts by the count of issues associated with the component.
        • lead Sorts by the user key of the component's project lead.
        • name Sorts by component name.
      • projectIdOrKey: string

        The project ID or project key (case sensitive).

      • Optionalquery?: string

        Filter the results using a literal string. Components with a matching name or description are returned (case insensitive).

      • OptionalstartAt?: number

        The index of the first item to return in a page of results (page offset).

    Returns Promise<PageBeanComponentWithIssueCount>

    Returned if the request is successful.

    example:

    {
    "isLast": false,
    "maxResults": 2,
    "nextPage": "https://your-domain.atlassian.net/rest/api/3/project/PR/component?startAt=2&maxResults=2",
    "self": "https://your-domain.atlassian.net/rest/api/3/project/PR/component?startAt=0&maxResults=2",
    "startAt": 0,
    "total": 7,
    "values": [
    {
    "assignee": {
    "accountId": "5b10a2844c20165700ede21g",
    "accountType": "atlassian",
    "active": false,
    "avatarUrls": {
    "16x16": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=16&s=16",
    "24x24": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=24&s=24",
    "32x32": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=32&s=32",
    "48x48": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=48&s=48"
    },
    "displayName": "Mia Krystof",
    "key": "",
    "name": "",
    "self": "https://your-domain.atlassian.net/rest/api/3/user?accountId=5b10a2844c20165700ede21g"
    },
    "assigneeType": "PROJECT_LEAD",
    "componentBean": {
    "ari": "ari:cloud:compass:fdb3fdec-4e70-be56-11ee-0242ac120002:component/fdb3fdec-4e70-11ee-be56-0242ac120002/fdb3fdec-11ee-4e70-be56-0242ac120002",
    "assignee": {
    "accountId": "5b10a2844c20165700ede21g",
    "accountType": "atlassian",
    "active": false,
    "avatarUrls": {
    "16x16": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=16&s=16",
    "24x24": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=24&s=24",
    "32x32": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=32&s=32",
    "48x48": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=48&s=48"
    },
    "displayName": "Mia Krystof",
    "key": "",
    "name": "",
    "self": "https://your-domain.atlassian.net/rest/api/3/user?accountId=5b10a2844c20165700ede21g"
    },
    "assigneeType": "PROJECT_LEAD",
    "description": "This is a Jira component",
    "id": "10000",
    "isAssigneeTypeValid": false,
    "lead": {
    "accountId": "5b10a2844c20165700ede21g",
    "accountType": "atlassian",
    "active": false,
    "avatarUrls": {
    "16x16": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=16&s=16",
    "24x24": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=24&s=24",
    "32x32": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=32&s=32",
    "48x48": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=48&s=48"
    },
    "displayName": "Mia Krystof",
    "key": "",
    "name": "",
    "self": "https://your-domain.atlassian.net/rest/api/3/user?accountId=5b10a2844c20165700ede21g"
    },
    "metadata": {
    "icon": "https://www.example.com/icon.png"
    },
    "name": "Component 1",
    "project": "HSP",
    "projectId": 10000,
    "realAssignee": {
    "accountId": "5b10a2844c20165700ede21g",
    "accountType": "atlassian",
    "active": false,
    "avatarUrls": {
    "16x16": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=16&s=16",
    "24x24": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=24&s=24",
    "32x32": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=32&s=32",
    "48x48": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=48&s=48"
    },
    "displayName": "Mia Krystof",
    "key": "",
    "name": "",
    "self": "https://your-domain.atlassian.net/rest/api/3/user?accountId=5b10a2844c20165700ede21g"
    },
    "realAssigneeType": "PROJECT_LEAD",
    "self": "https://your-domain.atlassian.net/rest/api/3/component/10000"
    },
    "description": "This is a Jira component",
    "id": "10000",
    "isAssigneeTypeValid": false,
    "issueCount": 1,
    "lead": {
    "accountId": "5b10a2844c20165700ede21g",
    "accountType": "atlassian",
    "active": false,
    "avatarUrls": {
    "16x16": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=16&s=16",
    "24x24": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=24&s=24",
    "32x32": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=32&s=32",
    "48x48": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=48&s=48"
    },
    "displayName": "Mia Krystof",
    "key": "",
    "name": "",
    "self": "https://your-domain.atlassian.net/rest/api/3/user?accountId=5b10a2844c20165700ede21g"
    },
    "name": "Component 1",
    "project": "HSP",
    "projectId": 10000,
    "realAssignee": {
    "accountId": "5b10a2844c20165700ede21g",
    "accountType": "atlassian",
    "active": false,
    "avatarUrls": {
    "16x16": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=16&s=16",
    "24x24": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=24&s=24",
    "32x32": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=32&s=32",
    "48x48": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=48&s=48"
    },
    "displayName": "Mia Krystof",
    "key": "",
    "name": "",
    "self": "https://your-domain.atlassian.net/rest/api/3/user?accountId=5b10a2844c20165700ede21g"
    },
    "realAssigneeType": "PROJECT_LEAD",
    "self": "https://your-domain.atlassian.net/rest/api/3/component/10000"
    },
    {
    "assignee": {
    "accountId": "5b10a2844c20165700ede21g",
    "accountType": "atlassian",
    "active": false,
    "avatarUrls": {
    "16x16": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=16&s=16",
    "24x24": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=24&s=24",
    "32x32": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=32&s=32",
    "48x48": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=48&s=48"
    },
    "displayName": "Mia Krystof",
    "key": "",
    "name": "",
    "self": "https://your-domain.atlassian.net/rest/api/3/user?accountId=5b10a2844c20165700ede21g"
    },
    "assigneeType": "PROJECT_LEAD",
    "componentBean": {
    "ari": "ari:cloud:compass:fdb3fdec-4e70-be56-11ee-0242ac120002:component/fdb3fdec-11ee-4e70-be56-0242ac120002/fdb3fdec-4e70-11ee-be56-0242ac120002",
    "assignee": {
    "accountId": "5b10a2844c20165700ede21g",
    "accountType": "atlassian",
    "active": false,
    "avatarUrls": {
    "16x16": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=16&s=16",
    "24x24": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=24&s=24",
    "32x32": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=32&s=32",
    "48x48": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=48&s=48"
    },
    "displayName": "Mia Krystof",
    "key": "",
    "name": "",
    "self": "https://your-domain.atlassian.net/rest/api/3/user?accountId=5b10a2844c20165700ede21g"
    },
    "assigneeType": "PROJECT_LEAD",
    "description": "This is a another Jira component",
    "id": "10050",
    "isAssigneeTypeValid": false,
    "lead": {
    "accountId": "5b10a2844c20165700ede21g",
    "accountType": "atlassian",
    "active": false,
    "avatarUrls": {
    "16x16": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=16&s=16",
    "24x24": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=24&s=24",
    "32x32": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=32&s=32",
    "48x48": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=48&s=48"
    },
    "displayName": "Mia Krystof",
    "key": "",
    "name": "",
    "self": "https://your-domain.atlassian.net/rest/api/3/user?accountId=5b10a2844c20165700ede21g"
    },
    "metadata": {
    "icon": "https://www.example.com/icon.png"
    },
    "name": "PXA",
    "project": "PROJECTKEY",
    "projectId": 10000,
    "realAssignee": {
    "accountId": "5b10a2844c20165700ede21g",
    "accountType": "atlassian",
    "active": false,
    "avatarUrls": {
    "16x16": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=16&s=16",
    "24x24": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=24&s=24",
    "32x32": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=32&s=32",
    "48x48": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=48&s=48"
    },
    "displayName": "Mia Krystof",
    "key": "",
    "name": "",
    "self": "https://your-domain.atlassian.net/rest/api/3/user?accountId=5b10a2844c20165700ede21g"
    },
    "realAssigneeType": "PROJECT_LEAD",
    "self": "https://your-domain.atlassian.net/rest/api/3/component/10000"
    },
    "description": "This is a another Jira component",
    "id": "10050",
    "isAssigneeTypeValid": false,
    "issueCount": 5,
    "lead": {
    "accountId": "5b10a2844c20165700ede21g",
    "accountType": "atlassian",
    "active": false,
    "avatarUrls": {
    "16x16": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=16&s=16",
    "24x24": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=24&s=24",
    "32x32": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=32&s=32",
    "48x48": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=48&s=48"
    },
    "displayName": "Mia Krystof",
    "key": "",
    "name": "",
    "self": "https://your-domain.atlassian.net/rest/api/3/user?accountId=5b10a2844c20165700ede21g"
    },
    "name": "PXA",
    "project": "PROJECTKEY",
    "projectId": 10000,
    "realAssignee": {
    "accountId": "5b10a2844c20165700ede21g",
    "accountType": "atlassian",
    "active": false,
    "avatarUrls": {
    "16x16": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=16&s=16",
    "24x24": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=24&s=24",
    "32x32": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=32&s=32",
    "48x48": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=48&s=48"
    },
    "displayName": "Mia Krystof",
    "key": "",
    "name": "",
    "self": "https://your-domain.atlassian.net/rest/api/3/user?accountId=5b10a2844c20165700ede21g"
    },
    "realAssigneeType": "PROJECT_LEAD",
    "self": "https://your-domain.atlassian.net/rest/api/3/component/10000"
    }
    ]
    }

    GET /rest/api/3/project/{projectIdOrKey}/component @scopes-current read:jira-work @scopes-beta read:project:jira, read:project.component:jira, read:user:jira, read:application-role:jira, read:avatar:jira, read:group:jira

  • Updates a component. Any fields included in the request are overwritten. If leadAccountId is an empty string ("") the component lead is removed.

    This operation can be accessed anonymously.

    Permissions required: Administer projects project permission for the project containing the component or Administer Jira global permission.

    Parameters

    Returns Promise<ProjectComponent>

    Returned if the request is successful.

    example:

    {
    "ari": "ari:cloud:compass:fdb3fdec-4e70-be56-11ee-0242ac120002:component/fdb3fdec-4e70-11ee-be56-0242ac120002/fdb3fdec-11ee-4e70-be56-0242ac120002",
    "assignee": {
    "accountId": "5b10a2844c20165700ede21g",
    "accountType": "atlassian",
    "active": false,
    "avatarUrls": {
    "16x16": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=16&s=16",
    "24x24": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=24&s=24",
    "32x32": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=32&s=32",
    "48x48": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=48&s=48"
    },
    "displayName": "Mia Krystof",
    "key": "",
    "name": "",
    "self": "https://your-domain.atlassian.net/rest/api/3/user?accountId=5b10a2844c20165700ede21g"
    },
    "assigneeType": "PROJECT_LEAD",
    "description": "This is a Jira component",
    "id": "10000",
    "isAssigneeTypeValid": false,
    "lead": {
    "accountId": "5b10a2844c20165700ede21g",
    "accountType": "atlassian",
    "active": false,
    "avatarUrls": {
    "16x16": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=16&s=16",
    "24x24": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=24&s=24",
    "32x32": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=32&s=32",
    "48x48": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=48&s=48"
    },
    "displayName": "Mia Krystof",
    "key": "",
    "name": "",
    "self": "https://your-domain.atlassian.net/rest/api/3/user?accountId=5b10a2844c20165700ede21g"
    },
    "metadata": {
    "icon": "https://www.example.com/icon.png"
    },
    "name": "Component 1",
    "project": "HSP",
    "projectId": 10000,
    "realAssignee": {
    "accountId": "5b10a2844c20165700ede21g",
    "accountType": "atlassian",
    "active": false,
    "avatarUrls": {
    "16x16": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=16&s=16",
    "24x24": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=24&s=24",
    "32x32": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=32&s=32",
    "48x48": "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=48&s=48"
    },
    "displayName": "Mia Krystof",
    "key": "",
    "name": "",
    "self": "https://your-domain.atlassian.net/rest/api/3/user?accountId=5b10a2844c20165700ede21g"
    },
    "realAssigneeType": "PROJECT_LEAD",
    "self": "https://your-domain.atlassian.net/rest/api/3/component/10000"
    }

    PUT /rest/api/3/component/{id} @scopes-current manage:jira-project @scopes-beta read:project:jira, read:user:jira, write:project.component:jira, read:application-role:jira, read:avatar:jira, read:group:jira, read:project.component:jira

  • Method to initialize the class. Normally used to set up validation rules.

    Returns void