Skip to main content

Use the Lattice SDK for gRPC in JavaScript

This page shows you how to set up the Lattice SDK for gRPC in JavaScript and make a gRPC request.

Click to go to the gRPC SDK repository. By downloading and/or using, you agree to the terms of use. If you do not agree, do not use the SDK.

Before you begin

Before you install and use the gRPC SDK in Java, do the following:

  1. Complete the setup steps to generate a valid API token and publish at least one entity to your environment.
  2. Install the latest version of NodeJS.
  3. Install the TypeScript compiler.

Set up your project

  1. Create a new folder for your project.
  2. In your project folder, set up packages and install type definitions for Node.js:
    npm init

Install the SDK

To install the gRPC SDK in JavaScript, add the following dependencies to your project:

npm install @anduril-industries/lattice-sdk
npm install @connectrpc/connect
npm install @connectrpc/connect-node

Optionally, handle unit tests in your project by installing Mocha:

npm install mocha

What's next