Elgato

Control Center

CastHub makes controlling Elgato Control Center easy by communicating on your behalf. For example:

async mounted() {
    await super.mounted();

    const { id } = this.identity;

    // Connect to the external WebSocket.
    const ws = await window.casthub.ws(id);

    // Listen to specific Control Center events.
    ws.on('deviceAdded', data => {
        console.log('deviceAdded', data);
    });

    // Request specific command repsonses.
    const response = await ws.send('getApplicationInfo');
    console.log(response);
}