| Total Complexity | 1 | 
| Total Lines | 20 | 
| Duplicated Lines | 0 % | 
| Changes | 1 | ||
| Bugs | 0 | Features | 0 | 
| 1 | # Licensed to the StackStorm, Inc ('StackStorm') under one or more | 
            ||
| 18 | class EnableHeartbeatAction(OpsGenieBaseAction):  | 
            ||
| 19 | def run(self, name):  | 
            ||
| 20 | """  | 
            ||
| 21 | Enable monitored heartbeat in OpsGenie.  | 
            ||
| 22 | |||
| 23 | Args:  | 
            ||
| 24 | - name: Name of the heartbeat.  | 
            ||
| 25 | |||
| 26 | Returns  | 
            ||
| 27 | - dict: The data returned from OpsGenie.  | 
            ||
| 28 | """  | 
            ||
| 29 | |||
| 30 |         body = {"apiKey": self.api_key, | 
            ||
| 31 | "name": name}  | 
            ||
| 32 | |||
| 33 |         data = self._req("POST", | 
            ||
| 34 | "v1/json/heartbeat/enable",  | 
            ||
| 35 | body=body)  | 
            ||
| 36 | |||
| 37 | return data  | 
            ||
| 38 |