To keep a small footprint in your application, the Trust Stack SDK is split into modules. Each module is a separate package and can be imported individually.This means you can install only what is important to your application.
Canvas
Admin
Hermes
DID
Copy
npm install @truststack/canvas# or yarn add @truststack/canvas# or pnpm add @truststack/canvas
Copy
npm install @truststack/admin# or yarn add @truststack/admin# or pnpm add @truststack/admin
Copy
npm install @truststack/hermes# or yarn add @truststack/hermes# or pnpm add @truststack/hermes
Copy
npm install @truststack/did# or yarn add @truststack/did# or pnpm add @truststack/did
If you call configure on any module, it will set those attributes for all modules.
Copy
import { AdminClient } from '@truststack/admin';AdminClient.configure({ accessKey: 'my-access-key' });...import { CanvasClient } from '@truststack/canvas';// This will use the access key set aboveconst client = new CanvasClient();client.createCanvasTemplate({ ... });