UNOFFICIAL and WIP JavaScript/TypeScript SDK for Parsec remote desktop.
This is an UNOFFICIAL package, which is also very early in development. The vast majority of necessary features is missing at this point. See the Roadmap project and issues on Github to get a list of upcoming functionalities.
I AM NOT associated with Parsec or Unity in any way.
npm install --save parsec-sdk
Online documentation is automatically generated using TypeDoc and hosted on Github Pages. It's available on https://maciejpedzich.github.io/node-parsec-sdk/
// CommonJS (ES5)
const { Client } = require('parsec-sdk');
// Module import (ES6+ and TypeScript)
import { Client } from 'parsec-sdk';
const parsec = new Client();
async function authDemo() {
try {
await parsec.authPersonal({
email: 'parsec-account-email@example.com',
password: 'ParsecAccountP4ssword!',
tfa: '123456' // OPTIONAL TFA code
});
console.log(`Peer ID: ${parsec.peerID}\nSession ID: ${parsec.sessionID}`);
} catch (error) {
console.error(error);
}
}
async function hostsDemo() {
try {
const { data } = await parsec.getHosts({ mode: 'desktop' });
console.log(data);
} catch (error) {
console.error(error);
}
}
authDemo();
hostsDemo();
After cloning the repository, simply cd
into the repository's directory in your CLI and run npm install
npm run prettier-format
npm run lint
npm run test
npm run build
npm run generate-docs
MIT