Update learning path unit order

Method

Method Description
learningpath.unitUpdateOrder Change the order of the learning path units.

Request parameters

{
    "learning_path_id": {LearningPathId},
    "units": [
        {"exam_id": {ExamId}},
        {"course_id": {CourseId}},
        ...
    ]
}

Response parameters

{
    "units": [
        {
            "order": {Order},
            "exam_id": {ExamId},
            "course_id": {CourseId},
            ...
        },
        ...
    ],
    "completed": {Completed}
}

The units list must contain every unit currently included into the learning path exactly once, in the new order. A missing, extra, repeated or unknown unit results in an error and the order is not changed. This operation never adds or removes units - use unit add and unit delete for that.

Variable Type Appearance Description
{LearningPathId} Integer Mandatory Learning path id.
units Array Mandatory All units of the learning path in the new order. Each entry contains exactly one of {ExamId} or {CourseId}.
{ExamId} Integer Optional Assessment id.
{CourseId} Integer Optional Course id.
{Order} Integer Mandatory New position of the unit, starting from 1. The response "units" list is only present when {Completed} is true, see unit list for all fields.
{Completed} Boolean Mandatory Indicates whether action was successfully completed or not.