ESPHome
2024.11.0
|
Data Structures | |
struct | Header |
class | HttpContainer |
class | HttpContainerArduino |
class | HttpContainerIDF |
class | HttpRequestArduino |
class | HttpRequestComponent |
class | HttpRequestIDF |
class | HttpRequestResponseTrigger |
class | HttpRequestSendAction |
class | HttpRequestUpdate |
class | OtaHttpRequestComponent |
class | OtaHttpRequestComponentFlashAction |
Enumerations | |
enum | HttpStatus { HTTP_STATUS_OK = 200, HTTP_STATUS_NO_CONTENT = 204, HTTP_STATUS_PARTIAL_CONTENT = 206, HTTP_STATUS_MULTIPLE_CHOICES = 300, HTTP_STATUS_MOVED_PERMANENTLY = 301, HTTP_STATUS_FOUND = 302, HTTP_STATUS_SEE_OTHER = 303, HTTP_STATUS_NOT_MODIFIED = 304, HTTP_STATUS_TEMPORARY_REDIRECT = 307, HTTP_STATUS_PERMANENT_REDIRECT = 308, HTTP_STATUS_BAD_REQUEST = 400, HTTP_STATUS_UNAUTHORIZED = 401, HTTP_STATUS_FORBIDDEN = 403, HTTP_STATUS_NOT_FOUND = 404, HTTP_STATUS_METHOD_NOT_ALLOWED = 405, HTTP_STATUS_NOT_ACCEPTABLE = 406, HTTP_STATUS_LENGTH_REQUIRED = 411, HTTP_STATUS_INTERNAL_ERROR = 500 } |
enum | OtaHttpRequestError : uint8_t { OTA_MD5_INVALID = 0x10, OTA_BAD_URL = 0x11, OTA_CONNECTION_ERROR = 0x12 } |
Functions | |
bool | is_redirect (int const status) |
Returns true if the HTTP status code is a redirect. More... | |
bool | is_success (int const status) |
Checks if the given HTTP status code indicates a successful request. More... | |
Definition at line 26 of file http_request.h.
enum esphome::http_request::OtaHttpRequestError : uint8_t |
Enumerator | |
---|---|
OTA_MD5_INVALID | |
OTA_BAD_URL | |
OTA_CONNECTION_ERROR |
Definition at line 19 of file ota_http_request.h.
|
inline |
Returns true if the HTTP status code is a redirect.
status | the HTTP status code to check |
Definition at line 59 of file http_request.h.
|
inline |
Checks if the given HTTP status code indicates a successful request.
A successful request is one where the status code is in the range 200-299
status | the HTTP status code to check |
Definition at line 80 of file http_request.h.