Skip to content

DI-Portal-GF-004 Create Package

Design Item ID: DI-Portal-GF-004
Design Item Name: Create Package Related Design Items: -
Related API:

Revision History:

Date Description

The functionality provides user with the ability to create package.
Package is package with kind = package. Package is versioning entity that can contain API documentation. Package can be created under workspace or group.

  1. User navigates to APIHUB Portal → workspace, or
  2. User navigates to APIHUB Portal → workspace → group
  1. User clicks Create →  Package button.
  2. The system opens Create Package popup with the following fields:
    • Name - required field.
    • Workspace/Parent Group - required field. By default, the value equals to the current group/workspace. It is possible to select group only under current workspace.
      • API to select group - GET /api/v2/packages:
        • kind = group
        • showAllDescendants = true
        • textFilter = <user input> if user searches group.
    • Alias - required field. Alias must be unique within parent group/workspace. If alias is not unique, the system shows the following message when user clicks Create button: “Alias “%s” is already reserved. Please use another alias.”
    • Description - short summary for package.
    • Private - if checked, then package will be private and by default, will be visible to current user only.
  3. User clicks Create.
  4. The system creates new package.
    • API to create group - POST /api/v2/packages:
      • parentId = <Id of workspace/group under which current package is created>
      • kind = package
      • name = <user input from Name field>
      • alias = <user input from Alias field>
      • description = <user input from Description field>
      • defaultRole. If Private checkbox is selected, then defaultRole = none. Otherwise, defaultRole = viewer.
  5. The system opens newly create package.
package