EMS-UGC API Docs
Manage

Batches

Batch Management APIs

Base URL: http://192.168.100.250/


Endpoints

MethodEndpointDescription
GET/batchesList all batches
GET/batches/{id}Get single batch (includes students relation)
POST/batchesCreate new batch
PUT/batches/{id}Update batch
DELETE/batches/{id}Delete batch
POST/batches/{id}/set-currentSet as current batch

List

Get All

GET /batches
Accept: application/json

View Single

GET /batches/{id}
Accept: application/json

Response includes students relation.


Create

POST /batches
Content-Type: application/json

Request Body:

{
  "name": "2077",
  "fiscal_year": "2081/82",
  "batchNepali": "२०७७",
  "start_date": "2024-01-01",
  "end_date": "2025-12-31",
  "is_current": true
}

Update

PUT /batches/{id}
Content-Type: application/json

Request Body:

{
  "name": "2078",
  "fiscal_year": "2082/83",
  "batchNepali": "२०७८",
  "start_date": "2025-01-01",
  "end_date": "2026-12-31",
  "is_current": false
}

Delete

DELETE /batches/{id}

Set as Current

POST /batches/{id}/set-current

On this page