ConnectCloud Developers

Import a bundle; with dryRun only the plan is returned (desk:admin)

POST /api/desk/v1/bundle

Module: Desk · operationId: importBundle · Tag: Configuration · Auth: access token (Authorization: Bearer <accessToken>)

Request body

application/json (required)

  • bundle (Bundle): Portable configuration (format desk.config/v1). All references use keys: types name their workflow key, spaces their type keys, labels their space key, categories their path of names, layouts "cf.".
    • format (string, required): Format of the bundle (one of desk.config/v1)
    • categories (array of object): Categories
    • description (string): Description of the bundle
    • enums (object): Value lists by kind
    • fields (array of object): Custom fields
    • key (string): Key of the bundle (templates)
    • labels (array of object): Labels
    • matrix (object): Priority matrix (impact × urgency)
    • name (string): Name of the bundle
    • prefix (string): Suggested prefix for conflicting keys
    • priorities (array of object): Priorities
    • projectTemplates (array of object): Project templates: type is the project type key; blueprint tasks name their typeId by type key, blueprint fields are keyed by field key
    • projectTypes (array of object): Project types: workflow, taskSpace and taskType are keys, layout "cf.", billing as in the project type settings
    • spaces (array of object): Spaces
    • teams (array of object): Teams
    • types (array of object): Item types
    • workflows (array of object): Workflows
  • dryRun (boolean): Only return the plan, change nothing
  • prefix (string): Up to 8 lower-case letters/digits for conflicting keys; default: the bundle suggestion

Example:

{
  "bundle": {
    "categories": [
      {
        "path": [
          "Netzwerk",
          "WLAN"
        ]
      }
    ],
    "format": "desk.config/v1",
    "key": "muster-it",
    "labels": [
      {
        "color": "warning",
        "name": "vor-ort"
      }
    ],
    "name": "Konfiguration Muster IT"
  },
  "dryRun": true,
  "prefix": "imp"
}

Responses

  • 200 Result or plan (application/json)
  • 409 in_use: the imported configuration would make a mail source, route, AI candidate, portal form or platform feedback kind deliver into a work type or a space with only work types (application/json)

Fields of the 200 answer:

  • changes (array of object): What the import does (or did) per entry
    • action (string): created: new; reused: an equal entry exists; renamed: created under another key (as) (one of created, reused, renamed)
    • as (string): Key the entry was created under (renamed)
    • key (string): Key of the entry in the bundle
    • kind (string): Kind of configuration entry (workflow, type, field, space, …)
    • name (string): The name or label of the entry, when it has one
  • dryRun (boolean): Only the plan: nothing was changed

Example 200 answer:

{
  "changes": [
    {
      "action": "reused",
      "key": "service",
      "kind": "workflow",
      "name": "Service"
    },
    {
      "action": "reused",
      "key": "stoerung",
      "kind": "type",
      "name": "Störung"
    },
    {
      "action": "reused",
      "key": "SUP",
      "kind": "space",
      "name": "Support"
    },
    {
      "action": "created",
      "key": "projekt",
      "kind": "workflow",
      "name": "Projekt"
    },
    {
      "action": "created",
      "key": "PRJ",
      "kind": "space",
      "name": "Kundenprojekte"
    },
    {
      "action": "created",
      "key": "kundenprojekt",
      "kind": "projectType",
      "name": "Kundenprojekt"
    },
    {
      "action": "created",
      "key": "erp-einfuehrung",
      "kind": "projectTemplate",
      "name": "ERP-Einführung"
    }
  ],
  "dryRun": true
}

Example request

curl -X POST 'https://api.mbcom.cloud/api/desk/v1/bundle' \
  -H "Authorization: Bearer $ACCESS_TOKEN" \
  -H 'Content-Type: application/json' \
  --data '{"bundle":{"categories":[{"path":["Netzwerk","WLAN"]}],"format":"desk.config/v1","key":"muster-it","labels":[{"color":"warning","name":"vor-ort"}],"name":"Konfiguration Muster IT"},"dryRun":true,"prefix":"imp"}'

View as Markdown · Interactive reference · OpenAPI