Rename the project and integrate it with cloudflare as well #1
Labels
No Label
No Milestone
No project
No Assignees
1 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: tudor.stanciu/godaddy-ddns#1
Loading…
Reference in New Issue
There is no content yet.
Delete Branch "%!s(<nil>)"
Deleting a branch is permanent. Although the deleted branch may exist for a short time before cleaning up, in most cases it CANNOT be undone. Continue?
https://developers.cloudflare.com/api/
ChatGPT:
Yes, Cloudflare does offer an API that allows you to programmatically update DNS records, including A records. This can be useful for automating the process of updating your DNS records when your dynamic IP address changes.
Here's a general overview of the steps you would need to take:
Log in to your Cloudflare account.
Go to "My Profile" and then to the "API Tokens" section.
Create a new API token with the necessary permissions. Make sure it has the required permissions to edit DNS records.
You will need the Zone ID of your domain and the Record ID of the specific A record you want to update. You can find these by making requests to the Cloudflare API or by checking the Cloudflare dashboard.
You can use the Cloudflare API to update the A record with your new IP address. You'll need to send a PUT request to the Cloudflare API endpoint for updating DNS records.
Here is a general example using cURL:
bash
Replace YOUR_ZONE_ID, YOUR_RECORD_ID, YOUR_API_TOKEN, example.com, and NEW_IP with your actual values.
Integrate this API call into your local service that tracks your dynamic IP. Whenever your IP changes, your service can use the Cloudflare API to update the A record automatically.
Make sure to secure your API token, as it grants access to your Cloudflare account. Keep in mind that Cloudflare's API documentation may change, so it's a good idea to refer to the official Cloudflare API documentation for the most up-to-date information: https://developers.cloudflare.com/api