/api/database/*
Endpoints for managing the database provider.GET /api/database/config
Returns the current database provider and whether it’s configured.POST /api/database/config
Sets a new database provider.Request body
sqlite, supabase, turso, planetscale.
POST /api/database/test
Tests a database connection with the provided credentials.Request body
Same format as POST/api/database/config.
Response
POST /api/database/migrate
Creates the required tables (user_settings, api_cache) in the current database provider.
Response
For Supabase and PlanetScale, the endpoint returns the SQL statements for manual execution instead of running them directly.