#7755 Authentication Fails, Your api key: ****4-UA is invalid (request_id: 7e669a45-a57f-428f-8fb5-500e9eae2b01)https://api.de

90.1**0 Posted at: 2 hours ago

Authentication Fails, Your api key:


4-UA is invalid (request_id: 7e669a45-a57f-428f-8fb5-500e9eae2b01)
https://api.deepseek.com/v1/
{'model': 'deepseek-v4-flash', 'timeout': 300, 'temperature': 0.1, 'max_tokens': 32768}
Traceback (most recent call last):
File "videotrans\translator\_openaicompat.py", line 77, in _item_task
File "openai\_utils\_utils.py", line 298, in wrapper
File "openai\resources\chat\completions\completions.py", line 1215, in create
File "openai\_base_client.py", line 1332, in post
File "openai\_base_client.py", line 1105, in request
openai.AuthenticationError: Error code: 401 - {'error': {'message': 'Authentication Fails, Your api key:
4-UA is invalid (request_id: 7e669a45-a57f-428f-8fb5-500e9eae2b01)', 'type': 'authentication_error', 'param': None, 'code': 'invalid_request_error'}}

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
File "videotrans\task\only_one.py", line 83, in run
File "videotrans\task\_stage_translate.py", line 31, in trans
File "videotrans\translator\_runner.py", line 63, in run
File "videotrans\translator\_base.py", line 68, in run
File "videotrans\translator\_base.py", line 107, in _run_text
File "tenacity\__init__.py", line 338, in wrapped_f
File "tenacity\__init__.py", line 477, in call
File "tenacity\__init__.py", line 378, in iter
File "tenacity\__init__.py", line 400, in
File "concurrent\futures\_base.py", line 451, in result
File "concurrent\futures\_base.py", line 403, in __get_result
File "tenacity\__init__.py", line 480, in call
File "videotrans\translator\_openaicompat.py", line 82, in _item_task
videotrans.configure.excepts.StopTask: Authentication Fails, Your api key:


4-UA is invalid (request_id: 7e669a45-a57f-428f-8fb5-500e9eae2b01)
https://api.deepseek.com/v1/
{'model': 'deepseek-v4-flash', 'timeout': 300, 'temperature': 0.1, 'max_tokens': 32768}

cfg=[TaskCfgVTT]当前工作模式: 翻译视频或音频 单视频模式
原始输入文件名: C:/Users/doris/Desktop/Nouveau dossier (2)/The Opener by Adrian Vega.mp4,
输出结果保存到文件夹: C:/Users/doris/Desktop/The Opener by Adrian Vega-mp4,
临时文件夹: C:/Users/doris/Desktop/Pyvideotrans/tmp/9164/41b81c5b69
未选 清理已存在
未启用CUDA加速
未选 降噪
STT Service:openai-whisper(Built-in), model_name: tiny, 发音语言: English, 断句方式:默认断句
TranslateSrt:DeepSeek,原始语言:English,目标语言:French, 未选 SendSRT
TTS Service:Edge-TTS (Free), 角色:Henri(Male/FR), 配音语言:French, 未选 二次语音识别
音量:+0%, 语速:+0%, 未选 音频加速, 已选 视频慢速
字幕: No Subtitles
已选 仅输出mp4
代理地址:


=
system:Windows-10-10.0.19045-SP0
version:v4.08
frozen:True
language:en
root_dir:C:/Users/doris/Desktop/Pyvideotrans

1 Replies

#1 DeepSeek reply at 2 hours ago

The error is a 401 Authentication failure from DeepSeek's API — your DeepSeek API key is invalid, incorrectly entered, or was revoked.

The traceback shows AuthenticationError: Error code: 401 - ...

Your api key: ****4-UA is invalid
, which means DeepSeek rejected the key you configured in the software.

This is not a bug in pyVideoTrans.

Fixes (in order of likelihood)

  1. Verify the key is valid and has balance

    • Log in to https://platform.deepseek.com/ and confirm the key still exists, is enabled, and the account has credit (an unpaid/zero-balance account can also trigger 401).
    • If the key was regenerated or deleted, create a new one.
  2. Re-enter the key in the software

    • Go to Menu → Settings/Translation Settings → DeepSeek, delete the old key, paste the new key, and save.
    • Watch for: leading/trailing spaces, missing characters, or accidentally pasting an email/password instead of the key.
  3. Check the API endpoint

    • Your log shows https://api.deepseek.com/v1/ — this is the correct DeepSeek endpoint.

      Leave it as-is unless you are intentionally routing through a proxy/relay (in which case the key must belong to that relay, not DeepSeek official).
  4. If you are using a third-party relay/proxy for DeepSeek

    • The key must match the relay provider, and the URL must be the relay's URL.

      A DeepSeek-official key will not work on a third-party URL and vice-versa.
  5. Also update your software

    • You are running v4.08.

      The latest is v4.14.

      Update to rule out any older channel-handling issues.

Side notes on your current config (not the cause of this error, but worth knowing)

  • openai-whisper with tiny model is the lowest-accuracy option — consider faster-whisper with large-v3-turbo for better results.
  • You selected 视频慢速 (Slow video) — this will significantly increase output file size and may cause frame freezing.

    If it's not necessary, prefer 音频加速 (Audio speed-up) only.
  • No Subtitles selected means no subtitle track will be embedded in the output.

请查阅相关文档:

Thinking...
Post Your Reply
If you have more than 50 messages, you will no longer receive an automatic reply. Please ask a new question!
Open source and free maintenance is not easy. If this project is helpful to you, please consider making a small donation to help the project continue to maintain and update.

Dondate via ko-fi.com

Related resource