Contact Manager API Diagnostics

Database Connection

✓ Database connection successful

✗ Database error: SQLSTATE[42000]: Syntax error or access violation: 1064 You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '?' at line 1

PHP Environment

✓ PHP version 8.1.33 (meets minimum requirement of 7.0.0)

✓ All required PHP extensions are installed

⚠ PhpSpreadsheet library not installed (Excel import will not work)

To install, run: composer require phpoffice/phpspreadsheet

API Endpoints

Endpoint Method Status
validate_user.phpPOST✓ File exists
get_clients.phpGET✓ File exists
get_call_logs.phpGET✓ File exists
add_call_log.phpPOST✓ File exists
import_csv.phpPOST✓ File exists
import_excel.phpPOST✓ File exists
import_parsed_clients.phpPOST✓ File exists
health.phpGET✓ File exists

Common Frontend Issues

Issue Solution
Email case sensitivity All emails are normalized to lowercase before comparison. Ensure the frontend is consistent in how it stores and sends email addresses.
Invalid date formats For call_date, use formats like "YYYY-MM-DD HH:MM:SS" or ISO 8601. For next_follow_up_date, use "YYYY-MM-DD".
Permission issues with call logs The user_email in a call log must match the created_by field of the client. Verify frontend is sending the correct user email.
Import issues Verify that CSV/Excel files have column headers that match the expected patterns (name, email, etc.)

Test Backend Access

Use this form to verify your frontend can communicate with the backend:

Results will appear here...