• 1.3 cc1e47981e

    phil released this 2025-10-05 21:09:33 +00:00 | 2 commits to main since this release

    1. Error Handling for Mullvad IP Fetch:

    • Adds || { log "[!] Failed to fetch IP from Mullvad"; exit 1; } immediately after the curl command to catch curl failures explicitly.

    2. Cloudflare Authentication Method:

    • Switches to using Authorization: Bearer $CLOUDFLARE_API_KEY header for authentication, which is the preferred modern approach.

    3. Required Environment Variables:

    • Only requires ZONE_ID, DNS_NAME, and CLOUDFLARE_API_KEY. CLOUDFLARE_EMAIL is no longer mandatory for missing variable checks, but it's still used in some API calls.

    4. Curl Exit Code Checks:

    • Checks curl exit codes explicitly after each API call (GET, POST, and PATCH) and logs errors when curl fails.

    5. Curl Headers Ordering and Content:

    • The Authorization: Bearer header replaces X-Auth-Key in all API calls except the POST and PATCH, where both X-Auth-Email and Authorization coexist.

    6. Curl Data Payload Ordering and Content:

    • The order of fields in JSON payload has changed slightly (e.g., "name" before "ttl"), and the comment for creation and update changed from "Created via script"/"Updated via script" to "Domain verification record".

    7. Additional Logging on Curl Failures:

    • Adds detailed logging of curl failure responses and exit codes.

    8. General Code Formatting and Minor Style Tweaks:

    • Minor changes in spacing and ordering of JSON fields.

    • Removal of some unnecessary blank lines.

    • Slight restructuring of error continuation logic.

    Downloads