From 45c3aeb218158f71fd37046b89e5aae5aff66f1d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lu=C3=ADs=20Gustavo=20Cuozzo?= Date: Wed, 17 Feb 2021 16:49:44 -0300 Subject: [PATCH] Add tag and config --- cpqdtrd/client.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cpqdtrd/client.py b/cpqdtrd/client.py index f72446d..39f162e 100644 --- a/cpqdtrd/client.py +++ b/cpqdtrd/client.py @@ -218,7 +218,7 @@ def unregister_all(self): del self._callbacks[name] self._reset_start() - def transcribe(self, path, timeout="auto", delete_after=True): + def transcribe(self, path, tag=None, config=None, timeout="auto", delete_after=True): """ Transcribe an audio file. @@ -267,7 +267,7 @@ def transcribe(self, path, timeout="auto", delete_after=True): webhooks += ["{}/{}".format(webhook_root, name) for name in self._callbacks] # Upload audio file. Currently only expects - r = self.api.create(path, callbacks_url=webhooks) + r = self.api.create(path, tag=tag, config=config, callbacks_url=webhooks) r.raise_for_status() job = r.json()["job"] job_id = job["id"]