- Fixed api_token vs mailketing_api_token column mapping - Added comprehensive debug logging to send-auth-otp - Added fallback logic for missing settings fields - Improved error messages for troubleshooting 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
19 lines
728 B
Bash
Executable File
19 lines
728 B
Bash
Executable File
#!/bin/bash
|
|
|
|
# Deploy Auth OTP Edge Functions to Self-Hosted Supabase
|
|
|
|
SUPABASE_URL="https://lovable.backoffice.biz.id"
|
|
SERVICE_ROLE_KEY="eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJpc3MiOiJzdXBhYmFzZSIsImlhdCI6MTc2NjAzNzEyMCwiZXhwIjo0OTIxNzEwNzIwLCJyb2xlIjoic2VydmljZV9yb2xlIn0.t6D9VwaukYGq4c_VbW1bkd3ZkKgldpCKRR13nN14XXc"
|
|
|
|
echo "Deploying send-auth-otp..."
|
|
|
|
curl -X POST "${SUPABASE_URL}/functions/v1/send-auth-otp" \
|
|
-H "Authorization: Bearer ${SERVICE_ROLE_KEY}" \
|
|
-H "Content-Type: application/json" \
|
|
-d '{"user_id":"test","email":"test@test.com"}' \
|
|
-v
|
|
|
|
echo ""
|
|
echo "If you see a response above, the function is deployed."
|
|
echo "If you see 404, the function needs to be deployed manually to your Supabase instance."
|