can1357/oh-my-pi · error · Error
vgyme rejected the upload
Error message
vgyme rejected the upload
What it means
The vgy.me upload API returns a JSON payload with an 'error' field; this error is thrown when error is present and not false/null, meaning vgy.me rejected the upload (bad userkey, invalid file, quota, etc.). The message is generic because vgy.me's payload shape does not reliably carry a reason here.
Source
Thrown at packages/coding-agent/src/blob-broker/uploaders-image-hosts.ts:348
const remoteId = typeof image.id === "string" ? image.id : undefined;
return publication("chevereto", request, url, { remoteId });
},
};
}
function createVgymeUploader(config: DestinationRuntimeConfig): BlobUploader {
const userKey = credentialString(config, "userKey");
return {
destination: "vgyme",
async upload(request) {
const response = await fetchFor(config)(VGYME_UPLOAD_URL, {
method: "POST",
body: multipartFile(request, "file", userKey ? { userkey: userKey } : {}),
});
const payload = await jsonResponse(response, "vgyme");
if (payload.error !== false && payload.error !== undefined && payload.error !== null) {
throw new Error("vgyme rejected the upload");
}
const url = directUrl(requiredString(payload, "image", "vgyme"), "vgyme");
const deletionUrl =
typeof payload.delete === "string" && payload.delete ? directUrl(payload.delete, "vgyme") : undefined;
return publication("vgyme", request, url, {
delete: deletionUrl ? { method: "DELETE", url: deletionUrl } : undefined,
remoteId: typeof payload.filename === "string" ? payload.filename : undefined,
});
},
};
}
/** Create a built-in image-host uploader, or `null` for another destination family. */
export function createImageHostUploader(
destination: BlobDestinationId,
config: DestinationRuntimeConfig,
): BlobUploader | null {
switch (destination) {View on GitHub (pinned to 9690622007)
Solutions
- Check the vgy.me userkey option in the destination config is correct and current
- Inspect the response payload's error value for the actual reason
- Try uploading without the userkey (anonymous upload) to isolate the key issue
- Retry later or check vgy.me service status if the payload error is transient
Example fix
// before
if (payload.error !== false && payload.error !== undefined && payload.error !== null) {
throw new Error("vgyme rejected the upload");
}
// after
if (payload.error !== false && payload.error !== undefined && payload.error !== null) {
throw new Error(`vgyme rejected the upload: ${String(payload.error)}`);
} Defensive patterns
Strategy: try-catch
Validate before calling
if (!userKey) console.warn("vgyme: uploading anonymously; provide a valid userkey to avoid quota rejections");
if (!file.type.startsWith("image/")) throw new Error("vgyme only accepts images"); Type guard
function isVgymeSuccess(payload: Record<string, unknown>): boolean {
return payload.error === false || payload.error === undefined || payload.error === null;
} Try / catch
try {
const url = uploadToVgyme(request);
} catch (err) {
if (err instanceof Error && err.message === "vgyme rejected the upload") {
// verify userkey, retry anonymously, or fall back to another host
}
throw err;
} Prevention
- Keep the vgy.me userkey current in destination config
- Only upload supported image formats/types
- Fall back to an alternate image host on rejection
- Log the payload.error value for the underlying reason
When it happens
Trigger: POSTing the multipart upload to VGYME_UPLOAD_URL and receiving a payload where payload.error is a truthy value — e.g. invalid userkey, unsupported file type, or server-side rejection.
Common situations: Expired or wrong vgy.me user key in config, uploading a file type vgy.me disallows, or vgy.me service degradation.
Related errors
- Anthropic file upload returned an invalid expiration time
- Gemini Files API finalized file state is not ACTIVE
- Gemini Files API upload initialization request failed
- Gemini Files API upload initialization failed with HTTP ${st
- Gemini Files API upload initialization response is missing X
AI-assisted analysis of can1357/oh-my-pi@9690622007 (2026-08-31).
Data as JSON: /api/errors/b3c9e01d372ab45c.
Report an issue: GitHub.