diff --git a/README.md b/README.md index 143870ef8480b139715cb0a8f6007ab77f5c5fab..d8af66b879c4dfb2ae84a032f57399c6ed1b74d1 100644 --- a/README.md +++ b/README.md @@ -66,8 +66,53 @@ in all object types ### dns-api.sh -Low level command to access the api +Low level command to access the api. It is called from ./dns-search.sh too - but can be started manually for custom api urls. `dns-api.sh [METHOD] URL` This script is used by dns-search.sh. Maybe you don't want to execute it directly. + +### Output + +You maybe want to start with the lazy mode. + +Here you see how it accesses the api and the returned json data of each request. + +Between the json data are lines starting with a semikolon - these are comments +written to STDERR. To hide them add a 2>/dev/null to hide the comments. + +```txt +./dns-search.sh www.iml.unibe.ch +; +; === INFOBLOX DNS SEARCH +; +; search for type : +; search regex : www.iml.unibe.ch +; +; === DNS API :: GET /record:host?name~=www.iml.unibe.ch&_return_fields%2B=aliases,ttl +[ + { + "_ref": "record:host/REFID:www.iml.unibe.ch/default", + "aliases": [ + ... + ], + "ipv4addrs": [ + { + "_ref": "record:host_ipv4addr/REFID_2:86.119.35.66/www.iml.unibe.ch/default", + "configure_for_dhcp": false, + "host": "www.iml.unibe.ch", + "ipv4addr": "86.119.35.66" + } + ], + "name": "www.iml.unibe.ch", + "ttl": 300, + "view": "default" + } +] +; === DNS API :: GET /record:host?alias~=www.iml.unibe.ch&_return_fields%2B=aliases,ttl +[] +; === DNS API :: GET /record:host?ipv4addr~=www.iml.unibe.ch&_return_fields%2B=aliases,ttl +[] +; === DNS API :: GET /record:cname?name~=www.iml.unibe.ch&_return_fields%2B=ttl +[] +```