5.7.248. Bugzilla::Extension::Workflows::WebService::ManageComponents

5.7.248.1. NAME

Bugzilla::Extension::Workflows::WebService::ManageComponents - API for handling Administration actions for the Bugzilla::Extension::Workflows::ManageComponents extension.

5.7.248.2. DESCRIPTION

This part of the Bugzilla API allows you to manage roles on, and basic data for, components and sub_components.

5.7.248.3. METHODS

See Bugzilla::WebService for a description of what STABLE, UNSTABLE, and EXPERIMENTAL mean, and for more description about error codes.

get_components EXPERIMENTAL

Description

Search for components and sub_components using the supplied parameters.

Params

pools:
array of strings of pool names to search on.
teams:
array of strings of team names to search on.
show_nested:
boolean Include all sub_components when a parent matches.
product:
string Product name to search on.
show_inactive:
boolean Include inactive components.
Example call

Get all the components my teams owns, including any sub_components owned by other teams, or no teams.

{
  "method":"ManageComponents.get_components",
  "params":[
    {
      "teams": ["My first team", "My second team"],
      "show_nested": 1
    }
  ]
}

Returns

An array of hashes of components and sub_components.

"components": [
  {
    "can_manage": 1,
    "default_assignee": "fu@example.com",
    "default_docs_contact": "",
    "default_pool": {
      "id": 2
      "name": "A backlog",
      "team": {
        "id": 1,
        "name": "A Team"
      },
    },
    "default_qa_contact": "qe@example.com",
    "description": "This is a very important component",
    "id": 17
    "initial_cc": "",
    "name": "my_component",
    "template": "Default",
    "type": "component",
  }
]

update_components EXPERIMENTAL

Description

Update components and sub components.

Params

This API expects and array , named components, containg a hash for each component or sub component you wish to edit. Fields that are absent from the has are not updated.

name:
string The name of the component being modified. Either this or ID must be set.
id:
int The ID of the component being modified. Either this or name must be set. For sub_components it is best to use the ID as names are not unique.
type:
string What type of component is is, ‘component’ or ‘sub_component’. Defaults to ‘component’.
default_assignee:
string The login name of the new default assignee.
default_qa_contact:
string The login name of the new default qa contact.
default_docs_contact:
string The login name of the new default docs contact.
description:
string The new description for the component.
template:
int|string The name or ID of the comment template to use on the new bug page.
default_pool:
int|string The name or ID of the new default pool for this component.
agile_team:
int|string The name or ID of the agile team to use as the sub-team for this component.
initial_cc:
Either string A comma separated list of user logins to add to the CCs when a new bug is opened for this component. Or a hash with the same in a key names “add”, “set”, or “remove”.
Example call

Change the default assignee for a component.

{
  "method": "ManageComponents.update_components",
  "params": [
    {
      "components": [
        {
          "default_assignee": "dave@example.com",
          "id": 11,
          "type": "component"
        }
      ]
    }
  ]
}

Returns

An array of hashes of components and sub_components that were modified. If a supplied component was not updated then it will not be returned.

"components": [
  {
    "agile_team": {
      "id": 2,
      "name": "B Team"
    }
    "can_manage": 1,
    "default_assignee": "fu@example.com",
    "default_docs_contact": "",
    "default_pool": {
      "id": 2
      "name": "A backlog",
      "team": {
        "id": 1,
        "name": "A Team"
      },
    },
    "default_qa_contact": "qe@example.com",
    "description": "This is a very important component",
    "id": 17
    "initial_cc": "",
    "name": "my_component",
    "template": "Default",
    "type": "component",
  }
]

This documentation undoubtedly has bugs; if you find some, please file them here.