Skip to main content

NPM Library

Introduction

The Simplicité NPM library is the official JavaScript client for connecting to a Simplicité backend from outside the platform — standalone web applications, server-side Node.js projects, or any framework-based frontend.

It exposes the same core API as the in-platform Ajax library and works in both browser and Node.js environments.

Installation

npm install simplicite

Basic usage

import simplicite from 'simplicite';

const app = simplicite.session({ url: '<instance URL>' });

try {
await app.login({ username: '<username>', password: '<password>' });

const obj = app.getBusinessObject('MyObject');
const list = await obj.search();
// Work with results
} catch (err) {
console.error(err.message);
}

Key features

  • Authentication: session management, login/logout
  • Business Object CRUD: search, get, create, update, delete
  • Document handling: inline documents and thumbnails
  • Metadata access: field definitions, list of values, object metadata

Demo repositories

Official examples for common environments:

EnvironmentRepository
Node.jsnodejs-demo
Plain HTML/JSweb-demo
Vue.jsvue-demo
Reactreact-demo
Angularangular-demo
React Nativereact-native-demo
Within Simplicitémodule-demo-jslib