Narnia's Psychedelic Mushrooms

    @sme-uploader/companion-client
    TypeScript icon, indicating that this package has built-in type declarations

    1.0.2 • Public • Published

    @sme-uploader/companion-client

    SME Uploader logo Build Status

    Client library for communication with Companion. Intended for use in SME Uploader plugins.

    Example

    const SmeUploader = require('@sme-uploader/core');
    const { Provider, RequestClient, Socket } = require('@sme-uploader/companion-client');
     
    const uploader = new SmeUploader();
     
    const client = new RequestClient(uploader, { companionUrl: 'https://sme-uploader.mywebsite.com/' });
    client.get('/drive/list').then(() => {});
     
    const provider = new Provider(uploader, {
      companionUrl: 'https://sme-uploader.mywebsite.com/',
      provider: providerPluginInstance
    });
    provider.checkAuth().then(() => {});
     
    const socket = new Socket({ target: 'wss://sme-uploader.mywebsite.com/' });
    socket.on('progress', () => {});

    Installation

    Unless you are writing a custom provider plugin, you do not need to install this.

    $ npm install @sme-uploader/companion-client

    License

    The MIT License.

    Install

    npm i @sme-uploader/companion-client

    DownloadsWeekly Downloads

    11

    Version

    1.0.2

    License

    MIT

    Unpacked Size

    67.2 kB

    Total Files

    24

    Last publish

    Collaborators

    • sme-uploader