1.0.47 • Published 3 months ago
curtain-web-api v1.0.47
Curtain Web API
This is a node.js package used to interact with the Curtain Web REST API.
Installation
npm install curtain-web-api pouchdb -s
npm install @types/pouchdb -D
Usage
import { CurtainWebApi } from 'curtain-web-api';
const curtainAPI = new CurtainWebApi("https://curtain-api-location/")
// Login to the API
curtainAPI.login("username", "password").then((result) => {
console.log(result);
// The result is an object containing the user's information
}).catch((error) => {
console.log(error);
});
// Get the user's information
curtainAPI.getUser().then((result) => {
console.log(result);
// The result is an object containing the user's information similar to the login but can only be performed after login have succeeded
}).catch((error) => {
console.log(error);
});
// Get session information
curtainAPI.getSessionSettings(sessionId).then((result) => {
console.log(result);
// The result is an object containing the session's basic information without any data
}).catch((error) => {
console.log(error);
});
// Get session data
curtainAPI.postSettings(sessionId, sessionToken).then((result) => {
console.log(result);
// The result is an object containing the session's data
}).catch((error) => {
console.log(error);
});
// Upload session data
curtainAPI.putSettings(settings, enableToPublic, description, sessionType).then((result) => {
console.log(result);
// The result is an object containing the session's data
}).catch((error) => {
console.log(error);
});
1.0.47
3 months ago
1.0.46
3 months ago
1.0.19
10 months ago
1.0.18
10 months ago
1.0.39
6 months ago
1.0.17
10 months ago
1.0.38
6 months ago
1.0.40
6 months ago
1.0.44
6 months ago
1.0.22
8 months ago
1.0.43
6 months ago
1.0.21
9 months ago
1.0.42
6 months ago
1.0.20
9 months ago
1.0.41
6 months ago
1.0.26
6 months ago
1.0.25
6 months ago
1.0.24
8 months ago
1.0.45
6 months ago
1.0.23
8 months ago
1.0.29
6 months ago
1.0.28
6 months ago
1.0.27
6 months ago
1.0.33
6 months ago
1.0.32
6 months ago
1.0.31
6 months ago
1.0.30
6 months ago
1.0.37
6 months ago
1.0.36
6 months ago
1.0.35
6 months ago
1.0.34
6 months ago
1.0.16
10 months ago
1.0.11
11 months ago
1.0.10
11 months ago
1.0.15
11 months ago
1.0.14
11 months ago
1.0.13
11 months ago
1.0.12
11 months ago
1.0.9
11 months ago
1.0.8
11 months ago
1.0.7
11 months ago
1.0.6
1 year ago
1.0.5
1 year ago
1.0.4
1 year ago
1.0.3
1 year ago
1.0.2
1 year ago
1.0.1
1 year ago
1.0.0
1 year ago