README.md in cloudflare-3.1.0 vs README.md in cloudflare-3.2.0
- old
+ new
@@ -87,9 +87,17 @@
# note: "some note about the block"
data = {"mode":"block","configuration":{"target":"ip","value":"#{ip}"},"notes":"#{note} #{Time.now.strftime("%m/%d/%y")} "}
response = zones.first.firewall_rules.post(data.to_json, content_type: 'application/json')
```
+Add a DNS record dynamically. Here we add an A record for `batman.example.com`:
+
+```ruby
+client = Cloudflare.connect(key: CF_KEY, email: CF_EMAIL)
+zone = client.zones.find_by_name("example.com")
+zone.dns_records.post({"type":"A","name":"batman","content":"127.0.0.1","proxied":false}.to_json, :content_type => "application/json")
+```
+
## Contributing
1. Fork it
2. Create your feature branch (`git checkout -b my-new-feature`)
3. Commit your changes (`git commit -am 'Add some feature'`)