I am writing a telegram bot in Python. The user enters the domain of the site, in the reply message I need to send him the dns record. How do I do this with the Cloudflare API?
fritex
January 9, 2023, 7:52pm
2
valetinles:
Python
Below should help a bit:
Very early on in the company’s history we decided that everything that CloudFlare does on behalf of its customer-base should be controllable via an API. In fact, when you login to the CloudFlare control panel, you’re really just making API calls to...
From the API reference:
Some other examples might help - I haven’t tested:
This is based on our previous post Python Cloudflare DNS A record update example but also creates the record if it doesn’t exist. #!/usr/bin/env python3 import CloudFlare import argparse import sys if __name__ == "__main__": parser =...
Est. reading time: 2 minutes
1 Like