Cloudflare Dynamic DNS via Python 3
https://github.com/woolweaver-bid/python-cloudflare-ddns
git clone https://github.com/mwoolweaver/python-cloudflare-ddns.git
cd python-cloudflare-ddns
pip3 install -r requirements.txt
In config/tokens.py you will see the following variables. Make sure you change these.
I have included some information about how to get these.
-
headers = { 'Authorization': 'Your-API-Token', # Get/Create API token here ---> https://dash.cloudflare.com/profile/api-tokens 'Content-Type': 'application/json' # Type of data to be passed must be application/json }
-
https://api.cloudflare.com/#getting-started-resource-ids
zoneID = 'Zone-ID-For-Domain' # Zone ID for domain we need to change
-
https://api.cloudflare.com/#dns-records-for-a-zone-list-dns-records
dnsID = 'DNS-ID-For-SubDomain' # DNS ID for subdomain we want to change
./cf_ddns.py