Docs home

Learner Batch Transfer

Moves learners from one batch to another: they are enrolled in the new batch and removed from the old one. Optionally carries over their progress when both batches teach the same subjects.

POST/batch/transfer
Learner Batch Transfer
curl --request POST \
  --url 'https://<your-api-host>/nuSource/api/v1/batch/transfer' \
  --header 'APIKEY: <your-api-key>' \
  --header 'ORGID: <your-org-id>' \
  --form 'JSONString={"from_master_batch_id":"3329","to_master_batch_id":108623,"student_ids":[91139236],"progress_transfer":1,"force_stud_transfer":0}'
{
  "code": 200,
  "message": "Success",
  "addedToQueue": 1
}

Access: Institute admins, plus custom roles that can manage learners or batches. Both batches must be in your organizations.

Request body: form-data with JSONString containing this JSON, and optionally a CSV file in a field named uploaded_file (up to 50 MB) with an Email column listing the learners to move instead of student_ids.

BodyJSONString
from_master_batch_idintegerrequired
Batch the learners are in now.
to_master_batch_idintegerrequired
Batch to move them to.
student_idsarray of integersYes, unless you upload a CSV
User IDs of the learners. Up to 100.
1 copies progress to the new batch. Both batches must have the same subjects.
1 skips learners already in the new batch instead of failing.
With a CSV: downloads a CSV of learners already in the new batch.
With a CSV: downloads a CSV listing each email and its error.
Response200application/json
codeinteger
Example: 200
messagestring
Example: Success
Example: 1

Notes: Errors: "Invalid Master Batch Id.", "You are not authorized to access this master batch.", "No student is selected", "Only 100 students can be transferred at a time.", "Invalid Student ID's" (learner not in your institute), "N out of M students already exist in the batch" (send force_stud_transfer: 1 to skip them), "All students already exist in batch", "The subjects do not match on both the batches. Please uncheck this option to proceed.". With a CSV, every email must match a learner enrolled in one of the two batches. Rate limit: 30 requests per 1 minute; going over locks you out for 30 minutes.

Updated yesterday

Ask AI