Process Feedback Codebeamer specific

First of all, create a Codebeamer project where the feedback will be collected. If you want to collect more information than the summary and a description, you have to create a new tracker and add additional fields to it. Further information to creating and customizing trackers can be found at here.

To configure Stages, the id of the target tracker is required. For custom fields, the customField ids are required. There are several ways to find them out (see below Configuration.xml - How to get the project, tracker and field id).

Stages uses the Codebeamer REST interface with Swagger V3 to create the trackerItem. See here for more information.

Codebeamer config.xml

To enable the following configuration section must be added in the conf/config.xml:

<stages-config>
  <!-- Insert this block to your stages config.xml file -->
  <feedback-systems>
    <feedback-system name="codebeamer">
      <host url="https://codebeamer.example.com/cb" ident="codebeamer1" displayName="Example Codebeamer">
 
        <!-- Credentials for a (technical) user who is allowed to create items in the Codebeamer project and tracker -->
        <property name="user" value="user" />
        <property name="password" value="secret" />
 
        <!-- Define the tracker (with the trackerId and the correspoinding keyName) where the item should be created in  -->
        <property name="trackerId" value="2267" />
        <property name="keyName" value="TASK" />
 
        <!-- The summary field will always be available and is automatically mapped to the Codebeamer name field -->
 
        <!--
        See common feedback documentation
        - The "target" defines the id of the custom field in Codebeamer (e.g. "customfield_10101").
        - Optional: The targetType defines the type of the Codebeamer trackerField. Supported tracker fields see below.
        -->
        <attributes>
            <attribute ident="description" type="text" target="description" />
        </attributes>
 
        <!--
        See common feedback documentation
        The "target" defines the id for the custom field in Codebeamer (e.g. "10000").
        Optional: The targetType defines the type of the Codebeamer tracker field. Supported tracker fields see below.
        -->
        <system-attribute-mappings>
            <attribute source="elementUrl" target="10000" targetType="UrlFieldValue" />
            <attribute source="creatorUsername" target="1000" targetType="UserReference" />
        </system-attribute-mappings>
 
        <!--
        See common feedback documentation
        The "target" defines the id for the custom field in Codebeamer (e.g. "10000").
        Optional: The targetType defines the type of the Codebeamer field. Supported Codebeamer fields see below.
        -->
        <custom-attribute-mappings>
            <attribute value="Stages" target="10001" />
        </custom-attribute-mappings>
      </host>
    </feedback-system>
  </feedback-systems>
</stages-config>

Basic Authentication

You need credentials for a (technical) user who is allowed to create issues in the Codebeamer project. This user also needs to be allowed to use the Codebeamer APIs (be part of the Group 'API User')

<property name="user" value="user" />
<property name="password" value="secret" />

Codebeamer Server

The user and password are the normal username and password of the user.

Codebeamer Tracker

The trackerId of the targeted tracker. The keyName (short name) of the targeted tracker.

Mandatory fields

For all issues, the fields name and description are mandatory. Name is automatically configured and will display the summary text. Description has to be configured in the configuration.xml as followed:

<attributes>
        <!-- map the stages-description (ident) into the codebeamer-description (target) -->
        <attribute ident="description" type="text" target="description" />
</attributes>

How to get the project, tracker and field id

Version 1: Via REST commands

Just enter the following REST statements into your browser and login with your Codebeamer username and password. Requires Permission to use Codebeamer APIs (be part of the Group 'API User')

  • For project id: GET {serveradress}/cb/rest/v3/projects
  • For tracker id: GET {serveradress}/cb/rest/v3/projects/{projectId}/trackers
  • For field id: GET {serveradress}/cb/rest/v3/trackers/{trackerId}

Or see Codebeamer documentation for Getting list of available projects, Getting list of trackers in a project, Getting the fields of a tracker.

Version 2: Via Codebeamer and calculation

To locate the project id, edit the project via the context points and look into the url:

To locate the tracker id, go to the tracker page and look into the url:

Or configure the tracker via the context points and read the id directly in Codebeamer:

To calculate the field id, configure the tracker with the field, select the field tab and click on the field name. At the top, a number is displayed in brackets.

This number has to be added to a base number, depending on the type of the field:

  • CustomFields: Base Number is 10000, add the displayed number to get the field id.
  • ChoiceField: Base Number is 1000, add the displayed number to get the field id.

Supported Codebeamer Tracker Fields and Types

  • Description: Custom Field:
    • Type Text: targetType=“TextFieldValue” (default if no targetType is set)
    • Type Wikilink/Url: targetType=“UrlFieldValue” (required to set hyperlinks)
  • Description: Choice Field:
    • Type Text: targetType=“UserReference” (required to set the requester automatically. Requester's username must be identical in Stages and Codebeamer)