> For the complete documentation index, see [llms.txt](https://onairos.gitbook.io/docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://onairos.gitbook.io/docs/developer-guides/developer-debugging.md).

# Developer Debugging

#### Errors and Debugging

All Errors and Debugging from the Inference API will be of the form

```jsx
    res.status(statusCode).send({ error: message }); 
```

Statuses of 200 are valid, and all others indicate potential issues

But here are common issues and solutions when integrating Onairos into your Application:

1. Onairos Extension closes Immediately after Opening

   Please ensure you have registered your App domain in your Onairos developement account
2. 'Refused to execute because it's MIME type (text/html)' or any similar warning like this:

<figure><img src="/files/rioJDAXSMfJ9bjimtyQE" alt=""><figcaption></figcaption></figure>

The onairos package uses dynamic imports to reduce package size and improve performance on your applications, seeing this error means your app is not copying the import chunks (sha-256 and othent/kms) from the onairos node modules folder to your build folder

Solution:

If you are using webpack or similar builds, you can utilize react-app-rewired build and the followin override-config.js:

\`\`\`jsx

```javascript
module.exports = function override(config, env) {
    // Do not run this configuration while in development mode
    if (env === 'development') {
        return config;
    }

    // Add the CopyPlugin to the list of plugins
    config.plugins = (config.plugins || []).concat([
        new CopyPlugin({
            patterns: [
                // Adjust the from path to the actual path of the onairos chunks in your node_modules
                { from: 'node_modules/onairos/dist/*.chunk.js', to: 'static/js/[name].[ext]' },
            ],
        }),
    ]);

    return config;
};
  
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## 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, and the optional `goal` query parameter:

```
GET https://onairos.gitbook.io/docs/developer-guides/developer-debugging.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
