codevsfp CLIsfp serverlibraries

Work Item

Get a work item by ID

sfp work-item get

Get a work item by ID

USAGE
  $ sfp work-item get -i <value> [--json] [--repository <value>] [-e <value>] [-t <value>] [--sfp-server-url
    <value>]

FLAGS
  -e, --email=<value>              Email address for authenticated user. Ignored if --application-token is provided. Can
                                   be set via SFP_SERVER_USER env var.
  -i, --id=<value>                 (required) Work item ID or key
  -t, --application-token=<value>  Application token for CI/CD authentication. Can be set via SFP_SERVER_TOKEN env var
                                   (CLI flags take precedence over env vars).
      --repository=<value>         The repository identifier. E.g `owner/repo` for GitHub/GitLab or `org/project/repo`
                                   for Azure DevOps
      --sfp-server-url=<value>     URL of the SFP server. Can be set via SFP_SERVER_URL env var or config: sfp
                                   config:set server-url

GLOBAL FLAGS
  --json  Format output as json.

DESCRIPTION
  Get a work item by ID

  Retrieves details of a work item. The platform is automatically determined from the project's workItems.provider
  configuration.

  ## Prerequisites
  The project must have workItems.provider configured:
  $ sfp server project update -r owner/repo -p configuration.workItems -v '{"provider": "jira"}'

  ## ID Formats by Platform
  - jira: Use issue key (e.g., DP-6, PROJ-123)
  - github: Use issue number (e.g., 42)
  - azure-devops: Use work item ID (e.g., 123)

  ## Examples
  # Get a Jira issue
  $ sfp work-item get --repository owner/repo --id DP-6

  # Get a GitHub issue
  $ sfp work-item get --repository owner/repo --id 42

  # Get an Azure DevOps work item
  $ sfp work-item get --repository owner/repo --id 123

See code: src/commands/work-item/get.ts

sfp work-item list

List work items for a project

USAGE
  $ sfp work-item list [--json] [--repository <value>] [-e <value>] [-t <value>] [--sfp-server-url <value>]
    [--status <value>] [--assignee <value>] [--type <value>] [--max-results <value>]

FLAGS
  -e, --email=<value>              Email address for authenticated user. Ignored if --application-token is provided. Can
                                   be set via SFP_SERVER_USER env var.
  -t, --application-token=<value>  Application token for CI/CD authentication. Can be set via SFP_SERVER_TOKEN env var
                                   (CLI flags take precedence over env vars).
      --assignee=<value>           Filter by assignee
      --max-results=<value>        [default: 50] Maximum number of results to return (1-100)
      --repository=<value>         The repository identifier. E.g `owner/repo` for GitHub/GitLab or `org/project/repo`
                                   for Azure DevOps
      --sfp-server-url=<value>     URL of the SFP server. Can be set via SFP_SERVER_URL env var or config: sfp
                                   config:set server-url
      --status=<value>             Filter by work item status
      --type=<value>               Filter by work item type (e.g., bug, story, task)

GLOBAL FLAGS
  --json  Format output as json.

DESCRIPTION
  List work items for a project

  Lists work items with optional filters. The platform and boards are automatically determined from the project's
  configuration.

  ## Prerequisites
  The project must have workItems configuration set:
  $ sfp server project update -r owner/repo -p configuration.workItems -v '{"provider": "jira", "boards": ["DP",
  "PROJ"]}'

  ## Configuration
  - provider: The work item platform (jira, azure-devops, github)
  - boards: Array of boards/projects to filter (Jira project keys, Azure DevOps area paths)

  ## Filter Options
  - status: Filter by status (e.g., "To Do", "In Progress", "Done")
  - assignee: Filter by assignee
  - type: Filter by work item type (e.g., "bug", "story", "task")

  ## Examples
  # List all work items (uses boards from project config)
  $ sfp work-item list --repository owner/repo

  # Filter by status
  $ sfp work-item list --repository owner/repo --status "In Progress"

  # Filter by assignee with limit
  $ sfp work-item list --repository owner/repo --assignee john.doe --max-results 10

See code: src/commands/work-item/list.ts

On this page