krsyer-server-monitor-pro 1.0.4 → 1.0.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/guestguru-api/.idea/guestguru-api.iml +9 -0
- package/guestguru-api/.idea/misc.xml +6 -0
- package/guestguru-api/.idea/modules.xml +8 -0
- package/guestguru-api/.idea/vcs.xml +6 -0
- package/guestguru-api/API_DESIGN_GUIDE.md +140 -0
- package/guestguru-api/API_DOCUMENTATION.md +504 -0
- package/guestguru-api/API_REQUIREMENTS_TENANTS.md +110 -0
- package/guestguru-api/AVAILABLE_TENANT_ENDPOINTS.md +137 -0
- package/guestguru-api/BACKEND_INSTRUCTIONS.md +77 -0
- package/guestguru-api/DINING_MODULE_INTEGRATION.md +175 -0
- package/guestguru-api/FRONTEND_FINANCE_MODULE.md +151 -0
- package/guestguru-api/README.md +93 -0
- package/guestguru-api/app.json +12 -0
- package/guestguru-api/database.sqlite +0 -0
- package/guestguru-api/eas.json +21 -0
- package/guestguru-api/ecosystem.config.js +19 -0
- package/guestguru-api/fix_db_schema.js +77 -0
- package/guestguru-api/list_columns.js +27 -0
- package/guestguru-api/package.json +34 -0
- package/guestguru-api/postman_backend_v2.json +1745 -0
- package/guestguru-api/postman_collection.json +477 -0
- package/guestguru-api/postman_environment.json +17 -0
- package/guestguru-api/public/icon.png +0 -0
- package/guestguru-api/public/icon_b64.txt +1 -0
- package/guestguru-api/readd_column.js +27 -0
- package/guestguru-api/server.js +263 -0
- package/guestguru-api/test_cashfree_connection.js +52 -0
- package/lib/controllers/cloudflareController.js +1 -1
- package/lib/controllers/dockerController.js +1 -1
- package/lib/controllers/networkController.js +1 -1
- package/lib/controllers/serverController.js +1 -1
- package/lib/ecosystem.config.js +1 -1
- package/lib/middleware/saasAuth.js +1 -1
- package/lib/public/script.js +4 -0
- package/lib/routes/cloudflareRoutes.js +1 -1
- package/lib/routes/dockerRoutes.js +1 -1
- package/lib/routes/networkRoutes.js +1 -1
- package/lib/routes/serverRoutes.js +1 -1
- package/lib/server.js +1 -1
- package/lib/services/cashfreeService.js +1 -1
- package/lib/views/activate.html +98 -0
- package/lib/views/index.html +5 -0
- package/license-portal/server.js +23 -11
- package/license-portal/views/pricing.html +5 -3
- package/package.json +1 -1
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
|
2
|
+
<module type="JAVA_MODULE" version="4">
|
|
3
|
+
<component name="NewModuleRootManager" inherit-compiler-output="true">
|
|
4
|
+
<exclude-output />
|
|
5
|
+
<content url="file://$MODULE_DIR$" />
|
|
6
|
+
<orderEntry type="inheritedJdk" />
|
|
7
|
+
<orderEntry type="sourceFolder" forTests="false" />
|
|
8
|
+
</component>
|
|
9
|
+
</module>
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
|
2
|
+
<project version="4">
|
|
3
|
+
<component name="ProjectRootManager" version="2" languageLevel="JDK_21" default="true" project-jdk-name="21" project-jdk-type="JavaSDK">
|
|
4
|
+
<output url="file://$PROJECT_DIR$/out" />
|
|
5
|
+
</component>
|
|
6
|
+
</project>
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
|
2
|
+
<project version="4">
|
|
3
|
+
<component name="ProjectModuleManager">
|
|
4
|
+
<modules>
|
|
5
|
+
<module fileurl="file://$PROJECT_DIR$/.idea/guestguru-api.iml" filepath="$PROJECT_DIR$/.idea/guestguru-api.iml" />
|
|
6
|
+
</modules>
|
|
7
|
+
</component>
|
|
8
|
+
</project>
|
|
@@ -0,0 +1,140 @@
|
|
|
1
|
+
# SaaS PG Management App - Frontend Design & API Guide
|
|
2
|
+
|
|
3
|
+
This guide outlines the backend API endpoints mapped to the required mobile screens for the SaaS PG Management Application. It is divided by **User Roles** (Super Admin, PG Owner, Resident).
|
|
4
|
+
|
|
5
|
+
## 🌍 Base URL
|
|
6
|
+
`http:// <server-ip> :5000/api`
|
|
7
|
+
|
|
8
|
+
---
|
|
9
|
+
|
|
10
|
+
## 🔐 Authentication Module
|
|
11
|
+
**Screens**: Login, Sign Up, Splash Screen
|
|
12
|
+
|
|
13
|
+
### 1. Login
|
|
14
|
+
* **Endpoint**: `POST /auth/signin`
|
|
15
|
+
* **Payload**: `{ "email": "...", "password": "..." }`
|
|
16
|
+
* **Response**: Returns `accessToken`, `role`, `ownerId`.
|
|
17
|
+
* **UI Design Notes**:
|
|
18
|
+
* Simple form with Email & Password.
|
|
19
|
+
* **Action**: Store `accessToken` securely (AsyncStorage).
|
|
20
|
+
* **Logic**: Redirect based on `role` ('superadmin' -> SA Dashboard, 'admin' -> Owner Dashboard, 'customer' -> Resident App).
|
|
21
|
+
|
|
22
|
+
### 2. Sign Up (PG Owners)
|
|
23
|
+
* **Endpoint**: `POST /auth/signup`
|
|
24
|
+
* **Payload**: `{ "name": "...", "email": "...", "password": "...", "phone": "...", "role": "admin" }`
|
|
25
|
+
* **UI Design Notes**:
|
|
26
|
+
* Registration form for new PG Owners.
|
|
27
|
+
* Show "Free Plan Active" success message after signup.
|
|
28
|
+
|
|
29
|
+
---
|
|
30
|
+
|
|
31
|
+
## 👑 Super Admin App
|
|
32
|
+
**Target Audience**: You (Platform Owner)
|
|
33
|
+
|
|
34
|
+
### 1. Dashboard / Owner Management
|
|
35
|
+
Manage the PG Owners who use your SaaS platform.
|
|
36
|
+
* **Endpoint**: `GET /superadmin/owners`
|
|
37
|
+
* **Display Data**: List of owners (Name, Email, Plan Name, Status).
|
|
38
|
+
* **UI Design Notes**:
|
|
39
|
+
* List view card for each PG Owner.
|
|
40
|
+
* **Toggle Switch**: "Block/Unblock" owner.
|
|
41
|
+
* **Endpoint**: `PUT /superadmin/owners/:id/toggle-block`
|
|
42
|
+
|
|
43
|
+
---
|
|
44
|
+
|
|
45
|
+
## 🏢 PG Owner App (SaaS Tenant)
|
|
46
|
+
**Target Audience**: Hostel/PG Managers
|
|
47
|
+
|
|
48
|
+
### 1. Owner Dashboard (Home)
|
|
49
|
+
Overview of their PG's performance.
|
|
50
|
+
* **Endpoint**: `GET /dashboard/admin`
|
|
51
|
+
* **Display Data**:
|
|
52
|
+
* **Stats Cards**: Total Rooms, Available Beds, Active Tenants.
|
|
53
|
+
* **Financials**: Total Revenue, Collected, Pending (Hardcoded trend +12%).
|
|
54
|
+
* **Recent Activity**: Feed of "Rent Received", "New Assignment".
|
|
55
|
+
* **UI Design Notes**:
|
|
56
|
+
* Rich graphical widgets (Pie chart for Occupancy).
|
|
57
|
+
* Scrollable "Activity Feed".
|
|
58
|
+
|
|
59
|
+
### 2. Pending Dues Screen
|
|
60
|
+
List of tenants who haven't paid rent.
|
|
61
|
+
* **Endpoint**: `GET /dashboard/admin/pending-rents?month=12&year=2025`
|
|
62
|
+
* **Display Data**: Total Pending Amount, List of Tenants (Name, Room, Due Amount).
|
|
63
|
+
* **UI Design Notes**:
|
|
64
|
+
* **Filter**: Month/Year picker.
|
|
65
|
+
* **List Item**: Tenant Name, Room No, RED text for "Due: ₹5000".
|
|
66
|
+
* **Action**: "Remind" button (WhatsApp intent).
|
|
67
|
+
|
|
68
|
+
### 3. Room Management
|
|
69
|
+
* **List Rooms**: `GET /rooms`
|
|
70
|
+
* *Grid view* of rooms showing Room No, Occupancy (2/3), Floor.
|
|
71
|
+
* **Add Room**: `POST /rooms`
|
|
72
|
+
* Fields: No, Floor, Capacity, Price, Amenities.
|
|
73
|
+
* **Edit Room**: `PUT /rooms/:id`
|
|
74
|
+
* **Delete**: `DELETE /rooms/:id`
|
|
75
|
+
* **UI Design Notes**:
|
|
76
|
+
* Floating Action Button (+) to add room.
|
|
77
|
+
* Visual indicator for "Full" rooms (Red) vs "Available" (Green).
|
|
78
|
+
|
|
79
|
+
### 4. Tenant Management
|
|
80
|
+
* **List Tenants**: `GET /tenants?status=Active`
|
|
81
|
+
* *List view* with Search Bar.
|
|
82
|
+
* Shows: Details, Room No, Status tag (Active/Due Payment).
|
|
83
|
+
* **Onboard Tenant**: `POST /tenants`
|
|
84
|
+
* **Form**: Name, Phone, Email, Assign Room (Dropdown), Rent Amount.
|
|
85
|
+
* **Uploads**: Profile Pic, ID Proof (Multipart form).
|
|
86
|
+
* **Tenant Details**: `GET /tenants/:id`
|
|
87
|
+
* Profile View, Payment History, Assigned Room.
|
|
88
|
+
* **Actions**:
|
|
89
|
+
* `POST /tenants/:id/move-out` (End stay).
|
|
90
|
+
* `DELETE /tenants/:id` (Archive).
|
|
91
|
+
|
|
92
|
+
### 5. Collection (Cash Entry)
|
|
93
|
+
Record a payment made offline.
|
|
94
|
+
* **Endpoint**: `POST /payments` (or `/tenants/collect-rent`)
|
|
95
|
+
* **Payload**: `{ "tenantId": "...", "amount": 5000, "type": "monthly_rent" }`
|
|
96
|
+
* **UI Design Notes**:
|
|
97
|
+
* "Collect Rent" modal on Tenant Details screen.
|
|
98
|
+
* Auto-updates Tenant status from "Due" to "Active".
|
|
99
|
+
|
|
100
|
+
### 6. Subscription Plan
|
|
101
|
+
Manage their SaaS subscription.
|
|
102
|
+
* **Endpoint**: `GET /subscriptions`
|
|
103
|
+
* Shows: Current Plan (Free/Premium), Expiry.
|
|
104
|
+
* **Upgrade**: `POST /subscriptions/upgrade`
|
|
105
|
+
* UI: Pricing Cards (Basic, Premium) -> Payment Gateway -> Success.
|
|
106
|
+
|
|
107
|
+
---
|
|
108
|
+
|
|
109
|
+
## 🏠 Resident App (Tenant)
|
|
110
|
+
**Target Audience**: Students/Professionals living in PG
|
|
111
|
+
|
|
112
|
+
### 1. Resident Home
|
|
113
|
+
* **Endpoint**: `GET /dashboard/customer`
|
|
114
|
+
* **Display Data**:
|
|
115
|
+
* **Profile**: Name, Room Number.
|
|
116
|
+
* **Announcements**: Carousel of latest notices from Owner.
|
|
117
|
+
* **Recent Payments**: List of last 5 transactions.
|
|
118
|
+
* **UI Design Notes**:
|
|
119
|
+
* Clean, welcoming header "Welcome Back, [Name]".
|
|
120
|
+
* **Quick Action**: "Pay Rent" button.
|
|
121
|
+
|
|
122
|
+
### 2. Announcements
|
|
123
|
+
* **Endpoint**: `GET /dashboard/announcements`
|
|
124
|
+
* **Display Data**: List of notices (e.g., "Water heater maintenance").
|
|
125
|
+
|
|
126
|
+
### 3. Payment History
|
|
127
|
+
* **Endpoint**: `GET /payments/my-history`
|
|
128
|
+
* **Display Data**: List of all payments (Date, Amount, Status).
|
|
129
|
+
* **UI Design Notes**:
|
|
130
|
+
* Card style for each transaction.
|
|
131
|
+
* Green badge for "Completed", Red for "Failed".
|
|
132
|
+
|
|
133
|
+
---
|
|
134
|
+
|
|
135
|
+
## ⚖️ Legal & Compliance
|
|
136
|
+
**Common Screens**: Settings > Terms / Privacy
|
|
137
|
+
|
|
138
|
+
* **Terms**: `GET /legal/terms`
|
|
139
|
+
* **Privacy**: `GET /legal/privacy`
|
|
140
|
+
* **UI Design Notes**: Simple text/webview render.
|
|
@@ -0,0 +1,504 @@
|
|
|
1
|
+
# PG Management System - Backend API
|
|
2
|
+
|
|
3
|
+
## Overview
|
|
4
|
+
This is a Node.js/Express backend for a SaaS-based PG Management application. It supports Authentication, Role-based access control (Superadmin, Admin, Customer), Room Management, and Payment processing (Stubbed/integrated logic).
|
|
5
|
+
|
|
6
|
+
## Base URL
|
|
7
|
+
`http://localhost:5000`
|
|
8
|
+
|
|
9
|
+
## Features
|
|
10
|
+
- **Authentication**: JWT based Login/Signup.
|
|
11
|
+
- **Roles**:
|
|
12
|
+
- `superadmin`: Full access.
|
|
13
|
+
- `admin`: Manage rooms, view all payments.
|
|
14
|
+
- `customer`: View own dashboard, make payments.
|
|
15
|
+
- **Payments**: Simulates payment gateway intent and confirmation.
|
|
16
|
+
- **Database**: SQLite (Development), configurable for Postgres/MySQL.
|
|
17
|
+
|
|
18
|
+
## Setup
|
|
19
|
+
1. `npm install`
|
|
20
|
+
2. `npm start`
|
|
21
|
+
3. Super Admin default credentials: `admin@pg.com` / `admin123`
|
|
22
|
+
|
|
23
|
+
## Postman Collection
|
|
24
|
+
Copy the JSON below and import it into Postman.
|
|
25
|
+
|
|
26
|
+
```json
|
|
27
|
+
{
|
|
28
|
+
"info": {
|
|
29
|
+
"_postman_id": "pg-backend-collection",
|
|
30
|
+
"name": "PG Management API",
|
|
31
|
+
"description": "Postman collection for PG Management SaaS Backend",
|
|
32
|
+
"schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json"
|
|
33
|
+
},
|
|
34
|
+
"item": [
|
|
35
|
+
{
|
|
36
|
+
"name": "Auth",
|
|
37
|
+
"item": [
|
|
38
|
+
{
|
|
39
|
+
"name": "Signup (Customer)",
|
|
40
|
+
"request": {
|
|
41
|
+
"method": "POST",
|
|
42
|
+
"header": [],
|
|
43
|
+
"body": {
|
|
44
|
+
"mode": "raw",
|
|
45
|
+
"raw": "{\n \"name\": \"John Customer\",\n \"email\": \"customer@example.com\",\n \"password\": \"password123\",\n \"phone\": \"9876543210\",\n \"role\": \"customer\"\n}",
|
|
46
|
+
"options": {
|
|
47
|
+
"raw": {
|
|
48
|
+
"language": "json"
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
},
|
|
52
|
+
"url": {
|
|
53
|
+
"raw": "{{url}}/api/auth/signup",
|
|
54
|
+
"host": [
|
|
55
|
+
"{{url}}"
|
|
56
|
+
],
|
|
57
|
+
"path": [
|
|
58
|
+
"api",
|
|
59
|
+
"auth",
|
|
60
|
+
"signup"
|
|
61
|
+
]
|
|
62
|
+
}
|
|
63
|
+
},
|
|
64
|
+
"response": []
|
|
65
|
+
},
|
|
66
|
+
{
|
|
67
|
+
"name": "Signin (Admin)",
|
|
68
|
+
"event": [
|
|
69
|
+
{
|
|
70
|
+
"listen": "test",
|
|
71
|
+
"script": {
|
|
72
|
+
"exec": [
|
|
73
|
+
"var jsonData = pm.response.json();",
|
|
74
|
+
"if(jsonData.accessToken) {",
|
|
75
|
+
" pm.environment.set(\"token\", jsonData.accessToken);",
|
|
76
|
+
" console.log(\"Token set successfully\");",
|
|
77
|
+
"}"
|
|
78
|
+
],
|
|
79
|
+
"type": "text/javascript"
|
|
80
|
+
}
|
|
81
|
+
}
|
|
82
|
+
],
|
|
83
|
+
"request": {
|
|
84
|
+
"method": "POST",
|
|
85
|
+
"header": [],
|
|
86
|
+
"body": {
|
|
87
|
+
"mode": "raw",
|
|
88
|
+
"raw": "{\n \"email\": \"admin@pg.com\",\n \"password\": \"admin123\"\n}",
|
|
89
|
+
"options": {
|
|
90
|
+
"raw": {
|
|
91
|
+
"language": "json"
|
|
92
|
+
}
|
|
93
|
+
}
|
|
94
|
+
},
|
|
95
|
+
"url": {
|
|
96
|
+
"raw": "{{url}}/api/auth/signin",
|
|
97
|
+
"host": [
|
|
98
|
+
"{{url}}"
|
|
99
|
+
],
|
|
100
|
+
"path": [
|
|
101
|
+
"api",
|
|
102
|
+
"auth",
|
|
103
|
+
"signin"
|
|
104
|
+
]
|
|
105
|
+
}
|
|
106
|
+
},
|
|
107
|
+
"response": []
|
|
108
|
+
},
|
|
109
|
+
{
|
|
110
|
+
"name": "Signin (Customer)",
|
|
111
|
+
"event": [
|
|
112
|
+
{
|
|
113
|
+
"listen": "test",
|
|
114
|
+
"script": {
|
|
115
|
+
"exec": [
|
|
116
|
+
"var jsonData = pm.response.json();",
|
|
117
|
+
"if(jsonData.accessToken) {",
|
|
118
|
+
" pm.environment.set(\"token\", jsonData.accessToken);",
|
|
119
|
+
"}"
|
|
120
|
+
],
|
|
121
|
+
"type": "text/javascript"
|
|
122
|
+
}
|
|
123
|
+
}
|
|
124
|
+
],
|
|
125
|
+
"request": {
|
|
126
|
+
"method": "POST",
|
|
127
|
+
"header": [],
|
|
128
|
+
"body": {
|
|
129
|
+
"mode": "raw",
|
|
130
|
+
"raw": "{\n \"email\": \"customer@example.com\",\n \"password\": \"password123\"\n}",
|
|
131
|
+
"options": {
|
|
132
|
+
"raw": {
|
|
133
|
+
"language": "json"
|
|
134
|
+
}
|
|
135
|
+
}
|
|
136
|
+
},
|
|
137
|
+
"url": {
|
|
138
|
+
"raw": "{{url}}/api/auth/signin",
|
|
139
|
+
"host": [
|
|
140
|
+
"{{url}}"
|
|
141
|
+
],
|
|
142
|
+
"path": [
|
|
143
|
+
"api",
|
|
144
|
+
"auth",
|
|
145
|
+
"signin"
|
|
146
|
+
]
|
|
147
|
+
}
|
|
148
|
+
},
|
|
149
|
+
"response": []
|
|
150
|
+
}
|
|
151
|
+
]
|
|
152
|
+
},
|
|
153
|
+
{
|
|
154
|
+
"name": "Rooms",
|
|
155
|
+
"item": [
|
|
156
|
+
{
|
|
157
|
+
"name": "Get All Rooms",
|
|
158
|
+
"request": {
|
|
159
|
+
"method": "GET",
|
|
160
|
+
"header": [
|
|
161
|
+
{
|
|
162
|
+
"key": "x-access-token",
|
|
163
|
+
"value": "{{token}}",
|
|
164
|
+
"type": "text"
|
|
165
|
+
}
|
|
166
|
+
],
|
|
167
|
+
"url": {
|
|
168
|
+
"raw": "{{url}}/api/rooms",
|
|
169
|
+
"host": [
|
|
170
|
+
"{{url}}"
|
|
171
|
+
],
|
|
172
|
+
"path": [
|
|
173
|
+
"api",
|
|
174
|
+
"rooms"
|
|
175
|
+
]
|
|
176
|
+
}
|
|
177
|
+
},
|
|
178
|
+
"response": []
|
|
179
|
+
},
|
|
180
|
+
{
|
|
181
|
+
"name": "Create Room (Admin)",
|
|
182
|
+
"request": {
|
|
183
|
+
"method": "POST",
|
|
184
|
+
"header": [
|
|
185
|
+
{
|
|
186
|
+
"key": "x-access-token",
|
|
187
|
+
"value": "{{token}}",
|
|
188
|
+
"type": "text"
|
|
189
|
+
}
|
|
190
|
+
],
|
|
191
|
+
"body": {
|
|
192
|
+
"mode": "raw",
|
|
193
|
+
"raw": "{\n \"roomNumber\": \"101\",\n \"floor\": 1,\n \"capacity\": 3,\n \"pricePerMonth\": 6000,\n \"amenities\": \"WiFi, TV\"\n}",
|
|
194
|
+
"options": {
|
|
195
|
+
"raw": {
|
|
196
|
+
"language": "json"
|
|
197
|
+
}
|
|
198
|
+
}
|
|
199
|
+
},
|
|
200
|
+
"url": {
|
|
201
|
+
"raw": "{{url}}/api/rooms",
|
|
202
|
+
"host": [
|
|
203
|
+
"{{url}}"
|
|
204
|
+
],
|
|
205
|
+
"path": [
|
|
206
|
+
"api",
|
|
207
|
+
"rooms"
|
|
208
|
+
]
|
|
209
|
+
}
|
|
210
|
+
},
|
|
211
|
+
"response": []
|
|
212
|
+
},
|
|
213
|
+
{
|
|
214
|
+
"name": "Update Room (Admin)",
|
|
215
|
+
"request": {
|
|
216
|
+
"method": "PUT",
|
|
217
|
+
"header": [
|
|
218
|
+
{
|
|
219
|
+
"key": "x-access-token",
|
|
220
|
+
"value": "{{token}}",
|
|
221
|
+
"type": "text"
|
|
222
|
+
}
|
|
223
|
+
],
|
|
224
|
+
"body": {
|
|
225
|
+
"mode": "raw",
|
|
226
|
+
"raw": "{\n \"pricePerMonth\": 6500,\n \"floor\": 2,\n \"amenities\": \"WiFi, TV, AC\",\n \"isMaintenance\": true\n}",
|
|
227
|
+
"options": {
|
|
228
|
+
"raw": {
|
|
229
|
+
"language": "json"
|
|
230
|
+
}
|
|
231
|
+
}
|
|
232
|
+
},
|
|
233
|
+
"url": {
|
|
234
|
+
"raw": "{{url}}/api/rooms/:id",
|
|
235
|
+
"host": [
|
|
236
|
+
"{{url}}"
|
|
237
|
+
],
|
|
238
|
+
"path": [
|
|
239
|
+
"api",
|
|
240
|
+
"rooms",
|
|
241
|
+
":id"
|
|
242
|
+
],
|
|
243
|
+
"variable": [
|
|
244
|
+
{
|
|
245
|
+
"key": "id",
|
|
246
|
+
"value": "ENTER_ROOM_ID_HERE"
|
|
247
|
+
}
|
|
248
|
+
]
|
|
249
|
+
}
|
|
250
|
+
},
|
|
251
|
+
"response": []
|
|
252
|
+
},
|
|
253
|
+
{
|
|
254
|
+
"name": "Delete Room (Admin)",
|
|
255
|
+
"request": {
|
|
256
|
+
"method": "DELETE",
|
|
257
|
+
"header": [
|
|
258
|
+
{
|
|
259
|
+
"key": "x-access-token",
|
|
260
|
+
"value": "{{token}}",
|
|
261
|
+
"type": "text"
|
|
262
|
+
}
|
|
263
|
+
],
|
|
264
|
+
"url": {
|
|
265
|
+
"raw": "{{url}}/api/rooms/:id",
|
|
266
|
+
"host": [
|
|
267
|
+
"{{url}}"
|
|
268
|
+
],
|
|
269
|
+
"path": [
|
|
270
|
+
"api",
|
|
271
|
+
"rooms",
|
|
272
|
+
":id"
|
|
273
|
+
],
|
|
274
|
+
"variable": [
|
|
275
|
+
{
|
|
276
|
+
"key": "id",
|
|
277
|
+
"value": "ENTER_ROOM_ID_HERE"
|
|
278
|
+
}
|
|
279
|
+
]
|
|
280
|
+
}
|
|
281
|
+
},
|
|
282
|
+
"response": []
|
|
283
|
+
}
|
|
284
|
+
]
|
|
285
|
+
},
|
|
286
|
+
{
|
|
287
|
+
"name": "Payments",
|
|
288
|
+
"item": [
|
|
289
|
+
{
|
|
290
|
+
"name": "Create Payment Intent",
|
|
291
|
+
"request": {
|
|
292
|
+
"method": "POST",
|
|
293
|
+
"header": [
|
|
294
|
+
{
|
|
295
|
+
"key": "x-access-token",
|
|
296
|
+
"value": "{{token}}",
|
|
297
|
+
"type": "text"
|
|
298
|
+
}
|
|
299
|
+
],
|
|
300
|
+
"body": {
|
|
301
|
+
"mode": "raw",
|
|
302
|
+
"raw": "{\n \"amount\": 6000,\n \"type\": \"monthly_rent\"\n}",
|
|
303
|
+
"options": {
|
|
304
|
+
"raw": {
|
|
305
|
+
"language": "json"
|
|
306
|
+
}
|
|
307
|
+
}
|
|
308
|
+
},
|
|
309
|
+
"url": {
|
|
310
|
+
"raw": "{{url}}/api/payments/create-intent",
|
|
311
|
+
"host": [
|
|
312
|
+
"{{url}}"
|
|
313
|
+
],
|
|
314
|
+
"path": [
|
|
315
|
+
"api",
|
|
316
|
+
"payments",
|
|
317
|
+
"create-intent"
|
|
318
|
+
]
|
|
319
|
+
}
|
|
320
|
+
},
|
|
321
|
+
"response": []
|
|
322
|
+
},
|
|
323
|
+
{
|
|
324
|
+
"name": "Confirm Payment",
|
|
325
|
+
"request": {
|
|
326
|
+
"method": "POST",
|
|
327
|
+
"header": [
|
|
328
|
+
{
|
|
329
|
+
"key": "x-access-token",
|
|
330
|
+
"value": "{{token}}",
|
|
331
|
+
"type": "text"
|
|
332
|
+
}
|
|
333
|
+
],
|
|
334
|
+
"body": {
|
|
335
|
+
"mode": "raw",
|
|
336
|
+
"raw": "{\n \"paymentId\": \"PASTE_PAYMENT_ID_HERE\",\n \"transactionId\": \"TXN_99999\",\n \"method\": \"upi\"\n}",
|
|
337
|
+
"options": {
|
|
338
|
+
"raw": {
|
|
339
|
+
"language": "json"
|
|
340
|
+
}
|
|
341
|
+
}
|
|
342
|
+
},
|
|
343
|
+
"url": {
|
|
344
|
+
"raw": "{{url}}/api/payments/confirm",
|
|
345
|
+
"host": [
|
|
346
|
+
"{{url}}"
|
|
347
|
+
],
|
|
348
|
+
"path": [
|
|
349
|
+
"api",
|
|
350
|
+
"payments",
|
|
351
|
+
"confirm"
|
|
352
|
+
]
|
|
353
|
+
}
|
|
354
|
+
},
|
|
355
|
+
"response": []
|
|
356
|
+
},
|
|
357
|
+
{
|
|
358
|
+
"name": "My History (Customer)",
|
|
359
|
+
"request": {
|
|
360
|
+
"method": "GET",
|
|
361
|
+
"header": [
|
|
362
|
+
{
|
|
363
|
+
"key": "x-access-token",
|
|
364
|
+
"value": "{{token}}",
|
|
365
|
+
"type": "text"
|
|
366
|
+
}
|
|
367
|
+
],
|
|
368
|
+
"url": {
|
|
369
|
+
"raw": "{{url}}/api/payments/my-history",
|
|
370
|
+
"host": [
|
|
371
|
+
"{{url}}"
|
|
372
|
+
],
|
|
373
|
+
"path": [
|
|
374
|
+
"api",
|
|
375
|
+
"payments",
|
|
376
|
+
"my-history"
|
|
377
|
+
]
|
|
378
|
+
}
|
|
379
|
+
},
|
|
380
|
+
"response": []
|
|
381
|
+
},
|
|
382
|
+
{
|
|
383
|
+
"name": "All Payments (Admin)",
|
|
384
|
+
"request": {
|
|
385
|
+
"method": "GET",
|
|
386
|
+
"header": [
|
|
387
|
+
{
|
|
388
|
+
"key": "x-access-token",
|
|
389
|
+
"value": "{{token}}",
|
|
390
|
+
"type": "text"
|
|
391
|
+
}
|
|
392
|
+
],
|
|
393
|
+
"url": {
|
|
394
|
+
"raw": "{{url}}/api/payments?status=pending",
|
|
395
|
+
"host": [
|
|
396
|
+
"{{url}}"
|
|
397
|
+
],
|
|
398
|
+
"path": [
|
|
399
|
+
"api",
|
|
400
|
+
"payments"
|
|
401
|
+
],
|
|
402
|
+
"query": [
|
|
403
|
+
{
|
|
404
|
+
"key": "status",
|
|
405
|
+
"value": "pending",
|
|
406
|
+
"description": "Optional filter: pending, completed, failed"
|
|
407
|
+
}
|
|
408
|
+
]
|
|
409
|
+
}
|
|
410
|
+
},
|
|
411
|
+
"response": []
|
|
412
|
+
}
|
|
413
|
+
]
|
|
414
|
+
},
|
|
415
|
+
{
|
|
416
|
+
"name": "Dashboard",
|
|
417
|
+
"item": [
|
|
418
|
+
{
|
|
419
|
+
"name": "Admin Stats",
|
|
420
|
+
"request": {
|
|
421
|
+
"method": "GET",
|
|
422
|
+
"header": [
|
|
423
|
+
{
|
|
424
|
+
"key": "x-access-token",
|
|
425
|
+
"value": "{{token}}",
|
|
426
|
+
"type": "text"
|
|
427
|
+
}
|
|
428
|
+
],
|
|
429
|
+
"url": {
|
|
430
|
+
"raw": "{{url}}/api/dashboard/admin",
|
|
431
|
+
"host": [
|
|
432
|
+
"{{url}}"
|
|
433
|
+
],
|
|
434
|
+
"path": [
|
|
435
|
+
"api",
|
|
436
|
+
"dashboard",
|
|
437
|
+
"admin"
|
|
438
|
+
]
|
|
439
|
+
}
|
|
440
|
+
},
|
|
441
|
+
"response": []
|
|
442
|
+
},
|
|
443
|
+
{
|
|
444
|
+
"name": "Customer Dashboard",
|
|
445
|
+
"request": {
|
|
446
|
+
"method": "GET",
|
|
447
|
+
"header": [
|
|
448
|
+
{
|
|
449
|
+
"key": "x-access-token",
|
|
450
|
+
"value": "{{token}}",
|
|
451
|
+
"type": "text"
|
|
452
|
+
}
|
|
453
|
+
],
|
|
454
|
+
"url": {
|
|
455
|
+
"raw": "{{url}}/api/dashboard/customer",
|
|
456
|
+
"host": [
|
|
457
|
+
"{{url}}"
|
|
458
|
+
],
|
|
459
|
+
"path": [
|
|
460
|
+
"api",
|
|
461
|
+
"dashboard",
|
|
462
|
+
"customer"
|
|
463
|
+
]
|
|
464
|
+
}
|
|
465
|
+
},
|
|
466
|
+
"response": []
|
|
467
|
+
},
|
|
468
|
+
{
|
|
469
|
+
"name": "Announcements",
|
|
470
|
+
"request": {
|
|
471
|
+
"method": "GET",
|
|
472
|
+
"header": [
|
|
473
|
+
{
|
|
474
|
+
"key": "x-access-token",
|
|
475
|
+
"value": "{{token}}",
|
|
476
|
+
"type": "text"
|
|
477
|
+
}
|
|
478
|
+
],
|
|
479
|
+
"url": {
|
|
480
|
+
"raw": "{{url}}/api/dashboard/announcements",
|
|
481
|
+
"host": [
|
|
482
|
+
"{{url}}"
|
|
483
|
+
],
|
|
484
|
+
"path": [
|
|
485
|
+
"api",
|
|
486
|
+
"dashboard",
|
|
487
|
+
"announcements"
|
|
488
|
+
]
|
|
489
|
+
}
|
|
490
|
+
},
|
|
491
|
+
"response": []
|
|
492
|
+
}
|
|
493
|
+
]
|
|
494
|
+
}
|
|
495
|
+
],
|
|
496
|
+
"variable": [
|
|
497
|
+
{
|
|
498
|
+
"key": "url",
|
|
499
|
+
"value": "http://localhost:5000",
|
|
500
|
+
"type": "string"
|
|
501
|
+
}
|
|
502
|
+
]
|
|
503
|
+
}
|
|
504
|
+
```
|