HTTP 400 · Bad Request
WEBPAGE_CURL_FAILED
Failure while fetching the webpage with cURL.
HTTP 400
Web previews
When & why it happens
Failure while fetching the webpage with cURL. Treated by gogram as a regular API error; inspect ErrResponseCode.Message for the exact code.
Handling in gogram
Surfaced as *gogram.ErrResponseCode. Match on the message:
if err, ok := err.(*gogram.ErrResponseCode); ok {
if err.Message == "WEBPAGE_CURL_FAILED" {
// handle this error
}
}
Related errors
URL_INVALIDInvalid URL provided.WEBDOCUMENT_INVALIDInvalid webdocument URL provided.WEBDOCUMENT_MIME_INVALIDInvalid webdocument mime type provided.WEBDOCUMENT_SIZE_TOO_BIGWebdocument is too big!WEBDOCUMENT_URL_INVALIDThe specified webdocument URL is invalid.WEBPAGE_MEDIA_EMPTYWebpage media empty.WEBPAGE_NOT_FOUNDA preview for the specified webpage url could not be generated.WEBPAGE_URL_INVALIDThe specified webpage url is invalid.