Quantcast
Channel: Kevin Deldycke - English
Viewing all articles
Browse latest Browse all 5

CloudFlare commands

$
0
0

API

DNS records

  • List DNS records of a zone:
$ curl-XGET"https://api.cloudflare.com/client/v4/zones//dns_records"\-H"Authorization: Bearer "\-H"Content-Type:application/json"
  • List DNS records IDs of a zone:
$ curl-XGET"https://api.cloudflare.com/client/v4/zones//dns_records"\-H"Authorization: Bearer "\-H"Content-Type:application/json"\|jq'.result[].id'"82c881261189dc8b8ddbd756cffccd21""324437ed3e1212770edeabb65bb3cd6a"
  • Delete one DNS record:
$ curl-XDELETE"https://api.cloudflare.com/client/v4/zones//dns_records/"\-H"Authorization: Bearer "\-H"Content-Type:application/json"
  • Delete all DNS records of a zone:
$ curl-XGET"https://api.cloudflare.com/client/v4/zones//dns_records"\-H"Authorization: Bearer "\-H"Content-Type:application/json"\|jq--raw-output'.result[].id'\|xargs-I'{}'\curl-XDELETE"https://api.cloudflare.com/client/v4/zones//dns_records/{}"\-H"Authorization: Bearer "\-H"Content-Type:application/json"

Viewing all articles
Browse latest Browse all 5

Latest Images

Trending Articles



Latest Images