StorageRestException
class StorageRestException(error: String, description: String, response: HttpResponse, val statusCode: Int, val code: String) : RestException(source)
Represents an exception thrown if the storage API returns an error response.
Parameters
error
A short error identifier string returned by the API, if available
description
A human-readable description of the error.
statusCode
The HTTP status code returned by the API
code
Service-specific error code from the Storage API response body, such as NoSuchKey, AccessDenied or ResourceAlreadyExists. Use this to branch on the specific error rather than parsing the message. Falls back to error when the server does not send a code. See https://supabase.com/docs/guides/storage/debugging/error-codes for a list of codes.