HTTP::S...:Message(3)

πŸ“¦
version 0.01 Β· 2 versions
, in fedora 43

πŸ’– HTTP::S...:Message β€” the perl doc for HTTP::Soup::Message πŸ’–

okay bestie, pull up a chair 🫢 you're reading the User Contributed Perl Documentation for HTTP::Soup::Message, and honestly? it's giving networking royalty. this is the object that carries your HTTP messages around like a little ✨messenger bag✨. every method, every property, every signal β€” it's all here. no skips. periodt.


🌸 NAME 🌸

HTTP::Soup::Message β€” that's the whole name, that's the vibe πŸ’…


πŸ¦‹ HIERARCHY πŸ¦‹

it's a Glib object, so it inherits like this:

Glib::Object
+----HTTP::Soup::Message

so yes, HTTP::Soup::Message is a Glib::Object at heart. nepo baby, but make it useful πŸ’œ


✨ METHODS ✨

every one of these returns something, and every one of them takes an optional $val that lets you set stuff too. iykyk.

  • string = $message->method ($val=undef)
    • $val (string)
  • string = $message->reason_phrase ($val=undef)
    • $val (string)
  • messagebody = $message->request_body ($val=undef)
    • $val (HTTP::Soup::MessageBody)
  • messageheaders = $message->request_headers ($val=undef)
    • $val (HTTP::Soup::MessageHeaders)
  • messagebody = $message->response_body ($val=undef)
    • $val (HTTP::Soup::MessageBody)
  • messageheaders = $message->response_headers ($val=undef)
    • $val (HTTP::Soup::MessageHeaders)
  • integer = $message->status_code ($val=0)
    • $val (integer)

no cap, that's the full list of methods. seven of them. each one's an accessor that can also be a mutator when you hand it a $val πŸŽ€


πŸŽ€ PROPERTIES πŸŽ€

these are the properties, bestie β€” the full glam squad. each one shows you its type, its default, and its access flags in that order. read the flags carefully because they tell you whether you can peek, poke, or both πŸ‘€

  • 'first-party' (HTTP::Soup::URI : default undef : readable / writable / private / static-nick / static-blurb) β€” the URI that was loaded in the application back when the message got requested.
  • 'flags' (HTTP::Soup::MessageFlags : default : readable / writable / private / static-nick / static-blurb) β€” assorted message options. yes the default is literally blank in the original, we respect that πŸ’€
  • 'http-version' (HTTP::Soup::HTTPVersion : default "http-1-1" : readable / writable / private / static-nick / static-blurb) β€” which HTTP protocol version we're using.
  • 'is-top-level-navigation' (boolean : default false : readable / writable) β€” true when the current message is navigating between top-levels.
  • 'method' (string : default "GET" : readable / writable / private / static-nick / static-blurb) β€” the message's HTTP method. classic GET energy out of the box.
  • 'priority' (HTTP::Soup::MessagePriority : default "normal" : readable / writable / private / static-nick / static-blurb) β€” how urgent this message thinks it is.
  • 'reason-phrase' (string : default undef : readable / writable / private / static-nick / static-blurb) β€” the HTTP response reason phrase.
  • 'request-body' (HTTP::Soup::MessageBody : default undef : readable / private / static-nick / static-blurb) β€” the HTTP request content. read-only bestie, no touching βœ‹
  • 'request-body-data' (Glib::Bytes : default undef : readable / private / static-nick / static-blurb) β€” the HTTP request body, as raw bytes.
  • 'request-headers' (HTTP::Soup::MessageHeaders : default undef : readable / private / static-nick / static-blurb) β€” the HTTP request headers.
  • 'response-body' (HTTP::Soup::MessageBody : default undef : readable / private / static-nick / static-blurb) β€” the HTTP response content.
  • 'response-body-data' (Glib::Bytes : default undef : readable / private / static-nick / static-blurb) β€” the HTTP response body, as raw bytes.
  • 'response-headers' (HTTP::Soup::MessageHeaders : default undef : readable / private / static-nick / static-blurb) β€” the HTTP response headers.
  • 'server-side' (boolean : default false : readable / writable / construct-only / private / static-nick / static-blurb) β€” whether the message is server-side instead of client-side. note the construct-only flag β€” you set this at construction time or not at all, periodt.
  • 'site-for-cookies' (HTTP::Soup::URI : default undef : readable / writable) β€” the URI to compare cookies against.
  • 'status-code' (Glib::UInt : default 0 : readable / writable / private / static-nick / static-blurb) β€” the HTTP response status code.
  • 'tls-certificate' (Glib::Object::_Unregistered::GTlsCertificate : default undef : readable / writable / private / static-nick / static-blurb) β€” the TLS certificate tied to the message.
  • 'tls-errors' (GTlsCertificateFlags : default ["no-flags"] : readable / writable / private / static-nick / static-blurb) β€” the verification errors on the message's TLS certificate. πŸ‘‘ important.
  • 'uri' (HTTP::Soup::URI : default undef : readable / writable / private / static-nick / static-blurb) β€” the message's Request-URI.

πŸ”₯ SIGNALS πŸ”₯

these fire when stuff happens. each one lists what it carries, so you know what your callback gets handed:

  • content-sniffed (HTTP::Soup::Message, string, GHashTable)
  • finished (HTTP::Soup::Message)
  • got-body (HTTP::Soup::Message)
  • got-chunk (HTTP::Soup::Message, HTTP::Soup::Buffer)
  • got-headers (HTTP::Soup::Message)
  • got-informational (HTTP::Soup::Message)
  • network-event (HTTP::Soup::Message, GSocketClientEvent, Glib::Object::_Unregistered::GIOStream)
  • restarted (HTTP::Soup::Message)
  • starting (HTTP::Soup::Message)
  • wrote-body (HTTP::Soup::Message)
  • wrote-body-data (HTTP::Soup::Message, HTTP::Soup::Buffer)
  • wrote-chunk (HTTP::Soup::Message)
  • wrote-headers (HTTP::Soup::Message)
  • wrote-informational (HTTP::Soup::Message)

the way that's fourteen signals... iconic honestly πŸ¦‹


🌈 ENUMS AND FLAGS 🌈

enum GSocketClientEvent

  • 'resolving' / G_SOCKET_CLIENT_RESOLVING
  • 'resolved' / G_SOCKET_CLIENT_RESOLVED
  • 'connecting' / G_SOCKET_CLIENT_CONNECTING
  • 'connected' / G_SOCKET_CLIENT_CONNECTED
  • 'proxy-negotiating' / G_SOCKET_CLIENT_PROXY_NEGOTIATING
  • 'proxy-negotiated' / G_SOCKET_CLIENT_PROXY_NEGOTIATED
  • 'tls-handshaking' / G_SOCKET_CLIENT_TLS_HANDSHAKING
  • 'tls-handshaked' / G_SOCKET_CLIENT_TLS_HANDSHAKED
  • 'complete' / G_SOCKET_CLIENT_COMPLETE

enum GTlsCertificateFlags

  • 'no-flags' / G_TLS_CERTIFICATE_NO_FLAGS
  • 'unknown-ca' / G_TLS_CERTIFICATE_UNKNOWN_CA
  • 'bad-identity' / G_TLS_CERTIFICATE_BAD_IDENTITY
  • 'not-activated' / G_TLS_CERTIFICATE_NOT_ACTIVATED
  • 'expired' / G_TLS_CERTIFICATE_EXPIRED
  • 'revoked' / G_TLS_CERTIFICATE_REVOKED
  • 'insecure' / G_TLS_CERTIFICATE_INSECURE
  • 'generic-error' / G_TLS_CERTIFICATE_GENERIC_ERROR
  • 'validate-all' / G_TLS_CERTIFICATE_VALIDATE_ALL

enum HTTP::Soup::HTTPVersion

  • 'http-1-0' / SOUP_HTTP_1_0
  • 'http-1-1' / SOUP_HTTP_1_1

flags HTTP::Soup::MessageFlags

  • 'no-redirect' / SOUP_MESSAGE_NO_REDIRECT
  • 'can-rebuild' / SOUP_MESSAGE_CAN_REBUILD
  • 'overwrite-chunks' / SOUP_MESSAGE_OVERWRITE_CHUNKS
  • 'content-decoded' / SOUP_MESSAGE_CONTENT_DECODED
  • 'certificate-trusted' / SOUP_MESSAGE_CERTIFICATE_TRUSTED
  • 'new-connection' / SOUP_MESSAGE_NEW_CONNECTION
  • 'idempotent' / SOUP_MESSAGE_IDEMPOTENT
  • 'ignore-connection-limits' / SOUP_MESSAGE_IGNORE_CONNECTION_LIMITS
  • 'do-not-use-auth-cache' / SOUP_MESSAGE_DO_NOT_USE_AUTH_CACHE

enum HTTP::Soup::MessagePriority

  • 'very-low' / SOUP_MESSAGE_PRIORITY_VERY_LOW
  • 'low' / SOUP_MESSAGE_PRIORITY_LOW
  • 'normal' / SOUP_MESSAGE_PRIORITY_NORMAL
  • 'high' / SOUP_MESSAGE_PRIORITY_HIGH
  • 'very-high' / SOUP_MESSAGE_PRIORITY_VERY_HIGH

🧚 SEE ALSO 🧚

  • HTTP::Soup
  • Glib::Object

go read those next, bestie, they're the supporting cast πŸ’œ


Copyright (C) 2011 by Emmanuel Rodriguez


and that's the whole page, babes ✨ this was perl v5.42.0, dated 2025-07-25, and you just read the HTTP::S...:Message(3) manual from the User Contributed Perl Documentation. slay, you're now officially informed πŸŽ€πŸ’–πŸ«Ά

πŸ“¦ where this page comes from