-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Labels
enhancementNew feature or requestNew feature or request
Description
Description
Implement the ability to add a new tenant to the system.
Requirements
- Create API endpoint: POST /api/v1/tenants
- Validate tenant data (name, email, phone, etc.)
- Store tenant in database
- Return created tenant with ID
- Handle errors appropriately
Request Body Example
{
"firstName": "string",
"lastName": "string",
"email": "string",
"phone": "string",
"nationalId": "string",
"dateOfBirth": "YYYY-MM-DD",
"emergencyContactName": "string",
"emergencyContactPhone": "string",
"status": "active"
}Expected Response
Success (201): Returns created tenant object
Error (400): Validation errors
Error (409): Duplicate email or national ID
Error (500): Server errors
Additional Notes
Validate email format and uniqueness
Validate phone number format
Ensure national ID is unique
Consider document upload for ID verification
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request