Connect to a MongoDB Realm Backend App - Node.js SDK
Overview
The Realm app client is the interface to the MongoDB Realm backend. It provides access to the authentication functionality, functions, and sync management.
Access the App Client
Pass the MongoDB Realm App ID for your Realm app, which you can find in the Realm UI.
Configuration
To set up your Realm app client, pass a configuration object to an instance
of Realm.App
.
Note
id
is a required field of the application configuration object. To see the full list of fields for the configuration object that Realm.App
accepts as a parameter, view the App Configuration Type Definitions.
Retrieve an Instance of the App Client
To retrieve an instance of the App Client from anywhere in your application, call Realm.App.getApp() and pass in your App ID
.