For testing, use [email protected] and 123456. It has all the data setup. Alternative would be [email protected] and 123456.
Log into a society account.
Required Fields:
emailAddress
: Society's email address (string)password
: Society's password (string)
Update society details, specifically the admin status.
isadmin
(boolean): Specifies if the user should be an admin.
200 OK
: Successfully updated society details.message
: "Success".
500 Internal Server Error
: Something went wrong while updating the society details.
Retrieve available maintenance heads and room size details.
Response Fields:
roomSizes
: List of available room sizes (array)maintenanceHeads
: List of maintenance heads (array)
Register a society with basic details, structure and maintenance details.
"roomDetails": {
"1": {
"roomNumber": 101,
"roomSize": "1BHK",
"maintainanceAmount": 5000,
"maintainanceHeadAmount": {
"1": 1500,
"2": 500,
"3": 2000,
"4": 1000
}
},
"2": {
"roomNumber": 102,
"roomSize": "2BHK",
"maintainanceAmount": 7500,
"maintainanceHeadAmount": {
"1": 1500,
"2": 500,
"3": 2000,
"4": 1000,
"5": 2500
}
},
"3": {
"roomNumber": 103,
"roomSize": "1BHK",
"maintainanceAmount": 5000,
"maintainanceHeadAmount": {
"1": 1500,
"2": 500,
"3": 2000,
"4": 1000
}
},
"4": {
"roomNumber": 104,
"roomSize": "2BHK",
"maintainanceAmount": 7500,
"maintainanceHeadAmount": {
"1": 1500,
"2": 500,
"3": 2000,
"4": 1000,
"5": 2500
}
}
}
Wing 2, 3, 4 Similar to Wing 1, but the name and room details may vary as shown above.
Notes Each wing contains details about its rooms and the maintenance amounts. The structure allows adding multiple wings, with each wing having its own room details and maintenance breakdown. Usage Example You can use this JSON structure to create or retrieve society-related data such as the number of wings, room details, and maintenance calculations. This format ensures that all relevant details are organized hierarchically for easy processing and access.
css Copy code
This markdown file provides a detailed and structured documentation of the JSON object, ensuring clear explanation of each field and the possible values they can have.
You said: Give all in a single file ChatGPT said: ChatGPT Here is the entire markdown documentation in a single .md file format:
md Copy code
This section describes the information related to the society.
name
(string): The name of the society.dateOfEstablishment
(string, date): The date the society was established inYYYY-MM-DD
format.emailAddress
(string): The email address of the society.password
(string): The password associated with the society account.phoneNumber
(string): The phone number of the society.address
(string): The address of the society.city
(string): The city where the society is located.state
(string): The state where the society is located.pincode
(string): The postal code (PIN code) of the society.numberOfWings
(string): The number of wings in the society.registrationNumber
(string): The registration number of the society.
{
"name": "name",
"dateOfEstablishment": "2024-08-11",
"emailAddress": "[email protected]",
"password": "123456",
"phoneNumber": "8879806920",
"address": "address",
"city": "city",
"state": "state",
"pincode": "400012",
"numberOfWings": "4",
"registrationNumber": "registrationNumber"
}
**Required Fields:**
```json
{ "societyDetails":{
"name": "name",
"dateOfEstablishment": "2024-08-11",
"emailAddress": "[email protected]",
"password": "123456",
"phoneNumber": "8879806920",
"address": "address",
"city": "city",
"state": "state",
"pincode": "400012",
"numberOfWings": "4",
"registrationNumber": "registrationNumber"
},
"wingInformation": {
"1": {
"name": "wing1",
"floors": 10,
"roomsPerFloor": 2,
"roomDetails": {
"1": {
"roomNumber": 101,
"roomSize": "1BHK",
"maintainanceAmount": 5000,
"maintainanceHeadAmount": {
"1": 1500,
"2": 500,
"3": 2000,
"4": 1000
}
}
}
}
}
}
Retrieve all owner details with room information.
Response Fields:
id
: Owner ID (integer)wingName
: Wing name (string)roomsize
: Room size (string)roomno
: Room number (integer)firstname
: Owner's first name (string)lastname
: Owner's last name (string)
Download an Excel file containing basic wing and room details.
Upload an Excel file with basic wing and room details.
Required Fields:
excel
: Excel file (file)
Retrieve notices for a society with optional filtering parameters.
id
(number, optional): Filter by specific notice IDactive
(boolean, optional): Filter by notice statustrue
: Get active noticesfalse
: Get inactive notices
start_date
(string, optional): Filter by start date (format: YYYY-MM-DD)end_date
(string, optional): Filter by end date (format: YYYY-MM-DD)categoryId
(number, optional): Filter by category ID
{
"categories": [...], // List of available notice categories
"notices": [...] // List of notices matching the filter criteria
}
{
"categories": [...], // List of available notice categories
"notices": "No Notices Found for the given filters"
}
400 Bad Request
: Invalid input for active parameter500 Internal Server Error
: Server-side error occurred
Create a new notice for a society.
title
(string, required): Title of the noticecontent
(string, required): Content of the noticestart_date
(string, required): Start date of the notice (format: YYYY-MM-DD)end_date
(string, required): End date of the notice (format: YYYY-MM-DD)categoryId
(number, required): Category ID for the notice
{
"title": "string",
"content": "string",
"start_date": "YYYY-MM-DD",
"end_date": "YYYY-MM-DD",
"category": "number"
}
422 Unprocessable Entity
: Invalid inputs with validation errors500 Internal Server Error
: Server-side error occurred
Update an existing notice.
id
(number, required): ID of the notice to update
title
(string, optional): Updated titlecontent
(string, optional): Updated contentstart_date
(string, optional): Updated start date (format: YYYY-MM-DD)end_date
(string, optional): Updated end date (format: YYYY-MM-DD)categoryId
(number, optional): Updated category ID
{
"title": "string",
"content": "string",
"start_date": "YYYY-MM-DD",
"end_date": "YYYY-MM-DD",
"category": "number"
}
400 Bad Request
: Invalid notice ID404 Not Found
: Notice not found500 Internal Server Error
: Server-side error occurred
Delete a notice.
id
(number, required): ID of the notice to delete
{
"message": "Successfully Deleted"
}
400 Bad Request
: Invalid notice ID403 Forbidden
: User doesn't have permission to delete the notice500 Internal Server Error
: Server-side error occurred
Retrieve complaints for a society based on provided filters.
socid
: Society ID (string)active
: Active status of the complaint (string: "true" or "false")start_date
: Start date to filter complaints (string, format: YYYY-MM-DD)end_date
: End date to filter complaints (string, format: YYYY-MM-DD)category
: Category ID to filter complaints (number)complaintId
: Specific complaint ID to retrieve (number)
200 OK
: Successfully retrieved the complaints{ "complaints": [ // Array of complaint objects ] }
400 Bad Request
: Invalidactive
parameter (not "true" or "false")500 Internal Server Error
: Something went wrong while retrieving the complaints
Create a new complaint in the system.
{
"society_id": number,
"title": string,
"description": string,
"category_id": number
}
201 Created
: Successfully created the complaint{ "complaintId": number }
500 Internal Server Error
: Something went wrong while creating the complaint
Update an existing complaint.
id
: ID of the complaint to update (number)
{
"title": string (optional),
"description": string (optional),
"categoryId": number (optional)
}
201 Created
: Successfully updated the complaint{ // Updated complaint object }
400 Bad Request
: Invalid complaint ID format403 Forbidden
: User does not have permission to update this complaint500 Internal Server Error
: Something went wrong while updating the complaint
Delete an existing complaint.
id
: ID of the complaint to delete (number)
204 Created
: Successfully deleted the complaint{ "message": "Successfully Deleted" }
400 Bad Request
: Invalid complaint ID format403 Forbidden
: User does not have permission to delete this complaint500 Internal Server Error
: Something went wrong while deleting the complaint
Retrieve comments for a specific complaint.
{
"complaint_id": number
}
200 OK
: Successfully retrieved the comments{ "commentId": [ // Array of comment objects ] }
422 Unprocessable Entity
: Invalid input data{ "message": "Invalid inputs passed, please check your data", "data": [ // Array of validation errors ] }
500 Internal Server Error
: Something went wrong while retrieving comments
Add a new comment to a complaint.
{
"complaint_id": number,
"content": string
}
complaint_id
: Required, must be numericcontent
: Required, non-empty string
201 Created
: Successfully created the comment{ "commentId": number }
422 Unprocessable Entity
: Invalid input data{ "message": "Invalid inputs passed, please check your data", "data": [ // Array of validation errors ] }
500 Internal Server Error
: Something went wrong while creating the comment
Delete a specific comment from a complaint.
{
"complaint_id": number,
"comment_id": number
}
complaint_id
: Required, must be numericcomment_id
: Required, must be numeric
200 OK
: Successfully deleted the comment{ "message": "Successfully Deleted" }
400 Bad Request
: Invalid comment ID format403 Forbidden
: User does not have permission to delete this comment422 Unprocessable Entity
: Invalid input data{ "message": "Invalid inputs passed, please check your data", "data": [ // Array of validation errors ] }
500 Internal Server Error
: Something went wrong while deleting the comment