# Error Handling and Troubleshooting

The Verifier and its integration libraries return clear HTTP status codes and JSON error messages when something goes wrong:

**Common Error Codes:**

* **400 Bad Request**: Invalid input, malformed VP queries, or missing parameters.
* **401 Unauthorized**: Missing or invalid `clientSecret`, or expired tokens.
* **403 Forbidden**: The request is not permitted for the given user or flow.
* **404 Not Found**: Non-existent verification requests or invalid endpoints.
* **500 Internal Server Error**: Unexpected issues, configuration errors, or downstream service failures.

**Example Error Response:**

```json
{
  "message": "Invalid request parameters",
  "code": 400
}
```

**Troubleshooting Tips:**

* Validate that your `vpQuery` definitions are correct.
* Check that you are passing the correct state, nonce, and tokens.
* Review server logs for more detailed error traces.
* Ensure that HTTPS is configured correctly and that credentials (e.g., `clientSecret`) are stored securely.

If errors persist, consider reviewing your Verifier configuration, verifying DID resolution, and confirming that the EMPE Blockchain is accessible and stable.


---

# 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.empe.io/develop/verifier/error-handling-and-troubleshooting.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.
