Get Started

Set up your first Nuvix project and make your first API call.

Nuvix provides a complete backend-as-a-service. This guide will get you from zero to a running application in minutes.

Create a Project

Everything in Nuvix starts with a Project.

  1. Log in to the Nuvix Console.
  2. Click Create Project.
  3. Give it a name (e.g., "My Awesome App") and a unique ID.

Save your Project ID. You'll need it to initialize the SDK.

Install the SDK

Nuvix provides type-safe SDKs for your client applications.

npm install @nuvix/client
yarn add @nuvix/client
pnpm add @nuvix/client

Initialize the Client

Initialize the SDK in your application's entry point (e.g., App.js, main.ts).

import { Client } from '@nuvix/client';

const nx = new Client()
    .setEndpoint('https://api.nuvix.in/v1') // Your API Endpoint
    .setProject('<PROJECT_ID>'); // Your Project ID

Make Your First Request

Let's test the connection by creating an anonymous session. This verifies that your app can talk to Nuvix.

import { Client } from '@nuvix/client';

const nx = new Client()
    .setEndpoint('https://api.nuvix.in/v1')
    .setProject('<PROJECT_ID>');

// Create an anonymous session
const session = await nx.account.createAnonymousSession();

console.log('Logged in as guest:', session.$id);

Next Steps

Now that you're connected, explore the core modules:

Server-Side Access

For backend scripts or administrative tasks, use the REST API with an API Key.

  1. In the Console, go to Settings > API Keys.
  2. Create a key with the scopes you need (e.g., documents.read, users.write).
  3. Pass the key in the X-API-Key header.
curl -H "X-Project-ID: <PROJECT_ID>" \
     -H "X-API-Key: <YOUR_API_KEY>" \
     https://api.nuvix.in/v1/users

How is this guide?

Last update: