Skip to main content

MIKRO400 - Invalid Response From MikroTik

Agent error code #MIKRO400 indicates that the agent reached the RouterOS REST API and received a response, but the response did not match the expected shape. The most common case is a non-2xx HTTP status with a JSON body that included a message field. Less commonly, a 2xx response that failed to parse.

This usually points at a transient RouterOS-side error (e.g., the device is reloading config) or an upstream proxy rewriting the response. It is rarely caused by a Knocknoc misconfiguration.

Steps to Resolve

Inspect the Agent Log

The agent logs the full RouterOS error message and HTTP status under the operation that produced the response. Search the agent log for the relevant operation to see the message/detail fields returned by RouterOS.

Retry the Operation

If the error is transient (e.g., the device was reloading), retrying after a short pause usually succeeds. If the error persists across multiple grants, treat it as a real problem and investigate.

Confirm No Proxy is Rewriting the Response

If the agent talks to RouterOS through an HTTP proxy or reverse proxy, confirm the proxy is not rewriting JSON responses. From the agent host, hit the REST endpoint with curl using the same path the agent uses and compare the response with what the agent logs.

Still Having Issues?

We can help you out, contact us at support@knocknoc.io.