how can i pause a service using another service?
Thanks in Advance!!
If you started running a service, it will either fail or end in less than a few seconds, so I think you're referring to Pause a Subscription and make it not triggering by any event afterwards?
If so, you can disable the subscription itself or the event that triggers it.
For example:
me.DisableSubscription({
propertyName: undefined /* STRING */,
eventName: undefined /* STRING */,
thingName: undefined /* THINGNAME */
});
Can i pause a event?
The regular Events used to trigger the subscriptions are: (Any)Alert, (Any)AlertAck, (Any)AlertReset, (Any)DataChange, ThingStart, Timer/ Scheduler.
You can disable Alerts or Timers to pause the Event, and enable them to restart, but it took same steps as disabling the Subscriptions but cause more side effects, so that's not suggested. And for DataChange event, we cannot pause it.