# Initialize

{% tabs %}
{% tab title="Commonjs" %}
{% code lineNumbers="true" %}

```javascript
const { Dubnium } = require('dubnium') // const dubnium = require('dubnium') works as well.
const db = new Dubnium('dirPath','ext', useConfig)
```

{% endcode %}

or

{% code lineNumbers="true" %}

```javascript
const db = new (require("dubnium"))("dirPath","ext")
```

{% endcode %}
{% endtab %}

{% tab title="ECMAScript" %}
{% code lineNumbers="true" %}

```javascript
import Dubnium from 'dubnium'
const db = new Dubnium('dirPath','ext', useConfig)
```

{% endcode %}
{% endtab %}
{% endtabs %}

{% hint style="info" %}
You can initialize as many databases as you want
{% endhint %}

### Parameters

<table><thead><tr><th>Name</th><th>About</th><th>Type</th><th data-type="checkbox">Required</th></tr></thead><tbody><tr><td>dirPath</td><td>The path to the directory to store Records.</td><td>string</td><td>true</td></tr><tr><td>ext</td><td>Custom file extension (default: <code>json</code>) </td><td>string</td><td>false</td></tr><tr><td>useConfig</td><td>Use config file (default: <code>true</code>)</td><td>bool</td><td>false</td></tr></tbody></table>


---

# 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://db.coolstone.dev/2/initialize.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.
