# check-creds

## check-creds

This is a stand-alone utility to help verify entries in `creds.json`.

The command does a trivial operation to verify credentials. If successful, a list of zones will be output (which may be an empty list). If the credentials or other problems prevent this operation from executing, the exit code will be non-zero and hopefully verbose error messages will be output.

```
Syntax:

   dnscontrol check-creds [command options] credkey provider

   --creds value   Provider credentials JSON file (default: "creds.json")
   --out value     Instead of stdout, write to this file

ARGUMENTS:
   credkey:  The name used in creds.json (first parameter to NewDnsProvider() in dnsconfig.js)
   provider: The name of the provider (second parameter to NewDnsProvider() in dnsconfig.js)
```

Starting in [v3.16](https://docs.dnscontrol.org/release/v316), "provider" is optional. If it is omitted (or the placeholder value `-` is used), the `TYPE` specified in `creds.json` will be used instead. A warning will be displayed with advice on how to remain compatible with v4.0.

Starting in v4.0, the "provider" argument is expected to go away.

### Examples

```shell
dnscontrol check-creds myr53 ROUTE53
```

Starting in [v3.16](https://docs.dnscontrol.org/release/v316):

```shell
dnscontrol check-creds myr53
dnscontrol check-creds myr53 -
dnscontrol check-creds myr53 ROUTE53
```

Starting in v4.0:

```shell
dnscontrol check-creds myr53
```

This command is the same as `get-zones` with `--format=nameonly`

## Developer Note

This command is not implemented for all providers.

To add this to a provider, implement the get-zones subcommand.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.dnscontrol.org/commands/check-creds.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
