This resource represents project features. Use it to get the list of features for a project and modify the state of a feature. The project feature endpoint is available only for Jira Software, both for team- and company-managed projects.

Hierarchy

  • CommonHttpService
    • ProjectFeaturesService

Constructors

  • Internal

    Create a new instance of the service.

    Parameters

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

    Returns ProjectFeaturesService

Methods

  • Returns the list of features for a project.

    Parameters

    • params: {
          projectIdOrKey: string;
      }
      • projectIdOrKey: string

        The ID or (case-sensitive) key of the project.

    Returns Promise<ContainerForProjectFeatures>

    Returned if the request is successful.

    example:

    {
    "features": [
    {
    "feature": "jsw.classic.roadmap",
    "imageUri": "https://jira.atlassian.com/s/sb53l8/b/3/ab8a7691e4738b4f147e293f0864adfd5b8d3c85/_/download/resources/com.atlassian.jira.rest:classic-project-features/simple-roadmap-feature.svg",
    "localisedDescription": "Your roadmap is an optimized location to create and manage your epics.",
    "localisedName": "Roadmap",
    "prerequisites": [],
    "projectId": 10001,
    "state": "ENABLED",
    "toggleLocked": true
    },
    {
    "feature": "jsw.classic.backlog",
    "imageUri": "https://jira.atlassian.com/s/sb53l8/b/3/ab8a7691e4738b4f147e293f0864adfd5b8d3c85/_/download/resources/com.atlassian.jira.rest:classic-project-features/simple-backlog-feature.svg",
    "localisedDescription": "Plan and prioritize work in a dedicated space. To enable and configure the backlog for each board, go to board settings.",
    "localisedName": "Backlog",
    "prerequisites": [],
    "projectId": 10001,
    "state": "ENABLED",
    "toggleLocked": true
    }
    ]
    }

    GET /rest/api/3/project/{projectIdOrKey}/features @scopes-current read:jira-work @scopes-beta read:project.feature:jira

  • Sets the state of a project feature.

    Parameters

    • params: {
          featureKey: string;
          projectFeatureState: ProjectFeatureState;
          projectIdOrKey: string;
      }
      • featureKey: string

        The key of the feature.

      • projectFeatureState: ProjectFeatureState

        Details of the feature state change.

        {
        "state": "ENABLED"
        }
      • projectIdOrKey: string

        The ID or (case-sensitive) key of the project.

    Returns Promise<ContainerForProjectFeatures>

    Returned if the request is successful.

    example:

    {
    "features": [
    {
    "feature": "jsw.classic.roadmap",
    "imageUri": "https://jira.atlassian.com/s/sb53l8/b/3/ab8a7691e4738b4f147e293f0864adfd5b8d3c85/_/download/resources/com.atlassian.jira.rest:classic-project-features/simple-roadmap-feature.svg",
    "localisedDescription": "Your roadmap is an optimized location to create and manage your epics.",
    "localisedName": "Roadmap",
    "prerequisites": [],
    "projectId": 10001,
    "state": "ENABLED",
    "toggleLocked": true
    },
    {
    "feature": "jsw.classic.backlog",
    "imageUri": "https://jira.atlassian.com/s/sb53l8/b/3/ab8a7691e4738b4f147e293f0864adfd5b8d3c85/_/download/resources/com.atlassian.jira.rest:classic-project-features/simple-backlog-feature.svg",
    "localisedDescription": "Plan and prioritize work in a dedicated space. To enable and configure the backlog for each board, go to board settings.",
    "localisedName": "Backlog",
    "prerequisites": [],
    "projectId": 10001,
    "state": "ENABLED",
    "toggleLocked": true
    }
    ]
    }

    PUT /rest/api/3/project/{projectIdOrKey}/features/{featureKey} @scopes-current manage:jira-project @scopes-beta write:project.feature:jira, read:project.feature:jira

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

    Returns void