Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
Validates a Dev Proxy configuration file without starting the proxy.
Tip
You can also use the shorter devproxy validate command, which works the same way.
Synopsis
devproxy config validate [options]
Options:
-c, --config-file <config-file> The path to the configuration file to validate
--output <format> Output format: text|json (default: text)
-?, -h, --help Show help and usage information
Usage
devproxy config validate
Options
| Name | Description | Allowed values | Default |
|---|---|---|---|
-c, --config-file <config-file> |
The path to the configuration file to validate | Local file path | devproxyrc.json |
--output <format> |
Output format | text, json |
text |
-?, -h, --help |
Show help and usage information | n/a | n/a |
Examples
Validate the default configuration file
devproxy config validate
Validate a specific configuration file
devproxy config validate --config-file ./my-config.json
Validate and get structured JSON output
devproxy config validate --output json
With --output json, Dev Proxy emits the validation result as a result record. The data property contains the result object:
{"type":"result","data":{"valid":false,"configFile":"/Users/user/project/devproxyrc.json","plugins":["LatencyPlugin"],"urlsToWatch":["https://api.contoso.com/*"],"errors":[{"path":"plugins[0].pluginPath","message":"Plugin assembly '/Users/user/project/plugins/DevProxy.Plugins.dll' not found"}],"warnings":[]},"timestamp":"2026-11-30T10:15:42.0000000Z"}
The result object contains the following properties:
| Property | Description |
|---|---|
valid |
true when the configuration has no errors, otherwise false |
configFile |
Full path to the validated configuration file |
plugins |
Names of the enabled plugins |
urlsToWatch |
Global URL patterns to watch |
errors |
List of errors. Each error has a path that points to the invalid setting and a message |
warnings |
List of warnings. Each warning has a path and a message |
Exit codes
| Code | Meaning |
|---|---|
0 |
Configuration is valid. The configuration might still contain warnings |
2 |
Configuration is invalid or file not found |
Remarks
The config validate command reports errors when:
- The configuration file doesn't exist or isn't valid JSON or YAML
- The configuration doesn't match the specified
$schema - There are no enabled plugins, or a plugin's path doesn't exist or its assembly doesn't contain the plugin
- A URL pattern in
urlsToWatchisn't valid - A plugin's configuration section doesn't match the schema specified in its
$schemaproperty. Dev Proxy validates a configuration section only when it specifies a$schemaandvalidateSchemasisn't set tofalse. The error's path is the name of the configuration section
The command reports warnings, which don't make the configuration invalid, when:
- The configuration file doesn't specify a
$schema, or the schema of the configuration file or a plugin's configuration section can't be retrieved - The schema version of the configuration file or a plugin's configuration section doesn't match the version of Dev Proxy
- An enabled plugin has no URLs to watch, because neither the plugin nor the configuration file defines
urlsToWatch. Dev Proxy doesn't load such plugins unless you pass URLs using the--urls-to-watchoption - A plugin references a
configSectionthat doesn't exist in the configuration file. In this case, the plugin uses its default configuration
Note
Schema validation only applies to JSON-based configuration files. YAML configuration files aren't validated against schemas at runtime.
Use this command in CI/CD pipelines to catch configuration errors before deploying.