openclaw/openclaw · error · Error
DeepInfra API key missing
Error message
DeepInfra API key missing
What it means
Thrown in generateVideo (extensions/deepinfra/video-generation-provider.ts:221) after resolveApiKeyForProvider returns an empty apiKey. The provider resolves the key from the auth store, agent config, and environment; if none yields a usable key, no request is sent. This mirrors the image provider's missingApiKeyError behavior.
Source
Thrown at extensions/deepinfra/video-generation-provider.ts:221
videoToVideo: {
enabled: false,
},
},
async generateVideo(req) {
if ((req.inputImages?.length ?? 0) > 0) {
throw new Error("DeepInfra video generation currently supports text-to-video only.");
}
if ((req.inputVideos?.length ?? 0) > 0) {
throw new Error("DeepInfra video generation does not support video reference inputs.");
}
const auth = await resolveApiKeyForProvider({
provider: "deepinfra",
cfg: req.cfg,
agentDir: req.agentDir,
store: req.authStore,
});
if (!auth.apiKey) {
throw new Error("DeepInfra API key missing");
}
const model = normalizeDeepInfraModelRef(req.model, defaultModel);
const deadline = createProviderOperationDeadline({
timeoutMs: req.timeoutMs,
label: "DeepInfra video generation",
});
const { baseUrl, allowPrivateNetwork, headers, dispatcherPolicy } =
resolveProviderHttpRequestConfig({
baseUrl: resolveDeepInfraVideoBaseUrl(req),
defaultBaseUrl: DEEPINFRA_BASE_URL,
allowPrivateNetwork: false,
defaultHeaders: {
Authorization: `Bearer ${auth.apiKey}`,
"Content-Type": "application/json",
},
provider: "deepinfra",
capability: "video",View on GitHub (pinned to 01804a7531)
Solutions
- Set the DeepInfra API key via 'openclaw configure' or the credentials store.
- Run 'openclaw doctor' to verify DeepInfra credential discovery.
- Confirm the key is associated with the 'deepinfra' provider id.
- Validate the key is active in the DeepInfra console.
Defensive patterns
Strategy: validation
Validate before calling
const auth = await resolveApiKeyForProvider({ provider: "deepinfra", cfg, agentDir, store });
if (!auth.apiKey) throw new Error("Configure the DeepInfra API key before video generation"); Type guard
async function isDeepInfraVideoKeyAvailable(ctx: { cfg: unknown; agentDir: unknown; store: unknown }): Promise<boolean> {
const auth = await resolveApiKeyForProvider({ provider: "deepinfra", ...ctx });
return typeof auth.apiKey === "string" && auth.apiKey.length > 0;
} Prevention
- Run onboarding ('openclaw configure') to store the DeepInfra key before first use.
- Use 'openclaw doctor' to confirm credentials resolve.
- Gate video features behind an isConfigured check in the UI.
When it happens
Trigger: A video generation request is made to DeepInfra, and resolveApiKeyForProvider({ provider: 'deepinfra', cfg, agentDir, store }) returns { apiKey: undefined }.
Common situations: DeepInfra API key not configured in credentials; running in an environment without the key; key stored under a different provider id; auth store not initialized; first run without onboarding.
Related errors
- BytePlus API key missing
- Deepgram API key missing
- DeepInfra video response returned malformed data URL base64
- DeepInfra video response missing video URL
- DeepInfra video generation requires an OpenAI-compatible end
AI-assisted analysis of openclaw/openclaw@01804a7531 (2026-08-12).
Data as JSON: /api/errors/972c7c9e8ed3a768.
Report an issue: GitHub.