╔════════════════════════════════════════════════════════════════════╗
║        FILES TO UPLOAD TO PRODUCTION SERVER - CHECKLIST           ║
║                micromaster.esoftking.com                           ║
╚════════════════════════════════════════════════════════════════════╝

📦 CRITICAL FILES (MUST UPLOAD):
═══════════════════════════════════

✅ bootstrap/app.php
   → Contains API routes configuration
   → Location: /home/esofsoln/micromaster.esoftking.com/bootstrap/app.php

✅ app/Models/User.php
   → Contains HasApiTokens trait for Sanctum
   → Location: /home/esofsoln/micromaster.esoftking.com/app/Models/User.php

✅ app/Http/Controllers/Api/PartnerApiController.php
   → Contains all API endpoints logic
   → Location: /home/esofsoln/micromaster.esoftking.com/app/Http/Controllers/Api/PartnerApiController.php

✅ routes/api.php
   → Contains API route definitions
   → Location: /home/esofsoln/micromaster.esoftking.com/routes/api.php

✅ composer.json
   → Contains laravel/sanctum dependency
   → Location: /home/esofsoln/micromaster.esoftking.com/composer.json

✅ composer.lock
   → Locks dependency versions
   → Location: /home/esofsoln/micromaster.esoftking.com/composer.lock


📦 OPTIONAL FILES (Upload if exists):
═══════════════════════════════════

✅ config/sanctum.php
   → Sanctum configuration (auto-created by vendor:publish)
   → Location: /home/esofsoln/micromaster.esoftking.com/config/sanctum.php


📦 BACKUP SQL (If cannot run migrations):
═══════════════════════════════════════════

✅ CREATE_PERSONAL_ACCESS_TOKENS_TABLE.sql
   → Run in phpMyAdmin to create personal_access_tokens table


═══════════════════════════════════════════════════════════════════

📋 AFTER UPLOADING - RUN ON SERVER:
══════════════════════════════════

Via SSH or cPanel Terminal:

cd /home/esofsoln/micromaster.esoftking.com

composer install --no-dev --optimize-autoloader
php artisan vendor:publish --provider="Laravel\Sanctum\SanctumServiceProvider"
php artisan migrate --force
php artisan route:clear
php artisan config:clear
php artisan cache:clear
php artisan config:cache
php artisan route:cache


═══════════════════════════════════════════════════════════════════

🔍 VERIFICATION - Test API:
══════════════════════════

Visit in browser:
https://micromaster.esoftking.com/api/partner/login

Expected: "The GET method is not supported for this route..."
(This means route exists! ✅)


═══════════════════════════════════════════════════════════════════

📱 ANDROID APP - Already Configured! ✅
═════════════════════════════════════

File: android-app/app/src/main/java/com/micromaster/partner/data/network/ApiConfig.kt
URL: https://micromaster.esoftking.com/api/

Build APK:
1. Open Android Studio
2. Build → Build Bundle(s) / APK(s) → Build APK(s)
3. Install on phone
4. Test login!


═══════════════════════════════════════════════════════════════════

✅ DEPLOYMENT COMPLETE WHEN:
═══════════════════════════

[ ] All files uploaded
[ ] Composer install ran successfully
[ ] Migrations ran successfully
[ ] Caches cleared
[ ] API responds (even with error is OK for GET)
[ ] Android app built
[ ] Login works from app
[ ] Dashboard loads


═══════════════════════════════════════════════════════════════════

