Skip to navigation

Stop the service and release resources. Calling it on a service that isn’t running does nothing.

Returns

void

Example

import { WebService } from '@signalwire/sdk';
const web = new WebService({
directories: { '/audio': './public/audio' },
basicAuth: ['audio', process.env['AUDIO_PASSWORD'] ?? ''],
});
await web.start();
process.on('SIGINT', () => {
web.stop();
process.exit(0);
});