fixing platform admin

This commit is contained in:
root
2026-05-06 22:58:23 -04:00
parent 695a7f7cc7
commit 750ae56a29
175 changed files with 31249 additions and 328 deletions
+7 -7
View File
@@ -1,6 +1,6 @@
# API Routes Inventory — RentFlow (Complete)
# API Routes Inventory — RentalDriveGo (Complete)
Base URL: `https://api.rentflow.com/api/v1`
Base URL: `https://api.RentalDriveGo.com/api/v1`
## Middleware Legend
- 🔒 `requireCompanyAuth` — valid Clerk JWT (Employee)
@@ -8,7 +8,7 @@ Base URL: `https://api.rentflow.com/api/v1`
- 💳 `requireSubscription` — blocks SUSPENDED/PENDING companies
- 🎫 `requireRenterAuth` — valid Renter JWT
- 🔑 `requireApiKey` — company public API key in `x-api-key` header
- 👑 `requireAdmin` — RentFlow super-admin role
- 👑 `requireAdmin` — RentalDriveGo super-admin role
> **Tenant isolation rule:** Every 🏢 route must use `where: { companyId: req.companyId }` in every query.
@@ -41,7 +41,7 @@ Base URL: `https://api.rentflow.com/api/v1`
---
## Subscriptions (AmanPay/PayPal subscription — RentFlow collects)
## Subscriptions (AmanPay/PayPal subscription — RentalDriveGo collects)
| Method | Path | Auth | Description |
|--------|------|------|-------------|
@@ -233,7 +233,7 @@ Base URL: `https://api.rentflow.com/api/v1`
## Company Public Site API (slug-resolved, no user auth)
> Used by SSR pages on `{slug}.rentflow.com`. Never subscription-gated.
> Used by SSR pages on `{slug}.RentalDriveGo.com`. Never subscription-gated.
| Method | Path | Auth | Description |
|--------|------|------|-------------|
@@ -249,7 +249,7 @@ Base URL: `https://api.rentflow.com/api/v1`
---
## Admin (RentFlow internal)
## Admin (RentalDriveGo internal)
| Method | Path | Auth | Description |
|--------|------|------|-------------|
@@ -349,7 +349,7 @@ Base URL: `https://api.rentflow.com/api/v1`
---
## Admin Panel Routes (admin.rentflow.com → api.rentflow.com/admin)
## Admin Panel Routes (admin.RentalDriveGo.com → api.RentalDriveGo.com/admin)
> All require admin JWT. Role hierarchy: VIEWER < FINANCE < SUPPORT < ADMIN < SUPER_ADMIN