diff --git a/README.md b/README.md index 36f5a78..97dbdc2 100644 --- a/README.md +++ b/README.md @@ -105,7 +105,9 @@ result = solver.normal('https://site-with-captcha.com/path/to/captcha.jpg', para ``` ### Audio Captcha -To bypass an audio captcha (mp3 formats only) use the following method. Language must be in foramt lang = 'en'. Acceptable languages are "en", "ru", "de", "el", "pt". +To bypass an audio captcha (mp3 formats only) use the following method. +You must provife the language as `lang = 'en'`. Supported languages are "en", "ru", "de", "el", "pt". + ```python result = solver.audio('path/to/captcha.mp3', lang = 'lang', param1=..., ...) # OR diff --git a/examples/audio/example.mp3 b/examples/audio/example.mp3 new file mode 100644 index 0000000..c063a6a Binary files /dev/null and b/examples/audio/example.mp3 differ diff --git a/twocaptcha/solver.py b/twocaptcha/solver.py index b0666ec..9123684 100755 --- a/twocaptcha/solver.py +++ b/twocaptcha/solver.py @@ -94,7 +94,7 @@ def audio(self, file, lang, method, **kwargs): #"method":"audio", #method if not ((not '.' in file and len(file) > 50) or (file.endswith(".mp3") and file.startswith("http"))): - raise ValidationException('File has not .mp3 base64 str. You must send .mp3 file or base64 str') + raise ValidationException('File extension is not .mp3 or it is not a base64 string.') method = self.get_method(file) method['method'] = "audio"