import {API, BaseService, kServiceUptime, kWidgetUptime} from '@bthlabs/homehub-core';

export class UptimeService extends BaseService {
  static kind = kServiceUptime;
  static widget = kWidgetUptime;
  async start () {
    const result = await API.Services.start(
      this.kind, this.instance, this.characteristics
    );

    this.notify(result);
  }
  async stop () {
    return API.Services.stop(kServiceUptime, this.instance);
  }
}
