> For the complete documentation index, see [llms.txt](https://codemash.gitbook.io/codemash/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://codemash.gitbook.io/codemash/cloud/integrations/test.md).

# Test an integration

Test a database integration — Norbix connects and runs a short write-and-read check.

**Where:** Database → Integrations → *integration* → **Test integration** · `/projects/<project>/db/integrations/<integrationId>/edit`

## Before you start

* The integration is saved — see [MongoDB](/codemash/cloud/integrations/providers/mongodb.md). A new integration must be saved before it can be tested.
* For MongoDB Atlas: the Atlas **Network Access** list allows the Norbix runtime IPs, and the user in the connection string can read and write.

## Steps

1. Open **Database → Integrations** and click the integration. Its badges show the state, for example **ENABLED** · **NOT TESTED**.
2. Scroll to the bottom of the form and press **Test integration**.

   <figure><img src="https://712692422-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FHy372bqsaex2cqS3ikhL%2Fuploads%2Fgit-blob-577a432398c90b826f05ee62a316bbc02bd2bded%2Ftest-1.png?alt=media" alt="The lower part of the Reporting replica integration form with the Test integration button"><figcaption><p>The Test integration button.</p></figcaption></figure>

## Result

While the test runs the button says **Testing...**. Then the panel shows **Test passed** (or **Test failed**) with the time of the run and one line per check — **CreateRepository**, **InsertRecord**, **FindRecord** and the others — each **Success** or with its error. The badge becomes **TESTED** (or **TEST FAILED**), and the list shows **Last Test Succeeded** `True`.

<figure><img src="https://712692422-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FHy372bqsaex2cqS3ikhL%2Fuploads%2Fgit-blob-298ca55b58b90a07b6c1bfa69bbb985eaf9389f6%2Ftest-2.png?alt=media" alt="Test passed, Last run 10/6/2026, with the checks CreateRepository, InsertRecord and FindRecord marked Success"><figcaption><p>A passed test.</p></figcaption></figure>

A failed test most often means the Atlas IP access list does not allow Norbix, or the user or password in the string is wrong. Fix the connection string, **Save**, and test again.

## Change or remove it later

* [Set it as default](/codemash/cloud/integrations/set-default.md) once it passes.
* [Disable or delete it](/codemash/cloud/integrations/disable.md).

## Do it from code

```ts
const test = await norbix.hub.database.testDatabaseIntegration({ integrationId: id });
console.log(test); // { items: [ { operation: 'CreateRepository', result: 'OK' }, { operation: 'InsertRecord', result: 'OK' }, … ] }
```

```sh
norbix hub database integration test --integrationId int_16tRKvLqwNnK1sPWkSkNUV
```

The client setup is on the [Database page](/codemash/cloud/database.md#use-it-from-code). API: [Test Database Integration](/codemash/api-reference/database/integrations/test-database-integration.md)
