# BiznisOS – pending tasks

Last updated: 4 December 2026. Everything not listed here is built (see PROGRESS.md).

## 1. Run the PHP tests (blocked – needs you)

The code has never been run under Laravel. This workspace cannot reach packagist.org, so `composer install` fails.

- Static checks pass: `python3 tools/qa.py --sql` (242 PHP files, 115 views, 284 routes, 73 tables imported).
- 169 PHPUnit tests are written but have not run: unit tests, feature tests, and a smoke test that opens every page.
- Expect a first round of small fixes when they do run.

**How to unblock (pick one):**
1. Allow `packagist.org` in Claude's Capabilities settings, then ask me to run and fix the tests here.
2. On your server: `composer install && cp .env.example .env && php artisan key:generate && tools/test.sh`, then send me the output.
3. Give me a GitHub repository. `.github/workflows/tests.yml` then runs everything on every push.

## 2. Phase 7 – Community and Learn (paused at your request)

Not started, except a draft migration kept outside the project (`phase7-draft/2026_12_11_000100_create_community_tables.php`).
Say "develop Phase 7" to start it.

## 3. Automatic subscription charging (next build item, not started)

Today, renewals are collected by an emailed payment link with reminders, which is built and working.
Still missing: charging a saved card or UPI AutoPay mandate with no click from the customer.

Plan:
- **Razorpay Subscriptions:** create a plan per product, create a subscription, and send the customer the authorisation link. Webhooks: `subscription.charged` extends the subscription; `subscription.halted` or `subscription.cancelled` marks it overdue or cancelled.
- **Stripe Billing:** Checkout in subscription mode. Webhooks: `invoice.paid` extends the subscription; `customer.subscription.deleted` cancels it.
- An "Auto-charge every period" switch on checkout pages for recurring products.
- Fake mode and tests, as with the other gateways.
- Must be tried with live Razorpay and Stripe accounts before customers use it.

## 4. Third-party accounts and keys (needs you)

All are placeholders (`CHANGE_ME`) until you add them. SETUP_REQUIRED.md explains each one.

- Server `.env`: mail (SMTP, Amazon SES or Mailgun), platform Razorpay keys for wallet top-ups, the platform OpenAI or Anthropic key, Google sign-in, SMS (MSG91 or Twilio), S3 or DigitalOcean Spaces (optional), and push keys (`php artisan biznisos:vapid`).
- Entered by each business under Integrations: WhatsApp Cloud API, Meta Lead Ads, Instagram, IndiaMART, Razorpay or Stripe, Google Calendar (including the free/busy permission), Zoom, MSG91 or Twilio.
- India specifics: DLT registration for SMS templates, and approved WhatsApp templates.
- Set `is_super_admin = 1` on your own user to see Platform feedback.

## 5. Deployment (needs you)

Follow DEPLOYMENT.md:
- Server with PHP 8.2, MySQL 8 and HTTPS.
- Caddy for custom domains, with `internal/caddy/ask`.
- Queue worker and the scheduler: `* * * * * php artisan schedule:run`. The scheduler runs reminders, renewals, Google sync, IndiaMART pull and workflows.
- `php artisan storage:link`, backups, and a staging site before production.
- Database: run `php artisan migrate`, or import `database/biznisos.sql`.

## 6. Check against the reference screens

Screens built without a reference screenshot follow the same layout as the rest of the app. Please click through them on staging with the demo logins (TESTING.md) and list anything that should look or work differently.

## 7. Not possible from here

- Native Play Store and App Store apps. The installable web app with push alerts covers most of the need. Native apps would be a separate project.

## Suggested order

1 → 5 → 4 → 6 → 3 → 2. Get the tests running and a staging server up first, then add keys, review the screens, and build the remaining features.
