Spaces:
Runtime error
Runtime error
Download src/api/controllers/label.controller.ts from oex2003/evolution-api: direct link, hf CLI and curl.
- Browser
- Download file 577 Bytes
-
https://huggingface.co/spaces/oex2003/evolution-api/resolve/main/src/api/controllers/label.controller.ts
- Command line
-
hf download hf://spaces/oex2003/evolution-api/src/api/controllers/label.controller.ts
-
curl -L -o label.controller.ts https://huggingface.co/spaces/oex2003/evolution-api/resolve/main/src/api/controllers/label.controller.ts
577 Bytes
| import { InstanceDto } from '@api/dto/instance.dto'; | |
| import { HandleLabelDto } from '@api/dto/label.dto'; | |
| import { WAMonitoringService } from '@api/services/monitor.service'; | |
| export class LabelController { | |
| constructor(private readonly waMonitor: WAMonitoringService) {} | |
| public async fetchLabels({ instanceName }: InstanceDto) { | |
| return await this.waMonitor.waInstances[instanceName].fetchLabels(); | |
| } | |
| public async handleLabel({ instanceName }: InstanceDto, data: HandleLabelDto) { | |
| return await this.waMonitor.waInstances[instanceName].handleLabel(data); | |
| } | |
| } | |