Installing the VIVERSE CLI Module

This document provides a guide for setting up the VIVERSE CLI Module which is a command-line tool for the VIVERSE platform, providing simple yet powerful functionality to manage VIVERSE accounts.

  • General description of what is this page

  • Prerequisites for using the VIVERSE CLI (node v22)

  • Installing the VIVERSE CLI in your account

  • Signing in with auth

  • A description of usage and how to learn more

  • Compatibility with VIVERSE

    • Do you need to use vite.js or can you use another library for building your project?

    • Do you need to use three.js or can you use other packages?

    • Can you do API calls from within your project on VIVERSE?


Pre-Requisites

  • Node.js v22.14.0 or later installed

Installing the VIVERSE CLI in your account

1

Install the tool using command prompt

A. Inside a command prompt, type: npm install -g @viverse/cli, then click Enter. Installing a package with -g installs the package globally. The location of globally installed packages depends on your operating system and npm configuration:

  • Windows : In windows, packages are installed in %APPDATA%\npm\node_modules .

  • macOS and Linux : In mac or Linux packages are typically installed in /usr/local/lib/node_modules or a user-specific directory like ~/.npm-global.

B. Confirm that the command line tool is installed based on screen feedback.

Signing into VIVERSE with VIVERSE CLI

1

Login to VIVERSE platform

A. Open a command prompt and type: viverse-cli auth login, then click Enter.

B. Enter VIVERSE email and password.

C. Confirm login was successful.

VIVERSE CLI usage

Process
Command

Login to VIVERSE platform

viverse-cli auth login

Non-interactive login for CI/CD integration

viverse-cli auth login -e <email> -p <password>

For CI/CD environments, it's recommended to use environment variables

viverse-cli auth login -e $VVS_EMAIL -p $VVS_PASSWORD

Check authentication status

viverse-cli auth status

Logout

viverse-cli auth logout

Publish content

viverse-cli publish <path>

View application list

viverse-cli app list

Compatibility with VIVERSE

Do you need to use three.js or can you use other packages?

No, VIVERSE CLI can be used with other WebGL frameworks, including AFRAME, Babylon, ReactThreeFibre, UnityWebGL, GodotHTML5 and more!

Do you need to use vite.js or can you use another library for building your project?

You don’t need to use Vite specifically. Any tool that builds standard web content is fine. Examples include Webpack, Parcel, Rollup, or custom pipelines from Unity WebGL, PlayCanvas, Three.js, etc.

The only thing we do require is that your build uses content hashing for file names, especially for JavaScript and CSS files.

This helps prevent cache issues. If the file name doesn’t change when the content changes, users might still get the old version due to browser cache.

Can you do API calls from within your project on VIVERSE?

Currently, we don’t support arbitrary external API calls from user content on VIVERSE, mainly for security and platform consistency.

However, we’re planning to pre-approve a set of popular service domains — like Firebase, Photon, and Lovable — so developers can integrate with these out of the box.

If you need to use a different third-party service, you can reach out to the VIVERSE team, and we’ll review it for potential inclusion. Please include your VIVERSE world URL and details about the endpoint you are desiring to use.

In the future, we’re looking at supporting per-content Domain access requests.

This will most likely be managed through the Creator Studio backend, rather than via the CLI, to give creators better visibility and control over their external dependencies.

Last updated

Was this helpful?