Skip to content

sopia-bot/sopia-core

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

304 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

sopia-core

Spoon radio core API https://www.spooncast.net/

Install

npm install sopia-core

or

yarn add sopia-core

Usage

import * as spoon from 'sopia-core';

(async () => {
    const sopia = new spoon.Client('DeviceUUID');
    await sopia.login('Your ID', 'Password', spoon.LoginType.PHONE);
    
    
    const socket = await sopia.liveManager.liveJoin(#Live);
    
    socket.on(spoon.LiveEvent.LIVE_JOIN, (e) => {
        // do something.
        ...
        socket.message('Message');
    });
    
    socket.on(spoon.LiveEvent.LIVE_MESSAGE, (e) => {
        // sender = e.author
    });
})();

About

Core api caller package for spooncast

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published