Skip to content

Physical Infrastructure

Base URL: http://192.168.100.250/


Method Endpoint Description
GET /physical-infrastructure List infrastructure by type
GET /physical-infrastructure/{id} Get single infrastructure
POST /physical-infrastructure Create infrastructure
PUT /physical-infrastructure/{id} Update infrastructure
DELETE /physical-infrastructure/{id} Delete infrastructure
DELETE /physical-infrastructure/images/{imageId} Delete image
POST /physical-infrastructure/create-type Create infrastructure type

GET /physical-infrastructure?infra_type=building
Accept: application/json

Query Parameters:

Param Description Example
infra_type Infrastructure type building, hostel, land, lab, library, furnitureEquipmentVehicle

GET /physical-infrastructure/{id}
Accept: application/json

POST /physical-infrastructure
Content-Type: application/json

Request Body:

{
"infra_type": "building",
"houseName": "Science Block",
"areaCoveredByBuilding": 2500,
"totalRoom": 20,
"totalClassroom": 12,
"condition": "Good"
}

PUT /physical-infrastructure/{id}
Content-Type: application/json

Request Body: Same as Create.


DELETE /physical-infrastructure/{id}?infra_type=building

DELETE /physical-infrastructure/images/{imageId}

POST /physical-infrastructure/create-type
Content-Type: application/json

Request Body:

{
"name": "Auditorium"
}