# Local-dev config ONLY. Enables a LOCAL D1 so `POST /api/ingest` and stored # surveys work end-to-end on your machine, without needing remote D1 perms. # wrangler d1 execute critterscope --local --config wrangler.dev.toml --file schema.sql # wrangler dev --local --config wrangler.dev.toml # The live deploy uses wrangler.toml (simulator; no D1) until a D1-capable # Cloudflare token is available — then move this binding into wrangler.toml # with the real database_id. name = "drones" main = "src/index.js" compatibility_date = "2024-11-01" compatibility_flags = ["nodejs_compat"] [vars] BASE_URL = "http://localhost:8787" DEFAULT_LON = "150.3119" DEFAULT_LAT = "-33.7300" DEFAULT_RADIUS_M = "1000" [[d1_databases]] binding = "DB" database_name = "critterscope" database_id = "local-critterscope"