mirror of
https://github.com/RGBCube/serenity
synced 2025-05-14 04:44:59 +00:00

This keeps the APIs separate as they are wildly different, a future improvement could be to somehow unify the APIs (if possible). Closes #23080.
20 lines
886 B
Text
20 lines
886 B
Text
#include <AK/URL.h>
|
|
|
|
endpoint RequestClient
|
|
{
|
|
request_started(i32 request_id, IPC::File fd) =|
|
|
request_progress(i32 request_id, Optional<u64> total_size, u64 downloaded_size) =|
|
|
request_finished(i32 request_id, bool success, u64 total_size) =|
|
|
headers_became_available(i32 request_id, HashMap<ByteString,ByteString,CaseInsensitiveStringTraits> response_headers, Optional<u32> status_code) =|
|
|
|
|
// Websocket API
|
|
// FIXME: See if this can be merged with the regular APIs
|
|
websocket_connected(i32 connection_id) =|
|
|
websocket_received(i32 connection_id, bool is_text, ByteBuffer data) =|
|
|
websocket_errored(i32 connection_id, i32 message) =|
|
|
websocket_closed(i32 connection_id, u16 code, ByteString reason, bool clean) =|
|
|
websocket_certificate_requested(i32 request_id) =|
|
|
|
|
// Certificate requests
|
|
certificate_requested(i32 request_id) =|
|
|
}
|