Skip to content
Snippets Groups Projects
kypo-adaptive-training-swagger-open-api.yaml 177 KiB
Newer Older
---
swagger: "2.0"
info:
  version: "Version: 2.2.1"
  title: "KYPO Adaptive Training Service - API Reference"
host: "localhost:8082"
basePath: "/kypo-adaptive-training/api/v1"
tags:
- name: "Export Imports"
- name: "Phases"
- name: "Tasks"
- name: "Training definitions"
- name: "Training instances"
- name: "Training runs"
- name: "Visualizations"
schemes:
- "http"
- "https"
paths:
  /exports/training-definitions/{definitionId}:
    get:
      tags:
      - "Export Imports"
      summary: "Get exported training definitions and phase."
      description: ""
      operationId: "getExportedTrainingDefinitionAndPhases"
      produces:
      - "application/octet-stream"
      parameters:
      - name: "definitionId"
        in: "path"
        description: "Id of training definition"
        required: true
        type: "integer"
        format: "int64"
      responses:
        200:
          description: "Training definitions and phase found and exported."
          schema:
            $ref: "#/definitions/TrainingDefinitionExportDTO"
41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787
        404:
          description: "Training definition not found."
          schema:
            $ref: "#/definitions/ApiError"
        500:
          description: "Unexpected condition was encountered."
          schema:
            $ref: "#/definitions/ApiError"
      security:
      - bearerAuth: []
  /exports/training-instances/{instanceId}:
    get:
      tags:
      - "Export Imports"
      summary: "Archive training instance"
      description: ""
      operationId: "archiveTrainingInstance"
      produces:
      - "application/octet-stream"
      parameters:
      - name: "instanceId"
        in: "path"
        description: "Id of training instance"
        required: true
        type: "integer"
        format: "int64"
      responses:
        200:
          description: "Training instance archived."
          schema:
            $ref: "#/definitions/TrainingInstanceArchiveDTO"
        404:
          description: "Training instance not found."
          schema:
            $ref: "#/definitions/ApiError"
        409:
          description: "Cannot archive instance that is not finished."
          schema:
            $ref: "#/definitions/ApiError"
        500:
          description: "Unexpected condition was encountered."
          schema:
            $ref: "#/definitions/ApiError"
      security:
      - bearerAuth: []
  /imports/training-definitions:
    post:
      tags:
      - "Export Imports"
      summary: "Import training definition with phase."
      description: ""
      operationId: "importTrainingDefinition"
      consumes:
      - "application/json"
      produces:
      - "application/json"
      parameters:
      - in: "body"
        name: "body"
        description: "Training definition to be imported"
        required: true
        schema:
          $ref: "#/definitions/ImportTrainingDefinitionDTO"
      - name: "fields"
        in: "query"
        description: "Fields which should be returned in REST API response"
        required: false
        type: "string"
      responses:
        200:
          description: "Training definition imported."
          schema:
            $ref: "#/definitions/TrainingDefinitionByIdDTO"
        500:
          description: "Unexpected condition was encountered."
          schema:
            $ref: "#/definitions/ApiError"
      security:
      - bearerAuth: []
  /training-definitions:
    get:
      tags:
      - "Training definitions"
      summary: "Get all Training Definitions."
      description: ""
      operationId: "findAllTrainingDefinitions"
      produces:
      - "application/json"
      parameters:
      - name: "fields"
        in: "query"
        description: "Fields which should be returned in REST API response"
        required: false
        type: "string"
      - name: "page"
        in: "query"
        description: "Results page you want to retrieve (0..N)"
        required: false
        type: "integer"
        x-example: 0
      - name: "size"
        in: "query"
        description: "Number of records per page."
        required: false
        type: "integer"
        x-example: 20
      - name: "sort"
        in: "query"
        description: "Sorting criteria in the format: property(,asc|desc). Default\
          \ sort order is ascending. Multiple sort criteria are supported."
        required: false
        type: "array"
        items:
          type: "string"
          example: "asc"
        collectionFormat: "multi"
        x-example: "asc"
      responses:
        200:
          description: "The requested resources have been found."
          schema:
            type: "array"
            items:
              $ref: "#/definitions/TrainingDefinitionByIdDTO"
        500:
          description: "Unexpected condition was encountered."
          schema:
            $ref: "#/definitions/ApiError"
      security:
      - bearerAuth: []
    post:
      tags:
      - "Training definitions"
      summary: "Create Training Definition"
      description: ""
      operationId: "createTrainingDefinition"
      consumes:
      - "application/json"
      produces:
      - "application/json"
      parameters:
      - in: "body"
        name: "body"
        description: "Training Definition to be created"
        required: false
        schema:
          $ref: "#/definitions/TrainingDefinitionCreateDTO"
      - name: "fields"
        in: "query"
        description: "Fields which should be returned in REST API response"
        required: false
        type: "string"
      responses:
        200:
          description: "The Training definition has been created."
          schema:
            $ref: "#/definitions/TrainingDefinitionByIdDTO"
        400:
          description: "The provided training definition is not valid"
          schema:
            $ref: "#/definitions/ApiError"
        500:
          description: "Unexpected condition was encountered."
          schema:
            $ref: "#/definitions/ApiError"
      security:
      - bearerAuth: []
    put:
      tags:
      - "Training definitions"
      summary: "Update Training Definition"
      description: "Only unreleased training definition can be updated"
      operationId: "updateTrainingDefinition"
      consumes:
      - "application/json"
      produces:
      - "application/json"
      parameters:
      - in: "body"
        name: "body"
        description: "Training definition to be updated"
        required: false
        schema:
          $ref: "#/definitions/TrainingDefinitionUpdateDTO"
      responses:
        200:
          description: "The training definition has been updated."
        400:
          description: "The provided training definition is not valid"
          schema:
            $ref: "#/definitions/ApiError"
        404:
          description: "The training definition has not been found."
          schema:
            $ref: "#/definitions/ApiError"
        409:
          description: "Cannot edit released or archived training definition."
          schema:
            $ref: "#/definitions/ApiError"
        500:
          description: "Unexpected condition was encountered."
          schema:
            $ref: "#/definitions/ApiError"
      security:
      - bearerAuth: []
  /training-definitions/designers:
    get:
      tags:
      - "Training definitions"
      summary: "Get designers."
      description: ""
      operationId: "getDesigners"
      produces:
      - "application/json"
      parameters:
      - name: "givenName"
        in: "query"
        description: "Given name filter."
        required: false
        type: "string"
      - name: "familyName"
        in: "query"
        description: "Family name filter."
        required: false
        type: "string"
      - name: "page"
        in: "query"
        description: "Results page you want to retrieve (0..N)"
        required: false
        type: "integer"
        x-example: 0
      - name: "size"
        in: "query"
        description: "Number of records per page."
        required: false
        type: "integer"
        x-example: 20
      - name: "sort"
        in: "query"
        description: "Sorting criteria in the format: property(,asc|desc). Default\
          \ sort order is ascending. Multiple sort criteria are supported."
        required: false
        type: "array"
        items:
          type: "string"
          example: "asc"
        collectionFormat: "multi"
        x-example: "asc"
      responses:
        200:
          description: "The designers have been found."
          schema:
            $ref: "#/definitions/UserInfoRestResource"
        500:
          description: "Unexpected condition was encountered."
          schema:
            $ref: "#/definitions/ApiError"
      security:
      - bearerAuth: []
  /training-definitions/for-organizers:
    get:
      tags:
      - "Training definitions"
      summary: "Get all Training Definitions for organizers."
      description: ""
      operationId: "findAllTrainingDefinitionsForOrganizers"
      produces:
      - "application/json"
      parameters:
      - name: "state"
        in: "query"
        description: "State of the training definition"
        required: true
        type: "string"
        enum:
        - "PRIVATED"
        - "RELEASED"
        - "ARCHIVED"
        - "UNRELEASED"
      - name: "fields"
        in: "query"
        description: "Fields which should be returned in REST API response"
        required: false
        type: "string"
      - name: "page"
        in: "query"
        description: "Results page you want to retrieve (0..N)"
        required: false
        type: "integer"
        x-example: 0
      - name: "size"
        in: "query"
        description: "Number of records per page."
        required: false
        type: "integer"
        x-example: 20
      - name: "sort"
        in: "query"
        description: "Sorting criteria in the format: property(,asc|desc). Default\
          \ sort order is ascending. Multiple sort criteria are supported."
        required: false
        type: "array"
        items:
          type: "string"
          example: "asc"
        collectionFormat: "multi"
        x-example: "asc"
      responses:
        200:
          description: "The Training definitions have been found."
          schema:
            type: "array"
            items:
              $ref: "#/definitions/TrainingDefinitionInfoDTO"
        500:
          description: "Unexpected condition was encountered."
          schema:
            $ref: "#/definitions/ApiError"
      security:
      - bearerAuth: []
  /training-definitions/organizers:
    get:
      tags:
      - "Training definitions"
      summary: "Get organizers."
      description: ""
      operationId: "getOrganizers"
      produces:
      - "application/json"
      parameters:
      - name: "givenName"
        in: "query"
        description: "Given name filter."
        required: false
        type: "string"
      - name: "familyName"
        in: "query"
        description: "Family name filter."
        required: false
        type: "string"
      - in: "body"
        name: "body"
        description: "Pagination support."
        required: false
        schema:
          $ref: "#/definitions/Pageable"
      - name: "page"
        in: "query"
        description: "Results page you want to retrieve (0..N)"
        required: false
        type: "integer"
        x-example: 0
      - name: "size"
        in: "query"
        description: "Number of records per page."
        required: false
        type: "integer"
        x-example: 20
      - name: "sort"
        in: "query"
        description: "Sorting criteria in the format: property(,asc|desc). Default\
          \ sort order is ascending. Multiple sort criteria are supported."
        required: false
        type: "array"
        items:
          type: "string"
          example: "asc"
        collectionFormat: "multi"
        x-example: "asc"
      responses:
        200:
          description: "The organizers have been found."
          schema:
            $ref: "#/definitions/UserInfoRestResource"
        500:
          description: "Unexpected condition was encountered."
          schema:
            $ref: "#/definitions/ApiError"
      security:
      - bearerAuth: []
  /training-definitions/{definitionId}:
    get:
      tags:
      - "Training definitions"
      summary: "Get Training Definition by Id."
      description: ""
      operationId: "findTrainingDefinitionById"
      produces:
      - "application/json"
      parameters:
      - name: "definitionId"
        in: "path"
        description: "ID of training definition to be retrieved."
        required: true
        type: "integer"
        format: "int64"
      - name: "fields"
        in: "query"
        description: "Fields which should be returned in REST API response"
        required: false
        type: "string"
      responses:
        200:
          description: "The Training definition has been found."
          schema:
            $ref: "#/definitions/TrainingDefinitionByIdDTO"
        404:
          description: "The Training definition has not been found."
          schema:
            $ref: "#/definitions/ApiError"
        500:
          description: "Unexpected condition was encountered."
          schema:
            $ref: "#/definitions/ApiError"
      security:
      - bearerAuth: []
    post:
      tags:
      - "Training definitions"
      summary: "Clone training definition"
      description: "Only released and archived training definitions can be cloned"
      operationId: "cloneTrainingDefinition"
      produces:
      - "application/json"
      parameters:
      - name: "definitionId"
        in: "path"
        description: "Id of training definition to be cloned"
        required: true
        type: "integer"
        format: "int64"
      - name: "title"
        in: "query"
        description: "Title of cloned definition"
        required: true
        type: "string"
      responses:
        200:
          description: "The Training definition has been cloned."
          schema:
            $ref: "#/definitions/TrainingDefinitionByIdDTO"
        404:
          description: "The Training definition has not been found."
          schema:
            $ref: "#/definitions/ApiError"
        500:
          description: "Unexpected condition was encountered."
          schema:
            $ref: "#/definitions/ApiError"
      security:
      - bearerAuth: []
    delete:
      tags:
      - "Training definitions"
      summary: "Delete training definition"
      description: "Released training definition cannot be deleted"
      operationId: "deleteTrainingDefinition"
      produces:
      - "application/json"
      parameters:
      - name: "definitionId"
        in: "path"
        description: "Id of training definition to be deleted"
        required: true
        type: "integer"
        format: "int64"
      responses:
        200:
          description: "The Training definition has been deleted."
        404:
          description: "The Training definition has not been found."
          schema:
            $ref: "#/definitions/ApiError"
        409:
          description: "Cannot delete released training definition."
          schema:
            $ref: "#/definitions/ApiError"
        500:
          description: "Unexpected condition was encountered."
          schema:
            $ref: "#/definitions/ApiError"
      security:
      - bearerAuth: []
  /training-definitions/{definitionId}/authors:
    get:
      tags:
      - "Training definitions"
      summary: "Get authors."
      description: ""
      operationId: "getAuthors"
      produces:
      - "application/json"
      parameters:
      - name: "definitionId"
        in: "path"
        description: "ID of the training definition which contains authors you want\
          \ to retrieve."
        required: true
        type: "integer"
        format: "int64"
      - name: "givenName"
        in: "query"
        description: "Given name filter."
        required: false
        type: "string"
      - name: "familyName"
        in: "query"
        description: "Family name filter."
        required: false
        type: "string"
      - in: "body"
        name: "body"
        description: "Pagination support."
        required: false
        schema:
          $ref: "#/definitions/Pageable"
      - name: "page"
        in: "query"
        description: "Results page you want to retrieve (0..N)"
        required: false
        type: "integer"
        x-example: 0
      - name: "size"
        in: "query"
        description: "Number of records per page."
        required: false
        type: "integer"
        x-example: 20
      - name: "sort"
        in: "query"
        description: "Sorting criteria in the format: property(,asc|desc). Default\
          \ sort order is ascending. Multiple sort criteria are supported."
        required: false
        type: "array"
        items:
          type: "string"
          example: "asc"
        collectionFormat: "multi"
        x-example: "asc"
      responses:
        200:
          description: "The authors have been found."
          schema:
            $ref: "#/definitions/UserInfoRestResource"
        404:
          description: "The training definition has not been found"
          schema:
            $ref: "#/definitions/ApiError"
        500:
          description: "Unexpected condition was encountered."
          schema:
            $ref: "#/definitions/ApiError"
      security:
      - bearerAuth: []
    put:
      tags:
      - "Training definitions"
      summary: "Edit authors."
      description: ""
      operationId: "editAuthors"
      produces:
      - "application/json"
      parameters:
      - name: "definitionId"
        in: "path"
        description: "ID of training definition to be updated."
        required: true
        type: "integer"
        format: "int64"
      - name: "authorsAddition"
        in: "query"
        description: "Ids of the users to be added to the training definition."
        required: false
        type: "array"
        items:
          type: "integer"
          format: "int64"
        collectionFormat: "multi"
      - name: "authorsRemoval"
        in: "query"
        description: "Ids of the users to be removed from the training definition."
        required: false
        type: "array"
        items:
          type: "integer"
          format: "int64"
        collectionFormat: "multi"
      - name: "page"
        in: "query"
        description: "Results page you want to retrieve (0..N)"
        required: false
        type: "integer"
        x-example: 0
      - name: "size"
        in: "query"
        description: "Number of records per page."
        required: false
        type: "integer"
        x-example: 20
      - name: "sort"
        in: "query"
        description: "Sorting criteria in the format: property(,asc|desc). Default\
          \ sort order is ascending. Multiple sort criteria are supported."
        required: false
        type: "array"
        items:
          type: "string"
          example: "asc"
        collectionFormat: "multi"
        x-example: "asc"
      responses:
        200:
          description: "The authors have been updated."
          schema:
            $ref: "#/definitions/UserInfoRestResource"
        404:
          description: "The training definition has not been found."
          schema:
            $ref: "#/definitions/ApiError"
        500:
          description: "Unexpected condition was encountered."
          schema:
            $ref: "#/definitions/ApiError"
      security:
      - bearerAuth: []
  /training-definitions/{definitionId}/designers-not-in-training-definition:
    get:
      tags:
      - "Training definitions"
      summary: "Get designers not in given training definition."
      description: ""
      operationId: "findDesignersNotInGivenTrainingDefinition"
      produces:
      - "application/json"
      parameters:
      - name: "definitionId"
        in: "path"
        description: "ID of the training definition which do not contains authors\
          \ you want to retrieve."
        required: true
        type: "integer"
        format: "int64"
      - name: "givenName"
        in: "query"
        description: "Given name filter."
        required: false
        type: "string"
      - name: "familyName"
        in: "query"
        description: "Family name filter."
        required: false
        type: "string"
      - name: "page"
        in: "query"
        description: "Results page you want to retrieve (0..N)"
        required: false
        type: "integer"
        x-example: 0
      - name: "size"
        in: "query"
        description: "Number of records per page."
        required: false
        type: "integer"
        x-example: 20
      - name: "sort"
        in: "query"
        description: "Sorting criteria in the format: property(,asc|desc). Default\
          \ sort order is ascending. Multiple sort criteria are supported."
        required: false
        type: "array"
        items:
          type: "string"
          example: "asc"
        collectionFormat: "multi"
        x-example: "asc"
      responses:
        200:
          description: "The designers have been found."
          schema:
            $ref: "#/definitions/UserInfoRestResource"
        404:
          description: "The training definition has not been found."
          schema:
            $ref: "#/definitions/ApiError"
        500:
          description: "Unexpected condition was encountered."
          schema:
            $ref: "#/definitions/ApiError"
      security:
      - bearerAuth: []
  /training-definitions/{definitionId}/phases:
    get:
      tags:
      - "Phases"
      summary: "Get all phase"
      description: "Get all phase associated with specified training definition"
      operationId: "getPhases"
      produces:
      - "application/json"
      parameters:
      - name: "definitionId"
        in: "path"
        description: "Training definition ID"
        required: true
        type: "integer"
        format: "int64"
      responses:
        200:
          description: "Phases returned"
          schema:
            type: "object"
        500:
          description: "Unexpected application error"
      security:
      - bearerAuth: []
    post:
      tags:
      - "Phases"
      summary: "Create a new phase"
      description: "Creates a new default phase with a specified type"
      operationId: "createPhase"
      produces:
      - "application/json"
      parameters:
      - name: "definitionId"
        in: "path"
        description: "Training definition ID"
        required: true
        type: "integer"
        format: "int64"
      - in: "body"
        name: "body"
        description: "Phase type"
        required: true
        schema:
          $ref: "#/definitions/PhaseCreateDTO"
      responses:
        200:
          description: "successful operation"
          schema:
            $ref: "#/definitions/AbstractLevelDTO"
        201:
          description: "Phase created"
        500:
          description: "Unexpected application error"
      security:
      - bearerAuth: []
    put:
      tags:
      - "Phases"
      summary: "Update phases"
      description: ""
      operationId: "updatePhases"
      produces:
      - "application/json"
      parameters:
      - name: "definitionId"
        in: "path"
        description: "Phase ID"
        required: true
        type: "integer"
        format: "int64"
      - in: "body"
        name: "body"
        description: "List of phases to be updated"
        required: false
        schema:
          type: "array"
          items:
            $ref: "#/definitions/AbstractPhaseUpdateDTO"
      responses:
        200:
          description: "Phases updated"
        500:
          description: "Unexpected application error"
      security:
      - bearerAuth: []
  /training-definitions/{definitionId}/phases/{phaseIdFrom}/move-to/{newPosition}:
    put:
      tags:
      - "Phases"
      summary: "Move phase to specified order"
      description: ""
      operationId: "movePhaseToSpecifiedOrder"
      produces:
      - "application/json"
      parameters:
      - name: "definitionId"
        in: "path"
        description: "Training definition ID"
        required: true
        type: "integer"
        format: "int64"
      - name: "phaseIdFrom"
        in: "path"
        description: "Phase ID - from"
        required: true
        type: "integer"
        format: "int64"
      - name: "newPosition"
        in: "path"
        description: "Position (order) to which the phase should be moved"
        required: true
        type: "integer"
        format: "int32"
      responses:
        200:
          description: "Phase moved to specified order"
        500:
          description: "Unexpected application error"
      security:
      - bearerAuth: []
  /training-definitions/{definitionId}/phases/{phaseId}:
    get:
      tags:
      - "Phases"
      summary: "Get phase by ID"
      description: ""
      operationId: "getPhase"
      produces:
      - "application/json"
      parameters:
      - name: "phaseId"
        in: "path"
        description: "Phase ID"
        required: true
        type: "integer"
        format: "int64"
      responses:
        200:
          description: "Phase returned"
          schema:
            $ref: "#/definitions/AbstractLevelDTO"
        500:
          description: "Unexpected application error"
      security:
      - bearerAuth: []
    delete:
      tags:
      - "Phases"
      summary: "Remove phase by ID"
      description: ""
      operationId: "getPhase"
      produces:
      - "application/json"
      parameters:
      - name: "phaseId"
        in: "path"
        description: "Phase ID"
        required: true
        type: "integer"
        format: "int64"
      responses:
        200:
          description: "Phase removed"
          schema:
            $ref: "#/definitions/AbstractLevelDTO"
        500:
          description: "Unexpected application error"
      security:
      - bearerAuth: []
  /training-definitions/{definitionId}/phases/{phaseId}/info:
    put:
      tags:
      - "Phases"
      summary: "Update info phase"
      description: ""
      operationId: "updateInfoPhase"
      produces:
      - "application/json"
      parameters:
      - name: "phaseId"
        in: "path"
        description: "Phase ID"
        required: true
        type: "integer"
        format: "int64"
      - in: "body"
        name: "body"
        description: "Info phase to be updated"
        required: false
        schema:
          $ref: "#/definitions/InfoPhaseUpdateDTO"
      responses:
        200:
          description: "Info phase updated"
          schema:
            $ref: "#/definitions/InfoPhaseDTO"
        500:
          description: "Unexpected application error"
      security:
      - bearerAuth: []
  /training-definitions/{definitionId}/phases/{phaseId}/questionnaire:
    put:
      tags:
      - "Phases"
      summary: "Update questionnaire phase"
      description: ""
      operationId: "updateQuestion"
      produces:
      - "application/json"
      parameters:
      - name: "phaseId"
        in: "path"
        description: "Phase ID"
        required: true
        type: "integer"
        format: "int64"
      - in: "body"
        name: "body"
        description: "Questionnaire to be updated"
        required: false
        schema:
          $ref: "#/definitions/QuestionnaireUpdateDTO"
      responses:
        200:
          description: "Questionnaire phase updated"
          schema:
            $ref: "#/definitions/QuestionnairePhaseDTO"
        500:
          description: "Unexpected application error"
      security:
      - bearerAuth: []
  /training-definitions/{definitionId}/phases/{phaseId}/tasks:
    post:
      tags:
      - "Tasks"
      summary: "Create a new task in a phase"
      description: "Creates a new default task in a specified training phase"
      operationId: "createTask"
      produces:
      - "application/json"
      parameters:
      - name: "phaseId"
        in: "path"
        description: "Training phase ID"
        required: true
        type: "integer"
        format: "int64"
      responses:
        200:
          description: "successful operation"
          schema:
            $ref: "#/definitions/TaskDTO"
        201:
          description: "Task created"
        500:
          description: "Unexpected application error"
      security:
      - bearerAuth: []
  /training-definitions/{definitionId}/phases/{phaseId}/tasks/{taskIdFrom}/move-to/{newPosition}:
    put:
      tags:
      - "Tasks"
      summary: "Move task to specified order"
      description: ""
      operationId: "moveTaskToSpecifiedOrder"
      produces:
      - "application/json"
      parameters: